Initial conditions block

Listing 38 Initial Conditions block in XML input file.
  <ParameterList name="Initial Conditions">
	  ...
	  ...
	  ...
  </ParameterList> <!--Initial Conditions-->

Initial conditions are specified for each mesh block, and all variables defined as degrees of freedom within a block must be assigned initial values. Vertex-CFD provides several types of initial conditions, listed below. The syntax for defining initial conditions in a mesh block is as follows:

Listing 39 Initial conditions for mesh block eblock-0_0.
    </ParameterList> <!-- -->
    <ParameterList>
      <Parameter name="Sideset ID" type="string" value="bottom"/>
      <Parameter name="Element Block ID" type="string" value="eblock-0_0"/>
      <Parameter name="Strategy" type="string" value="IncompressibleBoundaryFlux"/>
      <ParameterList name="Data">
        <Parameter name="Type" type="string" value="No-Slip"/>
      </ParameterList> <!-- Data -->
    </ParameterList> <!-- -->
  </ParameterList> <!-- Boundary Conditions -->

  <ParameterList name="Initial Conditions">
    <ParameterList name="eblock-0_0">
      <ParameterList name="Constant Lagrange Pressure">
        <Parameter name="Type" type="string" value="Constant"/>
        <Parameter name="Equation Set Name" type="string" value="lagrange_pressure"/>
        <Parameter name="Value" type="double" value="0.0"/>
      </ParameterList> <!-- Constant Lagrange Pressure -->
      <ParameterList name="Constant Velocity 0">
Listing 40 Initial conditions for mesh blocks fluid_1, fluid_2, solid_1 and solid_2.
  <ParameterList name="Initial Conditions">
    <ParameterList name="fluid_1">
      <ParameterList name="Constant Lagrange Pressure">
        <Parameter name="Type" type="string" value="Constant"/>
        <Parameter name="Equation Set Name" type="string" value="lagrange_pressure"/>
        <Parameter name="Value" type="double" value="0.0"/>
      </ParameterList> <!-- Constant Lagrange Pressure -->
      <ParameterList name="Laminar Flow">
        <Parameter name="Type" type="string" value="IncompressibleLaminarFlow"/>
        <Parameter name="Average velocity" type="double" value="0.1"/>
        <Parameter name="Maximum height" type="double" value="-0.005"/>
        <Parameter name="Minimum height" type="double" value="-0.015"/>
        <Parameter name="Temperature" type="double" value="300.0"/>
      </ParameterList> <!-- Laminar Flow -->
    </ParameterList> <!-- fluid_1 -->
    <ParameterList name="fluid_2">
      <ParameterList name="Constant Lagrange Pressure">
        <Parameter name="Type" type="string" value="Constant"/>
        <Parameter name="Equation Set Name" type="string" value="lagrange_pressure"/>
        <Parameter name="Value" type="double" value="0.0"/>
      </ParameterList> <!-- Constant Lagrange Pressure -->
      <ParameterList name="Laminar Flow">
        <Parameter name="Type" type="string" value="IncompressibleLaminarFlow"/>
        <Parameter name="Average velocity" type="double" value="0.1"/>
        <Parameter name="Maximum height" type="double" value="-0.005"/>
        <Parameter name="Minimum height" type="double" value="-0.015"/>
        <Parameter name="Temperature" type="double" value="300.0"/>
      </ParameterList> <!-- Laminar Flow -->
    </ParameterList> <!-- fluid_2 -->
    <ParameterList name="solid_1">
      <ParameterList name="Temperature">
        <Parameter name="Type" type="string" value="Constant"/>
        <Parameter name="Equation Set Name" type="string" value="temperature"/>
        <Parameter name="Value" type="double" value="300.0"/>

The initial conditions for mesh block eblock-0_0 are defined in a sub-list whose value matches the mesh block name. Individual initial conditions are then specified within sub-lists selected from the options below. The name of each sub-list is provided by the user. Some initial-condition types apply to a single variable, such as Constant, while others define conditions for a set of variables on a mesh block — for example, Laminar Flow.

<Constant initial condition>
Type
Type:

string

Value:

Constant

Usage:

Required

Description:

Define an uniform initial conditions for the variable defined in Equation Set Name.

Equation Set Name
Type:

string

Value:

Variable name

Usage:

Required

Description:

Variable name to initialize (should be the same name as defined in the source code).

Value
Type:

double

Value:

\([-\infty;\infty]\)

Usage:

Required

Description:

Value to initialize the variable set in Equation Set Name with.

Listing 41 Set an initial condition of 0.0 for the variable lagrange_pressure.
1      <Parameter name="Sideset ID" type="string" value="bottom"/>
2      <Parameter name="Element Block ID" type="string" value="eblock-0_0"/>
3      <Parameter name="Strategy" type="string" value="IncompressibleBoundaryFlux"/>
4      <ParameterList name="Data">
5        <Parameter name="Type" type="string" value="No-Slip"/>
<Laminar Flow>

Note

The laminar initial condition supports channel flow in 2D and 3D, and pipe and duct flow in 3D. The flow direction can be selected using Flow Direction. The velocity components are initialized according to the selected laminar flow profile. The temperature is set to a uniform value when enabled.

Type
Type:

string

Value:

IncompressibleLaminarFlow

Usage:

Required

Description:

Define a laminar flow profile.

Flow Profile Type
Type:

string

Value:

Channel, Pipe, Duct

Usage:

Optional

Default:

Channel

Description:

Select the laminar flow profile. Channel is available in 2D and 3D, while Pipe and Duct are only available in 3D.

Flow Direction
Type:

string

Value:

x, y, z

Usage:

Optional

Default:

x

Description:

Direction of the flow.

Minimum height
Type:

double

Value:

\([-\infty;\infty]\)

Usage:

Required

Description:

Minimum coordinate defining the height of the flow profile.

Maximum height
Type:

double

Value:

\([-\infty;\infty]\)

Usage:

Required

Description:

Maximum coordinate defining the height of the flow profile.

Channel Wall Normal Direction
Type:

string

Value:

x, y, z

Usage:

Optional

Default:

y

Description:

Direction normal to the channel walls for the Channel profile. It must be different from Flow Direction.

Minimum width
Type:

double

Value:

\([-\infty;\infty]\)

Usage:

Required for Duct

Description:

Minimum coordinate defining the width of the Duct profile.

Maximum width
Type:

double

Value:

\([-\infty;\infty]\)

Usage:

Required for Duct

Description:

Maximum coordinate defining the width of the Duct profile.

Average velocity
Type:

double

Value:

\([0;\infty]\)

Usage:

Required

Description:

Average velocity in the flow direction.

Temperature
Type:

double

Value:

\([0;\infty]\)

Usage:

Optional

Description:

Uniform value for the temperature when solving the temperature equation.

Listing 42 Set laminar flow initial conditions (parabolic velocity profile) and uniform temperature.
1      <ParameterList name="Laminar Flow">
2        <Parameter name="Type" type="string" value="IncompressibleLaminarFlow"/>
3        <Parameter name="Average velocity" type="double" value="0.1"/>
4        <Parameter name="Maximum height" type="double" value="-0.005"/>
5        <Parameter name="Minimum height" type="double" value="-0.015"/>
6        <Parameter name="Temperature" type="double" value="300.0"/>
7      </ParameterList> <!-- Laminar Flow -->
<Taylor Green Vortex>

Note

The Taylor-Green-Vortex problem initializes the pressure and velocity components with sinusoidal functions.

Type
Type:

string

Value:

IncompressibleTaylorGreenVortex

Usage:

Required

Description:

Initialize the Navier-Stokes equations with the Taylor-Green-Vortex.

Listing 43 Initialize the velocity and the pressure for the Taylor-Green-Vortex problem.
1      <ParameterList name="Green Taylor Vortex">
2        <Parameter name="Type" type="string" value="IncompressibleTaylorGreenVortex"/>
3      </ParameterList> <!-- Green Taylor Vortex -->
<Turbulent Channel>

Note

The turbulent channel assumes a flow in the x-direction. The wall boundaries are perpandicular to the y-direction and periodic boundaries are assumed in the z-direction.

Type
Type:

string

Value:

IncompressibleTurbulentChannel

Usage:

Required

Description:

Initialize a turbulent flow in a 3-D channel.

Kinematic Viscosity
Type:

double

Value:

\([0;\infty]\)

Usage:

Required

Description:

Kinematic viscosity of the turbulent flow.

Half Width
Type:

double

Value:

\([0;\infty]\)

Usage:

Required

Description:

Half-width of the turbulent channel (y-direction).

Friction Reynolds Number
Type:

double

Value:

\([0;\infty]\)

Usage:

Required

Description:

Targeted friction Reynolds number.

Lx
Type:

double

Value:

\([0;\infty]\)

Usage:

Required

Description:

Geometry dimension in the x-direction/flow direction.

Ly
Type:

double

Value:

\([0;\infty]\)

Usage:

Required

Description:

Geometry dimension in the y-direction/spanwise direction.

LNumber of M
Type:

int

Value:

\([0;\infty]\)

Usage:

Optional

Default:

3

Description:

Number of modes used to generate the turbulent initial conditions.

Add Random Perturbations
Type:

bool

Value:

true, false

Usage:

Optional

Default:

false

Description:

Add random perturbations to the initial turbulent flow.

Temperature
Type:

double

Value:

\([0;\infty]\)

Usage:

Optional

Description:

Initial value for the temperature. Required when solving for the temperature equation.

Listing 44 Initial conditions for a turbulent channel flow.
1      <ParameterList name="Turbulent Channel Flow">
2        <Parameter name="Type" type="string" value="IncompressibleTurbulentChannel"/>
3        <Parameter name="Kinematic Viscosity" type="double" value="5.56e-3"/>
4        <Parameter name="Half Width" type="double" value="1.0"/>
5        <Parameter name="Friction Reynolds Number" type="double" value="180.0"/>
6        <Parameter name="L_x" type="double" value="12.56637"/>
7        <Parameter name="L_z" type="double" value="4.18879"/>
8        <Parameter name="Number of Modes" type="int" value="3"/>
9      </ParameterList> <!-- Turbulent Channel Flow -->
<Circle initial condition>
Type
Type:

string

Value:

Circle

Usage:

Required

Description:

Define a circle/sphere step condition for the variable defined in Equation Set Name.

Equation Set Name
Type:

string

Value:

Variable name

Usage:

Required

Description:

Variable name to initialize (should be the same name as defined in the source code).

Inside Value
Type:

double

Value:

\([-\infty;\infty]\)

Usage:

Required

Description:

Value inside the circle/sphere to initialize the variation set in Equation Set Name with.

Outside Value
Type:

double

Value:

\([-\infty;\infty]\)

Usage:

Required

Description:

Value outside the circle/sphere to initialize the variation set in Equation Set Name with.

Radius
Type:

double

Value:

\([0;\infty]\)

Usage:

Required

Description:

Radius of the circle/sphere.

Center
Type:

Array(double)

Value:

\([-\infty;\infty]\)

Usage:

Required

Description:

Coordiantes of the center of the circle/sphere.

<Sinusoidal initial condition>
Type
Type:

string

Value:

Sinusoidal

Usage:

Required

Description:

Define a sinusoidal initial condition for the variable defined in Equation Set Name of the type \(A \sin(|\vec{x}| + \phi)\).

Equation Set Name
Type:

string

Value:

Variable name

Usage:

Required

Description:

Variable name to initialize (should be the same name as defined in the source code).

Amplitude
Type:

double

Value:

\([0;\infty]\)

Usage:

Required

Description:

Value of the amplitude \(A\) multiplying the sinusoidal function.

Phase Angle
Type:

double

Value:

\([-\infty;\infty]\)

Usage:

Required

Description:

Phase angle \(\phi\).

<Step initial condition>
Type
Type:

string

Value:

Step

Usage:

Required

Description:

Specific a step initial condition with left and right values separated by an axis/plane perpandicular to the x-axis.

Equation Set Name
Type:

string

Value:

Variable name

Usage:

Required

Description:

Variable name to initialize (should be the same name as defined in the source code).

Origin
Type:

double

Value:

\([-\infty;\infty]\)

Usage:

Required

Description:

x-coordinate of the axis/plane separating the left and right values.

Left Value
Type:

double

Value:

\([-\infty;\infty]\)

Usage:

Required

Description:

Left value to axis/plane specified by the Origin x-coordinate.

Right Value
Type:

double

Value:

\([-\infty;\infty]\)

Usage:

Required

Description:

Right value to axis/plane specified by the Origin x-coordinate.

<Gaussian initial condition>
Type
Type:

string

Value:

Gaussian

Usage:

Required

Description:

Gaussian profile with the following definition: \(d + \prod_{i=0}^{d} a_i \exp \left( (b_i - x_i ) (\frac{1}{2\sigma^2} - x_i) \right)\)

Equation Set Name
Type:

string

Value:

Variable name

Usage:

Required

Description:

Variable name to initialize (should be the same name as defined in the source code).

Center
Type:

Array(double)

Value:

\([-\infty;\infty]\)

Usage:

Required

Description:

Speficy \(\vec{b}\).

Sigma
Type:

Array(double)

Value:

\([-\infty;\infty]\)

Usage:

Required

Description:

Speficy \(\vec{\sigma}\).

Base
Type:

Array(double)

Value:

\([-\infty;\infty]\)

Usage:

Required

Description:

Speficy \(d\).

Scaling
Type:

string

Value:

scaled, unscaled

Usage:

Optional

Default:

unscaled

Description:

Scaling factor multiplying the Gaussian function. If unscaled is specified, the scaling is defaulted to \(\sqrt(2\pi) \sigma\).

Scale
Type:

Array(double)

Value:

\([-\infty;\infty]\)

Usage:

Optional if Scaling is set to unscaled.

Default:

\(\sqrt(2\pi) \sigma\)

Description:

Scaling to use when Scaling is set to scaled.

Listing 45 Gaussian initial conditions used in a Vertex-RAD input file.
      <ParameterList name="Gaussian Species 0">
        <Parameter name="Type" type="string" value="Gaussian"/>
        <Parameter name="Scaling" type="string" value="scaled"/>
        <Parameter name="Equation Set Name" type="string" value="species_0"/>
        <Parameter name="Center" type="Array(double)" value="{0.4, 0.5}"/>
        <Parameter name="Base" type="double" value="0.0"/>
        <Parameter name="Sigma" type="Array(double)" value="{0.05, 1000.00}"/>
        <Parameter name="Scale" type="double" value="1.0"/>
      </ParameterList> <!-- Gaussian Species 0 -->
<Inverse Gaussian initial condition>
Type
Type:

string

Value:

InverseGaussian

Usage:

Required

Description:

Gaussian profile with the following definition: \(\frac{1}{d + \prod_{i=0}^{d} a_i \exp \left( (b_i - x_i ) (\frac{1}{2\sigma^2} - x_i) \right)}\)

Equation Set Name
Type:

string

Value:

Variable name

Usage:

Required

Description:

Variable name to initialize (should be the same name as defined in the source code).

Center
Type:

Array(double)

Value:

\([-\infty;\infty]\)

Usage:

Required

Description:

Speficy \(\vec{b}\).

Sigma
Type:

Array(double)

Value:

\([-\infty;\infty]\)

Usage:

Required

Description:

Speficy \(\vec{\sigma}\).

Base
Type:

Array(double)

Value:

\([-\infty;\infty]\)

Usage:

Required

Description:

Speficy \(d\).

Scaling
Type:

string

Value:

scaled, unscaled

Usage:

Optional

Default:

unscaled

Description:

Scaling factor multiplying the Gaussian function. If unscaled is specified, the scaling is defaulted to \(\sqrt(2\pi) \sigma\).

Scale
Type:

Array(double)

Value:

\([-\infty;\infty]\)

Usage:

Optional if Scaling is set to unscaled.

Default:

\(\sqrt(2\pi) \sigma\)

Description:

Scaling to use when Scaling is set to scaled.

<From Solution File>
Type
Type:

string

Value:

From File

Usage:

Required

Description:

Initialize a list of degree of freedoms from an Exodus solution file generated by Vertex-CFD from a previous run. The mesh and basis function type and order must remain the same. The last time step available in the Exodus solution file will be used.

Field Names
Type:

string

Value:

Degree of freedom names separated by a comma.

Usage:

Required

Description:

List of degree of freedoms to initialize. Example of syntax: “lagrange_pressure, velocity_0, velocity_1, temperature”.