Peano
Loading...
Searching...
No Matches
exahype2.api.NonconservativeProduct.NonconservativeProduct Class Reference

The non-conservative product B(Q) applied to a jump deltaQ in a given direction, i.e. More...

Inheritance diagram for exahype2.api.NonconservativeProduct.NonconservativeProduct:
Collaboration diagram for exahype2.api.NonconservativeProduct.NonconservativeProduct:

Data Structures

class  Generator
 NonconservativeProduct-specific code generation. More...
 

Public Member Functions

 __init__ (self, str implementation=None, bool stateless=False)
 implementation: str A C++ snippet that becomes nonconservativeProduct()'s body (the empty string is a valid, generated no-op body), or None (the default) to leave nonconservativeProduct() pure virtual for you to implement by hand.
 
- Public Member Functions inherited from exahype2.api.PDETerm.PDETerm
str __repr__ (self)
 
str __str__ (self)
 
"PDETerm.Generator" generator (self)
 Code generator for this term: an instance of this term's own (possibly subclass-specific) Generator.
 

Static Public Attributes

tuple SIGNATURE
 
str NAME = "nonconservativeProduct"
 
- Static Public Attributes inherited from exahype2.api.PDETerm.PDETerm
str NAME
 
str SIGNATURE
 

Additional Inherited Members

- Data Fields inherited from exahype2.api.PDETerm.PDETerm
 name
 
 implementation
 
 stateless
 

Detailed Description

The non-conservative product B(Q) applied to a jump deltaQ in a given direction, i.e.

BTimesDeltaQ = B(Q) * deltaQ

The signature matches exahype2::fv::rusanov::NonconservativeProductFunctor, i.e. what the Rusanov kernels hand over:

virtual void nonconservativeProduct(
const double* __restrict__ Q, // Q[{{NUMBER_OF_UNKNOWNS}}+{{NUMBER_OF_AUXILIARY_VARIABLES}}]
const double* __restrict__ deltaQ, // deltaQ[{{NUMBER_OF_UNKNOWNS}}+{{NUMBER_OF_AUXILIARY_VARIABLES}}]
const tarch::la::Vector<Dimensions, double>& x,
const tarch::la::Vector<Dimensions, double>& volumeSize,
double t,
double dt,
int normal,
double* __restrict__ BTimesDeltaQ // BTimesDeltaQ[{{NUMBER_OF_UNKNOWNS}}]
);

The kernels evaluate the term on each face of a volume: Q is the average of the two adjacent volumes, deltaQ the difference right minus left (or top minus bottom, ...) along normal. Both include the auxiliary variables, so a term can use the jump of a material parameter, e.g. of a bathymetry. The output only holds unknowns entries.

The size of the volume is called volumeSize rather than h - as it is in the legacy API - as h frequently is the name of an unknown, e.g. the water height of the shallow water equations.

Definition at line 8 of file NonconservativeProduct.py.

Constructor & Destructor Documentation

◆ __init__()

exahype2.api.NonconservativeProduct.NonconservativeProduct.__init__ (   self,
str   implementation = None,
bool   stateless = False 
)

Field Documentation

◆ NAME

◆ SIGNATURE

tuple exahype2.api.NonconservativeProduct.NonconservativeProduct.SIGNATURE
static
Initial value:
= (
"const double* __restrict__ Q, "
"const double* __restrict__ deltaQ, "
"const tarch::la::Vector<Dimensions, double>& x, "
"const tarch::la::Vector<Dimensions, double>& volumeSize, "
"double t, "
"double dt, "
"int normal, "
"double* __restrict__ BTimesDeltaQ"
)

Definition at line 42 of file NonconservativeProduct.py.


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