blackoilproblem.hh
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  Copyright (C) 2014 by Andreas Lauser
5 
6  This file is part of the Open Porous Media project (OPM).
7 
8  OPM is free software: you can redistribute it and/or modify
9  it under the terms of the GNU General Public License as published by
10  the Free Software Foundation, either version 2 of the License, or
11  (at your option) any later version.
12 
13  OPM is distributed in the hope that it will be useful,
14  but WITHOUT ANY WARRANTY; without even the implied warranty of
15  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16  GNU General Public License for more details.
17 
18  You should have received a copy of the GNU General Public License
19  along with OPM. If not, see <http://www.gnu.org/licenses/>.
20 */
26 #ifndef EWOMS_BLACKOIL_PROBLEM_HH
27 #define EWOMS_BLACKOIL_PROBLEM_HH
28 
29 #include "blackoilproperties.hh"
30 
32 
33 namespace Ewoms {
34 
39 template<class TypeTag>
40 class BlackOilProblem : public MultiPhaseBaseProblem<TypeTag>
41 {
42 private:
44  typedef typename GET_PROP_TYPE(TypeTag, Problem) Implementation;
45  typedef typename GET_PROP_TYPE(TypeTag, Scalar) Scalar;
46  typedef typename GET_PROP_TYPE(TypeTag, Simulator) Simulator;
47 
48 public:
55  : ParentType(simulator)
56  {}
57 
61  template <class Context>
62  int pvtRegionIndex(const Context &context, int spaceIdx, int timeIdx) const
63  { return 0; }
64 
68  template <class Context>
69  Scalar rockCompressibility(const Context &context, int spaceIdx, int timeIdx) const
70  { return 0.0; }
71 
75  template <class Context>
76  Scalar rockReferencePressure(const Context &context, int spaceIdx, int timeIdx) const
77  { return 1e5; }
78 
79 private:
81  Implementation &asImp_()
82  { return *static_cast<Implementation *>(this); }
83 
85  const Implementation &asImp_() const
86  { return *static_cast<const Implementation *>(this); }
87 };
88 
89 } // namespace Ewoms
90 
91 #endif
Scalar rockCompressibility(const Context &context, int spaceIdx, int timeIdx) const
Returns the compressibility of the porous medium of a cell.
Definition: blackoilproblem.hh:69
Base class for all problems which use the black-oil model.
Definition: blackoilproblem.hh:40
Simulator & simulator()
Returns Simulator object used by the simulation.
Definition: fvbaseproblem.hh:504
Scalar rockReferencePressure(const Context &context, int spaceIdx, int timeIdx) const
Returns the reference pressure for rock the compressibility of a cell.
Definition: blackoilproblem.hh:76
Declares the properties required by the black oil model.
int pvtRegionIndex(const Context &context, int spaceIdx, int timeIdx) const
Returns the index of the relevant region for thermodynmic properties.
Definition: blackoilproblem.hh:62
Manages the initializing and running of time dependent problems.
Definition: simulator.hh:73
Definition: baseauxiliarymodule.hh:35
The base class for the problems of ECFV discretizations which deal with a multi-phase flow through a ...
BlackOilProblem(Simulator &simulator)
Definition: blackoilproblem.hh:54
The base class for the problems of ECFV discretizations which deal with a multi-phase flow through a ...
Definition: multiphasebaseproblem.hh:55