Encyclopaedia Index

### (b) How to create BFC grids

BFC calculations are little different from non-BFC ones in respect of problem set-up. The user has only:-

1. to set BFC=T in (group 6 of) the Q1 file, and
2. to create a suitable body-fitted-coordinate grid.

Body-fitted grids are specified in terms of their cell-corner coordinates in Cartesian space. The typical point is: XC(I,J,K), YC(I,J,K) and ZC(I,J,K).

Here,

• I ranges from 1 to NX+1,
• J from 1 to NY+1, and
• K from 1 to NZ+1,
the NX, NY and NZ being the numbers of cells in the three PHOENICS-coordinate directions.

The correspondence between I, J and K and the control-cell indices IX, IY, IZ is given in the following table, which lists the corner-point indices for the PHOENICS cell IX, IY, IZ:

```
------------------------------------------------------------
Corner          index I       index J       index K
------------------------------------------------------------
low south west        I             J             K
high south west       I             J             K+1
low north west        I             J+1           K
high north west       I             J+1           K+1
low south east        I+1           J             K
high south east       I+1           J             K+1
low north east        I+1           J+1           K
high north east       I+1           J+1           K+1
------------------------------------------------------------
```
The X, Y and Z attached to the control-cell indices IX, IY, IZ have no necessary connection with the XC, YC and ZC of the Cartesian coordinates in body-fitted coordinates and are significant only in the Cartesian and cylindrical-polar grid options.

The XC, YC and ZC arrays can be filled in several ways, separately or in combination, viz:

• by setting individual values (see ARRAY and SETPT for further information);
• by setting values at selected points, and filling the gaps in accordance with either:
• algebraic interpolations or
• a Laplace-equation solver.

• Input-library case b102 shows how this can be done by way of PIL commands.
• Input-library case b966 shows how this can be done by activating Fortran sequences which have been provided, as examples, in gxbfgr.for.
• The relevant parts of the PLANT library contain many examples of how the required Fortran coding can be generated automatically.
• a tutorial

See ARRAY, SEEPTS, SETPT, DOMAIN, SETLIN and MAGIC for further information about the older grid-setting commands.

See GSET for details of the grid-generation commands supplied with version 1.6 and beyond.

See also SUBROU for information on the subroutines which may be called from GROUND for retrieval and setting of coordinate values.

The body-fitted-coordinate option requires, in general, more in-core storage than the Cartesian-coordinate option. Thus, it is often necessary to enlarge the dimensions of the arrays used by the SATELLITE and EARTH programs. See DIMENS for further information.