PLANT is a means of setting the values of variables. This account of the PLANT language and syntax therefore begins, in section 1.5.2, with a list of what variables, and types of variables, can be set via PLANT.
The settings are made by way of PLANT-language statements. It is therefore necessary to explain that these have the form:
and then to describe the components of these statements.
Within the Q1 file, PLANT-related statements are arranged in blocks; and PIL statements may also be included in such blocks. The rules governing the ordering of these statements are explained in section 1.5.
The variables can be used, within the GROUND coding, in several different ways. PLANT enables the user to indicate the use to which they should be put by the inclusion of tags, each of which must have a name and a number.
These concepts are explained in section 1.5.5?.
Unless otherwise qualified, PLANT-made settings prevail at all locations and times within the flow-simulation space. Several settings qualifiers are provided in the PLANT language.
They, and their associated arguments and optional extensions, are described in section 1.5.6 ?.
PLANT can set values of variables of several distinct types,
defined as follows:
Click here for the variable types
The full list of variables, here arranged in the group-by-group manner which is used in Q1 files, is as follows:
Click here for the variable list
Settings are made by inclusion in the Q1 file of lines such as:
VAR=expression
Such lines, comprising an equals sign, the to-be-set variable on the left, and the expression on the right, are called PLANT settings or relationships. Examples are:-
In connexion with the last of these, it should be noted that, since NU
does not feature explicitly in the just-presented list of variables,
it must, if the setting is to be valid, feature implicitly.
This is possible only if NU is recognised by PIL as a full-field
variable, i.e. the subject of a prior PIL statement such as:
STORE(NU) .
It is now time to turn attention to the right-hand-side of the setting statement and to state the rules governing the formation of expressions. This is done in the next sub-section.
An expression, in the present sense, is an algebraic sequence of operands and operators.
The operands which may be used in PLANT expressions can be:-
Note that the arguments must be contained within the square brackets. Obviously, the use of arguments is the more convenient when more than one index shift is needed to reach the neighbour cell from the current one.
The operators, which specify the actions to be performed on the operands, are the same as the arithmetic and intrinsic functions provided by FORTRAN, namely:
Some typical expressions, taken from the Input File Library, now follow:
4186.8*(0.616-.0040428*T1+1.8333e-5*T1**2)
10.*MASS2
XG2D+YG2D
C1**3*TIM**3
RG(1)*(RG(2)**2+H1**2)*(RG(2)+H1)
RG(2)*COS(RG(2)*XG2D)
EXP(-RG(1)*(1.-XG2D))
FLOAT(ISTEP)*AMAX1(AMIN1(1.0,5.-FLOAT(ISTEP)),0.0)
(1.-AMAX1((OLD(TEM1[IG(1),IG(2),])-:TLIM:)/ABS(OLD($
TEM1[IG(3),IG(4),])-:TLIM:),0.))*:ENUL:*2*:RHO1:/DXU2D
Evidently, PLANT expressions can have considerable complexity; for this reason, as is
illustrated by the final example, insertion of the $ sign
is allowed, to signify "continuation" or "word wrap". More than one such sign
is permissible in the same expression.
Some typical PLANT statements, for the moment with tags but without qualifiers, are as follows:
The tags are the quantities contained within the angular brackets, which
precede the variable settings.
Their purpose is to define what kind of setting is being made, in order
that the PLANT Fortran-writing subroutine knows where to place the
corresponding coding.
The significances of the above statements are:
As will be evident from the above explanations, PLANT statements do not stand on their own. Their significances depend on declarations and value ascriptions which have preceded them in the Q1 file, and on COVAL statements which immediately follow.
The connexion with COVALs will be explained in section 1.5.6. First, in section 1.5.5, a full account will be given of all the tags used by PLANT.
The complete list of tags used by PLANT, with brief indications of what kinds of settings they denote, is as follows:
The first four characters after the { comprise the name of the tag.
The ?? which ends the tag is a two-digit number which must be inserted so at to distinguish two settings having the same name.
Further information about these tags, and where they are used is provided in the following table. The items are arranged in the order of the data-input groups which are conventional in the Q1 file.
Data-input group | Tag name | Setting | GROUND group and section | Call location |
2 | SCTS | Time-step | 2 | At the start of each time step |
3 | SCXS | x-grid ratio | 3 | start of slab |
4 | SCYS | y-grid ratio | 4 | ditto |
5 | SCZS | z-grid ratio | 5 | ditto |
6 | MXYZ | BFC corner coordinates | 19, sect 2 | start of sweep |
6 | MXYZ | BFC corner coordinates | 19, sect 7 | finish of sweep |
7 | PRPT | radiation properties | 9, sect 7 | start of hydr. itrtn. |
8 | SCUF | extra velocity | 8, sect 1 | convection-flux calculation |
8 | SCUS | extra velocity | 8, sect 2 | convection-flux calculation |
8 | SCVF | extra velocity | 8, sect 3 | convection-flux calculation |
8 | SCVS | extra velocity | 8, sect 4 | convection-flux calculation |
8 | SCWF | extra velocity | 8, sect 5 | convection-flux calculation |
8 | SCWS | extra velocity | 8, sect 6 | convection-flux calculation |
9 | PRPT | material properties | 9, sect 1 | start of hydr. itrtn. |
10 | PRPT | inter-phase properties | 10, sect 1 to 5 | start of hydr. itrtn. |
10 | PRPT | inter-phase properties | 10, sect 1 to 5 | start of hydr. irtn. |
11 | INIT | initial fields | 11 | at PATCH evaluation time |
13 | SORC | boundary conditions and sources | 13, sect 1 and 12 | at PATCH evaluation time |
14 | SORC | down-stream pressure for parabolic | 13, sect 1 and 12 | at start of slab |
15 to 23 | SC01 | various | 19, sect 1 | start of time step |
15 to 23 | SC02 | various | 19, sect 2 | start of sweep |
15 to 23 | SC03 | various | 19, sect 3 | start of IZ slab |
15 to 23 | SC04 | various | 19, sect 4 | start of iteration |
15 to 23 | SC05 | various | 19, sect 5 | end of iteration |
15 to 23 | SC06 | various | 19, sect 6 | end of IZ slab |
15 to 23 | SC07 | various | 19, sect 7 | end of sweep |
15 to 23 | SC08 | various | 19, sect 8 | end of time step |
15 to 23 | SC09 | various | 19, sect 9 | start of solution |
15 to 23 | SC10 | various | 19, sect 10 | end of solution |
There are PLANT options which are aimed to provide the users with the means to plant the specific codings in a flow domain regions defined in terms of physical space coordinates rather than grid ones.
PLANT can use the grid free distribution of the marker, MARK, over the flow domain as a series of objects fitted in the arbitrarily specified cartesian grid.
The coding which is then PLANTed in GROUND contains logic for the mathematical expression to be tied up with the regions filled by the specific marker property.
The syntax of PATCH and COVAL qualifiers is as follows
PATCH(SSmrkNAM,TYPE,1,NX,1,NY,1,NZ,1,LSTEP)
{SORC01} CO = { expression }
{SORC01} VAL = { expression }
COVAL(SSmrkNAM,V1,GRND,GRND)
Here SS ( Space Source ) stands for special PATCH name characters; mrk stands for the value of the MARK variable which is used to define the region over which expressions should be applied; and the last three characters, NAM, can be used arbitrarily.
Note that PATCH arguments are applied for the whole domain, not for a part of it.
Examples now follow.
Example 1, extracted from Case Y621 of the PLANT library, which should be examined if the full story is required.
PATCH(SS111EAS,EAST,1,NX,1,NY,NZ,NZ,1,LSTEP)
This example shows how SISBC function is used to set automatically (guided by PRPS distribition ) zero-normal stress boundary conditions at the solid 111 -fluid interface as indicated by the PATCH name SS111??.
Example 2, extracted from Case Y619 of the PLANT library, which should be examined if the full story is required.
** Secondary inlet mass flux
PATCH(SS002,WEST,1,NX,1,NY,1,NZ,1,1)
The above example shows how the grid-free PATCH/COVAL qualifiers are used to introduce the number of settings together with interspersed comments of explanation and elaboration.
Many more examples can be found in sections 3 and 4 of this document.
It has been found that in many cases it is very convenient to use the REGION and PLACE qualifiers with reduced numbers of arguments. In what follows the reduced-format options will be described first for REGION and then for PLACE qualifiers.
REGION options are the variants of what follows:
- REGION () is equivalent to REGION(,,,,,,,) and both have the effect of REGION(1,NX,1,NY,1,NZ,1,LSTEP);
- REGION(,,,,,,,8) is equal to REGION(1,NX,1,NY,1,NZ,1,8);
- REGION(,,,,,,7,8) is equal to REGION(1,NX,1,NY,1,NZ,7,8);
- REGION(,,,,,6,7,8) is equal to REGION(1,NX,1,NY,1,6,7,8);
- REGION(,,,,5,6,7,8) is equal to REGION(1,NX,1,NY,5,6,7,8);
- REGION(,,,4,5,6,7,8) is equal to REGION(1,NX,1,4,5,6,7,8);
- REGION(,,3,4,5,6,7,8) is equal to REGION(1,NX,3,4,5,6,7,8);
- REGION(,2,3,4,5,6,7,8) is equal to REGION(1,2,3,4,5,6,7,8);
- REGION(1,2,3,4,5,6,7,8) is equal to REGION(1,2,3,4,5,6,7,8);
- REGION(1,2) is equal to REGION(1,2,1,NY,1,NZ,1,LSTEP).
PLACE options are the variants of what follows:
The above format options are widely used in PLANT library and many more examples can be found in sections 3 and 4 of this document.