MAIA bb96820c
Multiphysics at AIA
Loading...
Searching...
No Matches
MPrimitiveVariables< nDim > Class Template Reference

Storage of the Position of the Primitive Variables (u, v, w, T, p) in the value vectors of the solvers ans surfaces. More...

#include <variables.h>

Inheritance diagram for MPrimitiveVariables< nDim >:
[legend]
Collaboration diagram for MPrimitiveVariables< nDim >:
[legend]

Public Member Functions

 MPrimitiveVariables (MInt noSpecies, MInt noRANSEq=0)
 Sets the position for the primitive variables. More...
 
 ~MPrimitiveVariables ()
 

Public Attributes

std::array< MInt, 3 > VV = {0, 1, 2}
 
MIntY
 Position of Yi. More...
 
MInt RANS_FIRST
 first Position of RANS Variables More...
 
MIntRANS_VAR
 Position of RANS Variables. More...
 
MInt noVariables
 The Nr. of primitive variables (nDim + 2) More...
 
MInt m_noSpecies
 
MInt m_noRansEquations
 
MFloat UInfinity {}
 
MFloat VInfinity {}
 
MFloat WInfinity {}
 
MFloat PInfinity {}
 
MFloat TInfinity {}
 
std::array< MFloat, nDim > VVInfinity
 
std::array< MFloat, nDim > ransInfinity
 
MFloat DthInfinity {}
 
MFloat muInfinity {}
 
MFloat DInfinity {}
 

Static Public Attributes

static constexpr MInt U = 0
 Position of U. More...
 
static constexpr MInt V = 1
 Position of V. More...
 
static constexpr MInt W = 2
 Position of W. More...
 
static constexpr std::array< MInt, 3 > VV = {0, 1, 2}
 Pointer for the velocities so you can use them in a loop. More...
 
static constexpr MInt P = nDim + 1
 Position of P. More...
 
static constexpr MInt RHO = nDim
 Position of RHO (equal to P in this case) More...
 
static constexpr MInt T = nDim + 1
 Position of T. More...
 
static constexpr MInt Z = nDim + 2
 Position of Z. More...
 
static constexpr MInt C = nDim + 2
 Position of C. More...
 

Detailed Description

template<MInt nDim>
class MPrimitiveVariables< nDim >
Date
begin: 00.05.19 change 00.05.19

If you search for a value in a value vector you only have to type in the name of the value you are searching (e.g. variables[T])

Warning
Be careful! Some value vectors include the conservative, others the primitive Variables

Definition at line 110 of file variables.h.

Constructor & Destructor Documentation

◆ MPrimitiveVariables()

template<MInt nDim>
MPrimitiveVariables< nDim >::MPrimitiveVariables ( MInt  noSpecies,
MInt  noRANSEq = 0 
)
inlineexplicit

Definition at line 113 of file variables.h.

113 {
114 m_noSpecies = noSpecies;
115 m_noRansEquations = noRANSEq;
116
117 Y = new MInt[m_noSpecies];
118 for(MInt i = 0; i < m_noSpecies; i++) {
119 Y[i] = Z + i;
120 }
121 // G = nDim+1;
122
123 RANS_FIRST = nDim + 2;
124 if(m_noSpecies != 0) {
125 RANS_FIRST = nDim + 2 + m_noSpecies;
126 }
127 if(m_noRansEquations > 0) {
129 for(MInt i = 0; i < m_noRansEquations; ++i) {
130 RANS_VAR[i] = RANS_FIRST + i;
131 }
132 } else {
133 RANS_VAR = nullptr;
134 }
135
137 }
MInt RANS_FIRST
first Position of RANS Variables
Definition: variables.h:170
MInt * Y
Position of Yi.
Definition: variables.h:168
static constexpr MInt Z
Position of Z.
Definition: variables.h:164
MInt noVariables
The Nr. of primitive variables (nDim + 2)
Definition: variables.h:175
MInt * RANS_VAR
Position of RANS Variables.
Definition: variables.h:172
int32_t MInt
Definition: maiatypes.h:62

◆ ~MPrimitiveVariables()

template<MInt nDim>
MPrimitiveVariables< nDim >::~MPrimitiveVariables ( )
inline

Definition at line 138 of file variables.h.

138 {
139 delete[] Y;
140 if(RANS_VAR != nullptr) {
141 delete[] RANS_VAR;
142 }
143 }

Member Data Documentation

◆ C

template<MInt nDim>
constexpr MInt MPrimitiveVariables< nDim >::C = nDim + 2
staticconstexpr

Definition at line 166 of file variables.h.

◆ DInfinity

template<MInt nDim>
MFloat MPrimitiveVariables< nDim >::DInfinity {}

Definition at line 181 of file variables.h.

◆ DthInfinity

template<MInt nDim>
MFloat MPrimitiveVariables< nDim >::DthInfinity {}

Definition at line 181 of file variables.h.

◆ m_noRansEquations

template<MInt nDim>
MInt MPrimitiveVariables< nDim >::m_noRansEquations

Definition at line 177 of file variables.h.

◆ m_noSpecies

template<MInt nDim>
MInt MPrimitiveVariables< nDim >::m_noSpecies

Definition at line 176 of file variables.h.

◆ muInfinity

template<MInt nDim>
MFloat MPrimitiveVariables< nDim >::muInfinity {}

Definition at line 181 of file variables.h.

◆ noVariables

template<MInt nDim>
MInt MPrimitiveVariables< nDim >::noVariables

Definition at line 175 of file variables.h.

◆ P

template<MInt nDim>
constexpr MInt MPrimitiveVariables< nDim >::P = nDim + 1
staticconstexpr

Definition at line 158 of file variables.h.

◆ PInfinity

template<MInt nDim>
MFloat MPrimitiveVariables< nDim >::PInfinity {}

Definition at line 178 of file variables.h.

◆ RANS_FIRST

template<MInt nDim>
MInt MPrimitiveVariables< nDim >::RANS_FIRST

Definition at line 170 of file variables.h.

◆ RANS_VAR

template<MInt nDim>
MInt* MPrimitiveVariables< nDim >::RANS_VAR

Definition at line 172 of file variables.h.

◆ ransInfinity

template<MInt nDim>
std::array<MFloat, nDim> MPrimitiveVariables< nDim >::ransInfinity

Definition at line 180 of file variables.h.

◆ RHO

template<MInt nDim>
constexpr MInt MPrimitiveVariables< nDim >::RHO = nDim
staticconstexpr

Definition at line 160 of file variables.h.

◆ T

template<MInt nDim>
constexpr MInt MPrimitiveVariables< nDim >::T = nDim + 1
staticconstexpr

Definition at line 162 of file variables.h.

◆ TInfinity

template<MInt nDim>
MFloat MPrimitiveVariables< nDim >::TInfinity {}

Definition at line 178 of file variables.h.

◆ U

template<MInt nDim>
constexpr MInt MPrimitiveVariables< nDim >::U = 0
staticconstexpr

Definition at line 146 of file variables.h.

◆ UInfinity

template<MInt nDim>
MFloat MPrimitiveVariables< nDim >::UInfinity {}

Definition at line 178 of file variables.h.

◆ V

template<MInt nDim>
constexpr MInt MPrimitiveVariables< nDim >::V = 1
staticconstexpr

Definition at line 148 of file variables.h.

◆ VInfinity

template<MInt nDim>
MFloat MPrimitiveVariables< nDim >::VInfinity {}

Definition at line 178 of file variables.h.

◆ VV [1/2]

template<MInt nDim>
constexpr std::array<MInt, 3> MPrimitiveVariables< nDim >::VV = {0, 1, 2}
staticconstexpr

Definition at line 153 of file variables.h.

◆ VV [2/2]

template<MInt nDim>
std::array<MInt, 3> MPrimitiveVariables< nDim >::VV = {0, 1, 2}

Definition at line 155 of file variables.h.

◆ VVInfinity

template<MInt nDim>
std::array<MFloat, nDim> MPrimitiveVariables< nDim >::VVInfinity

Definition at line 179 of file variables.h.

◆ W

template<MInt nDim>
constexpr MInt MPrimitiveVariables< nDim >::W = 2
staticconstexpr

Definition at line 150 of file variables.h.

◆ WInfinity

template<MInt nDim>
MFloat MPrimitiveVariables< nDim >::WInfinity {}

Definition at line 178 of file variables.h.

◆ Y

template<MInt nDim>
MInt* MPrimitiveVariables< nDim >::Y

Definition at line 168 of file variables.h.

◆ Z

template<MInt nDim>
constexpr MInt MPrimitiveVariables< nDim >::Z = nDim + 2
staticconstexpr

Definition at line 164 of file variables.h.


The documentation for this class was generated from the following file: