![]() |
DamBreak++ Wave Simulator 0.3
DamBreak++ Simulation Framework
|
Global instance of the simulation. Hold the different parameters of run (simulation parameters). Use the CRTP (Curious Recursive Template Pattern) known as static polymorphism) More...
#include <Sfx_SimulationMgr.h>
Public Types | |
enum class | eInitialWaveProfile { SINE , STEP } |
Initial wave profile. More... | |
enum class | eRiverBedType { FLATBED = 0 , ONESTEP = 1 , HYDJUMP = 2 , RANDOM = 3 } |
Bottom topography type. More... | |
enum class | eFrictionType { NoFriction , FrictionValue } |
enum class | ePhysicalBCType { EMcNeilBC , EllignoBC } |
Physical boundary condition. More... |
Public Member Functions | |
void | updateTime () |
Use this method to set the time during any point during the simulation. | |
void | setStartTime (float64 aStartTime) noexcept |
Use this method to specify the time at the start of the simulation. | |
void | setStopTime (float64 aStopTime) noexcept |
simulation stop time | |
void | setNumTimeStep (uint32 aNumTimeStep) noexcept |
Set the number of time-step. | |
float64 | getStartTime () const noexcept |
Getter. | |
float64 | getStopTime () const noexcept |
Getter. | |
float64 | getTime () noexcept |
Getter. | |
void | setTimeStep (const float64 aTimeStep) noexcept |
Setter. | |
float64 | getTimeStep () noexcept |
Time stepping. | |
bool | useFixedTimeStep () noexcept |
Fix/variable time step. | |
bool | onStart () |
Entry point. | |
void | registerSimulator (std::shared_ptr< Sfx::Simulator > aSim) |
Set instance of simulator. | |
void | setTolerance (float32 aTolerance) |
solution accuracy tolerance factor | |
float32 | getTolerance () |
Getter. | |
std::shared_ptr< Sfx::Simulator > | getSimulator () const |
Returns simulator instance. | |
void | setNujicAlphaCoeff (float64 aAlphaCoeff) |
Coefficient used in the numerical flux algorithm (Nujic) | |
float64 | getNujicAlphaCoeff () const |
Nujic coefficent use in Numerical flux calculation. | |
float64 | getCFL () const noexcept |
Courant-Friedrich-Levy number of the simulation. | |
void | setCFL (const float64 aCFL) noexcept |
Set CFL number. | |
bool | useFriction () const noexcept |
Friction flag ON?OFF. | |
void | setUseFriction (bool aUseFriction) noexcept |
Set friction flag ON/OFF. | |
bool | useFlatBed () const noexcept |
Flat bed flag ON/OFF. | |
void | setUseFlatBed (bool aUseFlatBed) noexcept |
Set flat bed flag ON/OFF. | |
bool | isUnitWidth () const noexcept |
void | setManningCoeff (float64 aNcoeff) noexcept |
Manning coefficient. | |
float64 | getManningCoeff () const noexcept |
Manning coefficient. | |
void | setUseSourceTerms (bool aUseSrcTerms) noexcept |
bool | getUseSourceTerms () const noexcept |
bool | usePressure () const noexcept |
void | setUsePressure (bool aUsePressure) noexcept |
void | setUseReconstruction (bool aUseReconstr) noexcept |
bool | useReconstruction () const noexcept |
bool | isRunning () const noexcept |
Simulation status. | |
void | setRunning (bool aIsRunning=true) |
Set simulation status. | |
void | startSimulation () noexcept |
Start simulation. | |
void | stopSimulation () noexcept |
Stop simulation. | |
void | setNbIterationsMax (uint32 aNumOfIterMax) noexcept |
uint32 | getNbIterationsMax () const noexcept |
Geter. | |
void | incrIteration () noexcept |
increment the number of iteration | |
uint32 | getNbIterations () const noexcept |
Getter. | |
void | setNbIterations (uint32 aNumOfIterations) noexcept |
Set number iterations. | |
void | saveScenario () |
parameters used to perform (reproduce) the simulation | |
void | loadSections (std::string_view aFileName="SectionIni.txt") |
load section from input file | |
void | setDBdataType (DamBreakData::eDataTypes aType) noexcept |
Setter. | |
float64 | getPhi0 () const noexcept |
Dam Break problem initial water depth upstream. | |
float64 | getPhi1 () const noexcept |
Dam Break problem initial water depth downstream. | |
void | setPhi1 (float64 aPhi1) noexcept |
Setter. | |
void | setPhi0 (float64 aPhi0) noexcept |
Setter. | |
DamBreakData::eDataTypes | getDBdataType () const noexcept |
std::string | getDBdataTypeStr () const noexcept |
std::string | getAlgorithmName () const |
Flux Numerical algorithm name for the current simulation. | |
void | setMethodName (const std::string &aMethodName) |
std::string | getPtrFluxAlgorithmName () const noexcept |
Numerical algorithm for the current simulation (ptr-2-function) | |
void | setPtrFluxAlgorithmName (const std::string &aMethodName) |
Pointer-to-function name. | |
CalculFF | getPtr2FAlgorithm (const std::string &aMethodName) |
Ptr-2-function convective flux algorithm. | |
CalculFF | currentAlgorithm () const |
Numerical flux algorithm. | |
mapFluxSchemeName | getMapSchemeName () const |
Getter. | |
const std::vector< float64 > & | getBottom () const |
flat bed only supported for now (debug purpose) | |
void | setupEnvironment () |
Manning coefficient. | |
void | printParamOfRun () const |
Print the parameters of run for this simulation. | |
void | setNbSections (uint32 aNbSections) noexcept |
Setter. | |
uint32 | getNbSections () const noexcept |
Getter. | |
void | setSectionType (dbpp::SectionFlow::eSectionType aSectype) noexcept |
Setter. | |
dbpp::SectionFlow::eSectionType | getSectionType () const noexcept |
Getter. | |
void | setDomainExtent (std::pair< float64, float64 > aDomainExt) noexcept |
Set computational domain extent. | |
std::pair< float64, float64 > | getDomainExtent () const noexcept |
Getter. | |
void | setBottomType (const eRiverBedType aBottomType) noexcept |
River bed type. | |
eRiverBedType | getBottomType () const noexcept |
Getter. | |
void | setFrictionValue (float64 aFrictionType) noexcept |
Set section flow friction value. | |
float64 | getFrictionValue () const noexcept |
Global friction value. | |
void | setBCType (const ePhysicalBCType aBCType) noexcept |
Physical boundary type. | |
ePhysicalBCType | getBCType () const noexcept |
void | setInitialWaveForm (eInitialWaveProfile aType) noexcept |
Set/Get Initial profile. | |
eInitialWaveProfile | getInitialWaveForm () const noexcept |
initial wave profile | |
void | registerDamBreakSystem (const Testvs19::DamBreakSystem *aDbSys) |
DamBreak physical system. | |
std::vector< float64 > | getWaterDepth () const |
Getter. |
Protected Member Functions | |
SimulationMgr () | |
Default ctor (protected denied access) | |
~SimulationMgr ()=default | |
Destructor ctor (protected denied access) | |
SimulationMgr (const SimulationMgr &aOther)=delete | |
copy not allowed | |
SimulationMgr & | operator= (const SimulationMgr &aOther)=delete |
assignment not allowed |
Friends | |
template<typename> | |
class | SfxSingleton |
Access to private member. |
Global instance of the simulation. Hold the different parameters of run (simulation parameters). Use the CRTP (Curious Recursive Template Pattern) known as static polymorphism)
|
strong |
|
strong |
|
strong |
|
strong |
|
protected |
Default ctor (protected denied access)
<
|
protecteddefault |
Destructor ctor (protected denied access)
|
protecteddelete |
copy not allowed
aOther | other object to copy from |
|
inline |
Numerical flux algorithm.
|
inline |
Flux Numerical algorithm name for the current simulation.
|
inlinenoexcept |
|
inline |
flat bed only supported for now (debug purpose)
|
inlinenoexcept |
Getter.
|
inlinenoexcept |
Courant-Friedrich-Levy number of the simulation.
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
Getter.
|
inlinenoexcept |
Global friction value.
|
inlinenoexcept |
initial wave profile
|
inlinenoexcept |
Manning coefficient.
|
inline |
Getter.
|
inlinenoexcept |
Getter.
|
inlinenoexcept |
Geter.
|
inlinenoexcept |
Getter.
|
inline |
Nujic coefficent use in Numerical flux calculation.
|
inlinenoexcept |
Dam Break problem initial water depth upstream.
|
inlinenoexcept |
Dam Break problem initial water depth downstream.
CalculFF Sfx::SimulationMgr::getPtr2FAlgorithm | ( | const std::string & | aMethodName | ) |
Ptr-2-function convective flux algorithm.
aMethodName | name of the algorithm |
|
inlinenoexcept |
Numerical algorithm for the current simulation (ptr-2-function)
|
inlinenoexcept |
Getter.
|
inline |
Returns simulator instance.
|
inlinenoexcept |
Getter.
|
inlinenoexcept |
Getter.
|
inlinenoexcept |
Getter.
|
inlinenoexcept |
Time stepping.
|
inline |
Getter.
|
inlinenoexcept |
|
inline |
Getter.
|
inlinenoexcept |
increment the number of iteration
|
inlinenoexcept |
Simulation status.
|
inlinenoexcept |
|
inline |
load section from input file
aFileName | file name |
bool Sfx::SimulationMgr::onStart | ( | ) |
|
protecteddelete |
assignment not allowed
aOther | other object to copy from |
void Sfx::SimulationMgr::printParamOfRun | ( | ) | const |
Print the parameters of run for this simulation.
|
inline |
DamBreak physical system.
aDbSys | Physical system |
|
inline |
Set instance of simulator.
aSim | DamBreak simulator instance |
|
inline |
parameters used to perform (reproduce) the simulation
|
inlinenoexcept |
Physical boundary type.
aBCType | boundary type |
|
inlinenoexcept |
River bed type.
aBottomType | bottom type |
|
inlinenoexcept |
Set CFL number.
aCFL | cfl value |
|
inlinenoexcept |
Setter.
aType | Dam Break data type |
|
inlinenoexcept |
Set computational domain extent.
aDomainExt | pair of values (min,max) |
|
inlinenoexcept |
Set section flow friction value.
aFrictionType | friction value |
|
inlinenoexcept |
Set/Get Initial profile.
aType | initial profile |
|
inlinenoexcept |
Manning coefficient.
aNcoeff | values (all sections) |
|
inline |
|
inlinenoexcept |
Set number iterations.
aNumOfIterations | number of iterations |
|
inlinenoexcept |
aNumOfIterMax |
|
inlinenoexcept |
Setter.
aNbSections | number of section |
|
inline |
Coefficient used in the numerical flux algorithm (Nujic)
aAlphaCoeff | Nujic coefficienty |
|
inlinenoexcept |
Set the number of time-step.
aNumTimeStep |
|
inlinenoexcept |
Setter.
aPhi0 | value to set downstream |
|
inlinenoexcept |
Setter.
aPhi1 | value to set upstream |
|
inline |
Pointer-to-function name.
aMethodName | name of the function |
|
inline |
Set simulation status.
aIsRunning | default is true |
|
inlinenoexcept |
Setter.
aSectype | section geometry type |
|
inlinenoexcept |
Use this method to specify the time at the start of the simulation.
|
inlinenoexcept |
simulation stop time
aStopTime | a time to stop |
|
inlinenoexcept |
Setter.
aTimeStep | Simulation time step |
|
inline |
solution accuracy tolerance factor
aTolerance | accuracy tolerance |
void Sfx::SimulationMgr::setupEnvironment | ( | ) |
Manning coefficient.
Setting some path and environment variable
|
inlinenoexcept |
Set flat bed flag ON/OFF.
aUseFlatBed |
|
inlinenoexcept |
Set friction flag ON/OFF.
aUseFriction | boolean value |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
Start simulation.
|
inlinenoexcept |
Stop simulation.
|
inline |
Use this method to set the time during any point during the simulation.
|
inlinenoexcept |
Fix/variable time step.
|
inlinenoexcept |
Flat bed flag ON/OFF.
|
inlinenoexcept |
Friction flag ON?OFF.
|
inlinenoexcept |
|
inlinenoexcept |
|
friend |
Access to private member.
simulation | instance |
|
private |
Numerical Flux Face algorithm
|
private |
...
|
private |
|
private |
Courant-Friedrich-Levy number
|
private |
|
private |
reference to the simulator
|
private |
Hudson as default, otherwise EMcNeil
|
private |
|
private |
|
private |
...
|
private |
|
private |
|
private |
...
|
private |
maximum step size (dt)
|
private |
flux algoritm name
|
private |
|
private |
number of iterations
|
private |
maximum number of iterations
|
private |
|
private |
number of time step for the simulation
|
private |
|
private |
|
private |
|
private |
Map the different algorithm with a string (name)
|
private |
|
private |
|
private |
...
|
private |
State variables count (number of state variables)
|
private |
...
|
private |
file name for stocking final profile
|
private |
Time step (currrent)
|
private |
Tolerance factor
|
private |
flag (default w_valPrmue is false)
|
private |
|
private |
flag (default w_value is false)
|
private |
flag (default w_value is false)
|
private |
flag (default w_value is true)
|
private |
flag (default w_value is true)