3.1-git
DUNE for Multi-{Phase, Component, Scale, Physics, ...} flow and transport in porous media
pengrobinsonparams.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 * See the file COPYING for full copying permissions. *
5 * *
6 * This program 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 * This program 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 this program. If not, see <http://www.gnu.org/licenses/>. *
18 *****************************************************************************/
29#ifndef DUMUX_PENG_ROBINSON_PARAMS_HH
30#define DUMUX_PENG_ROBINSON_PARAMS_HH
31
33
34namespace Dumux {
35
44template <class Scalar>
46{
47public:
52 Scalar a() const
53 { return a_; }
54
55
60 Scalar b() const
61 { return b_; }
62
67 void checkDefined() const
68 {
69#ifndef NDEBUG
72#endif
73 };
74
80 void setA(Scalar value)
81 { a_ = value; }
82
88 void setB(Scalar value)
89 { b_ = value; }
90
91protected:
92 Scalar a_;
93 Scalar b_;
94};
95
96} // end namespace
97
98#endif
Some templates to wrap the valgrind macros.
bool CheckDefined(const T &value)
Make valgrind complain if the object occupied by an object is undefined.
Definition: valgrind.hh:72
make the local view function available whenever we use the grid geometry
Definition: adapt.hh:29
Stores and provides access to the Peng-Robinson parameters.
Definition: pengrobinsonparams.hh:46
Scalar a_
Definition: pengrobinsonparams.hh:92
void checkDefined() const
If run under valgrind, this method produces an warning if the parameters where not determined correct...
Definition: pengrobinsonparams.hh:67
Scalar b_
Definition: pengrobinsonparams.hh:93
void setA(Scalar value)
Set the attractive parameter 'a' of the Peng-Robinson fluid.
Definition: pengrobinsonparams.hh:80
Scalar a() const
Returns the attractive parameter 'a' of the Peng-Robinson fluid.
Definition: pengrobinsonparams.hh:52
void setB(Scalar value)
Set the repulsive parameter 'b' of the Peng-Robinson fluid.
Definition: pengrobinsonparams.hh:88
Scalar b() const
Returns the repulsive parameter 'b' of the Peng-Robinson fluid.
Definition: pengrobinsonparams.hh:60