Ember
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | Private Attributes | List of all members
SplitSolver Class Referenceabstract

Implements operator split integration for reacting flow problems. More...

#include <splitSolver.h>

Inheritance diagram for SplitSolver:
[legend]

Public Member Functions

 SplitSolver ()
 
virtual ~SplitSolver ()
 
void setOptions (const ConfigOptions &_options)
 Set configuration options needed by the solver.
 
void resize (index_t nRows, index_t nCols)
 Set the size of all internal arrays when the problem size changes.
 
void calculateTimeDerivatives (double dt)
 Compute estimated time derivatives for each split term based on deltas for each integrator phase.
 
int step ()
 Take one global timestep.
 
virtual void setupStep ()=0
 Take actions at the start of the time step.
 
virtual int finishStep ()=0
 Take actions at the end of a time step.
 
virtual void prepareIntegrators ()=0
 Prepare split term integrators.
 
void integrateSplitTerms (double t, double dt)
 Take one global timestep by integrating the split terms and computing the deltas for each integrator phase.
 
virtual void writeStateFile (const std::string &fileName="", bool errorFile=false, bool updateDerivatives=true)
 Create prof.h5 file.
 
Balanced Strang-split Integration Terms

These functions should be overloaded by derived classes to implement the integration of the split terms.

virtual void integrateConvectionTerms ()=0
 
virtual void integrateProductionTerms ()=0
 
virtual void integrateDiffusionTerms ()=0
 

Public Attributes

dmatrix state
 Current state.
 
dmatrix startState
 State at the start of the current integrator stage.
 
dmatrix deltaConv
 Change in state due to convection terms during the current time step.
 
dmatrix deltaDiff
 Change in state due to diffusion terms during the current time step.
 
dmatrix deltaProd
 Change in state due to production terms during the current time step.
 
dmatrix ddtConv
 Estimated time derivatives of convection terms, based on the deltaConv of the previous time step.
 
dmatrix ddtDiff
 Estimated time derivatives of the diffusion terms, based on the deltaDiff of the previous time step.
 
dmatrix ddtProd
 Estimated time derivatives of production terms, based on the deltaProd of the previous time step.
 
dmatrix ddtCross
 Time derivative associated with terms taken as constant over a time step.
 
dmatrix splitConstConv
 Splitting constants for the convection terms.
 
dmatrix splitConstDiff
 Splitting constants for the diffusion terms.
 
dmatrix splitConstProd
 Splitting constants for the production terms.
 
PerfTimer splitTimer
 Timer for amount of time used by splitting procedure.
 
ConfigOptions options
 Options read from the input file.
 
double tStart
 Integrator start time.
 
double tEnd
 Integrator termination time (upper bound)
 
double tNow
 Current time reached by the integrator.
 
double tStageStart
 Start time for the active integrator stage.
 
double tStageEnd
 End time for the active integrator stage.
 
double t
 start time of the current global timestep
 
double dt
 Global timestep used by the split solver.
 

Private Member Functions

Internal methods for each stages

These methods do the neccessary actions before and after each split integration stage.

void _integrateConvectionTerms (double tStart, double tEnd, int stage)
 
void _integrateProductionTerms (double tStart, double tEnd, int stage)
 
void _integrateDiffusionTerms (double tStart, double tEnd, int stage)
 

Private Attributes

bool useBalancedSplitting
 'true' to use rebalanced splitting, 'false' to use regular Strang splitting
 

Detailed Description

Implements operator split integration for reacting flow problems.

Solves systems of equations with convection, reaction, and diffusion terms using either Strang splitting or rebalanced splitting.

Constructor & Destructor Documentation

◆ SplitSolver()

SplitSolver::SplitSolver ( )
inline

◆ ~SplitSolver()

virtual SplitSolver::~SplitSolver ( )
inlinevirtual

Member Function Documentation

◆ setOptions()

void SplitSolver::setOptions ( const ConfigOptions _options)

Set configuration options needed by the solver.

◆ resize()

void SplitSolver::resize ( index_t  nRows,
index_t  nCols 
)

Set the size of all internal arrays when the problem size changes.

◆ calculateTimeDerivatives()

void SplitSolver::calculateTimeDerivatives ( double  dt)

Compute estimated time derivatives for each split term based on deltas for each integrator phase.

◆ step()

int SplitSolver::step ( )

Take one global timestep.

◆ setupStep()

virtual void SplitSolver::setupStep ( )
pure virtual

Take actions at the start of the time step.

Used by derived classes to perform actions that need to be done at the start of a time step, before the splitting constants are computed.

Implemented in FlameSolver.

◆ finishStep()

virtual int SplitSolver::finishStep ( )
pure virtual

Take actions at the end of a time step.

Used by derived classes to perform any actions that need to be done at the end of the time step, after the time derivatives have been calculated based on the results of integrating the split equations.

Implemented in FlameSolver.

◆ prepareIntegrators()

virtual void SplitSolver::prepareIntegrators ( )
pure virtual

Prepare split term integrators.

Used by derived classes to assign split constants to the integrators for the individual terms and perform any other actions that should take place

Implemented in FlameSolver.

◆ integrateSplitTerms()

void SplitSolver::integrateSplitTerms ( double  t,
double  dt 
)

Take one global timestep by integrating the split terms and computing the deltas for each integrator phase.

◆ integrateConvectionTerms()

virtual void SplitSolver::integrateConvectionTerms ( )
pure virtual

Implemented in FlameSolver.

◆ integrateProductionTerms()

virtual void SplitSolver::integrateProductionTerms ( )
pure virtual

Implemented in FlameSolver.

◆ integrateDiffusionTerms()

virtual void SplitSolver::integrateDiffusionTerms ( )
pure virtual

Implemented in FlameSolver.

◆ writeStateFile()

virtual void SplitSolver::writeStateFile ( const std::string &  fileName = "",
bool  errorFile = false,
bool  updateDerivatives = true 
)
inlinevirtual

Create prof.h5 file.

Parameters
fileNameThe name of the output file.
errorFileSetting this to 'true' will generate a more verbose output file
updateDerivativesSetting this to 'true' will compute time derivatives based on the current state. This flag should only set if all of the solvers and auxillary arrays are sized corresponding to the current state, e.g. after integration but but before regridding.

Reimplemented in FlameSolver.

◆ _integrateConvectionTerms()

void SplitSolver::_integrateConvectionTerms ( double  tStart,
double  tEnd,
int  stage 
)
private

◆ _integrateProductionTerms()

void SplitSolver::_integrateProductionTerms ( double  tStart,
double  tEnd,
int  stage 
)
private

◆ _integrateDiffusionTerms()

void SplitSolver::_integrateDiffusionTerms ( double  tStart,
double  tEnd,
int  stage 
)
private

Member Data Documentation

◆ state

dmatrix SplitSolver::state

Current state.

◆ startState

dmatrix SplitSolver::startState

State at the start of the current integrator stage.

◆ deltaConv

dmatrix SplitSolver::deltaConv

Change in state due to convection terms during the current time step.

◆ deltaDiff

dmatrix SplitSolver::deltaDiff

Change in state due to diffusion terms during the current time step.

◆ deltaProd

dmatrix SplitSolver::deltaProd

Change in state due to production terms during the current time step.

◆ ddtConv

dmatrix SplitSolver::ddtConv

Estimated time derivatives of convection terms, based on the deltaConv of the previous time step.

◆ ddtDiff

dmatrix SplitSolver::ddtDiff

Estimated time derivatives of the diffusion terms, based on the deltaDiff of the previous time step.

◆ ddtProd

dmatrix SplitSolver::ddtProd

Estimated time derivatives of production terms, based on the deltaProd of the previous time step.

◆ ddtCross

dmatrix SplitSolver::ddtCross

Time derivative associated with terms taken as constant over a time step.

These terms are held constant because they depend on state variables that cross the split dimensions, e.g. Soret mass fluxes.

◆ splitConstConv

dmatrix SplitSolver::splitConstConv

Splitting constants for the convection terms.

◆ splitConstDiff

dmatrix SplitSolver::splitConstDiff

Splitting constants for the diffusion terms.

◆ splitConstProd

dmatrix SplitSolver::splitConstProd

Splitting constants for the production terms.

◆ splitTimer

PerfTimer SplitSolver::splitTimer

Timer for amount of time used by splitting procedure.

◆ options

ConfigOptions SplitSolver::options

Options read from the input file.

◆ tStart

double SplitSolver::tStart

Integrator start time.

◆ tEnd

double SplitSolver::tEnd

Integrator termination time (upper bound)

◆ tNow

double SplitSolver::tNow

Current time reached by the integrator.

◆ tStageStart

double SplitSolver::tStageStart

Start time for the active integrator stage.

◆ tStageEnd

double SplitSolver::tStageEnd

End time for the active integrator stage.

◆ t

double SplitSolver::t

start time of the current global timestep

◆ dt

double SplitSolver::dt

Global timestep used by the split solver.

◆ useBalancedSplitting

bool SplitSolver::useBalancedSplitting
private

'true' to use rebalanced splitting, 'false' to use regular Strang splitting


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