27 #ifndef OPM_COMPONENT_HPP
28 #define OPM_COMPONENT_HPP
30 #include <opm/common/ErrorMacros.hpp>
31 #include <opm/common/Exceptions.hpp>
42 template <
class ScalarT,
class Implementation>
46 typedef ScalarT Scalar;
48 static const bool isTabulated =
false;
62 static void init(Scalar , Scalar ,
unsigned ,
63 Scalar , Scalar ,
unsigned )
70 { OPM_THROW(std::runtime_error,
"Not implemented: Component::gasIsCompressible()"); }
76 { OPM_THROW(std::runtime_error,
"Not implemented: Component::gasIsIdeal()"); }
82 { OPM_THROW(std::runtime_error,
"Not implemented: Component::liquidIsCompressible()"); }
88 { OPM_THROW(std::runtime_error,
"Not implemented: Component::name()"); }
94 { OPM_THROW(std::runtime_error,
"Not implemented: Component::molarMass()"); }
100 { OPM_THROW(std::runtime_error,
"Not implemented: Component::criticalTemperature()"); }
106 { OPM_THROW(std::runtime_error,
"Not implemented: Component::criticalPressure()"); }
112 { OPM_THROW(std::runtime_error,
"Not implemented: Component::tripleTemperature()"); }
118 { OPM_THROW(std::runtime_error,
"Not implemented: Component::triplePressure()"); }
126 template <
class Evaluation>
128 { OPM_THROW(std::runtime_error,
"Not implemented: Component::vaporPressure()"); }
136 template <
class Evaluation>
137 static Evaluation
gasDensity(
const Evaluation& ,
const Evaluation& )
138 { OPM_THROW(std::runtime_error,
"Not implemented: Component::gasDensity()"); }
146 template <
class Evaluation>
148 { OPM_THROW(std::runtime_error,
"Not implemented: Component::liquidDensity()"); }
156 template <
class Evaluation>
157 static Evaluation
gasEnthalpy(
const Evaluation& ,
const Evaluation& )
158 { OPM_THROW(std::runtime_error,
"Not implemented: Component::gasEnthalpy()"); }
166 template <
class Evaluation>
168 { OPM_THROW(std::runtime_error,
"Not implemented: Component::liquidEnthalpy()"); }
176 template <
class Evaluation>
178 { OPM_THROW(std::runtime_error,
"Not implemented: Component::gasInternalEnergy()"); }
186 template <
class Evaluation>
188 { OPM_THROW(std::runtime_error,
"Not implemented: Component::liquidInternalEnergy()"); }
197 template <
class Evaluation>
199 { OPM_THROW(std::runtime_error,
"Not implemented: Component::gasViscosity()"); }
207 template <
class Evaluation>
209 { OPM_THROW(std::runtime_error,
"Not implemented: Component::liquidViscosity()"); }
214 template <
class Evaluation>
216 { OPM_THROW(std::runtime_error,
"Not implemented: Component::gasThermalConductivity()"); }
221 template <
class Evaluation>
223 { OPM_THROW(std::runtime_error,
"Not implemented: Component::liquidThermalConductivity()"); }
228 template <
class Evaluation>
230 { OPM_THROW(std::runtime_error,
"Not implemented: Component::gasHeatCapacity()"); }
235 template <
class Evaluation>
237 { OPM_THROW(std::runtime_error,
"Not implemented: Component::liquidHeatCapacity()"); }
static Evaluation gasDensity(const Evaluation &, const Evaluation &)
The density in of the component at a given pressure in and temperature in .
Definition: Component.hpp:137
static Evaluation liquidDensity(const Evaluation &, const Evaluation &)
The density of the liquid component at a given pressure in and temperature in . ...
Definition: Component.hpp:147
Abstract base class of a pure chemical species.
Definition: Component.hpp:43
static Evaluation gasThermalConductivity(const Evaluation &, const Evaluation &)
Thermal conductivity of the component [W/(m^2 K/m)] as a gas.
Definition: Component.hpp:215
static Evaluation liquidViscosity(const Evaluation &, const Evaluation &)
The dynamic liquid viscosity of the pure component.
Definition: Component.hpp:208
static Scalar criticalPressure()
Returns the critical pressure in of the component.
Definition: Component.hpp:105
static Evaluation vaporPressure(const Evaluation &)
The vapor pressure in of the component at a given temperature in .
Definition: Component.hpp:127
static bool liquidIsCompressible()
Returns true iff the liquid phase is assumed to be compressible.
Definition: Component.hpp:81
static void init(Scalar, Scalar, unsigned, Scalar, Scalar, unsigned)
A default routine for initialization, not needed for components and must not be called.
Definition: Component.hpp:62
static Evaluation liquidEnthalpy(const Evaluation &, const Evaluation &)
Specific enthalpy of the pure component in liquid.
Definition: Component.hpp:167
static Evaluation liquidHeatCapacity(const Evaluation &, const Evaluation &)
Specific isobaric heat capacity of the component [J/kg] as a liquid.
Definition: Component.hpp:236
static Evaluation gasInternalEnergy(const Evaluation &, const Evaluation &)
Specific internal energy of the pure component in gas.
Definition: Component.hpp:177
static bool gasIsIdeal()
Returns true iff the gas phase is assumed to be ideal.
Definition: Component.hpp:75
static Evaluation gasEnthalpy(const Evaluation &, const Evaluation &)
Specific enthalpy of the pure component in gas.
Definition: Component.hpp:157
static Evaluation gasViscosity(const Evaluation &, const Evaluation &)
The dynamic viscosity of the pure component at a given pressure in and temperature in ...
Definition: Component.hpp:198
static Scalar triplePressure()
Returns the pressure in at the component's triple point.
Definition: Component.hpp:117
static Scalar criticalTemperature()
Returns the critical temperature in of the component.
Definition: Component.hpp:99
static Evaluation gasHeatCapacity(const Evaluation &, const Evaluation &)
Specific isobaric heat capacity of the component [J/kg] as a gas.
Definition: Component.hpp:229
static Evaluation liquidThermalConductivity(const Evaluation &, const Evaluation &)
Thermal conductivity of the component [W/(m^2 K/m)] as a liquid.
Definition: Component.hpp:222
static Evaluation liquidInternalEnergy(const Evaluation &, const Evaluation &)
Specific internal energy of pure the pure component in liquid.
Definition: Component.hpp:187
static Scalar tripleTemperature()
Returns the temperature in at the component's triple point.
Definition: Component.hpp:111
static const char * name()
A human readable name for the component.
Definition: Component.hpp:87
static bool gasIsCompressible()
Returns true iff the gas phase is assumed to be compressible.
Definition: Component.hpp:69
static Scalar molarMass()
The molar mass in of the component.
Definition: Component.hpp:93