chombo-discharge
Public Member Functions | Protected Attributes | List of all members
RtLayout< T > Class Template Reference

Class for holding a set of RtSolvers. T must derive from RtSolver. More...

#include <CD_RtLayout.H>

Public Member Functions

 RtLayout (const Vector< RefCountedPtr< RtSpecies >> &a_RtSpecies)
 Full constructor. More...
 
virtual ~RtLayout ()
 Destructor (does nothing)
 
virtual RtIterator< T > iterator ()
 Get iterator. More...
 
virtual const std::string getRealm () const
 Get realm where the solvers are allocated.
 
virtual void setRealm (const std::string a_realm)
 Set realm for solvers. More...
 
virtual void addSolver (RefCountedPtr< T > a_solver)
 Add a new solver to the solver layout. More...
 
virtual void parseOptions ()
 Parse options.
 
virtual void parseRuntimeOptions ()
 Parse runtime options.
 
virtual void allocate ()
 Allocate internal storage for solvers.
 
virtual void preRegrid (const int a_base, const int a_oldFinestLevel)
 Pre regrid stuff. More...
 
virtual void deallocate ()
 Deallocate internal storage for solvers.
 
virtual void regrid (const int a_lmin, const int a_oldFinestLevel, const int a_newFinestLevel)
 Regrid all solvers. More...
 
virtual void registerOperators ()
 Register operators.
 
virtual void setAmr (const RefCountedPtr< AmrMesh > &a_amr)
 Set amr. More...
 
virtual void setComputationalGeometry (const RefCountedPtr< ComputationalGeometry > &a_computationalGeometry)
 Set the computational geometry. More...
 
virtual void sanityCheck ()
 Do a sanity check.
 
virtual void setPhase (phase::which_phase a_phase=phase::gas)
 Set phase. More...
 
virtual void setVerbosity (const int a_verbosity)
 Set verbosity. More...
 
virtual void setTime (const int a_step, const Real a_time, const Real a_dt)
 Set time. More...
 
virtual void setSource (const EBAMRCellData &a_source)
 Convenience function. Set source terms for all species. Mostly used for debugging. More...
 
virtual void setSource (const Real a_source)
 Convenience function. Set constant source terms for all species. Mostly used for debugging. More...
 
virtual void setStationary (const bool a_stationary)
 Turn on/off stationary. More...
 
virtual void writePlotFile ()
 Convenience function. All solvers write plot files.
 
virtual void advance (const Real a_dt)
 Convenience function. Call advance method for each solver. More...
 
virtual void initialData ()
 Fill with initial data. More...
 
virtual bool isStationary ()
 Check if solvers are stationary.
 
virtual phase::which_phase getPhase ()
 Get phase.
 
virtual Vector< RefCountedPtr< T > > & getSolvers ()
 Get solvers.
 
virtual Vector< RefCountedPtr< RtSpecies > > & getSpecies ()
 Get species.
 
virtual Vector< EBAMRCellData * > getSources ()
 Get all source terms.
 
virtual Vector< EBAMRCellData * > getPhis ()
 Get all states.
 

Protected Attributes

std::string m_realm
 Realm.
 
phase::which_phase m_phase
 Phase.
 
Vector< RefCountedPtr< T > > m_solvers
 Solvers.
 
Vector< RefCountedPtr< RtSpecies > > m_species
 Species.
 
int m_verbosity
 Verbosity.
 

Detailed Description

template<class T>
class RtLayout< T >

Class for holding a set of RtSolvers. T must derive from RtSolver.

Constructor & Destructor Documentation

◆ RtLayout()

template<class T >
RtLayout< T >::RtLayout ( const Vector< RefCountedPtr< RtSpecies >> &  a_RtSpecies)

Full constructor.

Parameters
[in]a_RtSpeciesList of RTE species.

Member Function Documentation

◆ addSolver()

template<class T >
void RtLayout< T >::addSolver ( RefCountedPtr< T >  a_solver)
virtual

Add a new solver to the solver layout.

Parameters
[in]a_solverNew RTE solver.

◆ advance()

template<class T >
void RtLayout< T >::advance ( const Real  a_dt)
virtual

Convenience function. Call advance method for each solver.

Parameters
[in]a_dtAdvance method.

◆ initialData()

template<class T >
void RtLayout< T >::initialData
virtual

Fill with initial data.

Only relevant for transient solvers

◆ iterator()

template<class T >
RtIterator< T > RtLayout< T >::iterator
virtual

Get iterator.

Returns
Returns a new iterator for iterating through the RTE solvers.

◆ preRegrid()

template<class T >
void RtLayout< T >::preRegrid ( const int  a_base,
const int  a_oldFinestLevel 
)
virtual

Pre regrid stuff.

Parameters
[in]a_baseCoarsest level which changes.
[in]a_oldFinestLevelFinest AMR level before regrid.

◆ regrid()

template<class T >
void RtLayout< T >::regrid ( const int  a_lmin,
const int  a_oldFinestLevel,
const int  a_newFinestLevel 
)
virtual

Regrid all solvers.

Parameters
[in]a_lminCoarsest level where grids did not change.
[in]a_oldFinestLevelFinest AMR level before the regrid.
[in]a_newFinestLevelFinest AMR level after the regrid.

◆ setAmr()

template<class T >
void RtLayout< T >::setAmr ( const RefCountedPtr< AmrMesh > &  a_amr)
virtual

Set amr.

Parameters
[in]a_amrAmrMesh object.

◆ setComputationalGeometry()

template<class T >
void RtLayout< T >::setComputationalGeometry ( const RefCountedPtr< ComputationalGeometry > &  a_computationalGeometry)
virtual

Set the computational geometry.

Parameters
[in]a_computationalGeometryComputational geometry.

◆ setPhase()

template<class T >
void RtLayout< T >::setPhase ( phase::which_phase  a_phase = phase::gas)
virtual

Set phase.

This must be done BEFORE callilng setComputationalGeometry

Parameters
[in]a_phasePhase

◆ setRealm()

template<class T >
void RtLayout< T >::setRealm ( const std::string  a_realm)
virtual

Set realm for solvers.

Parameters
[in]a_realmRealm name

◆ setSource() [1/2]

template<class T >
void RtLayout< T >::setSource ( const EBAMRCellData a_source)
virtual

Convenience function. Set source terms for all species. Mostly used for debugging.

Parameters
[in]a_sourceSource term. Copied into every solver's source term.

◆ setSource() [2/2]

template<class T >
void RtLayout< T >::setSource ( const Real  a_source)
virtual

Convenience function. Set constant source terms for all species. Mostly used for debugging.

Parameters
[in]a_sourceSource term set on every solver.

◆ setStationary()

template<class T >
void RtLayout< T >::setStationary ( const bool  a_stationary)
virtual

Turn on/off stationary.

Parameters
[in]a_stationaryIf true, every RTE solver will be set to stationary.

◆ setTime()

template<class T >
void RtLayout< T >::setTime ( const int  a_step,
const Real  a_time,
const Real  a_dt 
)
virtual

Set time.

Parameters
[in]a_stepTime step number
[in]a_timeTime (in seconds)
[in]a_dtTime step increment
Note
This sets m_step=a_step, m_time=a_time, m_dt=a_dt for all solvers.

◆ setVerbosity()

template<class T >
void RtLayout< T >::setVerbosity ( const int  a_verbosity)
virtual

Set verbosity.

Parameters
[in]a_verbosityVerbosity level for solvers.

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