MiscibilityLiveOil.hpp
Go to the documentation of this file.
1 //===========================================================================
2 //
3 // File: MiscibilityLiveOil.hpp
4 //
5 // Created: Wed Feb 10 09:08:09 2010
6 //
7 // Author: Bjørn Spjelkavik <bsp@sintef.no>
8 //
9 // Revision: $Id$
10 //
11 //===========================================================================
12 /*
13  Copyright 2010 SINTEF ICT, Applied Mathematics.
14 
15  This file is part of the Open Porous Media project (OPM).
16 
17  OPM is free software: you can redistribute it and/or modify
18  it under the terms of the GNU General Public License as published by
19  the Free Software Foundation, either version 3 of the License, or
20  (at your option) any later version.
21 
22  OPM is distributed in the hope that it will be useful,
23  but WITHOUT ANY WARRANTY; without even the implied warranty of
24  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25  GNU General Public License for more details.
26 
27  You should have received a copy of the GNU General Public License
28  along with OPM. If not, see <http://www.gnu.org/licenses/>.
29 */
30 
31 #ifndef SINTEF_MISCIBILITYLIVEOIL_HEADER
32 #define SINTEF_MISCIBILITYLIVEOIL_HEADER
33 
38 #include "MiscibilityProps.hpp"
39 
40 #include <opm/parser/eclipse/EclipseState/EclipseState.hpp>
41 
42 namespace Opm
43 {
45  {
46  public:
47  MiscibilityLiveOil(const PvtoTable& pvtoTable);
48  virtual ~MiscibilityLiveOil();
49 
50  virtual double getViscosity(int region, double press, const surfvol_t& surfvol) const;
51  virtual double R (int region, double press, const surfvol_t& surfvol) const;
52  virtual double dRdp(int region, double press, const surfvol_t& surfvol) const;
53  virtual double B (int region, double press, const surfvol_t& surfvol) const;
54  virtual double dBdp(int region, double press, const surfvol_t& surfvol) const;
55 
56  virtual void getViscosity(const std::vector<PhaseVec>& pressures,
57  const std::vector<CompVec>& surfvol,
58  int phase,
59  std::vector<double>& output) const;
60  virtual void B(const std::vector<PhaseVec>& pressures,
61  const std::vector<CompVec>& surfvol,
62  int phase,
63  std::vector<double>& output) const;
64  virtual void dBdp(const std::vector<PhaseVec>& pressures,
65  const std::vector<CompVec>& surfvol,
66  int phase,
67  std::vector<double>& output_B,
68  std::vector<double>& output_dBdp) const;
69  virtual void R(const std::vector<PhaseVec>& pressures,
70  const std::vector<CompVec>& surfvol,
71  int phase,
72  std::vector<double>& output) const;
73  virtual void dRdp(const std::vector<PhaseVec>& pressures,
74  const std::vector<CompVec>& surfvol,
75  int phase,
76  std::vector<double>& output_R,
77  std::vector<double>& output_dRdp) const;
78 
79  protected:
80  double evalR(double press, const surfvol_t& surfvol) const;
81  void evalRDeriv(double press, const surfvol_t& surfvol, double& R, double& dRdp) const;
82  double evalB(double press, const surfvol_t& surfvol) const;
83  void evalBDeriv(double press, const surfvol_t& surfvol, double& B, double& dBdp) const;
84 
85  // item: 1=B 2=mu;
86  double miscible_oil(double press, const surfvol_t& surfvol, int item,
87  bool deriv = false) const;
88 
89  // PVT properties of live oil (with dissolved gas)
90  std::vector<std::vector<double> > saturated_oil_table_;
91  std::vector<std::vector<std::vector<double> > > undersat_oil_tables_;
92  };
93 
94 }
95 
96 #endif // SINTEF_MISCIBILITYLIVEOIL_HEADER
97 
virtual double B(int region, double press, const surfvol_t &surfvol) const
virtual double R(int region, double press, const surfvol_t &surfvol) const
std::vector< std::vector< double > > saturated_oil_table_
Definition: MiscibilityLiveOil.hpp:90
Definition: BlackoilFluid.hpp:31
void evalRDeriv(double press, const surfvol_t &surfvol, double &R, double &dRdp) const
virtual double dBdp(int region, double press, const surfvol_t &surfvol) const
std::vector< std::vector< std::vector< double > > > undersat_oil_tables_
Definition: MiscibilityLiveOil.hpp:91
Definition: MiscibilityLiveOil.hpp:44
double evalB(double press, const surfvol_t &surfvol) const
CompVec surfvol_t
Definition: MiscibilityProps.hpp:49
virtual double getViscosity(int region, double press, const surfvol_t &surfvol) const
virtual double dRdp(int region, double press, const surfvol_t &surfvol) const
Definition: MiscibilityProps.hpp:46
double evalR(double press, const surfvol_t &surfvol) const
double miscible_oil(double press, const surfvol_t &surfvol, int item, bool deriv=false) const
void evalBDeriv(double press, const surfvol_t &surfvol, double &B, double &dBdp) const
MiscibilityLiveOil(const PvtoTable &pvtoTable)