Peano 4
Loading...
Searching...
No Matches
examples::exahype2::loh1::AbstractLOH1OnGPU Class Referenceabstract

#include <AbstractLOH1OnGPU.h>

Inheritance diagram for examples::exahype2::loh1::AbstractLOH1OnGPU:
Collaboration diagram for examples::exahype2::loh1::AbstractLOH1OnGPU:

Public Types

enum class  SolverState {
  GridConstruction , GridInitialisation , Primary , Secondary ,
  PlottingInitialCondition , PrimaryAfterGridInitialisation , Plotting
}
 
- Public Types inherited from exahype2::Solver
enum class  Offloadable { Yes }
 This is a "fake" enum, i.e. More...
 

Public Member Functions

 AbstractLOH1OnGPU ()
 
double getMinTimeStamp () const final
 
double getMaxTimeStamp () const final
 
double getMinTimeStepSize () const final
 
double getMaxTimeStepSize () const final
 
virtual::exahype2::RefinementCommand refinementCriterion (const double *__restrict__ Q, const tarch::la::Vector< Dimensions, double > &volumeCentre, const tarch::la::Vector< Dimensions, double > &volumeH, double t) final
 
virtual void adjustSolution (double *__restrict__ Q, const tarch::la::Vector< Dimensions, double > &volumeCentre, const tarch::la::Vector< Dimensions, double > &volumeH, double t, double dt)=0
 Feel free to change the solution in the particular finite volume.
 
virtual void boundaryConditions (const double *__restrict__ Qinside, double *__restrict__ Qoutside, const tarch::la::Vector< Dimensions, double > &faceCentre, const tarch::la::Vector< Dimensions, double > &volumeH, double t, int normal)=0
 Apply boundary conditions.
 
void startGridConstructionStep () override
 If you hook into this routine, ensure the abstract base class operation is still invoked.
 
void finishGridConstructionStep () override
 If you hook into this routine, ensure the abstract base class operation is still invoked.
 
void startGridInitialisationStep () override
 If you hook into this routine, ensure the abstract base class operation is still invoked.
 
void finishGridInitialisationStep () override
 If you hook into this routine, ensure the abstract base class operation is still invoked.
 
void startTimeStep (double globalMinTimeStamp, double globalMaxTimeStamp, double globalMinTimeStepSize, double globalMaxTimeStepSize) override
 If you hook into this routine, ensure the abstract base class operation is still invoked.
 
void finishTimeStep () override
 If you hook into this routine, ensure the abstract base class operation is still invoked.
 
void startPlottingStep (double globalMinTimeStamp, double globalMaxTimeStamp, double globalMinTimeStepSize, double globalMaxTimeStepSize) override
 If you hook into this routine, ensure the abstract base class operation is still invoked.
 
void finishPlottingStep () override
 If you hook into this routine, ensure the abstract base class operation is still invoked.
 
double getMaxMeshSize () const override
 
double getMinMeshSize () const override
 
SolverState getSolverState () const
 
- Public Member Functions inherited from exahype2::Solver
virtual double getMinTimeStamp (bool ofLastTimeStepOnly=false) const =0
 There are two different falvours of a minimal time stamp: On the one hand, there's a global minimum time stamp over the whole mesh.
 
virtual double getMaxTimeStamp (bool ofLastTimeStepOnly=false) const =0
 
virtual void suspendSolversForOneGridSweep ()=0
 
virtual bool mayPlot () const =0
 Not all solvers allow you to plot after each grid sweep.
 
virtual void startSimulation ()=0
 
virtual void finishSimulation ()=0
 

Static Public Member Functions

static std::string toString (SolverState)
 
static void sourceTerm (const double *__restrict__ Q, const tarch::la::Vector< Dimensions, double > &volumeCentre, const tarch::la::Vector< Dimensions, double > &volumeH, double t, double dt, double *__restrict__ S)
 

Static Public Attributes

static std::bitset< Dimensions > PeriodicBC
 Alias for periodic boundary conditions.
 

Protected Attributes

const int _NumberOfFiniteVolumesPerAxisPerPatch
 
double _timeStamp
 
SolverState _solverState
 
double _maxH
 
double _minH
 

Static Protected Attributes

static tarch::logging::Log _log
 

Detailed Description

Definition at line 32 of file AbstractLOH1OnGPU.h.

Member Enumeration Documentation

◆ SolverState

Enumerator
GridConstruction 
GridInitialisation 
Primary 
Secondary 
PlottingInitialCondition 
PrimaryAfterGridInitialisation 
Plotting 

Definition at line 34 of file AbstractLOH1OnGPU.h.

Constructor & Destructor Documentation

◆ AbstractLOH1OnGPU()

examples::exahype2::loh1::AbstractLOH1OnGPU::AbstractLOH1OnGPU ( )

Definition at line 73 of file AbstractLOH1OnGPU.cpp.

Member Function Documentation

◆ adjustSolution()

virtual void examples::exahype2::loh1::AbstractLOH1OnGPU::adjustSolution ( double *__restrict__ Q,
const tarch::la::Vector< Dimensions, double > & volumeCentre,
const tarch::la::Vector< Dimensions, double > & volumeH,
double t,
double dt )
pure virtual

Feel free to change the solution in the particular finite volume.

You can for example change the initial conditions by overwriting the solution for t=0. You may change Q. All other parameters are in.

Implemented in examples::exahype2::loh1::LOH1OnGPU.

◆ boundaryConditions()

virtual void examples::exahype2::loh1::AbstractLOH1OnGPU::boundaryConditions ( const double *__restrict__ Qinside,
double *__restrict__ Qoutside,
const tarch::la::Vector< Dimensions, double > & faceCentre,
const tarch::la::Vector< Dimensions, double > & volumeH,
double t,
int normal )
pure virtual

Apply boundary conditions.

You can overwrite both the inside and outside values though most BCs only modify the outside ones. Please note that the boundary conditions you set here are after that subject to the Riemann solver, i.e. flux and eigenvalues.

Implemented in examples::exahype2::loh1::LOH1OnGPU.

◆ finishGridConstructionStep()

void examples::exahype2::loh1::AbstractLOH1OnGPU::finishGridConstructionStep ( )
overridevirtual

If you hook into this routine, ensure the abstract base class operation is still invoked.

Implements exahype2::Solver.

Definition at line 88 of file AbstractLOH1OnGPU.cpp.

◆ finishGridInitialisationStep()

void examples::exahype2::loh1::AbstractLOH1OnGPU::finishGridInitialisationStep ( )
overridevirtual

If you hook into this routine, ensure the abstract base class operation is still invoked.

Implements exahype2::Solver.

Definition at line 99 of file AbstractLOH1OnGPU.cpp.

◆ finishPlottingStep()

void examples::exahype2::loh1::AbstractLOH1OnGPU::finishPlottingStep ( )
overridevirtual

If you hook into this routine, ensure the abstract base class operation is still invoked.

Implements exahype2::Solver.

Definition at line 151 of file AbstractLOH1OnGPU.cpp.

◆ finishTimeStep()

void examples::exahype2::loh1::AbstractLOH1OnGPU::finishTimeStep ( )
overridevirtual

If you hook into this routine, ensure the abstract base class operation is still invoked.

Implements exahype2::Solver.

Definition at line 129 of file AbstractLOH1OnGPU.cpp.

References _solverState(), and _timeStamp().

Here is the call graph for this function:

◆ getMaxMeshSize()

double examples::exahype2::loh1::AbstractLOH1OnGPU::getMaxMeshSize ( ) const
overridevirtual

Implements exahype2::Solver.

Definition at line 14 of file AbstractLOH1OnGPU.cpp.

References _maxH().

Here is the call graph for this function:

◆ getMaxTimeStamp()

double examples::exahype2::loh1::AbstractLOH1OnGPU::getMaxTimeStamp ( ) const
final

Definition at line 24 of file AbstractLOH1OnGPU.cpp.

References _timeStamp().

Here is the call graph for this function:

◆ getMaxTimeStepSize()

double examples::exahype2::loh1::AbstractLOH1OnGPU::getMaxTimeStepSize ( ) const
finalvirtual

Implements exahype2::Solver.

Definition at line 34 of file AbstractLOH1OnGPU.cpp.

◆ getMinMeshSize()

double examples::exahype2::loh1::AbstractLOH1OnGPU::getMinMeshSize ( ) const
overridevirtual

Implements exahype2::Solver.

Definition at line 9 of file AbstractLOH1OnGPU.cpp.

References _minH.

◆ getMinTimeStamp()

double examples::exahype2::loh1::AbstractLOH1OnGPU::getMinTimeStamp ( ) const
final

Definition at line 19 of file AbstractLOH1OnGPU.cpp.

References _timeStamp().

Here is the call graph for this function:

◆ getMinTimeStepSize()

double examples::exahype2::loh1::AbstractLOH1OnGPU::getMinTimeStepSize ( ) const
finalvirtual

Implements exahype2::Solver.

Definition at line 29 of file AbstractLOH1OnGPU.cpp.

◆ getSolverState()

examples::exahype2::loh1::AbstractLOH1OnGPU::SolverState examples::exahype2::loh1::AbstractLOH1OnGPU::getSolverState ( ) const

Definition at line 39 of file AbstractLOH1OnGPU.cpp.

References _solverState().

Here is the call graph for this function:

◆ refinementCriterion()

exahype2::RefinementCommand examples::exahype2::loh1::AbstractLOH1OnGPU::refinementCriterion ( const double *__restrict__ Q,
const tarch::la::Vector< Dimensions, double > & volumeCentre,
const tarch::la::Vector< Dimensions, double > & volumeH,
double t )
final
Parameters
QVector of unknowns
tTime

Definition at line 46 of file AbstractLOH1OnGPU.cpp.

References _maxH(), exahype2::Keep, tarch::la::max(), exahype2::Refine, and tarch::la::smallerEquals().

Here is the call graph for this function:

◆ sourceTerm()

void examples::exahype2::loh1::AbstractLOH1OnGPU::sourceTerm ( const double *__restrict__ Q,
const tarch::la::Vector< Dimensions, double > & volumeCentre,
const tarch::la::Vector< Dimensions, double > & volumeH,
double t,
double dt,
double *__restrict__ S )
static

Definition at line 177 of file AbstractLOH1OnGPU.cpp.

◆ startGridConstructionStep()

void examples::exahype2::loh1::AbstractLOH1OnGPU::startGridConstructionStep ( )
overridevirtual

If you hook into this routine, ensure the abstract base class operation is still invoked.

Implements exahype2::Solver.

Definition at line 83 of file AbstractLOH1OnGPU.cpp.

References _solverState(), and assertion.

Here is the call graph for this function:

◆ startGridInitialisationStep()

void examples::exahype2::loh1::AbstractLOH1OnGPU::startGridInitialisationStep ( )
overridevirtual

If you hook into this routine, ensure the abstract base class operation is still invoked.

Implements exahype2::Solver.

Definition at line 92 of file AbstractLOH1OnGPU.cpp.

References _solverState(), assertion, logDebug, and toString().

Here is the call graph for this function:

◆ startPlottingStep()

void examples::exahype2::loh1::AbstractLOH1OnGPU::startPlottingStep ( double globalMinTimeStamp,
double globalMaxTimeStamp,
double globalMinTimeStepSize,
double globalMaxTimeStepSize )
overridevirtual

If you hook into this routine, ensure the abstract base class operation is still invoked.

Implements exahype2::Solver.

Definition at line 136 of file AbstractLOH1OnGPU.cpp.

References _solverState().

Here is the call graph for this function:

◆ startTimeStep()

void examples::exahype2::loh1::AbstractLOH1OnGPU::startTimeStep ( double globalMinTimeStamp,
double globalMaxTimeStamp,
double globalMinTimeStepSize,
double globalMaxTimeStepSize )
overridevirtual

If you hook into this routine, ensure the abstract base class operation is still invoked.

Implements exahype2::Solver.

Definition at line 103 of file AbstractLOH1OnGPU.cpp.

References _solverState(), logDebug, and toString().

Here is the call graph for this function:

◆ toString()

std::string examples::exahype2::loh1::AbstractLOH1OnGPU::toString ( SolverState state)
static

Definition at line 155 of file AbstractLOH1OnGPU.cpp.

References state.

Field Documentation

◆ _log

tarch::logging::Log examples::exahype2::loh1::AbstractLOH1OnGPU::_log
staticprotected

Definition at line 202 of file AbstractLOH1OnGPU.h.

◆ _maxH

double examples::exahype2::loh1::AbstractLOH1OnGPU::_maxH
protected

Definition at line 210 of file AbstractLOH1OnGPU.h.

◆ _minH

double examples::exahype2::loh1::AbstractLOH1OnGPU::_minH
protected

Definition at line 211 of file AbstractLOH1OnGPU.h.

Referenced by getMinMeshSize().

◆ _NumberOfFiniteVolumesPerAxisPerPatch

const int examples::exahype2::loh1::AbstractLOH1OnGPU::_NumberOfFiniteVolumesPerAxisPerPatch
protected

Definition at line 204 of file AbstractLOH1OnGPU.h.

◆ _solverState

SolverState examples::exahype2::loh1::AbstractLOH1OnGPU::_solverState
protected

Definition at line 208 of file AbstractLOH1OnGPU.h.

◆ _timeStamp

double examples::exahype2::loh1::AbstractLOH1OnGPU::_timeStamp
protected

Definition at line 206 of file AbstractLOH1OnGPU.h.

◆ PeriodicBC

std::bitset<Dimensions> examples::exahype2::loh1::AbstractLOH1OnGPU::PeriodicBC
static

Alias for periodic boundary conditions.

Definition at line 79 of file AbstractLOH1OnGPU.h.


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