In the following we describe the session file configuration. Specifically we consider the sections
under the tag <CONDITIONS>
in the session (.xml) file.
Under this section it is possible to set the parameters of the simulation.
1<PARAMETERS> 2 <P> TimeStep = 0.0000001 </P> 3 <P> FinTime = 1.0 </P> 4 <P> NumSteps = FinTime/TimeStep </P> 5 <P> IO_CheckSteps = 5000 </P> 6 <P> IO_InfoSteps = 1 </P> 7 <P> Gamma = 1.4 </P> 8 <P> pInf = 101325 </P> 9 <P> rhoInf = 1.225 </P> 10 <P> GasConstant = 287.058 </P> 11 <P> TInf = pInf/(287.058*rhoInf) </P> 12 <P> Twall = pInf/(287.058*rhoInf)+15.0 </P> 13 <P> uInf = 147.4 </P> 14 <P> vInf = 0.0 </P> 15 <P> wInf = 0.0 </P> 16 <P> mu = 1e-5 </P> 17 <P> Pr = 0.72 </P> 18 <P> thermalConductivity = 0.02 </P> 19 <P> IO_Timer_Level = 3 </P> 20</PARAMETERS>
TimeStep
is the time-step we want to use.
FinTime
is the final physical time at which we want our simulation to stop.
NumSteps
is the equivalent of FinTime
but instead of specifying the physical final
time we specify the number of time-steps.
IO_CheckSteps
sets the number of steps between successive checkpoint files. No
checkpoint file is written if it is set to 0.
IO_InfoSteps
sets the number of steps between successive info stats are printed
to screen.
Gamma
ratio of the specific heats. Default value = 1.4.
pInf
farfield pressure (i.e. p∞). Default value = 101325 Pa.
rhoInf
farfield density (i.e. ρ∞). Default value = 1.225 Kg∕m3.
GasConstant
universal gas contant. Default value = 287.058 JKg-1K-1.
TInf
farfield temperature (i.e. T∞). Default value = 288.15 K.
Twall
temperature at the wall when isothermal boundary conditions are employed
(i.e. Tw). Default value = 300.15K.
uInf
farfield X-component of the velocity (i.e. u∞). Default value = 0.1 m∕s.
vInf
farfield Y -component of the velocity (i.e. v∞). Default value = 0.0 m∕s.
wInf
farfield Z-component of the velocity (i.e. w∞). Default value = 0.0 m∕s.
mu
dynamic viscosity (i.e. μ∞). Default value = 1.78e-05 Pas.
Pr
Prandtl number. Default value = 0.72.
thermalConductivity
thermal conductivity (i.e. κ∞). This can be set as an
alternative to Pr
, in which case the Prandtl number is calculated from κ∞ (it is
only possible to set one of them). By default, this is obtained from the Prandtl
number.
CFL
is the CFL number (explicit and implicit solvers).
CFLGrowth
is the growing CFL (explicit and implicit solvers).
CFLEnd
is the maximum value of the CFL number (explicit and implicit solvers).
Timer_IO_Level
defines the amount of timer information that is printed after the
solver is finished. The default value is -1, which disables output. By selecting a
value between 0 and 2, more detailed timer information is printed.
Under this section it is possible to set the time integration scheme information.
1<TIMEINTEGRATIONSCHEME> 2 <METHOD> RungeKutta </METHOD> 3 <VARIANT> SSP </VARIANT> 4 <ORDER> 3 </ORDER> 5</TIMEINTEGRATIONSCHEME>
TimeIntegrationScheme
is the time-integration scheme we want to use. There are
implicit and explicit schemes for the Compressible flow solver. For an explicit
discretization, the time-integration schemes supported are as follows
Name | <METHOD> | <VARIANT> | <ORDER> |
Forward Euler | ForwardEuler | - | 1 |
Runge Kutta 2 - SSP | RungeKutta | SSP | 2 |
Runge Kutta 3 - SSP | RungeKutta | SSP | 3 |
Runge Kutta 4 | ClassicalRungeKutta | - | 4 |
Runge Kutta 5 | RungeKutta | - | 5 |
For an implicit discretization, the time-integration schemes available are
Name | <METHOD> | <VARIANT> | <ORDER> |
Backward Euler | BackwardEuler | - | 1 |
Backward Differentiation Formula Implicit | BDFImplicit | - | 1 |
Backward Differentiation Formula Implicit | BDFImplicit | - | 2 |
Singly Diagonally Implicit Runge Kutta | DIRK | - | 2 |
Singly Diagonally Implicit Runge Kutta | DIRK | - | 3 |
Singly Diagonally Implicit Runge Kutta | DIRK | ES5 | 3 |
Singly Diagonally Implicit Runge Kutta | DIRK | - | 4 |
Singly Diagonally Implicit Runge Kutta | DIRK | ES5 | 4 |
Under this section it is possible to set the solver information.
1<SOLVERINFO> 2 <I PROPERTY="EQTYPE" VALUE="NavierStokesImplicitCFE" /> 3 <I PROPERTY="Projection" VALUE="DisContinuous" /> 4 <I PROPERTY="TimeIntegrationMethod" VALUE="DIRKOrder2" /> 5 <I PROPERTY="AdvectioType" VALUE="WeakDG" /> 6 <I PROPERTY="DiffusionType" VALUE="InteriorPenalty" /> 7 <I PROPERTY="UpwindType" VALUE="Roe" /> 8 <I PROPERTY="ProblemType" VALUE="General" /> 9 <I PROPERTY="ViscosityType" VALUE="Constant" /> 10 <I PROPERTY="EquationOfState" VALUE="IdealGas" /> 11 <I PROPERTY="Driver" VALUE="Standard" /> 12</SOLVERINFO>
EQType
is the tag which specify the equations we want solve:
Explicit discretization in time:
NavierStokesCFE
(Compressible Navier-Stokes equations).
EulerCFE
(Compressible Euler equations).
Implicit discretization in time:
NavierStokesImplicitCFE
(Compressible Navier-Stokes equations).
EulerImplicitCFE
(Compressible Euler equations).
Projection
is the type of projection we want to use:
DisContinuous
.
Note that the Continuous projection is not supported in the Compressible
Flow Solver.
AdvectionType
is the advection operator we want to use.
WeakDG
(classical DG in weak form).
FRDG
(Flux-Reconstruction recovering nodal DG scheme).
FRSD
(Flux-Reconstruction recovering a spectral difference (SD) scheme).
FRHU
(Flux-Reconstruction recovering Huynh (G2) scheme).
FRcmin
(Flux-Reconstruction with c = cmin).
FRcinf
(Flux-Reconstruction with c = ∞).
Note that only WeakDG
is fully supported, the other operators work only with
quadrilateral elements (2D or 2.5D).
DiffusionType
is the diffusion operator we want to use for the Navier-Stokes equations:
LDGNS
(LDG with primitive variables. The penalty term is inversely
proportional to the element size, proportional to the local viscosity for the
momentum equations and to the thermal conductivity for the energy equation,
and proportional to an optional parameter LDGNSc11
which is by default set to
one; proportionality to polynomial order can be manually imposed by setting
the parameter LDGNSc11
equal to p2).
LFRDGNS
(Flux-Reconstruction recovering nodal DG scheme).
LFRSDNS
(Flux-Reconstruction recovering a spectral difference (SD) scheme).
LFRHUNS
(Flux-Reconstruction recovering Huynh (G2) scheme).
LFRcminNS
(Flux-Reconstruction with c = cmin).
LFRcinfNS
(Flux-Reconstruction with c = ∞).
InteriorPenalty
(Symmetric interior penalty method).
Note that only LDGNS
and InteriorPenalty
are fully supported, the other operators
work only with quadrilateral elements (2D or 2.5D).
UpwindType
is the numerical interface flux (i.e. Riemann solver) we want to use for the
advection operator:
AUSM0
.
AUSM1
.
AUSM2
.
AUSM3
.
Average
.
ExactToro
.
HLL
.
HLLC
.
LaxFriedrichs
.
Roe
.
ViscosityType
is the viscosity type we want to use:
Constant
(Constant viscosity).
Variable
(Variable viscosity through the Sutherland’s law).
EquationOfState
allows selecting an equation of state for accounting for non-ideal gas
behaviour:
IdealGas
(default option).
VanDerWaals
(requires additional parameters Tcrit
and Pcrit
).
RedlichKwong
(requires additional parameters Tcrit
and Pcrit
).
PengRobinson
(requires additional parameters Tcrit
, Pcrit
and
AcentricFactor
).
Driver
specifies the type of problem to be solved:
Standard
(default option to solve the unsteady equations).
SteadyState
(uses the Selective Frequency Damping method (see Sec. 11.1.4)
to obtain a steady-state solution of the Navier-Stokes equations (explicit or
implicit)).
ShockCaptureType
specifies the type of operator to be used for shock capturing:
NonSmooth
add a Laplacian operator to apply artificial diffusion (see
Sec. 9.4.1.1). This option is only supported for explicit solvers (EulerCFE
and
NavierStokesCFE
).
Physical
add artificial viscosity to the physical viscosity. This option
is only supported for Navier-Stokes solvers (NavierStokesCFE
and
NavierStokesImplicitCFE
).
ShockSensorType
specifies the sensor type of shock capturing to be used:
Modal
(default) use a modal sensor to identify where to add viscosity (see
Sec. 9.4.1.2).
Dilatation
use a dilatation sensor to identify where to add viscosity.
DucrosSensor
apply a Ducros [12] (anti-vorticity) filter to the shock sensor:
On
Off
Smoothing
apply a smoothing filter to the shock sensor:
C0
smooth the artificial viscosity to be a continuous field.
In this section we can specify the boundary conditions for our problem. First we need
to define the variables under the section VARIABLES
. For a 1D problem we have:
1<VARIABLES> 2 <V ID="0"> rho </V> 3 <V ID="1"> rhou </V> 4 <V ID="2"> E </V> 5</VARIABLES>
For a 2D problem we have
1<VARIABLES> 2 <V ID="0"> rho </V> 3 <V ID="1"> rhou </V> 4 <V ID="2"> rhov </V> 5 <V ID="3"> E </V> 6</VARIABLES>
For a 3D problem we have:
1<VARIABLES> 2 <V ID="0"> rho </V> 3 <V ID="1"> rhou </V> 4 <V ID="2"> rhov </V> 5 <V ID="3"> rhow </V> 6 <V ID="4"> E </V> 7</VARIABLES>
After having defined the variables depending on the dimensions of the problem we want to solve, it is necessary to specify the boundary regions on which we want to define the boundary conditions:
1<BOUNDARYREGIONS> 2 <B ID="0"> C[100] </B> 3</BOUNDARYREGIONS>
Finally we can specify the boundary conditions on the regions specified under BOUNDARYREGIONS
.
Note that the no-slip, isothermal, wall boundary condition requires Twall to be specified. In
the following are some examples for a 2D problem:
Slip wall boundary conditions:
1<BOUNDARYCONDITIONS> 2 <REGION REF="0"> 3 <D VAR="rho" USERDEFINEDTYPE="Wall" VALUE="0" /> 4 <D VAR="rhou" USERDEFINEDTYPE="Wall" VALUE="0" /> 5 <D VAR="rhov" USERDEFINEDTYPE="Wall" VALUE="0" /> 6 <D VAR="E" USERDEFINEDTYPE="Wall" VALUE="0" /> 7 </REGION> 8</BOUNDARYCONDITIONS>
No-slip wall boundary conditions:
1<BOUNDARYCONDITIONS> 2 <REGION REF="0"> 3 <D VAR="rho" USERDEFINEDTYPE="WallViscous" VALUE="0" /> 4 <D VAR="rhou" USERDEFINEDTYPE="WallViscous" VALUE="0" /> 5 <D VAR="rhov" USERDEFINEDTYPE="WallViscous" VALUE="0" /> 6 <D VAR="E" USERDEFINEDTYPE="WallViscous" VALUE="0" /> 7 </REGION> 8</BOUNDARYCONDITIONS>
Adiabatic wall boundary conditions:
1<BOUNDARYCONDITIONS> 2 <REGION REF="0"> 3 <D VAR="rho" USERDEFINEDTYPE="WallAdiabatic" VALUE="0" /> 4 <D VAR="rhou" USERDEFINEDTYPE="WallAdiabatic" VALUE="0" /> 5 <D VAR="rhov" USERDEFINEDTYPE="WallAdiabatic" VALUE="0" /> 6 <D VAR="E" USERDEFINEDTYPE="WallAdiabatic" VALUE="0" /> 7 </REGION> 8</BOUNDARYCONDITIONS>
In some cases we need to excite perturbations inside the boundary layer. This can be
achieved by setting part of the wall as a disturbance strip. In the no-slip/adiabatic wall
boundary conditions, if the VALUE
is not exact "0" but any expression, which can be
time-dependent, the value of the expression will be added to the ghost state of what it
should be in the input boundary conditions, and then generate a non-zero flux through
the Riemann solver. The following is an example to set a disturbance strip of
amplitude A, frequency f, and in the range of [x0,x0 + len] on a flat plate.
1 <BOUNDARYCONDITIONS> 2 <REGION REF="0"> 3 <D VAR="rho" USERDEFINEDTYPE="WallAdiabatic" VALUE="0" /> 4 <D VAR="rhou" USERDEFINEDTYPE="WallAdiabatic" VALUE="0" /> 5 <D VAR="rhov" USERDEFINEDTYPE="WallAdiabatic" 6 VALUE="A*sin(2*PI*f*t)*sin(2*PI*(x-x0)/len) 7 *(x>=x0)*(x<=(x0+len))" /> 8 <D VAR="E" USERDEFINEDTYPE="WallAdiabatic" VALUE="0" /> 9 </REGION> 10 </BOUNDARYCONDITIONS>
Farfield boundary conditions (including inviscid characteristic boundary conditions):
1<BOUNDARYCONDITIONS> 2 <REGION REF="0"> 3 <D VAR="rho" VALUE="rhoInf" /> 4 <D VAR="rhou" VALUE="rhoInf*uInf" /> 5 <D VAR="rhov" VALUE="rhoInf*vInf" /> 6 <D VAR="E" 7 VALUE="pInf/(Gamma-1)+0.5*rhoInf*(uInf*uInf+vInf*vInf)"/> 8 </REGION> 9</BOUNDARYCONDITIONS>
Pressure outflow boundary conditions:
1<BOUNDARYCONDITIONS> 2 <REGION REF="0"> 3 <D VAR="rho" USERDEFINEDTYPE="PressureOutflow" VALUE="0" /> 4 <D VAR="rhou" USERDEFINEDTYPE="PressureOutflow" VALUE="0" /> 5 <D VAR="rhov" USERDEFINEDTYPE="PressureOutflow" VALUE="0" /> 6 <D VAR="E" USERDEFINEDTYPE="PressureOutflow" VALUE="pOut" /> 7 </REGION> 8</BOUNDARYCONDITIONS>
where pOut
is the target static pressure at the boundary.
Stagnation inflow boundary condition:
1<BOUNDARYCONDITIONS> 2 <REGION REF="0"> 3 <D VAR="rho" USERDEFINEDTYPE="StagnationInflow" VALUE="rho0" /> 4 <D VAR="rhou" USERDEFINEDTYPE="StagnationInflow" VALUE="nx" /> 5 <D VAR="rhov" USERDEFINEDTYPE="StagnationInflow" VALUE="ny" /> 6 <D VAR="rhov" USERDEFINEDTYPE="StagnationInflow" VALUE="nz" /> 7 <D VAR="E" USERDEFINEDTYPE="StagnationInflow" VALUE="p0/(Gamma-1)" /> 8 </REGION> 9</BOUNDARYCONDITIONS>
where rho0
and p0
are the stagnation density and stagnation pressure, respectively. The
values nx
, ny
, and nz
further define the direction of the flow. Note that it is not
necessary to normalize the vector (nx, ny, nz)
, it will be done automatically by the
solver. If the flow direction isn’t specified, the flow will enter in the boundary-normal
direction. The stagnation inflow boundary condition imposes a constant stagnation
density and stagnation pressure on the boundary. These quantities are related to the
stagnation temperature through the relation T0 = p0/(rho0 * GasConstant)
. This
boundary condition is useful in situations when stagnation quantities are known at the
inlet, rather than the actual density and pressure. In addition to this, the
standard boundary condition where 5 quantities (the conservative variables)
are imposed on the boundary is not suitable in many situations because in a
subsonic compressible flow, only 4 out of 5 variables can be imposed at an
inlet boundary. In contrast, the stagnation inflow boundary condition only
imposes 4 quantities (2 stagnation quantities, and the direction of the flow). The
last quantitity at the inlet will instead be determined by the solution inside
the domain. If you have a good estimate of one additional quantitity at the
inlet, such as the magnitude of the velocity or the static pressure, you can
estimate all remaining quantities at the inlet for the isentropic compressible flow
relations. In fact, at each iteration, the solver uses the isentropic flow relations
combined with the quantities imposed by the boundary + one quantity from
the interior solution to compute all remaining quantities at the boundary.
Once this has been done, the flux over the boundary at that iteration can be
computed.
Subsonic boundary condition enforcing entropy and pressure:
1<BOUNDARYCONDITIONS> 2 <REGION REF="0"> 3 <D VAR="rho" USERDEFINEDTYPE="EnforceEntropyPressure" VALUE="rhoInf" /> 4 <D VAR="rhou" USERDEFINEDTYPE="EnforceEntropyPressure" VALUE="rhoInf*uInf" /> 5 <D VAR="rhov" USERDEFINEDTYPE="EnforceEntropyPressure" VALUE="rhoInf*vInf" /> 6 <D VAR="rhov" USERDEFINEDTYPE="EnforceEntropyPressure" VALUE="rhoInf*wInf" /> 7 <D VAR="E" USERDEFINEDTYPE="EnforceEntropyPressure" VALUE="pInf/(Gamma-1) + 0.5*rhoInf*(uInf*uInf + vInf*vInf)" /> 8 </REGION> 9</BOUNDARYCONDITIONS>
where the input type can be either VALUE
or FILE
such that the specified entropy
and pressure distribution (corresponding to the input rhoInf
, rhoInf*uInf
,
rhoInf*vInf
, rhoInf*wInf
, and E
) will be enforced on the subsonic inflow
boundary. If the flow is supersonic, all the conditions are naturelly agreed
with the input distribution. The following two conditions follows the same
rule.
Subsonic boundary condition enforcing entropy and velocity:
1<BOUNDARYCONDITIONS> 2 <REGION REF="0"> 3 <D VAR="rho" USERDEFINEDTYPE="EnforceEntropyVelocity" VALUE="rhoInf" /> 4 <D VAR="rhou" USERDEFINEDTYPE="EnforceEntropyVelocity" VALUE="rhoInf*uInf" /> 5 <D VAR="rhov" USERDEFINEDTYPE="EnforceEntropyVelocity" VALUE="rhoInf*vInf" /> 6 <D VAR="rhov" USERDEFINEDTYPE="EnforceEntropyVelocity" VALUE="rhoInf*wInf" /> 7 <D VAR="E" USERDEFINEDTYPE="EnforceEntropyVelocity" VALUE="pInf/(Gamma-1) + 0.5*rhoInf*(uInf*uInf + vInf*vInf)" /> 8 </REGION> 9</BOUNDARYCONDITIONS>
where both tangential and normal velocity components are enforced. Therefore the angle of attack is maintained.
Subsonic boundary condition enforcing entropy and total enthalpy:
1<BOUNDARYCONDITIONS> 2 <REGION REF="0"> 3 <D VAR="rho" USERDEFINEDTYPE="EnforceEntropyTotalEnthalpy" VALUE="rhoInf" /> 4 <D VAR="rhou" USERDEFINEDTYPE="EnforceEntropyTotalEnthalpy" VALUE="rhoInf*uInf" /> 5 <D VAR="rhov" USERDEFINEDTYPE="EnforceEntropyTotalEnthalpy" VALUE="rhoInf*vInf" /> 6 <D VAR="rhov" USERDEFINEDTYPE="EnforceEntropyTotalEnthalpy" VALUE="rhoInf*wInf" /> 7 <D VAR="E" USERDEFINEDTYPE="EnforceEntropyTotalEnthalpy" VALUE="pInf/(Gamma-1) + 0.5*rhoInf*(uInf*uInf + vInf*vInf)" /> 8 </REGION> 9</BOUNDARYCONDITIONS>
Under the two following sections it is possible to define the initial conditions and the exact solution (if existent).
1<FUNCTION NAME="InitialConditions"> 2 <E VAR="rho" VALUE="rhoInf"/> 3 <E VAR="rhou" VALUE="rhoInf*uInf" /> 4 <E VAR="rhov" VALUE="rhoInf*vInf" /> 5 <E VAR="E" 6 VALUE="pInf/(Gamma-1)+0.5*rhoInf*(uInf*uInf+vInf*vInf)"/> 7</FUNCTION> 8 9<FUNCTION NAME="ExactSolution"> 10 <E VAR="rho" VALUE="rhoInf" /> 11 <E VAR="rhou" VALUE="rhoInf*uInf" /> 12 <E VAR="rhov" VALUE="rhoInf*vInf" /> 13 <E VAR="E" 14 VALUE="pInf/(Gamma-1)+0.5*rhoInf*(uInf*uInf+vInf*vInf)"/> 15</FUNCTION>