28#ifndef EWOMS_NCP_PRIMARY_VARIABLES_HH
29#define EWOMS_NCP_PRIMARY_VARIABLES_HH
31#include <dune/common/fvector.hh>
33#include <opm/material/constraintsolvers/NcpFlash.hpp>
34#include <opm/material/densead/Math.hpp>
35#include <opm/material/fluidstates/CompositionalFluidState.hpp>
54template <
class TypeTag>
66 enum { pressure0Idx = Indices::pressure0Idx };
67 enum { saturation0Idx = Indices::saturation0Idx };
68 enum { fugacity0Idx = Indices::fugacity0Idx };
72 using ComponentVector = Dune::FieldVector<Scalar, numComponents>;
90 using ParentType::operator=;
95 template <
class Flu
idState>
105 assert(fluidState.temperature(0) == fluidState.temperature(
phaseIdx));
155 template <
class Flu
idState>
162 EnergyModule::setPriVarTemperatures(*
this, fluidState);
167 const Scalar
pRef = FsToolbox::value(fluidState.pressure(
refPhaseIdx));
176 (*this)[fugacity0Idx +
compIdx] =
181 (*this)[pressure0Idx] = FsToolbox::value(fluidState.pressure(0));
185 (*this)[saturation0Idx +
phaseIdx] = FsToolbox::value(fluidState.saturation(
phaseIdx));
Provides the auxiliary methods required for consideration of the energy equation.
Definition energymodule.hh:54
Represents the primary variables used by the a model.
Definition fvbaseprimaryvariables.hh:53
Represents the primary variables used by the compositional multi-phase NCP model.
Definition ncpprimaryvariables.hh:56
void assignNaive(const FluidState &fluidState, unsigned refPhaseIdx=0)
Directly retrieve the primary variables from an arbitrary fluid state.
Definition ncpprimaryvariables.hh:156
void assignMassConservative(const FluidState &fluidState, const MaterialLawParams &matParams, bool isInEquilibrium=false)
< Import base class assignment operators.
Definition ncpprimaryvariables.hh:96
NcpPrimaryVariables(const NcpPrimaryVariables &value)=default
Contains the classes required to consider energy as a conservation quantity in a multi-phase module.
Represents the primary variables used by the a model.
This file contains a set of helper functions used by VFPProd / VFPInj.
Definition blackoilbioeffectsmodules.hh:43
constexpr auto getPropValue()
get the value data member of a property
Definition propertysystem.hh:240
typename Properties::Detail::GetPropImpl< TypeTag, Property >::type::type GetPropType
get the type alias defined in the property (equivalent to old macro GET_PROP_TYPE(....
Definition propertysystem.hh:233
Declares the properties required for the NCP compositional multi-phase model.