The Main Menu is where all the domain-related settings, such as domain size, variables solved, physical properties, numerical and output controls are set. Any source which operates over the whole domain is also set from here.

The main menu is reached by:

- clicking the Main Menu button on the hand-set;
- clicking the icon on the toolbar;
- clicking ' Settings - Domain attributes' on the top bar of the main graphics window; or
- double-clicking the Domain entry in the Object Management Panel.

All these methods bring up the Main Menu top panel.

This is the top panel of the main menu, and can be reached from any other panel by
clicking on **Top menu**. It is the panel displayed whenever the Main menu is activated
from the hand-set, and it is the only panel from which it is possible to return to the
main VR-Editor environment.

Image: TOP PANEL

From the **Top menu** panel, a Title can be set for the current case. This is a text
string up to 40 characters long, which then appears in all the input and output files.

The buttons along the top of the panel allow the setting and modification of the case. In general, it is best to start at the top left, and work from left to right, top row then bottom row, as this minimises the chances of missing out settings.

The (show) 'Less' button is special, in that when pressed it changes to (show) 'More', and all the menu panels show only the most commonly used options. This mode is aimed at beginners and in-frequent users, who do not wish to be swamped with options they may not need. All the images of menu panels are in the full (show) 'more' mode. The mode is recorded in the Q1 file saved at the end of the session, and hence will be used next time the Q1 is loaded.

The buttons perform the following functions:

**Geometry**: Grid settings - co-ordinate systems, steady/transient**Models**: Solution of variables, turbulence models etc.**Properties**: Density, viscosity etc.**Initialisation**: Initial values.**Help**: Help on that panel. Help on individual items is obtained by clicking the ? in the top-right corner of an item.**Top menu**: Go to the top level.**Sources**: Whole-domain sources, e.g. buoyancy.**Numerics**: Solution control settings.**GROUND**: Values for GROUND.**Output**: Print-out and field dumping controls.**OK**: Return to VR-Editor. This button only appears on the top panel.**INFORM**: Start the In-Form Editor.**Domain Faces**: Apply fixed-flow, fixed pressure or friction boundary conditions to selected domain faces or wind velocity profile conditions at all faces.

The Help button on each panel gives a more detailed overview of the functions available from that panel - it links to the relevant section of this document.

Help on individual data-entry boxes and buttons can be obtained by clicking on the '**?'**
in the top-right of the window, and then clicking on the required item.

Some panels contain more lines than can be shown. In such at case, a Page Dn and Line Dn button will appear at the bottom of the panel. These scroll the panel down by a page or a single line to reveal the remaining options. The font and screen resolution influence this, so the menu panels may not appear exactly as depicted here.

The In-Form editor allows commands in the In-Form language to be added to the model. In-Form allows the specification of:

- space and time discretization,
- initial values,
- material properties,
- body shapes and motions,
- sources,
- boundary conditions, and
- special print-out features

by way of formulae placed in the data-input file. The In-Form editor provides a simple interactive means of creating and modifying the formulae.

Clicking the 'INFORM' button on the Top Menu panel brings up a dialog which allows you to select which Inform Save block to create or open.

Image: The In-Form Editor Save block Selector

Once a Save block has been selected,
**'Edit Save block'** will open a file editor to edit the Save block.

Image: The In-Form Editor

When the Q1 is saved, each Save block is written to the corresponding Group of the Q1.

Full details can be found in INFORM: TR 003.

To delete an existing save block, select it from the 'Existing save blocks' list and click 'Edit Save block'. In the file editor delete the entire block including the 'save begin' and 'save end' lines, then save and exit. The block will no longer appear in the 'Existing blocks' list and will re-appear in the 'All Save blocks list.

Clicking on this button brings up a dialog from which boundary conditions can be applied to entire domain faces.

Xmin, Xmax, Ymin, Ymax, Zmin, Zmax denote the opposite faces of the domain in the X, Y and Z directions. The available options are:

**Wall Yes**- create a PLATE object at this domain face. The name (for X) will be DOM_XMIN_W or DOM_XMAX_W**Open Ye**s - create an OUTLET object at this domain face. The name (for X) will be DOM_XMIN_O or DOM_XMAX_O**Flow Yes**- create an INLET object at this domain face. The name (for X) will be DOM_XMIN_I or DOM_XMAX_I**Settings**- opens the attributes dialog of the chosen domain-face object.

These objects will appear on the screen, and will be listed in the Object Management Panel.The default names for these objects can be changed from the Object Specification dialogs as for any other object.

At a face, these options are mutually exclusive - selecting one will deselect any other selection. The objects are created with default attributes. The user must ensure that any non-default values, such as an inlet velocity or wall surface temperature, are set by opening the attribute dialogs for these objects and setting any required values.

Any PLATE, OUTLET or INLET objects which cover the entire face of the domain will be recognised as domain-face, and will cause the appropriate flags to be set to Yes on the above dialog.

For external wind-driven flows it will often be much easier to activate the WIND object.

The function of the WIND object is to provide boundary conditions representing the atmospheric boundary layer due to the wind at all faces of the domain in a self-consistent manner. The following conditions are applied:

- At upwind domain faces a fixed mass flow condition is applied,
- At downwind domain faces a fixed pressure boundary is applied,
- At the upper face of the domain (the sky), a fixed pressure boundary is applied with diffusive links to the velocity and turbulence quantities at that height, and
- optionally a friction condition can be applied at the lower face to represent the ground.

Image: GEOMETRY

For Cartesian and Polar co-ordinates, this is the same dialog that is displayed by
clicking on the **Grid mesh** button on the hand-set, then clicking on the mesh region to be
changed. Region 1 in each direction is initially selected. Descriptions of how to modify
the mesh are given in VR-Editor
Hand-set, Mesh Toggle, and in Space
and Time grids.

The settings are:

**Co-ordinate system:**Toggles between Cartesian, cylindrical-polar and Body-Fitted (BFC).**Time dependence:**Toggles between Steady and Transient**Inner radius**(only for cylindrical-polar)**:**Sets the inner radius for a cylindrical-polar grid.**Time step settings**(only for transient): Displays a dialog for managing the time-step distribution.**Partial solids treatment**(only for Cartesian or Polar): This toggles between SPARSOL (the default), PARSOL and Off.**Partial solids treatment settings**: This displays a dialog from which the minimum and maximum fluid volume fractions for PARSOL can be set. Any cell in which the fluid volume fraction is below the minimum value is considered fully-blocked, and any cell in which it is above the maximum is considered full-open. The default values are 0.001 and 0.999. Resetting these to, say, 0.01 and 0.99 can eliminate very small fluid cut-cells, which can lead to unrealistic pressures.**Auto Meshing:**Toggles between auto and manual meshing in each of the domain directions.**Domain size:**Sets the total extent of the domain in the X, Y and Z directions. In cylindrical-polar co-ordinates, the X size is set in radians.**Domain origin:**Sets the coordinates of the origin of the domain. This need not be (0.0, 0.0, 0.0) and can be negative.**Number of cells:**Sets the total number of cells in the X, Y and Z directions. If all regions are 'Set', or the grid is 'auto' this value cannot be changed directly as there are no 'Free' regions to accommodate the change.**Tolerance:**Sets the tolerance in each direction (in the same units as the domain dimension, usually meters) used for matching the grid to objects.**Number of regions:**This displays the current number of regions in each direction. This can only be changed by modifying objects or modifying the tolerance.**Modify region:**This is the number of the region selected for modification. In the diagram above, an X-Z plane is displayed, and the cursor was clicked into the first region in X, and the first region in Z. To modify a different region, enter its number here directly and click 'Apply', or click OK, then click on the new region.**Size:**This displays the size (in meters or radians) of the region selected for modification. The size of a region can only be changed by modifying objects or modifying the tolerance.-
**Distribution:**This toggles between**Power law**and**Geometrical progression**. It controls how the cells within the region are spaced. -
**Cell Power:**This toggles between**Free**and**Set**.**Free**means that the number of cells can be automatically adjusted as the total number of cells is changed, so as to keep the grid as uniform as possible.**Set**means that the number of cells in this region, and their distribution, have been set by the user (or Auto-mesher) and cannot be automatically changed. -
**Cells in region:**This initially displays the number of cells allocated to this region by the automatic meshing algorithm. When the automatic meshing is turned off, the number of cells in this region can be changed by typing in a different value. Cells will be taken from, or distributed amongst other 'Free' regions to keep the total number constant. **Power/ratio:**This sets the expansion power, or geometric expansion common ratio. The default setting of 1.0 gives a uniform mesh. Positive values mean that the expansion goes from the start of the region towards the end, negative values mean the expansion starts at the end and goes to the beginning.**Symmetric:**This toggles between**No**and**Yes**. If Yes, the expansion specified by Distribution and Power/ratio is applied symmetrically from each end of the region.**Edit all regions:**This displays a dialog which shows all the region settings in a particular direction and allows them to be changed. This is where the Auto-meshing parameters can be adjusted.

For Body-Fitted Co-ordinates, changes to the grid are made in the BFC menu.

This panel controls the variables to be solved, and the models used.

Image: MODELS

Equation formulation, Simulation is, Lagrangian Particle Tracker (GENTRA), Solution for velocity and pressure, Free-surface models, Energy equation, Turbulence models, Radiation models, Combustion Models, Mean Age of Air, Solution control / Extra variables, Advanced user Options

**Models - Equation Formulation**This allows the formulation of the equations to be chosen. The options are:

- Elliptic_Staggered
- Elliptic_GCV
- Elliptic_CCM
- Parabolic
- Fully_developed

The main choice is between elliptic, parabolic and fully-developed. Elliptic is the most usual form, as it allows for recirculation.

There is a further choice of staggered or collocated velocity formulation. In the staggered formulation, velocities are stored at cell face centres, in the collocated form they are stored at cell centres, just like pressure and temperature.

The staggered form is usually best for Cartesian and polar grids, the GCV collocated for BFC. See also the CCM entry in the PHOENICS Encyclopaedia.

Parabolic performs a marching integration suitable for flows with no recirculation, e.g. developing pipe flows or jet spreading.

Fully-developed calculations will give the flow rate for a given pressure-drop, or the pressure-drop for a given flow, without any information on how the flow developed.

**Models - Single / Multi-Phase**This option switches between single and multi-phase operation. If the domain is occupied by a single fluid, which does not change phase, or by several fluids which ARE ALWAYS SEPARATED by solid, the flow can be treated as single phase. If the fluid changes phase, or there are several MIXED fluids, then the flow must be treated as multi-phase.

The available options are:

**One phase**only one phase present (or several completely separated fluids).**IPSA Full**. This solves the full momentum equations for two phases, allowing for inter-phase heat and mass transfer.**IPSA Equal vel**. This assumes that the velocities of the two phases are always equal, but allows inter-phase heat and mass transfer.**Algebraic Slip**. This solves reduced equations for several dispersed phases in a carrier. Inter-phase heat and mass transfer are not included.

The Encyclopaedia entry on Multi-phase flow gives more details.

**Models - Lagrangian Particle Tracker (GENTRA)**This activates the GENTRA Lagrangian particle tracker, which is described in The Gentra User Guide TR/211. The particle tracker is an alternative way of treating multi-phase flows. It is suitable for dilute suspensions, where volume-fraction effects are small. Packets of particles are tracked through the domain. Each packet represents a large number of particles following this path. The particles can exchange heat, mass and momentum with the carrier fluid.

**Models - Pressure And Velocity**This option switches ON or OFF the solution for the pressure variable P1, and the velocities U1, V1 and W1 (depending on the dimensionality of the problem). If the simulation is two-phase, then the second phase velocities U2, V2 and W2 will also be activated. If the grid dimensionality is changed later, the required velocity component( s) will be added or removed as needed.

Pressure and velocity must be

**ON**before it becomes possible to select Multi-Phase or Free-Surface models.**Models - Solution For Swirl**If the geometry is axi-symmetrical (two dimensional in the Y-Z plane), this option switches on the solution for the swirl component of velocity. (This button is only present for cylindrical-polar geometries.)

**Models - Free Surface Models**The available free surface models are:

- Volume Of Fluid
- CICSAM - (Compressive Interface Capturing Scheme for Arbitrary Meshes)
- HRIC - (High Resolution Interface Capturing Scheme)
- MHRIC - (Modified HRIC)
- STACS - (Switching Technique for Advection and Capturing of Surfaces)
- THINC - (Tangent of Hyperbola for INterface Capturing)

- Scalar equation
- Height of liquid

VOF retains the sharpness of the interface well.

The Scalar Equation Method (SEM) is a simplified VOF which does not preserve the interface so well, but may run slightly faster.

Both VOF and SEM are good for overturning or breaking interfaces, but are restricted to very small time steps.

The VOF schemes, especially STACS can tolerate bigger time steps than SEM.

Height of Liquid (HOL) can run steady-state, or with larger time steps but cannot deal with overturning interfaces.

See also the POLIS entries on Volume of Fluid and Scalar Equation Method and Height of Liquid.

- Volume Of Fluid
**Models - Energy Equation**The energy equation can be solved in one of two forms:

- Temperature (TEM1/TEM2), or
- Enthalpy (H1/H2)

The enthalpy form is often more suited to combustion applications, the temperature form to conjugate heat transfer. Internally, the equation is always cast in enthalpy form, so the units of the sources are always Watts.

**Models - Energy Equation, Total/Static**By default, the Temperature form is set to 'Total', the enthalpy form to 'Static'. The static form includes the substantial derivative of the pressure and the kinetic heating terms in the energy conservation equation as additional source terms, the Total form does not.

If the flow is highly compressible (high Mach number) the Temperature form should be switched to 'Static' otherwise incorrect solutions will be obtained. This is because all the property formulae require the static temperature.

The Enthalpy form can be used in 'Total' form as long as a suitable temperature derivation is selected in the properties panel.

**Models - Turbulence Models**The available turbulence models are divided into the following groups:

- LAMINAR - The flow is laminar and there is no turbulence model.
- CONSTANT-EFFECTIVE - The turbulent viscosity is constant. The default setting is 200 times the laminar viscosity.
- LVEL - Generalised length-scale zero-equation model, useful when there are many objects and the grid is coarse.
- USER - User-defined model for advanced users.

- KE Variants - Several variants of the K-E model usually giving enhanced performance for
recirculating flow.
- KECHEN - Chen-Kim two-equation k-e model. Gives better prediction of separation and vortexes. (This is the default turbulence model).
- KEREAL - Realisable K-E model. Gives better prediction of separation and vortexes.
- KERNG - RNG derived two-equation k-e model. Gives better prediction of separation and vortexes. However, the user is advised that the model results in substantial deterioration in the prediction of plane and round free jets in stagnant surroundings.
- KEMODL - Classical two-equation high Reynolds number k-e model.
- KEMMK - Murakami, Mochida and Kondo k-e model for flow around bluff bodies as encountered for example in wind-engineering applications.
- KEKL - Kato-Launder k-e model for flow around bluff bodies as encountered for example in wind-engineering applications.
- KEMODL-YAP - k-e model with Yap correction for separated flows.
- TSKEMO - Two scale k-e model for flows in which there is an appreciable time lag between the turbulent production and dissipation processes.

- Low-Re KE models - Several Low-Reynolds Number variants of the K-E model.
- KECHEN-LOWRE - Low Reynolds variant of Chen-Kim model.
- KEMODL-LOWRE - Lam-Bremhorst low Reynolds version of k-ε.
- KEMODL-LOWRE-YAP - Lam-Bremhorst low Reynolds k-ε with Yap correction for separated flows.
- KEMODL-2L - Two layer k- ε model, which uses the high-Re k-ε model only away from the wall in the fully-turbulent region, and the near-wall viscosity- affected layer is resolved with a one-equation model involving a length-scale prescription. This saves mesh points and improves convergence rates.

- Kω Variants - Several variants of the K-ω model
- Low-Re Kω models - Several Low-Reynolds Number variants of the K-ω model.
- KWMODL-LOWRE - Low Reynolds Wilcox model.
- KWMENTER-LOWRE - Low Reynolds Menter (1992) k-ω model
- KWSST-LOWRE - Low Reynolds k-ω SST model

- Sub-grid-scale LES Models
- SGSMOD - Smagorinsky sub-grid scale LES model with wall damping
- SGSMOD_NOWD - Smagorinsky sub-grid scale LES model with no wall damping
- SGSMOD_VDWD - with Van Driest wall damping function

- Others- A range of models, from simple one-equation models to Reynolds Stress (REYSTRS),
including a Sub-Grid-Scale LES model (SGSMOD).
- MIXLEN - Prandtl mixing-length model. Simple model for unbounded flows.
- MIXLEN-RICE - Mixing-length model for bubble-column reactors.
- KLMODL - Prandtl energy model. One-equation k-l model for wall-dominated flows.
- KVMODL - Saffman-Spalding two-equation. k-vorticity model
- REYSTRS - Reynolds stress model

All models are described in the POLIS Encyclopaedia under ' Turbulence', where each has its own descriptive article.

**Brief advice**: use the simplest model which produces realistic results. In many cases, the CHEN-KIM model provides a reasonable compromise between accuracy and economy. If there are many walls (obstacles) present, the LVEL model will be even more economical, and also more accurate for coarse grids.**Models - Radiation Models**The following radiation models are available:

They are described in full in the PHOENICS Encyclopaedia under ' Radiative Heat Transfer in PHOENICS'.

**WARNING:**The 6-Flux and Radiosity models are not fully implemented in the Menu, especially with regard to the boundary conditions or conjugate heat transfer. Please use the ' User-defined' object attribute to set the boundary conditions described in POLIS. The IMMERSOL and P-1 T3 models**are**fully implemented.**Models - Combustion Models**The following combustion models are available:

**3_GASES**- Simple Chemically-Reacting System (SCRS), mixing controlled or kinetically controlled**7_GASES**-Extended SCRS**Wood**- Wood combustion model**Coal**- Coal combustion model**Oil**- Oil combustion model**Chemkin**- Interface to Sandia Labs CHEMKIN program

They are described in the PHOENICS Encyclopaedia under: ' Combustion', ' Reaction', ' SCRS', ' Extended Simple Chemically-reacting System',' CHEMKIN Interface'. There are examples in the 'Chemical-reaction library'.

**WARNING:**Only the 3_GASES model is fully implemented in the Menu. The remaining models are not yet implemented in the Menu. Solution of the required variables can be activated through the Solution control - Extra variables button below.Please use the 'User-defined' object attribute to set the boundary conditions described in POLIS.

**Models - Mean Age of Air**The AGE variable represents an estimate of the 'time since entry'. It is obtained by solving for a tracer, named AGE, which has a uniform source of 1/m

^{3}/s, and is zero at all inflow boundaries. If the flow were one-dimensional and steady, AGE would be equal to the time spent by local air particles in traveling from the entrance to the point in question.**Models - Solution Control / Extra Variables**

Image: SOLUTION CONTROL / EXTRA VARIABLESThis panel gives options to:

- Activate storage of user-named variables - enter a name up to 4 characters in STORE box and click 'Apply'. Several names separated by ',' can be entered.
- Activate solution of user-named variables - enter a name up to 4 characters in SOLVE box and click 'Apply'. Several names separated by ',' can be entered.
- Set the solution control switches (SOLUTN command) for all stored and solved variables.
The settings are:
- Storage - create a 3D store which then appears in the solution file PHI for plotting.
- Solution - solve the variable (implies STORE).
- Whole-field - solve using whole-field solver when Y, solve using slab-wise solver when N.
- Point-by-point - solve using point-by-point solver when Y, solve using slab-wise or whole-field solver when N.
- Explicit - use explicit formulation for transient term when Y, implicit formulation when N.
- Harmonic - use harmonic averaging for diffusion coefficients when Y, arithmetic averaging when N.
- Solver type - select the linear-equation solver (and pre-conditioner) to use for each variable. Please see the POLIS entry on Solvers(and Pre-conditioners) for more details.

- Set the terms in the equation for each variable (TERMS command). The settings, which are on a separate panel, are: Built-in source, Convection, Diffusion, Transient, Phase 1 variable, Interphase transfer.

See the POLIS Encyclopaedia entries on SOLUTN and TERMS for more information.

**Models - Advanced User Options**This panel gives access to PIL settings from Groups 7 and 8 which are not covered by the other sub-menus of this panel.

From this panel, the main domain material can be chosen from the CHAM-supplied property libraries.

The domain material is the material that initially fills the entire solution domain. Regions of the domain can then be filled with other fluids or solids by creating BLOCKAGE objects, and selecting the required material for them.

The individual properties loaded from the library for the domain fluid can then be edited - changed. This is not possible for the properties used for blockages. If a blockage is assigned the ' domain material', it will automatically pick up the properties specified here.

The reference pressure and temperature values are always added to the calculated pressure and temperature before use in property calculations. The reference temperature is set by choosing Centigrade (reference temperature is 273) or Kelvin (reference temperature is 0) for 'Temperature units'.

Image: PROPERTIES using Property Tables

The 'Ambient pressure' and 'Ambient temperature' entries set the pressure and temperature prevailing outside the domain. These values can be used, if desired, to set the pressure and temperature at all INLET, WIND, WIND_PROFILE, OUTLET, FAN and PRESSURE_RELIEF objects.

When 'Initialise from ambient' is set ON (the default), the initial values of pressure (P1) and temperature (TEM1) are always made consistent with the ambient values set here.

When 'Set buoyancy from ambient' is ON (the default), the reference temperature for Boussinesq buoyancy is set to the ambient temperature, or for density_difference buoyancy, the reference density is calculated from the ambient pressure and temperature.

The 'Property storage' button allows the field values of the properties to be placed in the EARTH output file PHI, so that they can be plotted in the viewer.

Turning the property tables OFF allows the individual properties to be set directly.

Image: PROPERTIES not using Property Tables

This panel is also accessed from the **Edit properties of current material**
button on the previous figure. For each property, a pull-down list of all available
options is provided. The available options are listed in Encyclopaedia.

Image: INITIALISATION

This panel provides options to:

- Activate a restart run
- Set all initial values to default. This is 1.0E-10 for all variables except:
- R1, R2, RS : 0.5
- EPOR, NPOR, HPOR, VPOR : 1.0
- PRPS : -1.0

- Set individual whole-domain initial values for all stored and solved variables. If 'Initialise from ambient' is ON on the Properties panel, the initial values of pressure (P1) and temperature (TEM1) will be grayed out and set to 'AMBIENT', as they will be taken from the ambient values. To enter other values, 'Initialise from ambient' must be set to OFF.

Unless explicitly set in this panel (or set to ambient), initial values for Temperature, Enthalpy, turbulence model quantities and solved-for passive scalars will be taken from the inlet values supplied at the first inlet defined.

NB. When solving for passive scalars where there is one inlet with a finite inlet value and one or more inlets or outlets with a value of 0.0 it can be important to set the initial value explicitly to 0.0, in case the domain is initialised to the finite inlet value.

If the inlet value of a scalar is 1.0, but the majority of the domain is filled with scalar=0.0, it is very important to explicitly initialise the relevant scalar(s) to zero.

If there are more than five stored/solved variables, the > (and <) buttons can be used to scroll through all available variables.

Although the names of the restart and cut-cell files may be displayed as upper-case, the Earth solver will convert them to lower-case.

If 'Restart cut-cell values' is set to NO, the values in the cut cells will retain their initial values as set here on restart, and the named file will not be read. This is useful when restarting a PARSOL=T run from a PARSOL=F run when the pbcl.dat file will be empty. It can also help avoid problems restarting parallel runs when the processors cannot agree on how many cut cells there are.

Image: SOURCES Panel

This panel allows the creation of whole-domain sources, which are **not**
attached to an object. All sources or boundary conditions which do not apply to the whole
domain must be attached to an object, and set through the appropriate object attribute dialog
box.

The '**Cyclic boundary conditions**' button gives the options:

- Turn cyclic boundaries ON for all IZ slabs
- Turn cyclic boundaries OFF for all IZ slabs
- Turn cyclic boundaries on and off for individual slabs.

Cyclic boundaries are then imposed between the first and last rows of cells in the IX direction, for the slabs indicated.

The **MOFOR ON/OFF** button (which only appears for Transient cases) activates the Moving Frames Of Reference model,
which allows objects to move through the domain. When turned ON, two extra buttons are
displayed. One allows the user to browse for the MOF file, and the other to edit it using
the currently-selected file editor. The MOF file controls the motion of the objects. For
more details, click here.

**Use Earth-Generated Wall Functions** when set to T causes the Earth solver to apply
wall function boundary conditions on
all exposed faces of all solids without the need for any explicit PATCH commands.

**Coeff. for auto wall functions**. This selects the type of turbulent wall function
used to calculate shear stress and heat transfer on PLATE and BLOCKAGE objects. The options
are:

- Blasius power law
- Logarithmic law of the wall
- Generalised law of the wall
- Fully-rough wall function

Option 2 is the default. Option 3 will give better heat transfer coefficients at re-attachment points. Option 4 is suitable for atmospheric boundary layers.

**Global wall roughness**

For the Log-Law and general log-law wall functions, this is the absolute 'sand-grain roughness' size for rough walls, according to the formula of Nikuradse.

Typical values of sand-grain size for pipe materials are:

Copper, brass 0.0000305 - 0.0009 Wrought iron, steel 0.000046 - 0.0024 Asphalted cast iron 0.0001 - 0.0021 Galvanised iron 0.000102 - 0.0046 Cast iron 0.0002 - 0.0055 Concrete 0.0003 - 0.003 Uncoated cast iron 0.000226 Coated cast iron 0.000102 Coated spun iron 0.000056 Cement 0.0004 - 0.0012 Wrought iron 0.00005 Uncoated steel 0.000028 Coated steel 0.000058 Wood stave 0.0002 - 0.0009 PVC 0.0000015

For fully-rough wall functions, it is the effective roughness height. Typical values of effective roughness height are:

Open flat terrain, grass, few isolated obstacles 0.03 Open sea 0.0002 Low crops, occasional large obstacles 0.10 High crops, scattered obstacles 0.25 Parkland, bushes, numerous obstacles 0.50 Suburb, forest, regular large obstacle coverage 0.50 to 1.0

This value is used for all blockages, and all plates which do not have their own value set.

**Scalable Wall functions**. The scalable wall function
attempts to prevent the deterioration of wall shear-stress accuracy as the mesh is refined.

In wall cells the Y+ values are prevented from
falling below the critical value of Y+_{c}. The shear
stress is calculated as if Y+ was Y+_{c}.

The critical Y+ can be set in 'Turbulence models', 'Settings'. The default value is 11.126.

The panel also allows built-in whole-field sources to be set, such as:

- Buoyancy (Gravitational forces)

The following buoyancy options are available

- Constant
- Density_difference
- Boussinesq Approximation
- Linear_in_2_scalars
All are described in the Encyclopaedia under 'Gravitational body forces'. In brief:

Option 1 applies the full gravitational force

Option 2 uses a reference density, and should be used if the density is not constant;

Option 3 uses a reference temperature, and should be used if the density is constant but the temperature is variable

Option 4 allows the buoyancy force to be a function of any two solved scalars.

If 'Set buoyancy from ambient' on the Properties panel is set to ON, the values needed for Options 2 and 3 will be taken from the ambient temperature and pressure set there.

To create a new whole-field source click on '**Advanced settings PIL**'.
If this is not visible ,click on '**Page down**' to show the next page of
options.

Image: WHOLE FIELD SOURCES

Enter the name of the PATCH in the '**New**'
box and click '**Apply**'. A new PATCH will be created; the Type, Coefficient and Value can now be set as
required. Clicking on **PATCH number** will cycle through the available Patches. The **>**
(and **<**) symbol next to **Variable** scrolls through the list of available
variables, if there are more than five.

Image: NUMERICS

The main entries on this panel allow the total number of iterations ( sweeps) over the whole domain, and the global convergence criterion to be set.

In transient cases, the 'Vary with time' button leads to a dialog from which the number of sweeps per time step can be changed with time or time step. Up to 15 bands of sweep settings can be made. If more are required, or the conditions for variation are more complex InForm can be used.

The submenus give options to:

- Set relaxations
- Set more detailed iteration control and select solver type
- Set upper and lower limits on the values allowed for variables
- Select higher-order differencing schemes for convection

**Numerics - Relaxation Settings**

Image: Default RELAXATION SETTINGS

Relaxation is a technique for slowing down possibly excessive rates of change. It does not affect the final solution. In many cases, convergence will be very hard to obtain without suitable relaxation settings. The relaxation methods available are described in the Encyclopaedia article on RELAX.

The default relaxation settings turn the Automatic Convergence Control (CONWIZ=T in the Q1) ON.

**Factor** sets the relaxation factor for the variable in question. When Automatic
ConvergenceControl is ON, only linear relaxation can be used for Pressure and velocity. For the
remaining scalars, false-time step relaxation can be used, though usually linear is preferred.

**Max increment** sets the maximum increment (change) from iteration to iteration
for each variable.

**Reference velocity** sets a typical velocity in the domain (usually
based on a typical inlet velocity)

**Reference length** is a typical length scale for the case, usually based
on the domain size.

The two reference quantities are used to estimate an initial timescale. In many cases, the default values work quite well. For large-scale external aerodynamics, for example flow over a city, where the domain may be kilometers in size it can be very important to set the reference length to an average domain size otherwise convergence may be unacceptably slow. The WIND object will do this automatically, otherwise the user should do so manually.

In this mode, any false time step settings for velocities are ignored - the solver will set linear relaxation of 0.5 for all velocities that have false time step relaxation. If the relaxation for velocities is switched to LINEAR, the user-set values will be used.

If no settings are made for the other variables, the solver will set linear relaxation of 0.5, except Temperature (TEM1) which is set to 0.25.

For fire simulations, the maximum increment for temperature (TEM1) should be reduced from the default value of 50°/sweep to, say, 10°/sweep, otherwise convergence may still be difficult. If the expected velocities are very small, the maximum increments for the velocity components should also be reduced. If a FIRE object (only available in FLAIR) is detected, and the relaxation for TEM1 is the default (no user setting has been made), the maximum increment for Temperature is automatically reduced to 10°/sweep.

'**Reset solution defaults**' resets all the solver control variables to
their default values, so that the Automatic Convergence Control can operate in full.

If the Automatic Convergence Control is turned off, the relaxation settings can be set individually.

Image: Manual RELAXATION SETTINGS

Typical values for false time step relaxation may be estimated from the governing time-scale of the process under consideration. Very often, values based on residence time work well. These can be calculated from:

Domain residence time ~ Domain length / Inlet velocity

Cell residence time ~ Domain length / Inlet velocity / Number of cells

False time step values within an order of magnitude of these will usually be effective.

For the velocity variables, it can be advantageous to use the Self-Adjusting Relaxation AlgoritHm (SARAH). This is activated by setting SARAH to a value > 0. Values around 1.0 have been found to work well.

False time step relaxation can be applied to all SOLVEd variables, except Pressure, by setting the 'Relaxation' flag to FALSDT. False time step values are trapped to always be greater or equal to zero.

Linear relaxation can be applied to any SOLVEd or STOREd variable by setting the RELAX flag to LINEAR. A value of 0.0 implies no change will be allowed, 1.0 will allow the full change to take place. Linear relaxation values are trapped to lie in the range 0.0 < value < 1.0

In BFC, linear relaxation of Pressure of the order 0.7 or less is often required.

The default values of the maximum increments (1.0E20) ensure that no limitation is applied. Any value less than that set here will be passed to the Earth solver. If large energy sources are present, it can help convergence to limit the changes in TEM1 to <50°/sweep as well as imposing physical upper and lower limits.

Image: ITERATION CONTROL

The POLIS Encyclopaedia entries on the individual items explain their function.

The default linear equation solver is based on Stone's Strongly Implicit method. To use the Conjugate - Residuals - Gradient solver for any variable, set ENDIT for that variable to GRND1. Circumstances under which this may be advantageous include:

- Pressure correction equation (P1) in buoyancy-driven flows, especially with complex geometry; and
- Temperature (TEM1) in complex conjugate heat transfer cases (except when PARSOL is active).

**Numerics - Limits on Variables**

Image: LIMITS ON VARIABLES

This panel allows minimum and maximum values for all SOLVEd and STOREd variables to be set. The POLIS Encyclopaedia entries on the individual items (VARMIN, VARMAX) explain their function.

**Numerics - Differencing Schemes**

By default, the selected differencing scheme applies to all SOLVEd variables. The default scheme is the HYBRID scheme.

Image: DIFFERENCING SCHEMES 1

Clicking on '**Set schemes individually**' allows the selection of
different schemes for different variables.

Image: DIFFERENCING SCHEMES 2

The complete list of scheme names is:

LUS FROMM CUS QUICK CDS SMART KOREN VANL1 HQUICK OSPRE VANL2 VANALB MINMOD SUPBEE UMIST HCUS CHARM

These are described in the POLIS Encyclopaedia entry SCHEMES FOR CONVECTION DISCRETIZATION.

This panel sets special variables for use in GROUND. The switch for PLANT is also on this panel.

Image: OUTPUT

This panel gives options to:

- Control the solver convergence_monitoring output and monitor update frequency;
- Control the solver end-of-run behaviour.
- Control how the convergence monitoring information is displayed;
- Set field print out controls.
- Select the frequency of field-dumping in terms of sweeps for steady-state cases, or time-steps for transient cases, and select which variables are written to the save file.
- Activate storage of derived quantities and print-out of wall function information.
- Activate the calculation and printing of forces and moments on objects.

This has three settings:

- Default - obey the settings in CHAM.INI
- On - always stop at the end of the run and wait for OK, whatever is in CHAM.INI
- Off - never stop at the end of the run, whatever is in CHAM.INI.

The solver can display convergence-monitoring information on the screen as graphs of:

- Spot values and residuals vs. sweep (the default)
- Maximum absolute correction and residual
- Minimum and maximum field values vs. sweep
- Maximum absolute correction and nett sum of sources vs. sweep

**Output - Print to RESULT file settings**

Image: PRINT TO RESULT

This panel controls whether the initial fields are to be printed, and whether to suppress the printout of the flow fields.

If 'Suppress all field printout' is ticked, the field printouts will be suppressed but the OUTPUT flags will not be changed, so that settings are not lost should the suppression be removed. In the Q1 this appears as

SPEDAT(SET,OUTPUT,NOFIELD,L,T)

in Group 19. The main reason for suppressing the printout is to reduce the size of the RESULT file for huge cases.

If 'Output MINIRES file' is un-ticked, the Earth solver will not produce the condensed convergence report file minires.htm at the end of the run. In the Q1 this appears as

SPEDAT(SET,GXMONI,MINIRES,L,F)

in Group 19.

Finer control over the printout is available on the **Advanced settings panel**:

Image: DETAILED PRINT TO RESULT

The settings are equivalent to arguments 1,2,4,5 & 6 of OUTPUT:

- Field print-out?
- Correction-equation monitor print-out?
- Whole-field residual print-out?
- Spot-value table and/or plot?
- Residual table or plot?

The POLIS Encyclopaedia entries on the individual items explain their function.

**Output - Write flow field settings**

Image: INTERMEDIATE DUMPS - OFF

Once Intermediate field dumps are switched ON, this controls the sweep (for steady-state) or time-step (for transient) frequency with which flow fields are written to disk file.

Image: INTERMEDIATE DUMPS - ON

The setting for 'Dump to file' for each variable determines whether that variable is written to the saved file or not. This can potentially save a lot of disk space by only writing the variables of real interest, but would also prevent such a 'thinned-out' file from being used as an Earth restart file.

In steady cases, the start letter for the dumped intermediate files is set to S.

In transient cases, intermediate flow fields can be dumped at regular time-step intervals. The names of these files are generated from a user-supplied letter, and the step number - e.g. A100. If the base name ends in 'IN', e.g. AIN, then the initial conditions are written to A0, and the Viewer will start the transient display at time t=0.

Note that if the start letter(s) are set to SW for a transient case, files will be
dumped for the requested sweeps of the current step, **not** the final fields at the
end of the time steps. Thus S1, S2, S3 etc will be the solutions of sweep 1, sweep 2,
sweep 3 of the current time step, and will be overwritten on the next time step. This is
intended as a debugging device to aid the investigation of poor convergence at a
particular step.

The letter Q cannot be used as a base for saved intermediate files as there will be a danger of overwriting the Q1 input file!

If the case is one- or two-dimensional in X and Y (i.e. NZ=1), leaving the start-letter blank causes Earth to write out a special file called PARPHI, in which the Z direction is used for time. Each Z plane is the solution for that time step.

If PARSOL is active, a cut-cell data file will be produced at the same time as the intermediate flow field file. The names of these files are generated as PBC<letter><number> - e.g. PBCA100.

Although the names of output and intermediate files may be displayed as upper-case, the Earth solver will convert them to lower-case.

By default, field dumping starts at the first sweep or step, and continues throughout the
run. The **Limits** button leads to a screen on which the first and last sweep or step for
dumping can be set. It is very rarely necessary to set such limits, and users are advised not
to do so unless specifically required.

Image: DERIVED VARIABLE panel

Placing the Skin friction coefficient, Stanton Number, Shear stress (actually friction
velocity squared, equivalent to shear stress divided by density), Yplus (non-dimensional
distance to the wall) and heat transfer coefficient (in W/m^{2}/K) into 3-D
storage allows them to be plotted in the Viewer or PHOTON, as well as appearing in the
RESULT file.

Note that the heat-transfer coefficients are only calculated for turbulent flow. To make them appear for laminar cases, the turbulent viscosity should be set to a very small value - say 1.0E-10.

The friction force components SHRX, SHRY and SHRZ are used in the force-integration routines to add the friction force to the pressure force acting on each object. If they are not stored, the integrated force will only contain the pressure component. Storage for the friction forces can also be activated from the Forces and moments ' Settings' panel.

If the Mach Number is stored, the Total or Stagnation Pressure (PTOT) is calculated from:

P_{tot} = (P1+PRESS0)*(1+((γ-1)/2)*M)^{γ/(γ-1)}

If the Reference Pressure PRESS0 (Main Menu - Properties) is set to zero, the total pressure may go below zero, leading to an error-stop.

If the Mach Number is not stored, the total pressure is calculated from:

P_{tot} = (P1+PRESS0) +0.5*V_{abs}^{2}

When this is 'On', the Earth solver will integrate the pressure forces over all objects and print the force information to the RESULT file. Control over which objects are included in these calculations is provided on the 'Settings' panel. If the friction force components (SHRX, SHRY and SHRZ) have been placed in 3D store, the force integration will include them.

The moments of the X-, Y- and Z-direction forces about the X, Y and Z axes are calculated, and the point of action of the force is deduced.

The force and moment calculations are only valid for Cartesian and cylindrical-polar grids. The forces and moments are always printed in the Cartesian co-ordinate system. Positive moments are clockwise in a right-handed co-ordinate system.

For each face-cell (cell containing some surface area) of each blockage object, the force is calculated as:

fp_{i} = P1*A_{i}
: the pressure force, where A_{i} is the surface area normal to direction i (X,Y
or Z)

ff_{i} = SHR_{j}*A_{j} +SHR_{k}*A_{k}
: the friction force, where A_{j}, A_{k} are the areas parallel to
direction i

ft_{i} = fp_{i} + ff_{i}
: the total force in each cell.

The forces are then summed over all the face-cells of an object to give the total force on the object:

Ft_{i} = sum(ft_{i})

The moments about the X,Y and Z axes are then calculated as:

m_{x} =
ft_{y}.Z
- ft_{z}.Y

m_{y} = -ft_{x}.Z
+ ft_{z}.X

m_{z} = ft_{x}.Y - ft_{y}.X

where X,Y and Z are the distances of the cell face centre from the X,Y and Z axes. The moments are summed over all face-cells of an object to give the total moment about each axis:

M_{i} = sum(m_{i})

The moments of the individual forces about each axis are also summed:

Mzx = sum(ft_{x}.Y); Myx = sum(-ft_{x}.Z)

Mzy = sum(-ft_{y}.X); Mxy = sum(ft_{y}.Z)

Mxz = sum(-ft_{z}.Y); Myz = sum(ft_{z}.X)

The point of action of the integrated force (the position where the moment is zero) can now be deduced from expressions like:

Xm = Myz/Ft_{z}; Ym = Mzx/Ft_{x}; Zm = Mxy/Ft_{y}

Similar summations are performed over all objects to give the total force acting, the total moment, and the point of action of the total force.

Further control over what is printed is provided on the 'Settings' panel.

Image: FORCES SETTINGS panel

The settings are:

- Include friction forces in force sum. When set to 'On', the applicable friction force components (SHRX, SHRY and SHRZ) will be automatically placed in 3D store
- Select blockages from a list to Exclude from, or Include in the force calculation. By default all solid blockage objects are included. This provides a method for restricting the force and moment calculation to only a selected number of objects. The 'Include' and 'Exclude' lists are always made compatible. The total force on all included objects is summed and printed.
- Calculate the drag coefficients based on the total force. When set to 'On', the user can specify a Reference Density, Reference Velocity, and Reference areas in each coordinate direction.

Image: FORCES SETTINGS panel with Drag CoefficientThe drag coefficients are then printed as:

Cd

_{i}= F_{i}/(0.5*RHO_{ref}*Vel_{ref}*Area_{ref,i})

- The moments of the total force about a user-set position (Xu,Yu,Zu) can also be printed. These are calculated as:

Mx' = Fy.(Zm-Zu)-Fz.(Ym-Yu)

My' = -Fx.(Zm-Zu)+Fz.(Xm-Xu)

Mz' = Fx.(Ym-Yu)-Fy.(Xm-Xu)

This displays the section of TR/326 relevant to the current panel. If the POLIS files cannot be found on the local computer, you are offered the opportunity to open the file from the CHAM website. Note that the location of the POLIS files is set in the CHAM.INI file as described here

This returns to the main graphics window, and applies all the changes made in the main menu. This button only exists on the Top menu.