PvtPropertiesBasic.hpp
Go to the documentation of this file.
1 /*
2  Copyright 2012 SINTEF ICT, Applied Mathematics.
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 3 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 
20 #ifndef OPM_PVTPROPERTIESBASIC_HEADER_INCLUDED
21 #define OPM_PVTPROPERTIESBASIC_HEADER_INCLUDED
22 
25 #include <vector>
26 
27 namespace Opm
28 {
29 
37  {
38  public:
41 
47  void init(const parameter::ParameterGroup& param);
48 
51  void init(const int num_phases,
52  const std::vector<double>& rho,
53  const std::vector<double>& visc);
54 
56  int numPhases() const;
57 
59  PhaseUsage phaseUsage() const;
60 
63  const double* surfaceDensities() const;
64 
66  void mu(const int n,
67  const double* p,
68  const double* T,
69  const double* z,
70  double* output_mu) const;
71 
73  void B(const int n,
74  const double* p,
75  const double* T,
76  const double* z,
77  double* output_B) const;
78 
80  void dBdp(const int n,
81  const double* p,
82  const double* T,
83  const double* z,
84  double* output_B,
85  double* output_dBdp) const;
86 
88  void R(const int n,
89  const double* p,
90  const double* z,
91  double* output_R) const;
92 
94  void dRdp(const int n,
95  const double* p,
96  const double* z,
97  double* output_R,
98  double* output_dRdp) const;
99 
100  private:
101  // The PVT properties. We need to store one value per PVT
102  // region.
103  std::vector<double> density_;
104  std::vector<double> viscosity_;
105  std::vector<double> formation_volume_factor_;
106  };
107 
108 }
109 
110 
111 
112 #endif // OPM_PVTPROPERTIESBASIC_HEADER_INCLUDED
void dRdp(const int n, const double *p, const double *z, double *output_R, double *output_dRdp) const
Solution factor and p-derivative as functions of p and z.
Definition: AnisotropicEikonal.hpp:43
PvtPropertiesBasic()
Default constructor.
Definition: ParameterGroup.hpp:109
void init(const parameter::ParameterGroup &param)
const double * surfaceDensities() const
int numPhases() const
Number of active phases.
PhaseUsage phaseUsage() const
void B(const int n, const double *p, const double *T, const double *z, double *output_B) const
Formation volume factor as a function of p, T and z.
void R(const int n, const double *p, const double *z, double *output_R) const
Solution factor as a function of p and z.
void dBdp(const int n, const double *p, const double *T, const double *z, double *output_B, double *output_dBdp) const
Formation volume factor and p-derivative as functions of p, T and z.
void mu(const int n, const double *p, const double *T, const double *z, double *output_mu) const
Viscosity as a function of p, T and z.
Definition: BlackoilPhases.hpp:36
const double visc
Definition: Units.hpp:152
Definition: PvtPropertiesBasic.hpp:36