Opm::SaturationOverlayFluidState< FluidState > Class Template Reference

This is a fluid state which allows to set the fluid saturations and takes all other quantities from an other fluid state. More...

#include <SaturationOverlayFluidState.hpp>

List of all members.

Public Types

enum  { numPhases = FluidState::numPhases }
enum  { numComponents = FluidState::numComponents }
typedef FluidState::Scalar Scalar

Public Member Functions

 SaturationOverlayFluidState (const FluidState &fs)
 Constructor.
 SaturationOverlayFluidState (const SaturationOverlayFluidState &fs)
SaturationOverlayFluidStateoperator= (const SaturationOverlayFluidState &fs)
auto saturation (unsigned phaseIdx) const -> decltype(std
 Returns the saturation of a phase [].
bool phaseIsPresent (unsigned phaseIdx) const
 Returns true iff a fluid phase shall be assumed to be present.
auto moleFraction (unsigned phaseIdx, unsigned compIdx) const -> decltype(std
 The mole fraction of a component in a phase [].
auto massFraction (unsigned phaseIdx, unsigned compIdx) const -> decltype(std
 The mass fraction of a component in a phase [].
auto averageMolarMass (unsigned phaseIdx) const -> decltype(std
 The average molar mass of a fluid phase [kg/mol].
auto molarity (unsigned phaseIdx, unsigned compIdx) const -> decltype(std
 The molar concentration of a component in a phase [mol/m^3].
auto fugacity (unsigned phaseIdx, unsigned compIdx) const -> decltype(std
 The fugacity of a component in a phase [Pa].
auto fugacityCoefficient (unsigned phaseIdx, unsigned compIdx) const -> decltype(std
 The fugacity coefficient of a component in a phase [-].
auto molarVolume (unsigned phaseIdx) const -> decltype(std
 The molar volume of a fluid phase [m^3/mol].
auto density (unsigned phaseIdx) const -> decltype(std
 The mass density of a fluid phase [kg/m^3].
auto molarDensity (unsigned phaseIdx) const -> decltype(std
 The molar density of a fluid phase [mol/m^3].
auto temperature (unsigned phaseIdx) const -> decltype(std
 The temperature of a fluid phase [K].
auto pressure (unsigned phaseIdx) const -> decltype(std
 The pressure of a fluid phase [Pa].
auto enthalpy (unsigned phaseIdx) const -> decltype(std
 The specific enthalpy of a fluid phase [J/kg].
auto internalEnergy (unsigned phaseIdx) const -> decltype(std
 The specific internal energy of a fluid phase [J/kg].
auto viscosity (unsigned phaseIdx) const -> decltype(std
 The dynamic viscosity of a fluid phase [Pa s].
void setSaturation (unsigned phaseIdx, const Scalar &value)
 Set the saturation [-] of a fluid phase.
void checkDefined () const
 Make sure that all attributes are defined.

Protected Attributes

const FluidState * fs_
std::array< Scalar, numPhases > saturation_

Detailed Description

template<class FluidState>
class Opm::SaturationOverlayFluidState< FluidState >

This is a fluid state which allows to set the fluid saturations and takes all other quantities from an other fluid state.


Constructor & Destructor Documentation

template<class FluidState >
Opm::SaturationOverlayFluidState< FluidState >::SaturationOverlayFluidState ( const FluidState &  fs  )  [inline]

Constructor.

The overlay fluid state copies the saturations from the argument, so it initially behaves exactly like the underlying fluid state.


Member Function Documentation

template<class FluidState >
auto Opm::SaturationOverlayFluidState< FluidState >::averageMolarMass ( unsigned  phaseIdx  )  const [inline]

The average molar mass of a fluid phase [kg/mol].

The average mass is the mean molar mass of a molecule of the fluid at current composition. It is defined as the sum of the component's molar masses weighted by the current mole fraction:

\[ \bar M_\alpha = \sum_\kappa M^\kappa x_\alpha^\kappa \]

template<class FluidState >
void Opm::SaturationOverlayFluidState< FluidState >::checkDefined (  )  const [inline]

Make sure that all attributes are defined.

This method does not do anything if the program is not run under valgrind. If it is, then valgrind will print an error message if some attributes of the object have not been properly defined.

template<class FluidState >
auto Opm::SaturationOverlayFluidState< FluidState >::molarity ( unsigned  phaseIdx,
unsigned  compIdx 
) const [inline]

The molar concentration of a component in a phase [mol/m^3].

This quantity is usually called "molar concentration" or just "concentration", but there are many other (though less common) measures for concentration.

http://en.wikipedia.org/wiki/Concentration


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

Generated on 25 Mar 2018 by  doxygen 1.6.1