Helper class for Van-der-Waals equation.
More...
#include <MoleculeDef.h>
Helper class for Van-der-Waals equation.
Definition at line 9 of file MoleculeDef.h.
◆ VanDerWaals()
Heed::VanDerWaals::VanDerWaals |
( |
double |
fPk, |
|
|
double |
fTk |
|
) |
| |
Definition at line 17 of file MoleculeDef.cpp.
17 : Pkh(fPk), Tkh(fTk) {
18
19 const double R = k_Boltzmann * Avogadro;
20
21 Vkh = R * 3.0 / 8.0 * Tkh / Pkh;
22 ah = 3 * Pkh * Vkh * Vkh;
23 bh = 1.0 / 3.0 * Vkh;
24}
◆ ~VanDerWaals()
virtual Heed::VanDerWaals::~VanDerWaals |
( |
| ) |
|
|
inlinevirtual |
◆ a()
double Heed::VanDerWaals::a |
( |
| ) |
const |
|
inline |
◆ b()
double Heed::VanDerWaals::b |
( |
| ) |
const |
|
inline |
◆ copy()
◆ Pk()
double Heed::VanDerWaals::Pk |
( |
| ) |
const |
|
inline |
◆ Tk()
double Heed::VanDerWaals::Tk |
( |
| ) |
const |
|
inline |
◆ Vk()
double Heed::VanDerWaals::Vk |
( |
| ) |
const |
|
inline |
◆ volume_of_mole()
double Heed::VanDerWaals::volume_of_mole |
( |
double |
T, |
|
|
double |
p, |
|
|
int & |
s_not_single |
|
) |
| |
Definition at line 26 of file MoleculeDef.cpp.
26 {
27 mfunname(
"VanDerWaals::volume_of_mole(...)");
28
29 double Tr = T / Tkh;
30 double Pr = p / Pkh;
32 Cubic cb(Pr, -1.0 / 3.0 * (Pr + 8 * Tr), 3, -1);
33 double r[3];
34 int q = cb.find_real_zero(r);
36 double x = r[q - 1];
37 double res = x * Vkh;
39 s_not_single = q == 2 ? 1 : 0;
40 return res;
41}
#define check_econd11(a, signb, stream)
#define Iprint2n(file, name1, name2)
Referenced by Heed::GasDef::GasDef().
The documentation for this class was generated from the following files: