Peano
Loading...
Searching...
No Matches
solvers.aderdg.actionsets.Prediction.Prediction Class Reference

The extrapolated solution from the space-time predictor has to be projected onto the faces, so we can then solve the Riemann problems. More...

Inheritance diagram for solvers.aderdg.actionsets.Prediction.Prediction:
Collaboration diagram for solvers.aderdg.actionsets.Prediction.Prediction:

Public Member Functions

 __init__ (self, solver, guard, on_hanging_cells=False)
 guard: String (C++ code) Predicate which controls whether this action set should run on_hanging_cells: bool Determines whether this is running on hanging cells or not, the actions on both differ
 get_body_of_operation (self, operation_name)
 Return actual C++ code snippets to be inserted into C++ code.
 get_action_set_name (self)
 You should replicate this function in each subclass, so you get meaningful action set names (otherwise, it will be AbstractADERDGActionSet0,1,2,...).
 get_includes (self)
 Return include statements that you need.
Public Member Functions inherited from solvers.aderdg.actionsets.AbstractADERDGActionSet.AbstractADERDGActionSet
 __init__ (self, solver)
 user_should_modify_template (self)
 Is the user allowed to modify the output.
Public Member Functions inherited from peano4.api.solversteps.ActionSet.ActionSet
 __init__ (self, descend_invocation_order=0, parallel=False)
 get_constructor_body (self)
 Define a tailored constructor body.
 get_static_initialisations (self, full_qualified_classname)
 get_destructor_body (self)
 get_body_of_createGridControlEventsForNextTraversal (self)
 Return the grid control events that this action set wants to trigger.
 get_implementation_of_createGridControlEventsForNextTraversal (self)
 Return the C++ implementation of createGridControlEventsForNextTraversal().
 get_body_of_prepareTraversal (self)
 get_implementation_of_prepareTraversal (self)
 Return the C++ implementation of prepareTraversal().
 get_body_of_unprepareTraversal (self)
 get_implementation_of_unprepareTraversal (self)
 Return the C++ implementation of unprepareTraversal().
 get_guard_of_operation (self, operation_name)
 Return the guard of an operation.
 get_implementation_of_operation (self, operation_name)
 Return the C++ implementation of an operation.
bool may_run_in_background_task (self)
 May a task graph compiler move touchCellFirstTime() into a task.
 get_attributes (self)
 Return attributes as copied and pasted into the generated class.

Protected Attributes

 _guard = guard
 _on_hanging_cells = on_hanging_cells
 _is_linear = solver._is_linear
tuple _use_custom_riemann_solver
tuple _use_point_source
int _multiple_precisions = len(solver._predictor_computation_precisions) > 1
Protected Attributes inherited from solvers.aderdg.actionsets.AbstractADERDGActionSet.AbstractADERDGActionSet
 _solver = solver

Static Protected Attributes

str _Template_TouchCellFirstTime_Preamble
str _Template_TouchCellFirstTime_Core
str _Template_TouchCellFirstTime_Epilogue
str _Template_PredictorAllocations
str _Template_FSTPVI_Linear_Without_PS
str _Template_FSTPVI_Linear_With_PS
str _Template_FSTPVI_Nonlinear
str _Template_SetFaceTimeStamps
str _Template_NumberOfPrecisionsIterator
str _Template_PerformRiemannSolutionOnHangingFacesAndSetFaceTimeStamps
str _Template_RiemannSolver
str _Template_CustomRiemannSolver
str _Template_FaceIntegral

Additional Inherited Members

Static Public Attributes inherited from peano4.api.solversteps.ActionSet.ActionSet
int descend_invocation_order = 0
bool parallel = False
str OPERATION_BEGIN_TRAVERSAL = "beginTraversal"
str OPERATION_END_TRAVERSAL = "endTraversal"
str OPERATION_CREATE_PERSISTENT_VERTEX = "createPersistentVertex"
str OPERATION_DESTROY_PERSISTENT_VERTEX = "destroyPersistentVertex"
str OPERATION_CREATE_HANGING_VERTEX = "createHangingVertex"
str OPERATION_DESTROY_HANGING_VERTEX = "destroyHangingVertex"
str OPERATION_CREATE_PERSISTENT_FACE = "createPersistentFace"
str OPERATION_DESTROY_PERSISTENT_FACE = "destroyPersistentFace"
str OPERATION_CREATE_HANGING_FACE = "createHangingFace"
str OPERATION_DESTROY_HANGING_FACE = "destroyHangingFace"
str OPERATION_CREATE_CELL = "createCell"
str OPERATION_DESTROY_CELL = "destroyCell"
str OPERATION_TOUCH_VERTEX_FIRST_TIME = "touchVertexFirstTime"
str OPERATION_TOUCH_VERTEX_LAST_TIME = "touchVertexLastTime"
str OPERATION_TOUCH_FACE_FIRST_TIME = "touchFaceFirstTime"
str OPERATION_TOUCH_FACE_LAST_TIME = "touchFaceLastTime"
str OPERATION_TOUCH_CELL_FIRST_TIME = "touchCellFirstTime"
str OPERATION_TOUCH_CELL_LAST_TIME = "touchCellLastTime"

Detailed Description

The extrapolated solution from the space-time predictor has to be projected onto the faces, so we can then solve the Riemann problems.

So the projection happens in one grid sweep, the corresponding Riemann solve in the next one.

Definition at line 10 of file Prediction.py.

Constructor & Destructor Documentation

◆ __init__()

solvers.aderdg.actionsets.Prediction.Prediction.__init__ ( self,
solver,
guard,
on_hanging_cells = False )

guard: String (C++ code) Predicate which controls whether this action set should run on_hanging_cells: bool Determines whether this is running on hanging cells or not, the actions on both differ

Definition at line 288 of file Prediction.py.

References __init__().

Referenced by __init__().

Here is the call graph for this function:
Here is the caller graph for this function:

Member Function Documentation

◆ get_action_set_name()

solvers.aderdg.actionsets.Prediction.Prediction.get_action_set_name ( self)

You should replicate this function in each subclass, so you get meaningful action set names (otherwise, it will be AbstractADERDGActionSet0,1,2,...).

Reimplemented from solvers.aderdg.actionsets.AbstractADERDGActionSet.AbstractADERDGActionSet.

Definition at line 376 of file Prediction.py.

References _on_hanging_cells.

◆ get_body_of_operation()

solvers.aderdg.actionsets.Prediction.Prediction.get_body_of_operation ( self,
operation_name )

Return actual C++ code snippets to be inserted into C++ code.

See class' string constants starting with OPERATION_ for possible values of operation_name. The snippet is executed if and only if the guard returned by get_guard_of_operation() holds, i.e. the body should not evaluate the guard itself. See the section "Guard and body" in the class documentation.

Reimplemented from peano4.api.solversteps.ActionSet.ActionSet.

Definition at line 308 of file Prediction.py.

References solvers.aderdg.AbstractSolverDeclarations.AbstractSolverDeclarations._is_linear, solvers.aderdg.AbstractSolverDefinitions.AbstractSolverDefinitions._is_linear, solvers.aderdg.actionsets.Correction.Correction._is_linear, _is_linear, _multiple_precisions, _on_hanging_cells, exagrype.api.FD4WithKODissipation.FD4WithKODissipation._solver, exahype2.api.blockstructured.AdaptMeshAndBalanceLoad.AdaptMeshAndBalanceLoad._solver, exahype2.api.blockstructured.ConsumeRefinementRequests.ConsumeRefinementRequests._solver, exahype2.api.blockstructured.DynamicMeshRefinement.DynamicMeshRefinement._solver, exahype2.api.blockstructured.LoadCheckpoint._LoadPatchesFromCheckpoint._solver, exahype2.api.blockstructured.LoadCheckpoint.LoadCheckpoint._solver, exahype2.api.fv.actionsets.AbstractFVActionSet.AbstractFVActionSet._solver, exahype2.api.fv.actionsets.ApplyDirichletBoundaryConditions.ApplyDirichletBoundaryConditions._solver, exahype2.api.fv.actionsets.DiscardPatchInterior.DiscardPatchInterior._solver, exahype2.api.fv.AdaptMeshAndBalanceLoad.AdaptMeshAndBalanceLoad._solver, exahype2.api.fv.PlotAsVTKFile.PlotAsVTKFile._solver, exahype2.api.fv.RusanovWithExplicitEuler.RusanovWithExplicitEuler._solver, exahype2.api.fv.RusanovWithExplicitEuler.RusanovWithExplicitEulerGenerator._solver, exahype2.api.fv.RusanovWithOptimisticExplicitEuler.RusanovWithOptimisticExplicitEuler._solver, exahype2.api.fv.SetupSimulationOverRegularGrid.SetupSimulationOverRegularGrid._solver, exahype2.api.fv.SetupSimulationWithUserCodedRefinementCriterion.SetupSimulationWithUserCodedRefinementCriterion._solver, exahype2.api.fv.WriteCheckpoint.WriteCheckpoint._solver, exahype2.api.rkfd4.actionsets.AbstractRKFD4ActionSet.AbstractRKFD4ActionSet._solver, exahype2.api.rkfd4.actionsets.ApplyDirichletBoundaryConditions.ApplyDirichletBoundaryConditions._solver, exahype2.api.rkfd4.AdaptMeshAndBalanceLoad.AdaptMeshAndBalanceLoad._solver, exahype2.api.rkfd4.CentralDifferencesWithRungeKutta.CentralDifferencesWithRungeKutta._solver, exahype2.api.rkfd4.PlotAsVTKFile.PlotAsVTKFile._solver, exahype2.api.rkfd4.SetupSimulationOverRegularGrid.SetupSimulationOverRegularGrid._solver, exahype2.api.rkfd4.WriteCheckpoint.WriteCheckpoint._solver, exahype2.api.Solver.Solver.GridConstruction._solver, exahype2.api.Solver.Solver.MeshAdaptation._solver, exahype2.api.Solver.Solver.NumericalScheme._solver, exahype2.api.Solver.Solver.NumericalScheme.NumericalSchemeGenerator._solver, exahype2.api.Solver.Solver.Plotter._solver, exahype2.api.Solver.Solver.SolverGenerator._solver, solvers.aderdg.actionsets.AbstractADERDGActionSet.AbstractADERDGActionSet._solver, solvers.aderdg.actionsets.Correction.Correction._Template_CustomRiemannSolver, _Template_CustomRiemannSolver, solvers.aderdg.actionsets.Correction.Correction._Template_FaceIntegral, _Template_FaceIntegral, _Template_FSTPVI_Linear_With_PS, _Template_FSTPVI_Linear_Without_PS, _Template_FSTPVI_Nonlinear, _Template_NumberOfPrecisionsIterator, _Template_PerformRiemannSolutionOnHangingFacesAndSetFaceTimeStamps, _Template_PredictorAllocations, solvers.aderdg.actionsets.Correction.Correction._Template_RiemannSolver, _Template_RiemannSolver, _Template_SetFaceTimeStamps, api.ReconstructPatchAndApplyFunctor.ReconstructPatchAndApplyFunctor._Template_TouchCellFirstTime_Core, _Template_TouchCellFirstTime_Core, api.ReconstructPatchWithHalo.ReconstructPatchWithHalo._Template_TouchCellFirstTime_Epilogue, _Template_TouchCellFirstTime_Epilogue, api.ReconstructPatchWithHalo.ReconstructPatchWithHalo._Template_TouchCellFirstTime_Preamble, _Template_TouchCellFirstTime_Preamble, solvers.aderdg.actionsets.Correction.Correction._use_custom_riemann_solver, _use_custom_riemann_solver, _use_point_source, api.ApplyPointWiselyToPatch.ApplyPointWiselyToPatch.guard(), api.ApplyPointWiselyToPatch.ApplyPointWiselyToPatch.guard(), api.InterpolateHangingFaces.InterpolateHangingFaces.guard, api.ProjectPatchOntoFaces.ProjectPatchOntoFaces.guard(), api.ProjectPatchOntoFaces.ProjectPatchOntoFaces.guard(), api.ProjectPatchWithHaloOntoFaces.ProjectPatchWithHaloOntoFaces.guard, api.ReconstructPatchWithHalo.ReconstructPatchWithHalo.guard, api.RestrictHangingFaces.RestrictHangingFaces.guard, exagrype.api.actionsets.AddKreissOligerDissipation.AddKreissOligerDissipation.guard, exahype2.api.blockstructured.DynamicMeshRefinement.DynamicMeshRefinement.guard, exahype2.api.fv.actionsets.ApplyDirichletBoundaryConditions.ApplyDirichletBoundaryConditions.guard, exahype2.api.fv.actionsets.ComputeMaxEigenvalue.ComputeMaxEigenvalue.guard, exahype2.api.fv.actionsets.DiscardPatchInterior.DiscardPatchInterior.guard, exahype2.api.fv.actionsets.InitialCondition.InitialCondition.guard, exahype2.api.fv.actionsets.InsertPatchInterior.InsertPatchInterior.guard, exahype2.api.fv.actionsets.ReadjustTimeStepSizeForOptimisticGlobalTimestepping.ReadjustTimeStepSizeForOptimisticGlobalTimestepping.guard, exahype2.api.fv.actionsets.ReduceMaxEigenvalue.ReduceMaxEigenvalue.guard, exahype2.api.fv.actionsets.SpawnTaskToUpdateCellInterior.SpawnTaskToUpdateCellInterior.guard, exahype2.api.fv.actionsets.UpdateCell.UpdateCell.guard, exahype2.api.fv.actionsets.UpdateCellGPU.UpdateCellGPU.guard, exahype2.api.fv.actionsets.UpdateCellInterior.UpdateCellInterior.guard, exahype2.api.fv.actionsets.UpdateCellShell.UpdateCellShell.guard, exahype2.api.rkfd4.actionsets.AddLopsidedAdvection.AddLopsidedAdvection.guard, exahype2.api.rkfd4.actionsets.ApplyDirichletBoundaryConditions.ApplyDirichletBoundaryConditions.guard, exahype2.api.rkfd4.actionsets.ComputeLinearCombination.ComputeLinearCombination.guard, exahype2.api.rkfd4.actionsets.ComputeMaxEigenvalue.ComputeMaxEigenvalue.guard, exahype2.api.rkfd4.actionsets.EvaluateRungeKuttaRightHandSide.EvaluateRungeKuttaRightHandSide.guard, exahype2.api.rkfd4.actionsets.InitialCondition.InitialCondition.guard, exahype2.api.rkfd4.actionsets.ReduceMaxEigenvalue.ReduceMaxEigenvalue.guard, peano4.api.actionsets.ConstructRegularGrid.ConstructRegularGrid.guard, solvers.fv.actionsets.AdaptivityCriterion.AdaptivityCriterion.guard, solvers.fv.actionsets.HandleBoundary.HandleBoundary.guard, solvers.fv.actionsets.InitialCondition.InitialCondition.guard, solvers.fv.actionsets.PostprocessSolution.EmptyPostprocessSolution.guard, solvers.fv.actionsets.PostprocessSolution.VolumeWisePostprocessSolution.guard, solvers.fv.actionsets.PreprocessSolution.EmptyPreprocessSolution.guard, solvers.fv.actionsets.PreprocessSolution.VolumeWisePreprocessSolution.guard, solvers.fv.EnclaveTasking.MergeEnclaveTaskOutcome.guard, solvers.limiting.actionsets.SaveNewCellData.SaveNewCellData.guard, solvers.limiting.actionsets.SpreadLimiterStatus.SpreadLimiterStatus.guard, solvers.limiting.actionsets.VerifyTroubledness.VerifyTroubledness.guard, solvers.rkdg.actionsets.AdaptivityCriterion.AdaptivityCriterion.guard, solvers.rkdg.actionsets.ComputeFinalLinearCombination.ComputeFinalLinearCombination.guard, solvers.rkdg.actionsets.InitialCondition.InitialCondition.guard, solvers.rkdg.actionsets.PostprocessSolution.CellWisePostprocessSolution.guard, solvers.rkdg.actionsets.PostprocessSolution.DoFWisePostprocessSolution.guard, solvers.rkdg.actionsets.PostprocessSolution.EmptyPostprocessSolution.guard, solvers.rkdg.actionsets.PreprocessSolution.CellWisePreprocessSolution.guard, solvers.rkdg.actionsets.PreprocessSolution.DoFWisePreprocessSolution.guard, and solvers.rkdg.actionsets.PreprocessSolution.EmptyPreprocessSolution.guard.

Here is the call graph for this function:

◆ get_includes()

solvers.aderdg.actionsets.Prediction.Prediction.get_includes ( self)

Return include statements that you need.

All of these includes will eventually end up in the header of the generated C++ code.

Reimplemented from solvers.aderdg.actionsets.AbstractADERDGActionSet.AbstractADERDGActionSet.

Definition at line 383 of file Prediction.py.

References exagrype.api.FD4WithKODissipation.FD4WithKODissipation._solver, exahype2.api.blockstructured.AdaptMeshAndBalanceLoad.AdaptMeshAndBalanceLoad._solver, exahype2.api.blockstructured.ConsumeRefinementRequests.ConsumeRefinementRequests._solver, exahype2.api.blockstructured.DynamicMeshRefinement.DynamicMeshRefinement._solver, exahype2.api.blockstructured.LoadCheckpoint._LoadPatchesFromCheckpoint._solver, exahype2.api.blockstructured.LoadCheckpoint.LoadCheckpoint._solver, exahype2.api.fv.actionsets.AbstractFVActionSet.AbstractFVActionSet._solver, exahype2.api.fv.actionsets.ApplyDirichletBoundaryConditions.ApplyDirichletBoundaryConditions._solver, exahype2.api.fv.actionsets.DiscardPatchInterior.DiscardPatchInterior._solver, exahype2.api.fv.AdaptMeshAndBalanceLoad.AdaptMeshAndBalanceLoad._solver, exahype2.api.fv.PlotAsVTKFile.PlotAsVTKFile._solver, exahype2.api.fv.RusanovWithExplicitEuler.RusanovWithExplicitEuler._solver, exahype2.api.fv.RusanovWithExplicitEuler.RusanovWithExplicitEulerGenerator._solver, exahype2.api.fv.RusanovWithOptimisticExplicitEuler.RusanovWithOptimisticExplicitEuler._solver, exahype2.api.fv.SetupSimulationOverRegularGrid.SetupSimulationOverRegularGrid._solver, exahype2.api.fv.SetupSimulationWithUserCodedRefinementCriterion.SetupSimulationWithUserCodedRefinementCriterion._solver, exahype2.api.fv.WriteCheckpoint.WriteCheckpoint._solver, exahype2.api.rkfd4.actionsets.AbstractRKFD4ActionSet.AbstractRKFD4ActionSet._solver, exahype2.api.rkfd4.actionsets.ApplyDirichletBoundaryConditions.ApplyDirichletBoundaryConditions._solver, exahype2.api.rkfd4.AdaptMeshAndBalanceLoad.AdaptMeshAndBalanceLoad._solver, exahype2.api.rkfd4.CentralDifferencesWithRungeKutta.CentralDifferencesWithRungeKutta._solver, exahype2.api.rkfd4.PlotAsVTKFile.PlotAsVTKFile._solver, exahype2.api.rkfd4.SetupSimulationOverRegularGrid.SetupSimulationOverRegularGrid._solver, exahype2.api.rkfd4.WriteCheckpoint.WriteCheckpoint._solver, exahype2.api.Solver.Solver.GridConstruction._solver, exahype2.api.Solver.Solver.MeshAdaptation._solver, exahype2.api.Solver.Solver.NumericalScheme._solver, exahype2.api.Solver.Solver.NumericalScheme.NumericalSchemeGenerator._solver, exahype2.api.Solver.Solver.Plotter._solver, exahype2.api.Solver.Solver.SolverGenerator._solver, solvers.aderdg.actionsets.AbstractADERDGActionSet.AbstractADERDGActionSet._solver, _use_point_source, and get_includes().

Referenced by get_includes().

Here is the call graph for this function:
Here is the caller graph for this function:

Field Documentation

◆ _guard

◆ _is_linear

◆ _multiple_precisions

int solvers.aderdg.actionsets.Prediction.Prediction._multiple_precisions = len(solver._predictor_computation_precisions) > 1
protected

Definition at line 306 of file Prediction.py.

Referenced by get_body_of_operation().

◆ _on_hanging_cells

solvers.aderdg.actionsets.Prediction.Prediction._on_hanging_cells = on_hanging_cells
protected

Definition at line 298 of file Prediction.py.

Referenced by get_action_set_name(), and get_body_of_operation().

◆ _Template_CustomRiemannSolver

str solvers.aderdg.actionsets.Prediction.Prediction._Template_CustomRiemannSolver
staticprotected
Initial value:
= """
repositories::{{SOLVER_INSTANCE}}.riemannSolver(
FL,
FR,
QL,
QR,
timeStamp,
timeStepSize,
marker.x(),
faceCentre,
direction,
isBoundary,
faceNumber
);
"""

Definition at line 260 of file Prediction.py.

Referenced by get_body_of_operation().

◆ _Template_FaceIntegral

str solvers.aderdg.actionsets.Prediction.Prediction._Template_FaceIntegral
staticprotected
Initial value:
= """
const double inverseDxDirection = 1.0 / marker.h()[d];
kernels::{{SOLVER_NAME}}::faceIntegral(
cellData.QIn[0],
FIn,
direction,
orientation,
inverseDxDirection,
timeStepSize
);
"""

Definition at line 276 of file Prediction.py.

Referenced by get_body_of_operation().

◆ _Template_FSTPVI_Linear_With_PS

str solvers.aderdg.actionsets.Prediction.Prediction._Template_FSTPVI_Linear_With_PS
staticprotected
Initial value:
= """
const auto pointSources = kernels::{{SOLVER_NAME}}::pointSources(
repositories::{{SOLVER_INSTANCE}},
marker.x(),
marker.h()
);
if (!pointSources.empty()) {
// Linear, with point sources
int numberOfIterations = kernels::{{SOLVER_NAME}}::fusedSpaceTimePredictorVolumeIntegral<{{SOLUTION_STORAGE_PRECISION}}, {{PREDICTOR_COMPUTATION_PRECISIONS[PRECISION_NUM]}}, {{CORRECTOR_COMPUTATION_PRECISION}}>(
repositories::{{SOLVER_INSTANCE}},
lQhbnd, lFhbnd, cellData.QIn[0],
marker.x(), marker.h(), timeStamp, timeStepSize,
pointSources
);
} else {
// Linear, without point sources
int numberOfIterations = kernels::{{SOLVER_NAME}}::fusedSpaceTimePredictorVolumeIntegralWithoutPointSources<{{SOLUTION_STORAGE_PRECISION}}, {{PREDICTOR_COMPUTATION_PRECISIONS[PRECISION_NUM]}}, {{CORRECTOR_COMPUTATION_PRECISION}}>(
repositories::{{SOLVER_INSTANCE}},
lQhbnd, lFhbnd, cellData.QIn[0],
marker.x(), marker.h(), timeStamp, timeStepSize,
pointSources
);
}
"""

Definition at line 112 of file Prediction.py.

Referenced by get_body_of_operation().

◆ _Template_FSTPVI_Linear_Without_PS

str solvers.aderdg.actionsets.Prediction.Prediction._Template_FSTPVI_Linear_Without_PS
staticprotected
Initial value:
= """
// Linear, without point sources
int numberOfIterations = kernels::{{SOLVER_NAME}}::fusedSpaceTimePredictorVolumeIntegral<{{SOLUTION_STORAGE_PRECISION}}, {{PREDICTOR_COMPUTATION_PRECISIONS[PRECISION_NUM]}}, {{CORRECTOR_COMPUTATION_PRECISION}}>(
repositories::{{SOLVER_INSTANCE}},
lQhbnd, lFhbnd, cellData.QIn[0],
marker.x(), marker.h(), timeStamp, timeStepSize,
std::vector<int>() // Empty vector
);
"""

Definition at line 102 of file Prediction.py.

Referenced by get_body_of_operation().

◆ _Template_FSTPVI_Nonlinear

str solvers.aderdg.actionsets.Prediction.Prediction._Template_FSTPVI_Nonlinear
staticprotected
Initial value:
= """
// Nonlinear, without point sources
int numberOfIterations = kernels::{{SOLVER_NAME}}::fusedSpaceTimePredictorVolumeIntegral<{{SOLUTION_STORAGE_PRECISION}}, {{PREDICTOR_COMPUTATION_PRECISIONS[PRECISION_NUM]}}, {{CORRECTOR_COMPUTATION_PRECISION}}>(
repositories::{{SOLVER_INSTANCE}},
lQhbnd, lFhbnd, cellData.QIn[0],
marker.x(), marker.h(), timeStamp, timeStepSize
);
"""

Definition at line 138 of file Prediction.py.

Referenced by get_body_of_operation().

◆ _Template_NumberOfPrecisionsIterator

str solvers.aderdg.actionsets.Prediction.Prediction._Template_NumberOfPrecisionsIterator
staticprotected
Initial value:
= """
::exahype2::PrecisionCommand myPrecision = repositories::{{SOLVER_INSTANCE}}.precisionCriterion(
cellData.QIn[0],
marker.x(),
marker.h(),
timeStepSize,
repositories::{{SOLVER_INSTANCE}}.getSolverState()
);
switch (myPrecision) {
{% for PRECISION_NUM in range(0,PREDICTOR_COMPUTATION_PRECISIONS|length) %}
case ::exahype2::PrecisionCommand::{{PRECISIONS_CAPITALIZED[PRECISION_NUM]}}:
{{ITERATION_CONTENT}}
break;
{% endfor %}
default:
assertion1WithExplanation(
false, myPrecision, "chosen precision was not in the previously specified options, as such there are no compiled kernels for this option."
);
}
"""

Definition at line 167 of file Prediction.py.

Referenced by get_body_of_operation().

◆ _Template_PerformRiemannSolutionOnHangingFacesAndSetFaceTimeStamps

str solvers.aderdg.actionsets.Prediction.Prediction._Template_PerformRiemannSolutionOnHangingFacesAndSetFaceTimeStamps
staticprotected

Definition at line 189 of file Prediction.py.

Referenced by get_body_of_operation().

◆ _Template_PredictorAllocations

str solvers.aderdg.actionsets.Prediction.Prediction._Template_PredictorAllocations
staticprotected

Definition at line 65 of file Prediction.py.

Referenced by get_body_of_operation().

◆ _Template_RiemannSolver

str solvers.aderdg.actionsets.Prediction.Prediction._Template_RiemannSolver
staticprotected
Initial value:
= """
kernels::{{SOLVER_NAME}}::riemannSolver<{{CORRECTOR_COMPUTATION_PRECISION}}>(
repositories::{{SOLVER_INSTANCE}},
FL,
FR,
QL,
QR,
timeStamp,
timeStepSize,
faceCentre,
marker.h(),
direction
);
"""

Definition at line 245 of file Prediction.py.

Referenced by get_body_of_operation().

◆ _Template_SetFaceTimeStamps

str solvers.aderdg.actionsets.Prediction.Prediction._Template_SetFaceTimeStamps
staticprotected
Initial value:
= """
/**
* Copy the estimates into the face data containers. Note that Peano uses a different ordering of
* the faces that the kernels, so these are reordered somewhat.
* The kernels order by dimension, then side of the face whereas Peano orders by
* side, then dimension.
* E.g., in 2d the kernels have the order left, right, lower face, upper face
* whereas Peano orders: left, lower, right, upper.
*
* 2d: 0,1,2,3 -> 0,2,1,3
* 3d: 0,1,2,3,4,5 -> 0,3,1,4,2,5
*/
for (int d = 0; d < Dimensions; d++) {
// Timestamp information for boundary handling
fineGridFaces{{SOLVER_NAME}}FaceLabel(d).setNewTimeStamp(1, timeStamp);
fineGridFaces{{SOLVER_NAME}}FaceLabel(d + Dimensions).setNewTimeStamp(0, timeStamp);
}
"""

Definition at line 147 of file Prediction.py.

Referenced by get_body_of_operation().

◆ _Template_TouchCellFirstTime_Core

str solvers.aderdg.actionsets.Prediction.Prediction._Template_TouchCellFirstTime_Core
staticprotected
Initial value:
= """
{{FUSED_PREDICTOR_VOLUME_INTEGRAL}}
{{PROJECT_SOLUTION_TO_FACES}}
"""

Definition at line 53 of file Prediction.py.

Referenced by get_body_of_operation().

◆ _Template_TouchCellFirstTime_Epilogue

str solvers.aderdg.actionsets.Prediction.Prediction._Template_TouchCellFirstTime_Epilogue
staticprotected
Initial value:
= """
fineGridCell{{SOLVER_NAME}}CellLabel.setTimeStepSize(timeStepSize);
repositories::{{SOLVER_INSTANCE}}.update(timeStepSize, timeStamp, marker.h()(0));
}
"""

Definition at line 58 of file Prediction.py.

Referenced by get_body_of_operation().

◆ _Template_TouchCellFirstTime_Preamble

str solvers.aderdg.actionsets.Prediction.Prediction._Template_TouchCellFirstTime_Preamble
staticprotected

Definition at line 17 of file Prediction.py.

Referenced by get_body_of_operation().

◆ _use_custom_riemann_solver

tuple solvers.aderdg.actionsets.Prediction.Prediction._use_custom_riemann_solver
protected
Initial value:
= (
solver._riemann_solver_implementation != PDETerms.None_Implementation
)

Definition at line 300 of file Prediction.py.

Referenced by get_body_of_operation().

◆ _use_point_source

tuple solvers.aderdg.actionsets.Prediction.Prediction._use_point_source
protected
Initial value:
= (
solver._point_sources_implementation != PDETerms.None_Implementation
)

Definition at line 303 of file Prediction.py.

Referenced by get_body_of_operation(), and get_includes().


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