The fluid system for the SPE-5 benchmark problem. More...
#include <dumux/material/fluidsystems/spe5.hh>
The fluid system for the SPE-5 benchmark problem.
A three-phase fluid system featuring gas, oil and water as phases and the seven components distilled water, Methane \((\mathrm{C_1})\), Propane \((\mathrm{C_3})\), Pentane \((\mathrm{C_5})\), Heptane \((\mathrm{C_7})\), Decane \((\mathrm{C_{10}})\), Pentadecane \((\mathrm{C_{15}})\) and Icosane \((\mathrm{C_{20}})\). For the water phase the IAPWS-97 formulation is used as equation of state, while for the gas and oil phases a Peng-Robinson equation of state with slightly modified parameters is used. This fluid system is highly non-linear, and the gas and oil phases also cannot be considered ideal.
See:
J.E. Killough, et al.: Fifth Comparative Solution Project: Evaluation of Miscible Flood Simulators, Ninth SPE Symposium on Reservoir Simulation, 1987 [37]
Public Types | |
using | ParameterCache = Spe5ParameterCache< Scalar, ThisType > |
using | H2O = Dumux::Components::H2O< Scalar > |
The component for pure water to be used. More... | |
Static Public Member Functions | |
static std::string | phaseName (int phaseIdx) |
Return the human readable name of a fluid phase. More... | |
static constexpr bool | isMiscible () |
Returns whether the fluids are miscible. More... | |
static constexpr bool | isGas (int phaseIdx) |
Return whether a phase is gaseous. More... | |
static constexpr bool | isCompressible (int phaseIdx) |
Return whether a phase is compressible. More... | |
static bool | isIdealMixture (int phaseIdx) |
Returns true if and only if a fluid phase is assumed to be an ideal mixture. More... | |
static bool | isIdealGas (int phaseIdx) |
Returns true if and only if a fluid phase is assumed to be an ideal gas. More... | |
static std::string | componentName (int compIdx) |
Return the human readable name of a component. More... | |
static Scalar | molarMass (int compIdx) |
Return the molar mass of a component in \(\mathrm{[kg/mol]}\). More... | |
static Scalar | criticalTemperature (int compIdx) |
Critical temperature of a component \(\mathrm{[K]}\). More... | |
static Scalar | criticalPressure (int compIdx) |
Critical pressure of a component \(\mathrm{[Pa]}\). More... | |
static Scalar | criticalMolarVolume (int compIdx) |
Molar volume of a component at the critical point \(\mathrm{[m^3/mol]}\). More... | |
static Scalar | acentricFactor (int compIdx) |
The acentric factor of a component \(\mathrm{[-]}\). More... | |
static Scalar | interactionCoefficient (int comp1Idx, int comp2Idx) |
Returns the interaction coefficient for two components. More... | |
static void | init () |
Initialize the fluid system's static parameters. More... | |
template<class FluidState > | |
static Scalar | density (const FluidState &fluidState, const ParameterCache ¶mCache, int phaseIdx) |
Calculate the density \(\mathrm{[kg/m^3]}\) of a fluid phase. More... | |
template<class FluidState > | |
static Scalar | molarDensity (const FluidState &fluidState, const ParameterCache ¶mCache, int phaseIdx) |
The molar density \(\rho_{mol,\alpha}\) of a fluid phase \(\alpha\) in \(\mathrm{[mol/m^3]}\). More... | |
template<class FluidState > | |
static Scalar | viscosity (const FluidState &fs, const ParameterCache ¶mCache, int phaseIdx) |
Calculate the dynamic viscosity of a fluid phase \(\mathrm{[Pa*s]}\). More... | |
template<class FluidState > | |
static Scalar | fugacityCoefficient (const FluidState &fs, const ParameterCache ¶mCache, int phaseIdx, int compIdx) |
Calculate the fugacity coefficient \(\mathrm{[-]}\) of an individual component in a fluid phase. More... | |
template<class FluidState > | |
static Scalar | diffusionCoefficient (const FluidState &fs, const ParameterCache ¶mCache, int phaseIdx, int compIdx) |
Calculate the binary molecular diffusion coefficient for a component in a fluid phase \(\mathrm{[mol^2 * s / (kg*m^3)]}\). More... | |
template<class FluidState > | |
static Scalar | binaryDiffusionCoefficient (const FluidState &fluidState, const ParameterCache ¶mCache, int phaseIdx, int compIIdx, int compJIdx) |
Given a phase's composition, temperature and pressure, return the binary diffusion coefficient \(\mathrm{[m^2/s]}\) for components \(i\) and \(j\) in this phase. More... | |
template<class FluidState > | |
static Scalar | enthalpy (const FluidState &fs, const ParameterCache ¶mCache, int phaseIdx) |
Given a phase's composition, temperature and pressure, calculate its specific enthalpy \(\mathrm{[J/kg]}\). More... | |
template<class FluidState > | |
static Scalar | thermalConductivity (const FluidState &fluidState, const ParameterCache ¶mCache, int phaseIdx) |
Given a phase's composition, temperature and pressure, calculate its thermal conductivity \(\mathrm{[W/(m K)]}\). More... | |
template<class FluidState > | |
static Scalar | heatCapacity (const FluidState &fluidState, const ParameterCache ¶mCache, int phaseIdx) |
Given a phase's composition, temperature and pressure, calculate its heat capacity \(\mathrm{[J/(kg K)]}\). More... | |
Static Public Attributes | |
static const int | numPhases = 3 |
Number of phases in the fluid system. More... | |
static const int | gPhaseIdx = 0 |
Index of the gas phase. More... | |
static const int | wPhaseIdx = 1 |
Index of the water phase. More... | |
static const int | oPhaseIdx = 2 |
Index of the oil phase. More... | |
static const int | numComponents = 7 |
Number of components in the fluid system. More... | |
static const int | H2OIdx = 0 |
static const int | C1Idx = 1 |
static const int | C3Idx = 2 |
static const int | C6Idx = 3 |
static const int | C10Idx = 4 |
static const int | C15Idx = 5 |
static const int | C20Idx = 6 |
using Dumux::FluidSystems::Spe5< Scalar >::H2O = Dumux::Components::H2O<Scalar> |
The component for pure water to be used.
using Dumux::FluidSystems::Spe5< Scalar >::ParameterCache = Spe5ParameterCache<Scalar, ThisType> |
|
inlinestatic |
The acentric factor of a component \(\mathrm{[-]}\).
compIdx | The index of the component to consider |
|
inlinestatic |
Given a phase's composition, temperature and pressure, return the binary diffusion coefficient \(\mathrm{[m^2/s]}\) for components \(i\) and \(j\) in this phase.
fluidState | An arbitrary fluid state |
paramCache | Container for cache parameters |
phaseIdx | The index of the fluid phase to consider |
compIIdx | The index of the first component to consider |
compJIdx | The index of the second component to consider |
|
inlinestatic |
Return the human readable name of a component.
compIdx | The index of the component to consider |
|
inlinestatic |
Molar volume of a component at the critical point \(\mathrm{[m^3/mol]}\).
compIdx | The index of the component to consider |
|
inlinestatic |
Critical pressure of a component \(\mathrm{[Pa]}\).
compIdx | The index of the component to consider |
|
inlinestatic |
Critical temperature of a component \(\mathrm{[K]}\).
compIdx | The index of the component to consider |
|
inlinestatic |
Calculate the density \(\mathrm{[kg/m^3]}\) of a fluid phase.
fluidState | An arbitrary fluid state |
paramCache | Container for cache parameters |
phaseIdx | The index of the fluid phase to consider |
|
inlinestatic |
Calculate the binary molecular diffusion coefficient for a component in a fluid phase \(\mathrm{[mol^2 * s / (kg*m^3)]}\).
Molecular diffusion of a compoent \(\mathrm{\kappa}\) is caused by a gradient of the chemical potential and follows the law
\[ J = - D grad \mu_\kappa \]
where \(\mathrm{\mu_\kappa}\) is the component's chemical potential, \(\mathrm{D}\) is the diffusion coefficient and \(\mathrm{J}\) is the diffusive flux. \(\mathrm{\mu_\kappa}\) is connected to the component's fugacity \(\mathrm{f_\kappa}\) by the relation
\[ \mu_\kappa = R T_\alpha \mathrm{ln} \frac{f_\kappa}{p_\alpha} \]
where \(\mathrm{p_\alpha}\) and \(\mathrm{T_\alpha}\) are the fluid phase' pressure and temperature.
fs | An arbitrary fluid state |
paramCache | Container for cache parameters |
phaseIdx | The index of the fluid phase to consider |
compIdx | The index of the component to consider |
|
inlinestatic |
Given a phase's composition, temperature and pressure, calculate its specific enthalpy \(\mathrm{[J/kg]}\).
fs | An arbitrary fluid state |
paramCache | Container for cache parameters |
phaseIdx | The index of the fluid phase to consider |
|
inlinestatic |
Calculate the fugacity coefficient \(\mathrm{[-]}\) of an individual component in a fluid phase.
The fugacity coefficient \(\mathrm{\phi^\kappa_\alpha}\) is connected to the fugacity \(\mathrm{f^\kappa_\alpha}\) and the component's mole fraction in a phase \(\mathrm{x^\kappa_\alpha}\) by means of the relation
\[ f^\kappa_\alpha = \phi^\kappa_\alpha \cdot x^\kappa_\alpha \cdot p_alpha \]
fs | An arbitrary fluid state |
paramCache | Container for cache parameters |
phaseIdx | The index of the fluid phase to consider |
compIdx | The index of the component to consider |
|
inlinestatic |
Given a phase's composition, temperature and pressure, calculate its heat capacity \(\mathrm{[J/(kg K)]}\).
fluidState | An arbitrary fluid state |
paramCache | Container for cache parameters |
phaseIdx | The index of the fluid phase to consider |
|
inlinestatic |
Initialize the fluid system's static parameters.
|
inlinestatic |
Returns the interaction coefficient for two components.
comp1Idx | The index of component 1 to consider |
comp2Idx | The index of component 2 to consider |
The values are given by the SPE5 paper.
|
inlinestaticconstexpr |
Return whether a phase is compressible.
phaseIdx | The index of the fluid phase to consider |
In the SPE-5 problems all fluids are compressible...
|
inlinestaticconstexpr |
Return whether a phase is gaseous.
phaseIdx | The index of the fluid phase to consider |
|
inlinestatic |
Returns true if and only if a fluid phase is assumed to be an ideal gas.
phaseIdx | The index of the fluid phase to consider |
|
inlinestatic |
Returns true if and only if a fluid phase is assumed to be an ideal mixture.
We define an ideal mixture as a fluid phase where the fugacity coefficients of all components times the pressure of the phase are independent on the fluid composition. This assumption is true if Henry's law and Raoult's law apply. If you are unsure what this function should return, it is safe to return false. The only damage done will be (slightly) increased computation times in some cases.
phaseIdx | The index of the fluid phase to consider |
|
inlinestaticconstexpr |
Returns whether the fluids are miscible.
|
inlinestatic |
The molar density \(\rho_{mol,\alpha}\) of a fluid phase \(\alpha\) in \(\mathrm{[mol/m^3]}\).
The molar density is defined by the mass density \(\rho_\alpha\) and the mean molar mass \(\overline M_\alpha\):
\[\rho_{mol,\alpha} = \frac{\rho_\alpha}{\overline M_\alpha} \;.\]
|
inlinestatic |
Return the molar mass of a component in \(\mathrm{[kg/mol]}\).
compIdx | The index of the component to consider |
|
inlinestatic |
Return the human readable name of a fluid phase.
phaseIdx | The index of the fluid phase to consider |
|
inlinestatic |
Given a phase's composition, temperature and pressure, calculate its thermal conductivity \(\mathrm{[W/(m K)]}\).
fluidState | An arbitrary fluid state |
paramCache | Container for cache parameters |
phaseIdx | The index of the fluid phase to consider |
|
inlinestatic |
Calculate the dynamic viscosity of a fluid phase \(\mathrm{[Pa*s]}\).
fs | An arbitrary fluid state |
paramCache | Container for cache parameters |
phaseIdx | The index of the fluid phase to consider |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
Index of the gas phase.
|
static |
|
static |
Number of components in the fluid system.
|
static |
Number of phases in the fluid system.
|
static |
Index of the oil phase.
|
static |
Index of the water phase.