OGS
DensityCook.h
Go to the documentation of this file.
1
10#pragma once
11
12#include "Adsorption.h"
13
14namespace Adsorption
15{
16
18{
19public:
20 double getAdsorbateDensity(const double T_Ads) const override;
21 double getAlphaT(const double T_Ads) const override;
22 double characteristicCurve(const double A) const override;
23 double dCharacteristicCurve(const double A) const override;
24};
25
26inline double rhoWaterDean(const double T_Ads)
27{
28 const double Tcel = T_Ads - 273.15;
29 const double b[] = { 999.9,2.03E-02,-6.16E-03,2.26E-05,-4.68E-08 };
30 if (Tcel <= 100.) {
31 return b[0] + Tcel * (b[1] + Tcel * (b[2] + Tcel * (b[3] + Tcel * b[4]) ) );
32 }
33
34 const double rho_100 =
35 b[0] + b[1] * 1.e2 + b[2] * 1.e4 + b[3] * 1.e6 + b[4] * 1.e8;
36 const double aT_100 = -1. / rho_100 * (b[1] + 2. * b[2] * 1.e2 +
37 3. * b[3] * 1.e4 + 4. * b[4] * 1.e6);
38 return rho_100 * (1. - aT_100 * (Tcel - 100.));
39}
40
41inline double alphaTWaterDean(const double T_Ads)
42{
43 const double Tcel = T_Ads - 273.15;
44 const double b[] = { 999.9,2.03E-02,-6.16E-03,2.26E-05,-4.68E-08 };
45 if (Tcel <= 100.) {
46 const double r = b[0] + Tcel * (b[1] + Tcel * (b[2] + Tcel * (b[3] + Tcel * b[4]) ) );
47 return -1.0/r * ( b[1] + Tcel * (2.0*b[2] + Tcel * (3.0*b[3] + Tcel * 4.0*b[4]) ) );
48 }
49
50 const double rho_100 =
51 b[0] + b[1] * 1.e2 + b[2] * 1.e4 + b[3] * 1.e6 + b[4] * 1.e8;
52 const double aT_100 = -1. / rho_100 * (b[1] + 2. * b[2] * 1.e2 +
53 3. * b[3] * 1.e4 + 4. * b[4] * 1.e6);
54 return aT_100 / (1. - aT_100 * (Tcel - 100.));
55}
56
57} // namespace Adsorption
double getAlphaT(const double T_Ads) const override
double dCharacteristicCurve(const double A) const override
double getAdsorbateDensity(const double T_Ads) const override
double characteristicCurve(const double A) const override
double rhoWaterDean(const double T_Ads)
Definition DensityCook.h:26
double alphaTWaterDean(const double T_Ads)
Definition DensityCook.h:41