0% found this document useful (0 votes)
50 views6 pages

Freecappuccino Input Specification Guide

The document describes the input parameters for a freeCappuccino simulation code. It lists the parameter keys, possible values, and descriptions for configuring a simulation. Parameters include the title, mesh format, whether to read a restart file, algorithms for solving equations, under-relaxation factors, tolerances, and schemes for convection, diffusion, and interpolating pressure to faces. The description spans multiple pages and notes that not all parameters are required or in a specific order.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
50 views6 pages

Freecappuccino Input Specification Guide

The document describes the input parameters for a freeCappuccino simulation code. It lists the parameter keys, possible values, and descriptions for configuring a simulation. Parameters include the title, mesh format, whether to read a restart file, algorithms for solving equations, under-relaxation factors, tolerances, and schemes for convection, diffusion, and interpolating pressure to faces. The description spans multiple pages and notes that not all parameters are required or in a specific order.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 6

freeCappuccino input file specification guide ° (from previous page)

September 20th 2022 Parameter key ö Values Ò Description Õ

Integer parameter for


Description of input parameters and their default values, possible values, description, discussion Int,
nrelaxU diffusion scheme - ad-
on status of the code related to it, etc. e.g. 1
vanced
The description below refers to fortran namelist file e.g. ’input.nml’ that is required to configure
Linear algebraic solver
the simulation. Not all the parameters have to be present, nor do they have to be in specific Sting,
lSolverU for momentum equa-
order. e.g. ’bicgstab’
tion

Int, Max no of iterations for


Parameter key ö Values Ò Description Õ maxiterU
e.g. 10 linear U-V-W equations
Descriptive name of the
String Absolute tolerance level
title case which will be writ- Real,
e.g. ’Laminar flow in cavity’ tolAbsU for residual for linear
ten in monitor file. e.g. 1e-13
U-V-W equations
Mesh format ’na-
Relative tolerance level
tiveMesh’ for native Real,
’nativeMesh’ tolRelU for residual for linear
mesh_format polyMesh format or e.g. 0.025
’foamMesh’ U-V-W equations
’foamMesh’ for Open-
FOAM polyMesh. Interpolation of pres-
sure to faces. Possi-
Read restart file - con- Sting,
pscheme ble choices are: ’lin-
lread T/F tinue simulation from e.g. ’linear’
ear’(default), ’weighted’,
saved state?
’central’.
Verbosity for linear
Activate Pressure field
ltest T/F solver convergence (for calcP T/F
calculation? True/False.
troubleshooting).
Under-relaxation factor
Activate Velocity field urfP Real, eg. 0.3
calcU T/F for pressure
calculation?
Linear algebraic solver
Under-relaxation factor Sting,
Real array, size(3), lSolverP for pressure/pressure
urfU for momentum equa- e.g. ’iccg’
e.g. 0.7, 0.7, 0.7 correction
tions.
Max no of iterations for
gamma-deferred cor- Int,
Real, maxiterP pressure/pressure cor-
gdsU rection parameter for e.g. 50
e.g. 1.0 rection
velocity.
Absolute tolerance level
String Convection scheme for
cSchemeU Real, for residual for pres-
e.g. ’linearUpwind’ momentum equation. tolAbsP
e.g. 1e-13 sure/pressure correc-
String, Diffusion scheme for tion
dSchemeU
e.g. ’skewness’ momentum equation
(continued next page) ±
(continued next page) ±

1 2
° (from previous page) ° (from previous page)

Parameter key ö Values Ò Description Õ Parameter key ö Values Ò Description Õ

Relative tolerance level Activate dynamic vis-


Real, for residual for pres- calcVis T/F cosity recalculation (
tolRelP
e.g. 0.025 sure/pressure correc- Non-Newtonian flows)
tion
There are many avail-
Turbulence model - see String, able models, see dis-
String, non_newtonian_model
TurbModel discussion at the end of e.g. ’PowerLaw’ cussion at the end of
e.g. ’none’, ’k_epsilon_std’
the document. the document.

Real, Under-relaxation factor, Real, Exponent for power-law


TurbModel%Scalar(n)%urf npow
e.g. 0.7 n ∈ {1, ..., 8}. e.g. 0.4 fluids

Deferred correction fac- Real, Consistency index for


TurbModel%Scalar(n)%gds e.g. 1.0 Consst
tor, n ∈ {1, ..., 8}. e.g. 10.0 power-law fluids

Convection scheme - Lower limit for the


String, Real,
TurbModel%Scalar(n)%cScheme default is second order shearmin shear rate magnitude
e.g. ’linearUpwind’ e.g. 1e-3
upwind, n ∈ {1, ..., 8}. for power-law fluids

Diffusion scheme, i.e. Tau_0 Real Yield stress


the method for normal
String, Exponential growth pa-
TurbModel%Scalar(n)%dScheme gradient at face uncor- megp Real
e.g. ’skewness’ rameter
rected/skewness/offset,
n ∈ {1, ..., 8}.
muplastic Real Plastic viscosity
Relaxation parameter
Int, non-orthogonal correc- muzero Real Zero shear rate viscosity
TurbModel%Scalar(n)%nrelax
e.g. 0 tion for face gradient,
Infinity shear rate vis-
{-1/0/1}, , n ∈ {1, ..., 8}. muinfty Real
cosity
Sting, Linear algebraic solver,
TurbModel%Scalar(n)%lSolver Natural time - time pa-
e.g. ’bicgstab’ n ∈ {1, ..., 8}. lamtime Real
rameter
Max number of itera-
Int, Real, Under-relaxation pa-
TurbModel%Scalar(n)%maxiter tions in linear solver, urfVis
e.g. 20 e.g. 0.8 rameter
n ∈ {1, ..., 8}..
Activate Temperature
Real, Absolute residual level,
TurbModel%Scalar(n)%tolAbs calcT T/F equation calculation?
e.g. 1e-13 n ∈ {1, ..., 8}.
True/False.
Relative drop in resid-
Real, Real, Under-relaxation fac-
TurbModel%Scalar(n)%tolRel ual to exit linear solver, urfT
e.g. 0.01 e.g. 0.7 tors.
n ∈ {1, ..., 8}.
Real, Deferred correction fac-
Real, Under-relaxation for gdsT
TurbModel%urfVis e.g. 1.0 tor.
e.g. 1.0 eddy-viscosity.

(continued next page) ±


(continued next page) ±

3 4
° (from previous page) ° (from previous page)

Parameter key ö Values Ò Description Õ Parameter key ö Values Ò Description Õ

Convection scheme - Relaxation parameter


String, Int,
cSchemeT default is second order nrelaxEn non-orthogonal correc-
e.g. ’linearUpwind’ e.g. 0
upwind. tion for face gradient.

Diffusion scheme, i.e. String, Linear algebraic solver


lSolverEn
String, the method for normal e.g. ’bicgstab’ type (see list below).
dSchemeT
e.g. ’skewness’ gradient at face skew-
ness/offset. Int, Max number of itera-
maxiterEn
e.g. 20 tions in linear solver.
Relaxation parameter
Real,
Int, non-orthogonal correc- tolAbsEn Absolute residual level.
nrelaxT e.g. 1e-15
e.g. 0 tion for face gradient.
Advanced. Relative drop in resid-
Real,
String, tolRelEn ual norm to exit linear
lSolverT Linear algebraic solver. e.g. 0.01
e.g. ’bicgstab’ solver.

Int, Max number of itera- Real, Prandtl-Schmid number


maxiterT sigtEn
e.g. 20 tions in linear solver. e.g. 0.9 for energy equation.

Real, What we solve here -


tolAbsT Absolute residual level.
e.g. 1e-15 solveTotalEnergy T/F default is total energy,
but other options are...
Real, Relative drop in resid-
tolRelT
e.g. 0.01 ual to exit linear solver. solveInternalEnergy T/F internal energy, or...
sigma_t - Prandtl- solveEnthalpy T/F enthaply.
Real,
sigt Schmid number for
e.g. 0.9
temperature. Add viscous dissipation
addViscDiss T/F
term? True/False.
Activate Energy field
calcEn T/F
calculation? True/False. Buoyancy activated?
lbuoy T/F
True/False.
Real, Under-relaxation fac-
urfEn
e.g. 0.9 tors. Bousinesq approxima-
boussinesq T/F
tion for buoyancy.
Real, Deferred correction fac-
gdsEn
e.g. 1.0 tor. Real, Reference temperature
tref
e.g. 300.0 for buoyant flows.
Convection scheme -
String,
cSchemeEn default is second order Real, Three components of
e.g. ’linearUpwind’ gravx
upwind. e.g. 0.0 gravity vector.

Diffusion scheme, i.e. Real,


gravy -
String, the method for normal e.g. -9.81
dSchemeEn
e.g. ’skewness’ gradient at face skew- Real,
ness/offset. gravz -
e.g. 0.0

(continued next page) ± (continued next page) ±

5 6
° (from previous page) ° (from previous page)

Parameter key ö Values Ò Description Õ Parameter key ö Values Ò Description Õ

Activate passive scalar Real, Deferred correction fac-


gdsEpot
calcCon T/F concentration field cal- e.g. 1.0 tor.
culation? True/False.
Sting,
lSolverEpot ’ Linear algebraic solver.
Real, Under-relaxation fac- e.g. ’iccg’
urfCon
e.g. 0.7 tors. Int, Max number of itera-
maxiterEpot
Real, Deferred correction fac- e.g. 20 tions in linear solver.
gdsCon
e.g. 1.0 tor. Real,
tolAbsEpot Absolute residual level.
e.g. 1e-15
Convection scheme -
String,
cSchemeCon default is second order Real, Relative drop in resid-
e.g. ’linearUpwind’ tolRelEpot
upwind. e.g. 0.01 ual to exit linear solver.

Diffusion scheme, i.e. Real,


densit Fluid density.
String, the method for normal e.g. 1.0
dSchemeCon
e.g. ’skewness’ gradient at face skew-
Real, Molecular dynamic vis-
ness/offset. viscos
e.g. 1e-2 cosity.
Type of non-orthogonal
Real, Prandtl coefficient for
correction for pranl
Int, e.g. 0.71 specific fluid.
nrelaxCon face gradient
e.g. 0
minimal/orthogonal/over- Real, Thermal expansion co-
relaxed. 1/0/-1. beta
e.g. 1e-3 efficient.
String,
lSolverCon Linear algebraic solver. Simple gradient hypoth-
e.g. ’bicgstab’ lsgdh T/F
esis for heat-fluxes, or...
Int, Max number of itera-
maxiterCon Generalized gradient
e.g. 20 tions in linear solver.
lggdh T/F hypothesis for heat
Real, fluxes, or...
tolAbsCon Absolute residual level.
e.g. 1e-15
Algebraic flux modelling
Real, Relative drop in resid- lafm T/F
tolRelCon for heat fluxes.
e.g. 0.01 ual to exit linear solver.
Real, Under-relaxation factor
Prandtl-Schmidt num- facnap
Real, e.g. 1.0 for Reynolds stresses.
sigCon ber for passive scalar
e.g. 0.9
concentration Real, Under-relaxation factor
facflx
e.g. 1.0 for heat fluxes.
Activate Electric poten-
calcEpot T/F tial field calculation? Unsteady simulation
True/False. ltransient T/F True/False and chose
ONE algorithm below
Real,
urfEpot Under-relaxation factor.
e.g. 0.8
(continued next page) ±
(continued next page) ±

7 8
° (from previous page) ° (from previous page)

Parameter key ö Values Ò Description Õ Parameter key ö Values Ò Description Õ

Backward-Euler; First- Pressure-velocity cou-


bdf T/F
Order Implicit, or... SIMPLE T/F pling method - SIMPLE,
or...
Second-Order Backward
bdf2 T/F Euler; Second-Order Pressure-velocity cou-
PISO T/F
Implicit, or... pling method - PISO.

Third-order backard, Number of PISO correc-


bdf3 T/F Int,
or... ncorr tions - only relevant for
e.g. 1
PISO.
CN T/F Crank-Nicolson.
Number of iterations
Gradient approxima- for pressure/pressure
tion, chose ONE: Un- Int,
npcor correction equation -
lstsq T/F weighted Least-Square e.g. 1
Number of Nonorthogo-
gradient approximation, nal corrections.
or...
Reference cell for set-
Least square gradients Int, ting pressure level
lstsq_qr T/F based on thin QR de- pRefCell
e.g. 1 (since we have pure
composition, or... Neumann problem)
Distance-square Desired level of con-
weighted version of Real,
lstsq_dm T/F tolerance vergence for SIMPLE
Least-Square Gradient, e.g. 1e-5
iterations.
or...
Int, Total number of
Node based Gauss gra- numstep
e.g. 1000 timesteps.
node_gauss T/F dient with pseudolapla-
cian interpolation. Real, Timestep size - also
timestep
e.g. 1e-3 known as dt.
Cell based Gauss gradi-
gauss T/F ent with simple linear Program writes out-
Int,
interpolation. nzapis put files every NZAPIS
e.g. 100
timesteps.
Number of iterations for
Int,
nigrad Gauss gradient approxi- Number of iterations in
e.g. 1
mation. Int, SIMPLE or PISO sequen-
maxit
e.g. 1 tial equation solution
Gradient limiter - loop.
global for all gradients
String,
limiter (none, Barth-Jespersen, Adaptive timestep size
e.g. ’Venkatakrishnan’
Venkatakishnan, multi- CoNumFix T/F based on target Courant
dimensional, R3) number? True/False.

(continued next page) ± (continued next page) ±

9 10
° (from previous page) ’IDDES_k_omega_sst’, ’DDES_k_omega_sst’. Many more to come soon!
The TurbModel is a variable of derived data type. In the namelist files it is initialized by a list of
data, delimited using comma, representing values of the data members in sequential order as
Parameter key ö Values Ò Description Õ they are listed in definition of the derived data type.
The ’TurbModel%name’ is first in the sequence so if we put ’TurbModel = k_omega_sst’, it will only
If CoNumFix=True then initialize the first data member of the derived type, which is the model name. This is fortunate
Real,
CoNumFixValue set target maximum circumstance and leads to compact initialization style. Turbulence model may have several
e.g. 1.0
Courant number here. (we often deal with two) equations which define the model, each for a separate scalar field.
Example is k −  model, where we solve separate equations for turbulence kinetic energy and
Do we have constant
turbulence kinetic energy dissipation rate. For every field we have in the model, we may set a
const_mflux T/F mass flow in the do-
value for any available parameter as seen in the table above. This can be done in any order, it
main? True/False.
is irrelevant. For example writing ’TurbModel%Scalar(1)%urf = 0.5’ will set the under-relaxation
If const_mflux=True factor for the first scalar field in the turbulence model to 0.5. ’TurbModel%Scalar(1)%cScheme
then set target bulk ve- = ’boundedLinearUpwind” will set the interpolation scheme for convection different from the
Real, default one (’linearUpwind’) for the first scalar field in the model.
magUbar locity for constant mass
e.g. 1.0
flow situation.

Possible linear algebraic solvers are: ’gauss_seidel’, ’dpcg’, ’iccg’, ’bicgstab’. Most computational
effort goes into solution of pressure Poisson equation, which is symmetric, positive definite. Use
Incomplete Cholesky Conjugate Gradient (ICCG) for that one. For other transport equations with
non-symmetric matrices Bi-CGStab is good option. Using LIS library enables greater choice for
precodnitioner/solver combinations, when necessary (eg. ’-i cg -p saamg -tol 0.01 -maxiter 10’
for CG with Smoothed Agglomeration Algebraic Multigird preconditioner with relative residual
norm reduction target of 0.01 and maximum of 10 iterations). For LIS solvers all solver parame-
ters, as seen in this example, are given within single text string.

Possible convection schemes are: ’cds’, ’central’, ’linearUpwind’, kappa, muscl, umist, smart,
boundedLinearUpwind, boundedCentral, etc. The list is long and you may consult the source
code, just look at the ’interpolation.f90’ module. If you use ’linearUpwind’ it is good to have gra-
dient (slope) limiter activated, such as ’Barth-Jespersen’, ’Venkatakrishnan’, ’multidimensional’
or ’R3’.

The rheology may be prescribed using the various non-Newtonian models. If we are inter-
ested in materials exhibiting such a behaviour we may set ’calcVis’ to true, to recalculate the
effective viscosity at each iteration, and choose an appropriate Non-Newtonian model. The op-
tions are: ’PowerLaw’ (Power law constitutive Model), ’HerschelBulkley’ (Herschel-Bulkley con-
stitutive regularized (Papanastasiou) Model), ’Bingham’ (Bingham model), ’BinghamPapanasta-
siou’ (Bingham-Papanastasiou model), ’Carreau’ (Carreau constitutive model), ’CarreauYasuda’
(Carreau-Yasuda constitutive model), ’Casson’ (Casson constitutive model), ’CassonPapanasta-
siou’ (Casson constitutive regularized (Papanastasiou) Model with consistency temperature de-
pendance), ’CrossModel’ (Cross constitutive model).

Choosing turbulence model is of course a big topic. Here is the short list of possibilities. Eddy
viscosity RANS models are: ’k_epsilon_std’, ’k_omega_sst’, ’Spalart_Allmaras’, ’k_epsilon_rng’,
’k_epsilon_rlzb’ (Realizable k −  model), ’k_epsilon_rlzb_2lewt’ (Realizable k −  model with
two-layer approach for wall cells and with enhanced wall functions using Reichardt blending
function), ’k_epsilon_std_2lewt’ (Standard k −  with two layer approach and enhanced wall
functions). The LES models are ’WALE’, and one equation ’k_eqn_eddy’. The hybrid models are:

11 12

You might also like