14#ifndef DUMUX_MPNC_LOCAL_RESIDUAL_HH 
   15#define DUMUX_MPNC_LOCAL_RESIDUAL_HH 
   17#include <dune/istl/bvector.hh> 
   32template<
class TypeTag>
 
   42    using Indices = 
typename ModelTraits::Indices;
 
   44    enum {numPhases = ModelTraits::numFluidPhases()};
 
   45    enum {phase0NcpIdx = Indices::phase0NcpIdx};
 
   48    using ParentType::ParentType;
 
   50    using typename ParentType::ElementResidualVector;
 
   53                                            const FVElementGeometry& fvGeometry,
 
   54                                            const ElementVolumeVariables& elemVolVars,
 
   55                                            const ElementFluxVariablesCache& elemFluxVarsCache,
 
   56                                            const ElementBoundaryTypes &bcTypes)
 const 
   58        ElementResidualVector residual = ParentType::evalFluxAndSource(element, fvGeometry, elemVolVars, elemFluxVarsCache, bcTypes);
 
   60        for (
auto&& scv : scvs(fvGeometry))
 
   63            for (
int phaseIdx = 0; phaseIdx < numPhases; ++phaseIdx)
 
   64                residual[scv.localDofIndex()][phase0NcpIdx + phaseIdx] = elemVolVars[scv].phaseNcp(phaseIdx);
 
 
 
Element-wise calculation of the local residual for problems using compositional fully implicit model.
Definition porousmediumflow/compositional/localresidual.hh:35
MpNc specific details needed to approximately calculate the local defect in the fully implicit scheme...
Definition porousmediumflow/mpnc/localresidual.hh:34
ElementResidualVector evalFluxAndSource(const Element &element, const FVElementGeometry &fvGeometry, const ElementVolumeVariables &elemVolVars, const ElementFluxVariablesCache &elemFluxVarsCache, const ElementBoundaryTypes &bcTypes) const
Definition porousmediumflow/mpnc/localresidual.hh:52
Defines all properties used in Dumux.
typename GetProp< TypeTag, Property >::type GetPropType
get the type alias defined in the property
Definition propertysystem.hh:296
The available discretization methods in Dumux.
Element-wise calculation of the local residual for problems using compositional fully implicit model.