Peano 4
Loading...
Searching...
No Matches
exahype2::dg::fluxaverage Namespace Reference

Functions

void solveRiemannProblem_pointwise_in_situ (::exahype2::dg::Flux flux, ::exahype2::dg::NonConservativeProduct ncp, ::exahype2::dg::MaxEigenvalue maxEigenvalue, const tarch::la::Vector< Dimensions, double > &faceCentre, const tarch::la::Vector< Dimensions, double > &cellSize, double t, double dt, int order, int unknowns, int auxiliaryVariables, int faceNumber, const double *__restrict__ quadraturePoints, bool useFlux, bool useNcp, const double *__restrict__ projectedValues, double *__restrict__ solution)
 Solve Riemann problem on face.
 
static void cellIntegral_patchwise_in_situ_GaussLegendre_functors (::exahype2::CellData &cellData, const int order, const int unknowns, const int auxiliaryVariables, Flux flux, NonConservativeProduct nonConservativeProduct, Source source, PointSources pointSources, const double *__restrict__ QuadratureNodes1d, const double *__restrict__ MassMatrixDiagonal1d, const double *__restrict__ StiffnessMatrix1d, const double *__restrict__ DerivativeOperator1d, bool evaluateFlux, bool evaluateNonconservativeProduct, bool evaluateSource, bool evaluatePointSources)
 Delegate to generic implementation in parent directory.
 
static void multiplyWithInvertedMassMatrix_GaussLegendre (::exahype2::CellData &cellData, const int order, const int unknowns, const int auxiliaryVariables, const double *__restrict__ MassMatrixDiagonal1d)
 Delegate to generic implementation.
 
static void integrateOverRiemannSolutionsAndAddToVolume_GaussLegendre (const double *const __restrict__ faceQLeft, const double *const __restrict__ faceQRight, const double *const __restrict__ faceQBottom, const double *const __restrict__ faceQUp, int order, int unknowns, const int auxiliaryVariables, const tarch::la::Vector< 2, double > &cellSize, const double *const __restrict__ BasisFunctionValuesLeft, const double *__restrict__ MassMatrixDiagonal1d, double *__restrict__ cellQ)
 Delegate to generic implementation.
 
static void integrateOverRiemannSolutionsAndAddToVolume_GaussLegendre (const double *const __restrict__ faceQLeft, const double *const __restrict__ faceQRight, const double *const __restrict__ faceQBottom, const double *const __restrict__ faceQUp, const double *const __restrict__ faceQFront, const double *const __restrict__ faceQBack, int order, int unknowns, const int auxiliaryVariables, const tarch::la::Vector< 3, double > &cellSize, const double *const __restrict__ BasisFunctionValuesLeft, const double *__restrict__ MassMatrixDiagonal1d, double *__restrict__ cellQ)
 Delegate to generic implementation.
 
template<typename Solver , int order, int unknowns, int auxiliaryVariables>
void cellIntegral_patchwise_in_situ_GaussLegendre (::exahype2::CellData &cellData, bool evaluateFlux, bool evaluateNonconservativeProduct, bool evaluateSource, bool evaluatePointSources)
 

Function Documentation

◆ cellIntegral_patchwise_in_situ_GaussLegendre()

template<typename Solver , int order, int unknowns, int auxiliaryVariables>
void exahype2::dg::fluxaverage::cellIntegral_patchwise_in_situ_GaussLegendre ( ::exahype2::CellData & cellData,
bool evaluateFlux,
bool evaluateNonconservativeProduct,
bool evaluateSource,
bool evaluatePointSources )

Definition at line 212 of file FluxAverage.h.

◆ cellIntegral_patchwise_in_situ_GaussLegendre_functors()

static void exahype2::dg::fluxaverage::cellIntegral_patchwise_in_situ_GaussLegendre_functors ( ::exahype2::CellData & cellData,
const int order,
const int unknowns,
const int auxiliaryVariables,
Flux flux,
NonConservativeProduct nonConservativeProduct,
Source source,
PointSources pointSources,
const double *__restrict__ QuadratureNodes1d,
const double *__restrict__ MassMatrixDiagonal1d,
const double *__restrict__ StiffnessMatrix1d,
const double *__restrict__ DerivativeOperator1d,
bool evaluateFlux,
bool evaluateNonconservativeProduct,
bool evaluateSource,
bool evaluatePointSources )
static

Delegate to generic implementation in parent directory.

static keyword required to avoid multiple definition linker errors.

Definition at line 96 of file FluxAverage.h.

References exahype2::dg::cellIntegral_patchwise_in_situ_GaussLegendre_functors().

Here is the call graph for this function:

◆ integrateOverRiemannSolutionsAndAddToVolume_GaussLegendre() [1/2]

static void exahype2::dg::fluxaverage::integrateOverRiemannSolutionsAndAddToVolume_GaussLegendre ( const double *const __restrict__ faceQLeft,
const double *const __restrict__ faceQRight,
const double *const __restrict__ faceQBottom,
const double *const __restrict__ faceQUp,
const double *const __restrict__ faceQFront,
const double *const __restrict__ faceQBack,
int order,
int unknowns,
const int auxiliaryVariables,
const tarch::la::Vector< 3, double > & cellSize,
const double *const __restrict__ BasisFunctionValuesLeft,
const double *__restrict__ MassMatrixDiagonal1d,
double *__restrict__ cellQ )
static

Delegate to generic implementation.

static keyword required to avoid multiple definition linker errors.

Definition at line 180 of file FluxAverage.h.

References exahype2::dg::integrateOverRiemannSolutionsAndAddToVolume_GaussLegendre().

Here is the call graph for this function:

◆ integrateOverRiemannSolutionsAndAddToVolume_GaussLegendre() [2/2]

static void exahype2::dg::fluxaverage::integrateOverRiemannSolutionsAndAddToVolume_GaussLegendre ( const double *const __restrict__ faceQLeft,
const double *const __restrict__ faceQRight,
const double *const __restrict__ faceQBottom,
const double *const __restrict__ faceQUp,
int order,
int unknowns,
const int auxiliaryVariables,
const tarch::la::Vector< 2, double > & cellSize,
const double *const __restrict__ BasisFunctionValuesLeft,
const double *__restrict__ MassMatrixDiagonal1d,
double *__restrict__ cellQ )
static

Delegate to generic implementation.

static keyword required to avoid multiple definition linker errors.

Definition at line 151 of file FluxAverage.h.

References exahype2::dg::integrateOverRiemannSolutionsAndAddToVolume_GaussLegendre().

Here is the call graph for this function:

◆ multiplyWithInvertedMassMatrix_GaussLegendre()

static void exahype2::dg::fluxaverage::multiplyWithInvertedMassMatrix_GaussLegendre ( ::exahype2::CellData & cellData,
const int order,
const int unknowns,
const int auxiliaryVariables,
const double *__restrict__ MassMatrixDiagonal1d )
static

Delegate to generic implementation.

static keyword required to avoid multiple definition linker errors.

Definition at line 132 of file FluxAverage.h.

References exahype2::dg::multiplyWithInvertedMassMatrix_GaussLegendre().

Here is the call graph for this function:

◆ solveRiemannProblem_pointwise_in_situ()

void exahype2::dg::fluxaverage::solveRiemannProblem_pointwise_in_situ ( ::exahype2::dg::Flux flux,
::exahype2::dg::NonConservativeProduct ncp,
::exahype2::dg::MaxEigenvalue maxEigenvalue,
const tarch::la::Vector< Dimensions, double > & faceCentre,
const tarch::la::Vector< Dimensions, double > & cellSize,
double t,
double dt,
int order,
int unknowns,
int auxiliaryVariables,
int faceNumber,
const double *__restrict__ quadraturePoints,
bool useFlux,
bool useNcp,
const double *__restrict__ projectedValues,
double *__restrict__ solution )

Solve Riemann problem on face.

This routine solves the Riemann problem on one face through simple averaging of the left and the right flux. Compared to solution averaging (cmp average subdirectory), this is twice as expensive.

The implementation is purely point-wise, i.e. we run over the quadrature points and use Rusanov per point. It is not clear if this is reasonable in all cases. It might be better for example to determine the max eigenvalue per face once and then update all quadrature point subject to this one eigenvalue.

Implementation details

The DoFs per face are ordered in standard Peano order:

    2 3
    0 1

2 3 [ o o ] 2 3 0 1 [ o o ] 0 1 2 3 0 1

The lrEnumerator is used for quantities that we evaluate right and left of the face. The faceEnumerator is for data that we evalutate directly on the face.

Sign discussion

We rely on the formulation as discussed on the page Discontinuous Galerkin. See dg.h or the doxygen html pages for details. As we bring the terms to the right-hand side, they all get an additional minus sign. At the same time, the flux left and right is multiplied with the normal. So while we use simple averaging, this average enters the left cell with -1 (outflow) and the right one with + (inflow). This results from the fact that all fluxes are axis-aligned.

Definition at line 6 of file FluxAverage.cpp.

References dfore.