All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Ewoms::FvBaseLocalResidual< TypeTag > Class Template Reference

Element-wise caculation of the residual matrix for models based on a finite volume spatial discretization. More...

#include <fvbaselocalresidual.hh>

Public Types

typedef Dune::BlockVector
< EvalVector,
Ewoms::aligned_allocator
< EvalVector, alignof(EvalVector)> > 
LocalEvalBlockVector
 

Public Member Functions

const LocalEvalBlockVector & residual () const
 Return the result of the eval() call using internal storage.
 
const EvalVector & residual (unsigned dofIdx) const
 Return the result of the eval() call using internal storage. More...
 
void eval (const Problem &problem, const Element &element)
 Compute the local residual, i.e. More...
 
void eval (const ElementContext &elemCtx)
 Compute the local residual, i.e. More...
 
void eval (LocalEvalBlockVector &residual, const ElementContext &elemCtx) const
 Compute the local residual, i.e. More...
 
void evalStorage (LocalEvalBlockVector &storage, const ElementContext &elemCtx, unsigned timeIdx) const
 Calculate the amount of all conservation quantities stored in all element's sub-control volumes for a given history index. More...
 
void evalFluxes (LocalEvalBlockVector &residual, const ElementContext &elemCtx, unsigned timeIdx) const
 Add the flux term to a local residual. More...
 
void computeStorage (EqVector &storage OPM_UNUSED, const ElementContext &elemCtx OPM_UNUSED, unsigned dofIdx OPM_UNUSED, unsigned timeIdx OPM_UNUSED) const
 Evaluate the amount all conservation quantities (e.g. More...
 
void computeFlux (RateVector &flux OPM_UNUSED, const ElementContext &elemCtx OPM_UNUSED, unsigned scvfIdx OPM_UNUSED, unsigned timeIdx OPM_UNUSED) const
 Evaluates the total mass flux of all conservation quantities over a face of a sub-control volume. More...
 
void computeSource (RateVector &source OPM_UNUSED, const ElementContext &elemCtx OPM_UNUSED, unsigned dofIdx OPM_UNUSED, unsigned timeIdx OPM_UNUSED) const
 Calculate the source term of the equation. More...
 

Static Public Member Functions

static void registerParameters ()
 Register all run-time parameters for the local residual.
 

Protected Member Functions

void evalBoundary_ (LocalEvalBlockVector &residual, const ElementContext &elemCtx, unsigned timeIdx) const
 Evaluate the boundary conditions of an element.
 
void evalBoundarySegment_ (LocalEvalBlockVector &residual, const BoundaryContext &boundaryCtx, unsigned boundaryFaceIdx, unsigned timeIdx) const
 Evaluate all boundary conditions for a single sub-control volume face to the local residual.
 
void evalVolumeTerms_ (LocalEvalBlockVector &residual, const ElementContext &elemCtx) const
 Add the change in the storage terms and the source term to the local residual of all sub-control volumes of the current element.
 

Detailed Description

template<class TypeTag>
class Ewoms::FvBaseLocalResidual< TypeTag >

Element-wise caculation of the residual matrix for models based on a finite volume spatial discretization.

Template Parameters
TypeTagThe type tag on which all required properties are defined.

Member Function Documentation

template<class TypeTag >
void Ewoms::FvBaseLocalResidual< TypeTag >::computeFlux ( RateVector &flux  OPM_UNUSED,
const ElementContext &elemCtx  OPM_UNUSED,
unsigned scvfIdx  OPM_UNUSED,
unsigned timeIdx  OPM_UNUSED 
) const
inline

Evaluates the total mass flux of all conservation quantities over a face of a sub-control volume.

Parameters
fluxArea-specific flux over the phase.
template<class TypeTag >
void Ewoms::FvBaseLocalResidual< TypeTag >::computeSource ( RateVector &source  OPM_UNUSED,
const ElementContext &elemCtx  OPM_UNUSED,
unsigned dofIdx  OPM_UNUSED,
unsigned timeIdx  OPM_UNUSED 
) const
inline

Calculate the source term of the equation.

Parameters
sourceThe values of the source term.
template<class TypeTag >
void Ewoms::FvBaseLocalResidual< TypeTag >::computeStorage ( EqVector &storage  OPM_UNUSED,
const ElementContext &elemCtx  OPM_UNUSED,
unsigned dofIdx  OPM_UNUSED,
unsigned timeIdx  OPM_UNUSED 
) const
inline

Evaluate the amount all conservation quantities (e.g.

phase mass) within a finite sub-control volume.

Parameters
storageStores the total amount of each conserved quantity inside the domain.
template<class TypeTag >
void Ewoms::FvBaseLocalResidual< TypeTag >::eval ( const Problem &  problem,
const Element &  element 
)
inline

Compute the local residual, i.e.

the deviation of the conservation equations from zero and store the results internally.

The results can be requested afterwards using the residual() method.

Parameters
problemThe physical problem which ought to be solved.
elementThe DUNE element (i.e. the codim-0 entity) of interest.
template<class TypeTag >
void Ewoms::FvBaseLocalResidual< TypeTag >::eval ( const ElementContext &  elemCtx)
inline

Compute the local residual, i.e.

the deviation of the conservation equations from zero and store the results internally.

The results can be requested afterwards using the residual() method.

template<class TypeTag >
void Ewoms::FvBaseLocalResidual< TypeTag >::eval ( LocalEvalBlockVector &  residual,
const ElementContext &  elemCtx 
) const
inline

Compute the local residual, i.e.

the deviation of the conservation equations from zero.

Parameters
residualStores the residual of each conserved quantity.
template<class TypeTag >
void Ewoms::FvBaseLocalResidual< TypeTag >::evalFluxes ( LocalEvalBlockVector &  residual,
const ElementContext &  elemCtx,
unsigned  timeIdx 
) const
inline

Add the flux term to a local residual.

Parameters
residualStores the residual of each conserved quantity.
timeIdxThe index used by the time discretization.
template<class TypeTag >
void Ewoms::FvBaseLocalResidual< TypeTag >::evalStorage ( LocalEvalBlockVector &  storage,
const ElementContext &  elemCtx,
unsigned  timeIdx 
) const
inline

Calculate the amount of all conservation quantities stored in all element's sub-control volumes for a given history index.

This is used to figure out how much of each conservation quantity is inside the element.

Parameters
storageStores the total amount of each conserved quantity inside the domain.
timeIdxThe index used by the time discretization.
template<class TypeTag >
const EvalVector& Ewoms::FvBaseLocalResidual< TypeTag >::residual ( unsigned  dofIdx) const
inline

Return the result of the eval() call using internal storage.


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