24#ifndef DUMUX_SOLIDSYSTEMS_COMPOSITIONAL_SOLID_PHASE_HH
25#define DUMUX_SOLIDSYSTEMS_COMPOSITIONAL_SOLID_PHASE_HH
28#include <dune/common/exceptions.hh>
31namespace SolidSystems {
40template <
class Scalar,
class Component1,
class Component2,
int numInert = 0>
66 case comp0Idx:
return ComponentOne::name();
67 case comp1Idx:
return ComponentTwo::name();
68 default: DUNE_THROW(Dune::InvalidStateException,
"Invalid component index " << compIdx);
97 case comp0Idx:
return ComponentOne::molarMass();
98 case comp1Idx:
return ComponentTwo::molarMass();
99 default: DUNE_THROW(Dune::InvalidStateException,
"Invalid component index " << compIdx);
106 template <
class Sol
idState>
107 static Scalar
density(
const SolidState& solidState)
109 Scalar rho1 = ComponentOne::solidDensity(solidState.temperature());
110 Scalar rho2 = ComponentTwo::solidDensity(solidState.temperature());
111 Scalar volFrac1 = solidState.volumeFraction(
comp0Idx);
112 Scalar volFrac2 = solidState.volumeFraction(
comp1Idx);
114 return (rho1*volFrac1+
115 rho2*volFrac2)/(volFrac1+volFrac2);
121 template <
class Sol
idState>
122 static Scalar
density(
const SolidState& solidState,
const int compIdx)
126 case comp0Idx:
return ComponentOne::solidDensity(solidState.temperature());
127 case comp1Idx:
return ComponentTwo::solidDensity(solidState.temperature());
128 default: DUNE_THROW(Dune::InvalidStateException,
"Invalid component index " << compIdx);
135 template <
class Sol
idState>
136 static Scalar
molarDensity(
const SolidState& solidState,
const int compIdx)
140 case comp0Idx:
return ComponentOne::solidDensity(solidState.temperature())/ComponentOne::molarMass();
141 case comp1Idx:
return ComponentTwo::solidDensity(solidState.temperature())/ComponentTwo::molarMass();
142 default: DUNE_THROW(Dune::InvalidStateException,
"Invalid component index " << compIdx);
149 template <
class Sol
idState>
152 Scalar lambda1 = ComponentOne::solidThermalConductivity(solidState.temperature());
153 Scalar lambda2 = ComponentTwo::solidThermalConductivity(solidState.temperature());
154 Scalar volFrac1 = solidState.volumeFraction(
comp0Idx);
155 Scalar volFrac2 = solidState.volumeFraction(
comp1Idx);
157 return (lambda1*volFrac1+
158 lambda2*volFrac2)/(volFrac1+volFrac2);
164 template <
class Sol
idState>
167 Scalar c1 = ComponentOne::solidHeatCapacity(solidState.temperature());
168 Scalar c2 = ComponentTwo::solidHeatCapacity(solidState.temperature());
169 Scalar volFrac1 = solidState.volumeFraction(
comp0Idx);
170 Scalar volFrac2 = solidState.volumeFraction(
comp1Idx);
173 c2*volFrac2)/(volFrac1+volFrac2);
Adaption of the non-isothermal two-phase two-component flow model to problems with CO2.
Definition: adapt.hh:29
A solid phase consisting of multiple inert solid components.
Definition: compositionalsolidphase.hh:42
static Scalar molarMass(int compIdx)
The molar mass in of the component.
Definition: compositionalsolidphase.hh:93
static Scalar thermalConductivity(const SolidState &solidState)
Thermal conductivity of the solid .
Definition: compositionalsolidphase.hh:150
static constexpr int comp1Idx
Definition: compositionalsolidphase.hh:54
static std::string name()
A human readable name for the solid system.
Definition: compositionalsolidphase.hh:75
static constexpr bool isInert()
Returns whether the component is inert (doesn't react)
Definition: compositionalsolidphase.hh:87
static Scalar density(const SolidState &solidState, const int compIdx)
The density of the solid phase at a given pressure and temperature.
Definition: compositionalsolidphase.hh:122
static Scalar heatCapacity(const SolidState &solidState)
Specific isobaric heat capacity of the pure solids .
Definition: compositionalsolidphase.hh:165
static constexpr int comp0Idx
Definition: compositionalsolidphase.hh:53
Component2 ComponentTwo
Definition: compositionalsolidphase.hh:45
Component1 ComponentOne
Definition: compositionalsolidphase.hh:44
static constexpr int numInertComponents
Definition: compositionalsolidphase.hh:52
static constexpr bool isCompressible(int compIdx)
Returns whether the phase is incompressible.
Definition: compositionalsolidphase.hh:81
static constexpr int numComponents
Definition: compositionalsolidphase.hh:51
static std::string componentName(int compIdx)
Return the human readable name of a solid phase.
Definition: compositionalsolidphase.hh:62
static Scalar molarDensity(const SolidState &solidState, const int compIdx)
The molar density of the solid phase at a given pressure and temperature.
Definition: compositionalsolidphase.hh:136
static Scalar density(const SolidState &solidState)
The density of the solid phase at a given pressure and temperature.
Definition: compositionalsolidphase.hh:107