ECOGEN 4.0
Evolutive, Compressible, Open, Genuine, Easy, N-phase
Loading...
Searching...
No Matches
Run Class Reference

Class regrouping all information for a simulation. More...

#include <Run.h>

Public Member Functions

 Run (std::string nameCasTest, const int &number)
 
 ~Run ()
 
void initialize ()
 Initialization of the simulation.
 
void solver ()
 Hyperbolic resolution + Relaxations + Source terms integration.
 
void finalize ()
 Cleaning simulation.
 
void restartSimulation ()
 
void restartSimulationMeshMapping (std::vector< GeometricalDomain * > &domains, Mesh *mesh)
 
const int & getNumberPhases () const
 

Private Member Functions

void integrationProcedure (double &dt, int lvl, double &dtMax, int &nbCellsTotalAMR)
 
void advancingProcedure (double &dt, int &lvl, double &dtMax)
 
void solveHyperbolic (double &dt, int &lvl, double &dtMax)
 
void solveHyperbolicO2 (double &dt, int &lvl, double &dtMax)
 
void solveAdditionalPhysics (double &dt, int &lvl)
 
void solveSourceTerms (double &dt, int &lvl)
 
void solveRelaxations (double &dt, int &lvl)
 
void verifyErrors () const
 

Private Attributes

int m_numTest
 Number of the simulation.
 
std::string m_simulationName
 Name of the simulation.
 
bool m_timeControlIterations
 Choice for time control mode (iteration or physical time)
 
int m_nbIte
 
int m_freq
 Requested number of final time iteration and frequency.
 
double m_finalPhysicalTime
 
double m_timeFreq
 Requested final physical time of the simulation and time frequency for output printing.
 
double m_cfl
 CFL criteria (between 0 and 1)
 
int m_numberPhases
 Number of phases.
 
int m_numberSolids
 Number of solid phases.
 
int m_numberEos
 Number of equations of states.
 
int m_numberTransports
 Number of additional transport variables.
 
int m_numberAddPhys
 Number of additional physical effects.
 
int m_numberSources
 Number of additional source terms.
 
int m_dimension
 dimension 1, 2 or 3
 
int m_MRF
 source term for Moving Reference Frame computation index(in the list of source term)
 
bool m_viscous
 Viscous flow additionnal physic option required to set proper wall boundary condition (false by default)
 
std::string m_order
 Precision scheme order (firstorder or secondOrder)
 
bool m_extractRefLength
 Option to extract cells' reference length.
 
std::vector< GeometricalDomain * > m_solidDomains
 Solid domains (immersed boundaries)
 
int m_lvlMax
 Maximum AMR level (if 0, then no AMR)
 
int m_nbCellsTotalAMR
 Number of total cells during the simulation.
 
bool m_parallelPreTreatment
 Choice for mesh parallel pre-treatment (needed for first simulation on a new parallel unstructured geometry)
 
bool m_smoothCrossSection1d
 1D with smooth cross section variation scheme if active
 
Meshm_mesh
 Mesh type object: contains all geometrical properties of the simulation.
 
Modelm_model
 Model type object: contains the flow model methods.
 
Gradientm_gradient
 Gradient type object: contains the gradient method.
 
TypeMeshContainer< Cell * > * m_cellsLvl
 Array of vectors (one per level) of computational cell objects: Contains physical fluid states.
 
TypeMeshContainer< Cell * > * m_cellsLvlGhost
 Array of vectors (one per level) of ghost cell objects.
 
TypeMeshContainer< CellInterface * > * m_cellInterfacesLvl
 Array of vectors (one per level) of interface objects between cells (or between a cell and a physical domain boundary)
 
Eos ** m_eos
 Array of Equations of states: Contains fluid EOS parameters.
 
std::vector< AddPhys * > m_addPhys
 Vector of Additional physics.
 
Symmetrym_symmetry
 Specific object for symmetry (cylindrical or spherical) if active.
 
std::vector< Source * > m_sources
 Vector of source terms.
 
Limiterm_globalLimiter
 Slope limiter type object for second order in space.
 
Limiterm_interfaceLimiter
 Slope limiter type object for second order in space specific to interface location.
 
Limiterm_globalVolumeFractionLimiter
 Slope limiter type object for second order in space specific to interface advected variables (alpha, transports)
 
Limiterm_interfaceVolumeFractionLimiter
 Slope limiter type object for second order in space specific to interface advected variables (alpha, transports) and to interface location.
 
std::vector< std::string > m_nameGTR
 Vector of transport variable names.
 
std::vector< std::string > m_nameQPA
 Vector of names of the quantities of additional physics.
 
std::vector< std::string > m_nameGPH
 Vector of phasic variables name.
 
double m_dt
 Explicit time step.
 
double m_dtNext
 Next time step.
 
double m_physicalTime
 Physical time.
 
int m_iteration
 time iteration number
 
int m_restartSimulation
 File number for restarting a simulation.
 
int m_restartAMRsaveFreq
 Frequency at which a save to restart a simulation is done (usefull only for AMR)
 
Inputm_input
 Input object.
 
Outputm_outPut
 Main output object.
 
std::vector< Output * > m_cuts
 Vector of output objects for cuts.
 
std::vector< Output * > m_probes
 Vector of output objects for probes.
 
std::vector< Output * > m_globalQuantities
 Vector of output objects for global quantities (mass or total energy)
 
std::vector< Output * > m_recordBoundaries
 Vector of output object for boundaries data recording.
 
timeStats m_stat
 Object linked to computational time statistics.
 
double * m_pMax
 Maximal pressure found between each written output (only for few test cases)
 
double * m_pMaxWall
 Coordinate of the maximal pressure found between each written output (only for few test cases)
 
double m_volumePhaseK
 Volume of phase k. Output with purpose to track the radius of a bubble over time.
 
double m_massWanted
 
double m_alphaWanted
 Mass and corresponding volume fraction for special output (only for few test cases)
 
bool m_recordPsat
 Add recording of saturation pressure (valid for a liquid/vapor couple and predominant phase should be first)
 
bool m_restartMeshMapping
 Option to set the mesh mapping restart option.
 
Outputm_outputMeshMapping
 Output object containing info from simulation to be mapped (usually the rough mesh)
 
std::string m_meshFileMapped
 Filename of the mesh to be mapped.
 

Friends

class Input
 
class Output
 
class OutputXML
 
class OutputGNU
 
class OutputProbeGNU
 
class OutputGlobalGNU
 
class OutputBoundaryGNU
 
class OutputBoundaryFluxGNU
 
class OutputBoundaryAllGNU
 
class Mesh
 

Detailed Description

Class regrouping all information for a simulation.

Constructor & Destructor Documentation

◆ Run()

Run::Run ( std::string  nameCasTest,
const int &  number 
)

◆ ~Run()

Run::~Run ( )

Member Function Documentation

◆ advancingProcedure()

void Run::advancingProcedure ( double &  dt,
int &  lvl,
double &  dtMax 
)
private

◆ finalize()

void Run::finalize ( )

Cleaning simulation.

Memory desallocations

◆ getNumberPhases()

const int & Run::getNumberPhases ( ) const
inline

◆ initialize()

void Run::initialize ( )

Initialization of the simulation.

◆ integrationProcedure()

void Run::integrationProcedure ( double &  dt,
int  lvl,
double &  dtMax,
int &  nbCellsTotalAMR 
)
private

◆ restartSimulation()

void Run::restartSimulation ( )

◆ restartSimulationMeshMapping()

void Run::restartSimulationMeshMapping ( std::vector< GeometricalDomain * > &  domains,
Mesh mesh 
)

◆ solveAdditionalPhysics()

void Run::solveAdditionalPhysics ( double &  dt,
int &  lvl 
)
private

◆ solveHyperbolic()

void Run::solveHyperbolic ( double &  dt,
int &  lvl,
double &  dtMax 
)
private

◆ solveHyperbolicO2()

void Run::solveHyperbolicO2 ( double &  dt,
int &  lvl,
double &  dtMax 
)
private

◆ solver()

void Run::solver ( )

Hyperbolic resolution + Relaxations + Source terms integration.

Hyperbolic part is solved using Finite Volume method :

\[ \frac{U^{n+1}_i-U^{n}_i}{\Delta t} = -\sum_{faces} \vec{F}^*_f \cdot \vec{n}_f \]

◆ solveRelaxations()

void Run::solveRelaxations ( double &  dt,
int &  lvl 
)
private

◆ solveSourceTerms()

void Run::solveSourceTerms ( double &  dt,
int &  lvl 
)
private

◆ verifyErrors()

void Run::verifyErrors ( ) const
private

Friends And Related Symbol Documentation

◆ Input

friend class Input
friend

◆ Mesh

friend class Mesh
friend

◆ Output

friend class Output
friend

◆ OutputBoundaryAllGNU

friend class OutputBoundaryAllGNU
friend

◆ OutputBoundaryFluxGNU

friend class OutputBoundaryFluxGNU
friend

◆ OutputBoundaryGNU

friend class OutputBoundaryGNU
friend

◆ OutputGlobalGNU

friend class OutputGlobalGNU
friend

◆ OutputGNU

friend class OutputGNU
friend

◆ OutputProbeGNU

friend class OutputProbeGNU
friend

◆ OutputXML

friend class OutputXML
friend

Member Data Documentation

◆ m_addPhys

std::vector<AddPhys*> Run::m_addPhys
private

Vector of Additional physics.

◆ m_alphaWanted

double Run::m_alphaWanted
private

Mass and corresponding volume fraction for special output (only for few test cases)

◆ m_cellInterfacesLvl

TypeMeshContainer<CellInterface*>* Run::m_cellInterfacesLvl
private

Array of vectors (one per level) of interface objects between cells (or between a cell and a physical domain boundary)

◆ m_cellsLvl

TypeMeshContainer<Cell*>* Run::m_cellsLvl
private

Array of vectors (one per level) of computational cell objects: Contains physical fluid states.

◆ m_cellsLvlGhost

TypeMeshContainer<Cell*>* Run::m_cellsLvlGhost
private

Array of vectors (one per level) of ghost cell objects.

◆ m_cfl

double Run::m_cfl
private

CFL criteria (between 0 and 1)

◆ m_cuts

std::vector<Output*> Run::m_cuts
private

Vector of output objects for cuts.

◆ m_dimension

int Run::m_dimension
private

dimension 1, 2 or 3

◆ m_dt

double Run::m_dt
private

Explicit time step.

◆ m_dtNext

double Run::m_dtNext
private

Next time step.

◆ m_eos

Eos** Run::m_eos
private

Array of Equations of states: Contains fluid EOS parameters.

◆ m_extractRefLength

bool Run::m_extractRefLength
private

Option to extract cells' reference length.

◆ m_finalPhysicalTime

double Run::m_finalPhysicalTime
private

◆ m_freq

int Run::m_freq
private

Requested number of final time iteration and frequency.

◆ m_globalLimiter

Limiter* Run::m_globalLimiter
private

Slope limiter type object for second order in space.

◆ m_globalQuantities

std::vector<Output*> Run::m_globalQuantities
private

Vector of output objects for global quantities (mass or total energy)

◆ m_globalVolumeFractionLimiter

Limiter* Run::m_globalVolumeFractionLimiter
private

Slope limiter type object for second order in space specific to interface advected variables (alpha, transports)

◆ m_gradient

Gradient* Run::m_gradient
private

Gradient type object: contains the gradient method.

◆ m_input

Input* Run::m_input
private

Input object.

◆ m_interfaceLimiter

Limiter* Run::m_interfaceLimiter
private

Slope limiter type object for second order in space specific to interface location.

◆ m_interfaceVolumeFractionLimiter

Limiter* Run::m_interfaceVolumeFractionLimiter
private

Slope limiter type object for second order in space specific to interface advected variables (alpha, transports) and to interface location.

◆ m_iteration

int Run::m_iteration
private

time iteration number

◆ m_lvlMax

int Run::m_lvlMax
private

Maximum AMR level (if 0, then no AMR)

◆ m_massWanted

double Run::m_massWanted
private

◆ m_mesh

Mesh* Run::m_mesh
private

Mesh type object: contains all geometrical properties of the simulation.

◆ m_meshFileMapped

std::string Run::m_meshFileMapped
private

Filename of the mesh to be mapped.

◆ m_model

Model* Run::m_model
private

Model type object: contains the flow model methods.

◆ m_MRF

int Run::m_MRF
private

source term for Moving Reference Frame computation index(in the list of source term)

◆ m_nameGPH

std::vector<std::string> Run::m_nameGPH
private

Vector of phasic variables name.

◆ m_nameGTR

std::vector<std::string> Run::m_nameGTR
private

Vector of transport variable names.

◆ m_nameQPA

std::vector<std::string> Run::m_nameQPA
private

Vector of names of the quantities of additional physics.

◆ m_nbCellsTotalAMR

int Run::m_nbCellsTotalAMR
private

Number of total cells during the simulation.

◆ m_nbIte

int Run::m_nbIte
private

◆ m_numberAddPhys

int Run::m_numberAddPhys
private

Number of additional physical effects.

◆ m_numberEos

int Run::m_numberEos
private

Number of equations of states.

◆ m_numberPhases

int Run::m_numberPhases
private

Number of phases.

◆ m_numberSolids

int Run::m_numberSolids
private

Number of solid phases.

◆ m_numberSources

int Run::m_numberSources
private

Number of additional source terms.

◆ m_numberTransports

int Run::m_numberTransports
private

Number of additional transport variables.

◆ m_numTest

int Run::m_numTest
private

Number of the simulation.

◆ m_order

std::string Run::m_order
private

Precision scheme order (firstorder or secondOrder)

◆ m_outPut

Output* Run::m_outPut
private

Main output object.

◆ m_outputMeshMapping

Output* Run::m_outputMeshMapping
private

Output object containing info from simulation to be mapped (usually the rough mesh)

◆ m_parallelPreTreatment

bool Run::m_parallelPreTreatment
private

Choice for mesh parallel pre-treatment (needed for first simulation on a new parallel unstructured geometry)

◆ m_physicalTime

double Run::m_physicalTime
private

Physical time.

◆ m_pMax

double* Run::m_pMax
private

Maximal pressure found between each written output (only for few test cases)

◆ m_pMaxWall

double* Run::m_pMaxWall
private

Coordinate of the maximal pressure found between each written output (only for few test cases)

◆ m_probes

std::vector<Output*> Run::m_probes
private

Vector of output objects for probes.

◆ m_recordBoundaries

std::vector<Output*> Run::m_recordBoundaries
private

Vector of output object for boundaries data recording.

◆ m_recordPsat

bool Run::m_recordPsat
private

Add recording of saturation pressure (valid for a liquid/vapor couple and predominant phase should be first)

◆ m_restartAMRsaveFreq

int Run::m_restartAMRsaveFreq
private

Frequency at which a save to restart a simulation is done (usefull only for AMR)

◆ m_restartMeshMapping

bool Run::m_restartMeshMapping
private

Option to set the mesh mapping restart option.

◆ m_restartSimulation

int Run::m_restartSimulation
private

File number for restarting a simulation.

◆ m_simulationName

std::string Run::m_simulationName
private

Name of the simulation.

◆ m_smoothCrossSection1d

bool Run::m_smoothCrossSection1d
private

1D with smooth cross section variation scheme if active

◆ m_solidDomains

std::vector<GeometricalDomain*> Run::m_solidDomains
private

Solid domains (immersed boundaries)

◆ m_sources

std::vector<Source*> Run::m_sources
private

Vector of source terms.

◆ m_stat

timeStats Run::m_stat
private

Object linked to computational time statistics.

◆ m_symmetry

Symmetry* Run::m_symmetry
private

Specific object for symmetry (cylindrical or spherical) if active.

◆ m_timeControlIterations

bool Run::m_timeControlIterations
private

Choice for time control mode (iteration or physical time)

◆ m_timeFreq

double Run::m_timeFreq
private

Requested final physical time of the simulation and time frequency for output printing.

◆ m_viscous

bool Run::m_viscous
private

Viscous flow additionnal physic option required to set proper wall boundary condition (false by default)

◆ m_volumePhaseK

double Run::m_volumePhaseK
private

Volume of phase k. Output with purpose to track the radius of a bubble over time.


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