opm-common
Loading...
Searching...
No Matches
Co2GasPvt.hpp
Go to the documentation of this file.
1// -*- mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
2// vi: set et ts=4 sw=4 sts=4:
3/*
4 This file is part of the Open Porous Media project (OPM).
5
6 OPM is free software: you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation, either version 2 of the License, or
9 (at your option) any later version.
10
11 OPM is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with OPM. If not, see <http://www.gnu.org/licenses/>.
18
19 Consult the COPYING file in the top-level source directory of this
20 module for the precise wording of the license and the list of
21 copyright holders.
22*/
27#ifndef OPM_CO2_GAS_PVT_HPP
28#define OPM_CO2_GAS_PVT_HPP
29
30#include <opm/common/utility/VectorWithDefaultAllocator.hpp>
31
33#include <opm/common/TimingMacros.hpp>
34#include <opm/common/ErrorMacros.hpp>
35#include <opm/common/utility/gpuDecorators.hpp>
37
43#include <opm/input/eclipse/EclipseState/Co2StoreConfig.hpp>
44#include <opm/material/components/CO2Tables.hpp>
45#include <opm/input/eclipse/EclipseState/EclipseState.hpp>
46#include <opm/input/eclipse/EclipseState/Tables/TableManager.hpp>
47
48#include <cstddef>
49#include <vector>
50
51namespace Opm {
52
53class EclipseState;
54class Schedule;
55class Co2StoreConfig;
56
57// forward declaration of the class so the function in the next namespace can be declared
58template <class Scalar, template<class> class Storage>
59class Co2GasPvt;
60
61#if HAVE_CUDA
62// declaration of make_view in correct namespace so friend function can be declared in the class
63namespace gpuistl {
64 template <class Scalar>
65 Co2GasPvt<Scalar, GpuView>
66 make_view(Co2GasPvt<Scalar, GpuVector>&);
67} // namespace gpuistl
68#endif // HAVE_CUDA
73template <class Scalar, template<class> class Storage = VectorWithDefaultAllocator>
74class Co2GasPvt
75{
78 using H2O = SimpleHuDuanH2O<Scalar>;
80 using ContainerT = Storage<Scalar>;
81 static constexpr bool extrapolate = true;
82
83public:
86
87 Co2GasPvt() = default;
88
89 explicit Co2GasPvt(const ContainerT& salinity,
90 int activityModel = 3,
91 int thermalMixingModel = 1,
92 Scalar T_ref = 288.71, //(273.15 + 15.56)
93 Scalar P_ref = 101325);
94
95 Co2GasPvt(const Params& params,
96 const ContainerT& brineReferenceDensity,
97 const ContainerT& gasReferenceDensity,
98 const ContainerT& salinity,
99 bool enableEzrokhiDensity,
100 bool enableVaporization,
101 int activityModel,
102 Co2StoreConfig::GasMixingType gastype)
103 : brineReferenceDensity_(brineReferenceDensity)
104 , gasReferenceDensity_(gasReferenceDensity)
105 , salinity_(salinity)
106 , enableEzrokhiDensity_(enableEzrokhiDensity)
107 , enableVaporization_(enableVaporization)
108 , activityModel_(activityModel)
109 , gastype_(gastype)
110 , co2Tables(params)
111{
112 assert(enableEzrokhiDensity == false && "Ezrokhi density not supported by GPUs");
113}
114
115#if HAVE_ECL_INPUT
116 void initFromState(const EclipseState& eclState, const Schedule&);
117#endif
118
119 void setNumRegions(std::size_t numRegions);
120
121 OPM_HOST_DEVICE void setVapPars(const Scalar, const Scalar)
122 {
123 }
124
125
126 OPM_HOST_DEVICE static constexpr bool isActive()
127 {
128 return true;
129 }
130
134 OPM_HOST_DEVICE void setReferenceDensities(unsigned regionIdx,
135 Scalar rhoRefBrine,
136 Scalar rhoRefGas,
137 Scalar /*rhoRefWater*/);
138
145 OPM_HOST_DEVICE void setEnableVaporizationWater(bool yesno)
146 { enableVaporization_ = yesno; }
147
151 OPM_HOST_DEVICE void setActivityModelSalt(int activityModel);
152
156 OPM_HOST_DEVICE void setThermalMixingModel(int thermalMixingModel);
157
161 OPM_HOST_DEVICE void initEnd()
162 {
163 }
164
168 OPM_HOST_DEVICE unsigned numRegions() const
169 { return gasReferenceDensity_.size(); }
170
171 OPM_HOST_DEVICE Scalar hVap(unsigned ) const
172 { return 0.0; }
173
177 template <class Evaluation>
178 OPM_HOST_DEVICE Evaluation internalEnergy(unsigned regionIdx,
179 const Evaluation& temperature,
180 const Evaluation& pressure,
181 const Evaluation& rv,
182 const Evaluation& rvw) const
183 {
184 OPM_TIMEBLOCK_LOCAL(internalEnergy, Subsystem::PvtProps);
185 if (gastype_ == Co2StoreConfig::GasMixingType::NONE) {
186 // use the gasInternalEnergy of CO2
187 return CO2::gasInternalEnergy(co2Tables, temperature, pressure, extrapolate);
188 }
189
190 assert(gastype_ == Co2StoreConfig::GasMixingType::IDEAL);
191 // account for H2O in the gas phase
192 Evaluation result = 0;
193 // The CO2STORE option both works for GAS/WATER and GAS/OIL systems
194 // Either rv og rvw should be zero
195 assert(rv == 0.0 || rvw == 0.0);
196 const Evaluation xBrine = convertRvwToXgW_(max(rvw,rv),regionIdx);
197 result += xBrine * H2O::gasInternalEnergy(temperature, pressure);
198 result += (1 - xBrine) * CO2::gasInternalEnergy(co2Tables, temperature, pressure, extrapolate);
199 return result;
200 }
201
206 template <class Evaluation>
207 OPM_HOST_DEVICE Evaluation viscosity(unsigned regionIdx,
208 const Evaluation& temperature,
209 const Evaluation& pressure,
210 const Evaluation& /*Rv*/,
211 const Evaluation& /*Rvw*/) const
212 { return saturatedViscosity(regionIdx, temperature, pressure); }
213
217 template <class Evaluation>
218 OPM_HOST_DEVICE Evaluation saturatedViscosity(unsigned /*regionIdx*/,
219 const Evaluation& temperature,
220 const Evaluation& pressure) const
221 {
222 OPM_TIMEBLOCK_LOCAL(saturatedViscosity, Subsystem::PvtProps);
223 // Neglects impact of vaporized water on the visosity
224 return CO2::gasViscosity(co2Tables, temperature, pressure, extrapolate);
225 }
226
230 template <class Evaluation>
231 OPM_HOST_DEVICE Evaluation inverseFormationVolumeFactor(unsigned regionIdx,
232 const Evaluation& temperature,
233 const Evaluation& pressure,
234 const Evaluation& rv,
235 const Evaluation& rvw) const
236 {
237 OPM_TIMEFUNCTION_LOCAL(Subsystem::PvtProps);
238 if (!enableVaporization_) {
239 return CO2::gasDensity(co2Tables, temperature, pressure, extrapolate) /
240 gasReferenceDensity_[regionIdx];
241 }
242
243 // Use CO2 density for the gas phase.
244 const auto& rhoCo2 = CO2::gasDensity(co2Tables, temperature, pressure, extrapolate);
245 //const auto& rhoH2O = H2O::gasDensity(temperature, pressure);
246 //The CO2STORE option both works for GAS/WATER and GAS/OIL systems
247 //Either rv og rvw should be zero
248 //assert(rv == 0.0 || rvw == 0.0);
249 //const Evaluation xBrine = convertRvwToXgW_(max(rvw,rv),regionIdx);
250 //const auto rho = 1.0/(xBrine/rhoH2O + (1.0 - xBrine)/rhoCo2);
251 return rhoCo2 / (gasReferenceDensity_[regionIdx] +
252 max(rvw,rv) * brineReferenceDensity_[regionIdx]);
253 }
254
258 template <class FluidState, class LhsEval = typename FluidState::Scalar>
259 std::pair<LhsEval, LhsEval>
260 inverseFormationVolumeFactorAndViscosity(const FluidState& fluidState, unsigned regionIdx)
261 {
262 const LhsEval& T = decay<LhsEval>(fluidState.temperature(FluidState::gasPhaseIdx));
263 const LhsEval& p = decay<LhsEval>(fluidState.pressure(FluidState::gasPhaseIdx));
264 const LhsEval& Rv = decay<LhsEval>(fluidState.Rv());
265 const LhsEval& Rvw = decay<LhsEval>(fluidState.Rvw());
266 return { this->inverseFormationVolumeFactor(regionIdx, T, p, Rv, Rvw),
267 this->viscosity(regionIdx, T, p, Rv, Rvw) };
268 }
269
273 template <class Evaluation>
274 OPM_HOST_DEVICE Evaluation saturatedInverseFormationVolumeFactor(unsigned regionIdx,
275 const Evaluation& temperature,
276 const Evaluation& pressure) const
277 {
278 OPM_TIMEFUNCTION_LOCAL(Subsystem::PvtProps);
279 const Evaluation rvw = rvwSat_(regionIdx, temperature, pressure,
280 Evaluation(salinity_[regionIdx]));
281 return inverseFormationVolumeFactor(regionIdx, temperature,
282 pressure, Evaluation(0.0), rvw);
283 }
284
292 template <class Evaluation>
293 OPM_HOST_DEVICE Evaluation saturationPressure(unsigned /*regionIdx*/,
294 const Evaluation& /*temperature*/,
295 const Evaluation& /*Rvw*/) const
296 { return 0.0; /* not implemented */ }
297
301 template <class Evaluation>
302 OPM_HOST_DEVICE Evaluation saturatedWaterVaporizationFactor(unsigned regionIdx,
303 const Evaluation& temperature,
304 const Evaluation& pressure) const
305 { return rvwSat_(regionIdx, temperature, pressure, Evaluation(salinity_[regionIdx])); }
306
310 template <class Evaluation = Scalar>
311 OPM_HOST_DEVICE Evaluation saturatedWaterVaporizationFactor(unsigned regionIdx,
312 const Evaluation& temperature,
313 const Evaluation& pressure,
314 const Evaluation& saltConcentration) const
315 {
316 OPM_TIMEFUNCTION_LOCAL(Subsystem::PvtProps);
317 const Evaluation salinity = salinityFromConcentration(temperature, pressure,
318 saltConcentration);
319 return rvwSat_(regionIdx, temperature, pressure, salinity);
320 }
321
325 template <class Evaluation>
326 OPM_HOST_DEVICE Evaluation saturatedOilVaporizationFactor(unsigned regionIdx,
327 const Evaluation& temperature,
328 const Evaluation& pressure,
329 const Evaluation& /*oilSaturation*/,
330 const Evaluation& /*maxOilSaturation*/) const
331 { return rvwSat_(regionIdx, temperature, pressure, Evaluation(salinity_[regionIdx])); }
332
336 template <class Evaluation>
337 OPM_HOST_DEVICE Evaluation saturatedOilVaporizationFactor(unsigned regionIdx,
338 const Evaluation& temperature,
339 const Evaluation& pressure) const
340 { return rvwSat_(regionIdx, temperature, pressure, Evaluation(salinity_[regionIdx])); }
341
342 template <class Evaluation>
343 OPM_HOST_DEVICE Evaluation diffusionCoefficient(const Evaluation& temperature,
344 const Evaluation& pressure,
345 unsigned /*compIdx*/) const
346 {
347 return BinaryCoeffBrineCO2::gasDiffCoeff(co2Tables, temperature, pressure, extrapolate);
348 }
349
350 OPM_HOST_DEVICE Scalar gasReferenceDensity(unsigned regionIdx) const
351 {
352 return gasReferenceDensity_[regionIdx];
353 }
354
355 OPM_HOST_DEVICE Scalar oilReferenceDensity(unsigned regionIdx) const
356 { return brineReferenceDensity_[regionIdx]; }
357
358 OPM_HOST_DEVICE Scalar waterReferenceDensity(unsigned regionIdx) const
359 { return brineReferenceDensity_[regionIdx]; }
360
361 OPM_HOST_DEVICE Scalar salinity(unsigned regionIdx) const
362 { return salinity_[regionIdx]; }
363
364 void setEzrokhiDenCoeff(const std::vector<EzrokhiTable>& denaqa);
365
366 // new get functions that will be needed to move a cpu based Co2GasPvt object to the GPU
367 OPM_HOST_DEVICE const ContainerT& getBrineReferenceDensity() const
368 { return brineReferenceDensity_; }
369
370 OPM_HOST_DEVICE const ContainerT& getGasReferenceDensity() const
371 { return gasReferenceDensity_; }
372
373 OPM_HOST_DEVICE const ContainerT& getSalinity() const
374 { return salinity_; }
375
376 OPM_HOST_DEVICE bool getEnableEzrokhiDensity() const
377 { return enableEzrokhiDensity_; }
378
379 OPM_HOST_DEVICE bool getEnableVaporization() const
380 { return enableVaporization_; }
381
382 OPM_HOST_DEVICE int getActivityModel() const
383 { return activityModel_; }
384
385 OPM_HOST_DEVICE Co2StoreConfig::GasMixingType getGasType() const
386 { return gastype_; }
387
388 OPM_HOST_DEVICE const Params& getParams() const
389 { return co2Tables; }
390
391private:
392 template <class LhsEval>
393 LhsEval ezrokhiExponent_(const LhsEval& temperature,
394 const ContainerT& ezrokhiCoeff) const
395 {
396 const LhsEval& tempC = temperature - 273.15;
397 return ezrokhiCoeff[0] + tempC * (ezrokhiCoeff[1] + ezrokhiCoeff[2] * tempC);
398 }
399
400 template <class LhsEval>
401 OPM_HOST_DEVICE LhsEval rvwSat_(unsigned regionIdx,
402 const LhsEval& temperature,
403 const LhsEval& pressure,
404 const LhsEval& salinity) const
405 {
406 OPM_TIMEFUNCTION_LOCAL(Subsystem::PvtProps);
407 if (!enableVaporization_) {
408 return 0.0;
409 }
410
411 // calulate the equilibrium composition for the given
412 // temperature and pressure.
413 LhsEval xgH2O;
414 LhsEval xlCO2;
416 temperature,
417 pressure,
418 salinity,
419 /*knownPhaseIdx=*/-1,
420 xlCO2,
421 xgH2O,
422 activityModel_,
423 extrapolate);
424
425 // normalize the phase compositions
426 xgH2O = max(0.0, min(1.0, xgH2O));
427
428 return convertXgWToRvw(convertxgWToXgW(xgH2O, salinity), regionIdx);
429 }
430
435 template <class LhsEval>
436 OPM_HOST_DEVICE LhsEval convertXgWToRvw(const LhsEval& XgW, unsigned regionIdx) const
437 {
438 OPM_TIMEFUNCTION_LOCAL(Subsystem::PvtProps);
439 Scalar rho_wRef = brineReferenceDensity_[regionIdx];
440 Scalar rho_gRef = gasReferenceDensity_[regionIdx];
441
442 return XgW / (1.0 - XgW) * (rho_gRef / rho_wRef);
443 }
444
449 template <class LhsEval>
450 OPM_HOST_DEVICE LhsEval convertRvwToXgW_(const LhsEval& Rvw, unsigned regionIdx) const
451 {
452 OPM_TIMEFUNCTION_LOCAL(Subsystem::PvtProps);
453 Scalar rho_wRef = brineReferenceDensity_[regionIdx];
454 Scalar rho_gRef = gasReferenceDensity_[regionIdx];
455
456 const LhsEval& rho_wG = Rvw * rho_wRef;
457 return rho_wG / (rho_gRef + rho_wG);
458 }
462 template <class LhsEval>
463 OPM_HOST_DEVICE LhsEval convertxgWToXgW(const LhsEval& xgW, const LhsEval& salinity) const
464 {
465 OPM_TIMEFUNCTION_LOCAL(Subsystem::PvtProps);
466 Scalar M_CO2 = CO2::molarMass();
467 LhsEval M_Brine = Brine::molarMass(salinity);
468
469 return xgW * M_Brine / (xgW * (M_Brine - M_CO2) + M_CO2);
470 }
471
472 #if HAVE_CUDA
473 template <class ScalarT>
474 friend Co2GasPvt<ScalarT, gpuistl::GpuView>
475 gpuistl::make_view(Co2GasPvt<ScalarT, gpuistl::GpuBuffer>&);
476 #endif // HAVE_CUDA
477
478 template <class LhsEval>
479 OPM_HOST_DEVICE const LhsEval salinityFromConcentration(const LhsEval&T, const LhsEval& P,
480 const LhsEval& saltConcentration) const
481 { return saltConcentration/H2O::liquidDensity(T, P, true); }
482
483 ContainerT brineReferenceDensity_{};
484 ContainerT gasReferenceDensity_{};
485 ContainerT salinity_{};
486 ContainerT ezrokhiDenNaClCoeff_{};
487 bool enableEzrokhiDensity_ = false;
488 bool enableVaporization_ = true;
489 int activityModel_{};
490 Co2StoreConfig::GasMixingType gastype_{};
491 Params co2Tables;
492};
493
494} // namespace Opm
495
496#if HAVE_CUDA
497namespace Opm::gpuistl {
498 template<class ScalarT>
499 Co2GasPvt<ScalarT, GpuBuffer>
500 copy_to_gpu(const Co2GasPvt<ScalarT>& cpuCo2)
501 {
502 return Co2GasPvt<ScalarT, GpuBuffer>(
503 copy_to_gpu(cpuCo2.getParams()),
504 GpuBuffer<ScalarT>(cpuCo2.getBrineReferenceDensity()),
505 GpuBuffer<ScalarT>(cpuCo2.getGasReferenceDensity()),
506 GpuBuffer<ScalarT>(cpuCo2.getSalinity()),
507 cpuCo2.getEnableEzrokhiDensity(),
508 cpuCo2.getEnableVaporization(),
509 cpuCo2.getActivityModel(),
510 cpuCo2.getGasType());
511 }
512
513 template <class ScalarT>
514 Co2GasPvt<ScalarT, GpuView>
515 make_view(Co2GasPvt<ScalarT, GpuBuffer>& co2GasPvt)
516 {
517 using ContainedType = ScalarT;
518
519 auto newBrineReferenceDensity = make_view<ContainedType>(co2GasPvt.brineReferenceDensity_);
520 auto newGasReferenceDensity = make_view<ContainedType>(co2GasPvt.gasReferenceDensity_);
521 auto newSalinity = make_view<ContainedType>(co2GasPvt.salinity_);
522
523 return Co2GasPvt<ScalarT, GpuView>(
524 make_view(co2GasPvt.co2Tables),
525 newBrineReferenceDensity,
526 newGasReferenceDensity,
527 newSalinity,
528 co2GasPvt.getEnableEzrokhiDensity(),
529 co2GasPvt.getEnableVaporization(),
530 co2GasPvt.getActivityModel(),
531 co2GasPvt.getGasType());
532 }
533} // namespace Opm::gpuistl
534#endif // HAVE_CUDA
535
536#endif
A class for the brine fluid properties.
Binary coefficients for brine and CO2.
A class for the CO2 fluid properties.
PiecewiseLinearTwoPhaseMaterialParams< TraitsT, GPUContainerType > copy_to_gpu(const PiecewiseLinearTwoPhaseMaterialParams< TraitsT > &params)
Move a PiecewiseLinearTwoPhaseMaterialParams-object to the GPU.
Definition PiecewiseLinearTwoPhaseMaterialParams.hpp:285
PiecewiseLinearTwoPhaseMaterialParams< TraitsT, ViewType > make_view(PiecewiseLinearTwoPhaseMaterialParams< TraitsT, ContainerType > &params)
this function is intented to make a GPU friendly view of the PiecewiseLinearTwoPhaseMaterialParams
Definition PiecewiseLinearTwoPhaseMaterialParams.hpp:312
A simple version of pure water with density from Hu et al.
Implements a scalar function that depends on two variables and which is sampled on an uniform X-Y gri...
Binary coefficients for brine and CO2.
Definition Brine_CO2.hpp:46
static OPM_HOST_DEVICE void calculateMoleFractions(const CO2Params &params, const Evaluation &temperature, const Evaluation &pg, const Evaluation &salinity, const int knownPhaseIdx, Evaluation &xlCO2, Evaluation &ygH2O, const int &activityModel, bool extrapolate=false)
Returns the mol (!) fraction of CO2 in the liquid phase and the mol_ (!) fraction of H2O in the gas p...
Definition Brine_CO2.hpp:111
static OPM_HOST_DEVICE Evaluation gasDiffCoeff(const CO2Params &params, const Evaluation &temperature, const Evaluation &pressure, bool extrapolate=false)
Binary diffusion coefficent [m^2/s] of water in the CO2 phase.
Definition Brine_CO2.hpp:63
A class for the brine fluid properties.
Definition BrineDynamic.hpp:49
Definition CO2Tables.hpp:63
A class for the CO2 fluid properties.
Definition CO2.hpp:58
static OPM_HOST_DEVICE Evaluation gasDensity(const Params &params, const Evaluation &temperature, const Evaluation &pressure, bool extrapolate=false)
Definition CO2.hpp:222
static OPM_HOST_DEVICE Scalar molarMass()
Definition CO2.hpp:73
static OPM_HOST_DEVICE Evaluation gasInternalEnergy(const Params &params, const Evaluation &temperature, const Evaluation &pressure, bool extrapolate=false)
Definition CO2.hpp:195
static OPM_HOST_DEVICE Evaluation gasViscosity(const Params &params, Evaluation temperature, const Evaluation &pressure, bool extrapolate=false)
Definition CO2.hpp:249
This class represents the Pressure-Volume-Temperature relations of the gas phase for CO2.
Definition Co2GasPvt.hpp:75
OPM_HOST_DEVICE Evaluation internalEnergy(unsigned regionIdx, const Evaluation &temperature, const Evaluation &pressure, const Evaluation &rv, const Evaluation &rvw) const
Returns the specific enthalpy [J/kg] of gas given a set of parameters.
Definition Co2GasPvt.hpp:178
OPM_HOST_DEVICE Evaluation inverseFormationVolumeFactor(unsigned regionIdx, const Evaluation &temperature, const Evaluation &pressure, const Evaluation &rv, const Evaluation &rvw) const
Returns the formation volume factor [-] of the fluid phase.
Definition Co2GasPvt.hpp:231
OPM_HOST_DEVICE Evaluation saturatedWaterVaporizationFactor(unsigned regionIdx, const Evaluation &temperature, const Evaluation &pressure, const Evaluation &saltConcentration) const
Returns the water vaporization factor [m^3/m^3] of water phase.
Definition Co2GasPvt.hpp:311
OPM_HOST_DEVICE Evaluation viscosity(unsigned regionIdx, const Evaluation &temperature, const Evaluation &pressure, const Evaluation &, const Evaluation &) const
Returns the dynamic viscosity [Pa s] of the fluid phase given a set of parameters.
Definition Co2GasPvt.hpp:207
OPM_HOST_DEVICE unsigned numRegions() const
Return the number of PVT regions which are considered by this PVT-object.
Definition Co2GasPvt.hpp:168
OPM_HOST_DEVICE void setEnableVaporizationWater(bool yesno)
Specify whether the PVT model should consider that the water component can vaporize in the gas phase.
Definition Co2GasPvt.hpp:145
OPM_HOST_DEVICE void initEnd()
Finish initializing the co2 phase PVT properties.
Definition Co2GasPvt.hpp:161
OPM_HOST_DEVICE Evaluation saturatedViscosity(unsigned, const Evaluation &temperature, const Evaluation &pressure) const
Returns the dynamic viscosity [Pa s] of fluid phase at saturated conditions.
Definition Co2GasPvt.hpp:218
OPM_HOST_DEVICE Evaluation saturationPressure(unsigned, const Evaluation &, const Evaluation &) const
Returns the saturation pressure of the gas phase [Pa] depending on its mass fraction of the brine com...
Definition Co2GasPvt.hpp:293
std::pair< LhsEval, LhsEval > inverseFormationVolumeFactorAndViscosity(const FluidState &fluidState, unsigned regionIdx)
Returns the formation volume factor [-] and viscosity [Pa s] of the fluid phase.
Definition Co2GasPvt.hpp:260
OPM_HOST_DEVICE void setThermalMixingModel(int thermalMixingModel)
Set thermal mixing model for co2 in brine.
Definition Co2GasPvt.cpp:152
OPM_HOST_DEVICE void setReferenceDensities(unsigned regionIdx, Scalar rhoRefBrine, Scalar rhoRefGas, Scalar)
Initialize the reference densities of all fluids for a given PVT region.
Definition Co2GasPvt.cpp:124
OPM_HOST_DEVICE void setActivityModelSalt(int activityModel)
Set activity coefficient model for salt in solubility model.
Definition Co2GasPvt.cpp:135
OPM_HOST_DEVICE Evaluation saturatedOilVaporizationFactor(unsigned regionIdx, const Evaluation &temperature, const Evaluation &pressure, const Evaluation &, const Evaluation &) const
Returns the oil vaporization factor [m^3/m^3] of the oil phase.
Definition Co2GasPvt.hpp:326
OPM_HOST_DEVICE Evaluation saturatedWaterVaporizationFactor(unsigned regionIdx, const Evaluation &temperature, const Evaluation &pressure) const
Returns the water vaporization factor [m^3/m^3] of the water phase.
Definition Co2GasPvt.hpp:302
OPM_HOST_DEVICE Evaluation saturatedInverseFormationVolumeFactor(unsigned regionIdx, const Evaluation &temperature, const Evaluation &pressure) const
Returns the formation volume factor [-] of water saturated gas at given pressure.
Definition Co2GasPvt.hpp:274
OPM_HOST_DEVICE Evaluation saturatedOilVaporizationFactor(unsigned regionIdx, const Evaluation &temperature, const Evaluation &pressure) const
Returns the oil vaporization factor [m^3/m^3] of the oil phase.
Definition Co2GasPvt.hpp:337
BinaryCoeff::Brine_CO2< Scalar, H2O, CO2 > BinaryCoeffBrineCO2
The binary coefficients for brine and CO2 used by this fluid system.
Definition Co2GasPvt.hpp:85
Definition Co2StoreConfig.hpp:33
static Scalar molarMass()
Definition Component.hpp:93
Definition EclipseState.hpp:62
Definition Schedule.hpp:101
A simple version of pure water with density from Hu et al.
Definition SimpleHuDuanH2O.hpp:66
static OPM_HOST_DEVICE Evaluation liquidDensity(const Evaluation &temperature, const Evaluation &pressure, bool extrapolate)
The density of pure water at a given pressure and temperature .
Definition SimpleHuDuanH2O.hpp:316
static OPM_HOST_DEVICE Evaluation gasInternalEnergy(const Evaluation &temperature, const Evaluation &pressure)
Specific internal energy of steam .
Definition SimpleHuDuanH2O.hpp:228
Convience header to include the gpuistl headers if HAVE_CUDA is defined.
This class implements a small container which holds the transmissibility mulitpliers for all the face...
Definition Exceptions.hpp:30
Scalar Brine< Scalar, H2O >::salinity
Default value for the salinity of the brine (dimensionless).
Definition Brine.hpp:391