MFEM v4.7.0
Finite element discretization library
Loading...
Searching...
No Matches
mfem::FluxFunction Class Referenceabstract

Abstract class for hyperbolic flux for a system of hyperbolic conservation laws. More...

#include <hyperbolic.hpp>

Inheritance diagram for mfem::FluxFunction:
[legend]

Public Member Functions

 FluxFunction (const int num_equations, const int dim)
 
virtual real_t ComputeFlux (const Vector &state, ElementTransformation &Tr, DenseMatrix &flux) const =0
 Compute flux F(u, x) for given state u and physical point x.
 
virtual real_t ComputeFluxDotN (const Vector &state, const Vector &normal, FaceElementTransformations &Tr, Vector &fluxDotN) const
 Compute normal flux. Optionally overloaded in the derived class to avoid creating full dense matrix for flux.
 
virtual void ComputeFluxJacobian (const Vector &state, ElementTransformation &Tr, DenseTensor &J) const
 Compute flux Jacobian. Optionally overloaded in the derived class when Jacobian is necessary (e.g. Newton iteration, flux limiter)
 

Public Attributes

const int num_equations
 
const int dim
 

Detailed Description

Abstract class for hyperbolic flux for a system of hyperbolic conservation laws.

Definition at line 57 of file hyperbolic.hpp.

Constructor & Destructor Documentation

◆ FluxFunction()

mfem::FluxFunction::FluxFunction ( const int num_equations,
const int dim )
inline

Definition at line 63 of file hyperbolic.hpp.

Member Function Documentation

◆ ComputeFlux()

virtual real_t mfem::FluxFunction::ComputeFlux ( const Vector & state,
ElementTransformation & Tr,
DenseMatrix & flux ) const
pure virtual

Compute flux F(u, x) for given state u and physical point x.

Parameters
[in]statevalue of state at the current integration point
[in]Trelement information
[out]fluxF(u, x)
Returns
real_t maximum characteristic speed
Note
One can put assertion in here to detect non-physical solution

Implemented in mfem::AdvectionFlux, mfem::BurgersFlux, mfem::EulerFlux, and mfem::ShallowWaterFlux.

◆ ComputeFluxDotN()

real_t mfem::FluxFunction::ComputeFluxDotN ( const Vector & state,
const Vector & normal,
FaceElementTransformations & Tr,
Vector & fluxDotN ) const
virtual

Compute normal flux. Optionally overloaded in the derived class to avoid creating full dense matrix for flux.

Parameters
[in]statestate at the current integration point
[in]normalnormal vector,
See also
CalcOrtho
Parameters
[in]Trface information
[out]fluxDotNnormal flux from the given element at the current integration point
Returns
real_t maximum (normal) characteristic velocity

Reimplemented in mfem::EulerFlux, and mfem::ShallowWaterFlux.

Definition at line 190 of file hyperbolic.cpp.

◆ ComputeFluxJacobian()

virtual void mfem::FluxFunction::ComputeFluxJacobian ( const Vector & state,
ElementTransformation & Tr,
DenseTensor & J ) const
inlinevirtual

Compute flux Jacobian. Optionally overloaded in the derived class when Jacobian is necessary (e.g. Newton iteration, flux limiter)

Parameters
statestate at the current integration point
Trelement information
Jflux Jacobian, J(i,j,d) = dF_{id} / u_j

Definition at line 106 of file hyperbolic.hpp.

Member Data Documentation

◆ dim

const int mfem::FluxFunction::dim

Definition at line 61 of file hyperbolic.hpp.

◆ num_equations

const int mfem::FluxFunction::num_equations

Definition at line 60 of file hyperbolic.hpp.


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