Loading...
Searching...
No Matches
Opm::P1FeGradientCalculator< TypeTag > Class Template Reference

This class calculates gradients of arbitrary quantities at flux integration points using first order finite elements ansatz functions. More...

`#include <p1fegradientcalculator.hh>`

Inheritance diagram for Opm::P1FeGradientCalculator< TypeTag >:

## Public Member Functions

template<bool prepareValues = true, bool prepareGradients = true>
void | prepare (const ElementContext &elemCtx, unsigned timeIdx)
| Precomputes the common values to calculate gradients and values of quantities at any flux approximation point.
template<class QuantityCallback>
auto | calculateScalarValue (const ElementContext &elemCtx, unsigned fapIdx, const QuantityCallback &quantityCallback) const -> std::remove_reference_t< typename QuantityCallback::ResultType >
| Calculates the value of an arbitrary quantity at any interior flux approximation point.
template<class QuantityCallback>
auto | calculateVectorValue (const ElementContext &elemCtx, unsigned fapIdx, const QuantityCallback &quantityCallback) const -> std::remove_reference_t< typename QuantityCallback::ResultType >
| Calculates the value of an arbitrary quantity at any interior flux approximation point.
template<class QuantityCallback, class EvalDimVector>
void | calculateGradient (EvalDimVector &quantityGrad, const ElementContext &elemCtx, unsigned fapIdx, const QuantityCallback &quantityCallback) const
| Calculates the gradient of an arbitrary quantity at any flux approximation point.
template<class QuantityCallback>
auto | calculateBoundaryValue (const ElementContext &elemCtx, unsigned fapIdx, const QuantityCallback &quantityCallback) -> decltype(ParentType::calculateBoundaryValue(elemCtx, fapIdx, quantityCallback))
| Calculates the value of an arbitrary quantity at any flux approximation point on the grid boundary.
template<class QuantityCallback, class EvalDimVector>
void | calculateBoundaryGradient (EvalDimVector &quantityGrad, const ElementContext &elemCtx, unsigned fapIdx, const QuantityCallback &quantityCallback) const
| Calculates the gradient of an arbitrary quantity at any flux approximation point on the boundary.
Public Member Functions inherited from Opm::FvBaseGradientCalculator< TypeTag >
template<bool prepareValues = true, bool prepareGradients = true>
void | prepare (const ElementContext &, unsigned)
| Precomputes the common values to calculate gradients and values of quantities at every interior flux approximation point.
template<class QuantityCallback>
auto | calculateScalarValue (const ElementContext &elemCtx, unsigned fapIdx, const QuantityCallback &quantityCallback) const -> std::remove_reference_t< decltype(quantityCallback.operator()(0))>
| Calculates the value of an arbitrary scalar quantity at any interior flux approximation point.
template<class QuantityCallback>
auto | calculateVectorValue (const ElementContext &elemCtx, unsigned fapIdx, const QuantityCallback &quantityCallback) const -> std::remove_reference_t< decltype(quantityCallback.operator()(0))>
| Calculates the value of an arbitrary vectorial quantity at any interior flux approximation point.
template<class QuantityCallback>
void | calculateGradient (EvalDimVector &quantityGrad, const ElementContext &elemCtx, unsigned fapIdx, const QuantityCallback &quantityCallback) const
| Calculates the gradient of an arbitrary quantity at any flux approximation point.
template<class QuantityCallback>
auto | calculateBoundaryValue (const ElementContext &, unsigned, const QuantityCallback &quantityCallback) -> decltype(quantityCallback.boundaryValue())
| Calculates the value of an arbitrary quantity at any flux approximation point on the grid boundary.
template<class QuantityCallback>
void | calculateBoundaryGradient (EvalDimVector &quantityGrad, const ElementContext &elemCtx, unsigned faceIdx, const QuantityCallback &quantityCallback) const
| Calculates the gradient of an arbitrary quantity at any flux approximation point on the boundary.

## Additional Inherited Members

Static Public Member Functions inherited from Opm::FvBaseGradientCalculator< TypeTag >
static void | registerParameters ()
| Register all run-time parameters for the gradient calculator of the base class of the discretization.

## Detailed Description

template<class TypeTag>
class Opm::P1FeGradientCalculator< TypeTag >

This class calculates gradients of arbitrary quantities at flux integration points using first order finite elements ansatz functions.

This approach can also be used for the vertex-centered finite volume (VCFV) discretization.

## Member Function Documentation

## calculateBoundaryGradient()

template<class TypeTag>
template<class QuantityCallback, class EvalDimVector>

void Opm::P1FeGradientCalculator< TypeTag >::calculateBoundaryGradient | ( | EvalDimVector & | quantityGrad,
|  | const ElementContext & | elemCtx,
|  | unsigned | fapIdx,
|  | const QuantityCallback & | quantityCallback ) const

inline

Calculates the gradient of an arbitrary quantity at any flux approximation point on the boundary.

Boundary gradients are always calculated using the two-point approximation.

Parameters

  quantityGrad | Resulting gradient
  elemCtx | The current execution context
  fapIdx | The local index of the flux approximation point in the current element's stencil.
  quantityCallback | A callable object returning the value of the quantity at an index of a degree of freedom

## calculateBoundaryValue()

template<class TypeTag>
template<class QuantityCallback>

auto Opm::P1FeGradientCalculator< TypeTag >::calculateBoundaryValue | ( | const ElementContext & | elemCtx,
|  | unsigned | fapIdx,
|  | const QuantityCallback & | quantityCallback )->decltype(ParentType::calculateBoundaryValue(elemCtx, fapIdx, quantityCallback))

inline

Calculates the value of an arbitrary quantity at any flux approximation point on the grid boundary.

Boundary values are always calculated using the two-point approximation.

Parameters

  elemCtx | The current execution context
  fapIdx | The local index of the flux approximation point in the current element's stencil.
  quantityCallback | A callable object returning the value of the quantity at an index of a degree of freedom

## calculateGradient()

template<class TypeTag>
template<class QuantityCallback, class EvalDimVector>

void Opm::P1FeGradientCalculator< TypeTag >::calculateGradient | ( | EvalDimVector & | quantityGrad,
|  | const ElementContext & | elemCtx,
|  | unsigned | fapIdx,
|  | const QuantityCallback & | quantityCallback ) const

inline

Calculates the gradient of an arbitrary quantity at any flux approximation point.

Parameters

  [out] | quantityGrad | Resulting gradient
  | elemCtx | The current execution context
  | fapIdx | The local index of the flux approximation point in the current element's stencil.
  | quantityCallback | A callable object returning the value of the quantity at an index of a degree of freedom

## calculateScalarValue()

template<class TypeTag>
template<class QuantityCallback>

auto Opm::P1FeGradientCalculator< TypeTag >::calculateScalarValue | ( | const ElementContext & | elemCtx,
|  | unsigned | fapIdx,
|  | const QuantityCallback & | quantityCallback ) const->std::remove_reference_t< typenameQuantityCallback::ResultType >

inline

Calculates the value of an arbitrary quantity at any interior flux approximation point.

Parameters

  elemCtx | The current execution context
  fapIdx | The local index of the flux approximation point in the current element's stencil.
  quantityCallback | A callable object returning the value of the quantity at an index of a degree of freedom

## calculateVectorValue()

template<class TypeTag>
template<class QuantityCallback>

auto Opm::P1FeGradientCalculator< TypeTag >::calculateVectorValue | ( | const ElementContext & | elemCtx,
|  | unsigned | fapIdx,
|  | const QuantityCallback & | quantityCallback ) const->std::remove_reference_t< typenameQuantityCallback::ResultType >

inline

Calculates the value of an arbitrary quantity at any interior flux approximation point.

Parameters

  elemCtx | The current execution context
  fapIdx | The local index of the flux approximation point in the current element's stencil.
  quantityCallback | A callable object returning the value of the quantity at an index of a degree of freedom

## prepare()

template<class TypeTag>
template<bool prepareValues = true, bool prepareGradients = true>

void Opm::P1FeGradientCalculator< TypeTag >::prepare | ( | const ElementContext & | elemCtx,
|  | unsigned | timeIdx )

inline

Precomputes the common values to calculate gradients and values of quantities at any flux approximation point.

Parameters

  elemCtx | The current execution context
  timeIdx | Time index

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

- opm/models/discretization/vcfv/p1fegradientcalculator.hh