CoolProp  4.2.5
An open-source fluid property and humid air property database
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Helium.cpp
Go to the documentation of this file.
1 /* Properties of Helium
2 by Ian Bell
3 
4 Thermo properties from
5 ---------------------
6 Ortiz-Vega, D.O., Hall, K.R., Arp, V.D., and Lemmon, E.W.,
7 Interim equation,
8 to be published in Int. J. Thermophys., 2010.
9 #Using the EOS constants from REFPROP by permission while awaiting Ortiz-Vega publication in JPCRD
10 
11 Transport properties from
12 -------------------------
13 Arp, V.D., McCarty, R.D., and Friend, D.G.,
14 "Thermophysical Properties of Helium-4 from 0.8 to 1500 K with
15 Pressures to 2000 MPa,"
16 NIST Technical Note 1334 (revised), 1998.
17 
18 Hands, B.A. and Arp, V.D.,
19 "A Correlation of Thermal Conductivity Data for Helium,"
20 Cryogenics, 21(12):697-703, 1981.
21 
22 */
23 
24 #if defined(_MSC_VER)
25 #define _CRTDBG_MAP_ALLOC
26 #define _CRT_SECURE_NO_WARNINGS
27 #include <stdlib.h>
28 #include <crtdbg.h>
29 // The most important line
30 //#define new new(_NORMAL_BLOCK, __FILE__, __LINE__)
31 #else
32 #include <stdlib.h>
33 #endif
34 
35 #include "math.h"
36 #include "stdio.h"
37 #include <string.h>
38 #include "CoolProp.h"
39 #include <vector>
40 #include <iostream>
41 #include <list>
42 #include "Helmholtz.h"
43 #include "FluidClass.h"
44 #include "Helium.h"
45 
47 {
48  static const double n[]={0,
49  0.009288766, //[1]
50  0.9258069, //[2]
51  -1.718156, //[3]
52  0.7606137, //[4]
53  -1.024864, //[5]
54  0.1052455, //[6]
55  -0.1875722, //[7]
56  -0.1287812, //[8]
57  -0.002227619, //[9]
58  0.1823465, //[10]
59  -0.04450014, //[11]
60  -0.00008729033, //[12]
61  0.0385432, //[13]
62  -0.9585106, //[14]
63  -0.0545401, //[15]
64  -0.0368726, //[16]
65  -0.001021851, //[17]
66  0.06166348, //[18]
67  0.02493437, //[19]
68  -0.008127424, //[20]
69  -0.008233032, //[21]
70  };
71  static const double d[]={0,
72  4, //[1]
73  1, //[2]
74  1, //[3]
75  2, //[4]
76  2, //[5]
77  3, //[6]
78  1, //[7]
79  1, //[8]
80  3, //[9]
81  2, //[10]
82  2, //[11]
83  8, //[12]
84  1, //[13]
85  1, //[14]
86  1, //[15]
87  2, //[16]
88  2, //[17]
89  2, //[18]
90  3, //[19]
91  3, //[20]
92  2, //[21]
93  };
94  static const double t[]={0.00,
95  1, //[1]
96  0.28, //[2]
97  0.735, //[3]
98  0.64, //[4]
99  0.82, //[5]
100  1.16, //[6]
101  1.28, //[7]
102  2, //[8]
103  0.41, //[9]
104  1.33, //[10]
105  4.2, //[11]
106  0.6, //[12]
107  3, //[13]
108  1, //[14]
109  8.2, //[15]
110  1, //[16]
111  2.71, //[17]
112  1, //[18]
113  1, //[19]
114  2, //[20]
115  1, //[21]
116  };
117  static const double cv[]={0,
118  0, //[1]
119  0, //[2]
120  0, //[3]
121  0, //[4]
122  0, //[5]
123  0, //[6]
124  1, //[7]
125  2, //[8]
126  2, //[9]
127  1, //[10]
128  2, //[11]
129  1, //[12]
130  2, //[13]
131  2, //[14]
132  2, //[15]
133  2, //[16]
134  2, //[17]
135  2, //[18]
136  2, //[19]
137  2, //[20]
138  2, //[21]
139  };
140  // alpha is used here for consistency with the definitions in R744.c upon which Helium.c is based
141  static const double alpha[]={
142  0,0,0,0,0,0,0,0,0,0,0,0,0, // indices [0-12]
143  1.0833, //[13]
144  18.3824, //[14]
145  5.0573, //[15]
146  0.2832, //[16]
147  6.0582, //[17]
148  0.2444, //[18]
149  0.0539, //[19]
150  0.185, //[20]
151  0.5941, //[21]
152  };
153  static const double beta[]={
154  0,0,0,0,0,0,0,0,0,0,0,0,0, // indices [0-12]
155  0.0385, //[13]
156  19.8246, //[14]
157  9.3799, //[15]
158  0.8073, //[16]
159  0.031, //[17]
160  0.0061, //[18]
161  0.3581, //[19]
162  0.7518, //[20]
163  7.4629, //[21]
164  };
165  static const double GAMMA[]={
166  0,0,0,0,0,0,0,0,0,0,0,0,0, // indices [0-12]
167  1.9776, //[13]
168  1.6178, //[14]
169  0.4371, //[15]
170  0.5355, //[16]
171  0.7777, //[17]
172  0.4832, //[18]
173  0.8162, //[19]
174  1.2896, //[20]
175  0.3577, //[21]
176  };
177  static const double epsilon[]={
178  0,0,0,0,0,0,0,0,0,0,0,0,0, // indices [0-12]
179  0.6914, //[13]
180  0.859, //[14]
181  0.8787, //[15]
182  2.7182, //[16]
183  2.0301, //[17]
184  0.89, //[18]
185  1.179, //[19]
186  0.568, //[20]
187  1.6412, //[21]
188  };
189 
190  phirlist.push_back(new phir_power(n,d,t,cv,1,12,13));
191  phirlist.push_back(new phir_gaussian(n,d,t,alpha,epsilon,beta,GAMMA,13,21,22));
192 
193  // Critical parameters
194  crit.rho = 4.002602 * 18.13;
195  crit.p = PressureUnit(227.6, UNIT_KPA);
196  crit.T = 5.1953;
197  crit.v = 1.0/crit.rho;
198 
199  // Other fluid parameters
200  params.molemass = 4.002602;
201  params.Ttriple = 2.1768;
202  params.ptriple = 5.05513477113;
203  params.accentricfactor = -0.385 ;
204  params.R_u = 8.314472;
205 
206  double T0 = 4.222,
207  rho0 = 124.95883288439697,
208  m,
209  c,
210  tau0 = crit.T/T0,
211  delta0 = rho0/crit.rho;
212 
213  // log(delta)+c+m*tau
214 
222  m = 1.7038767900158605-1.5/tau0;
223 
230  c = 1.6384427034133615 - log(delta0)-m*tau0-1.5*log(tau0);
231 
232  phi_BC * phi0_lead_ = new phi0_lead(c,m);
233  phi_BC * phi0_logtau_ = new phi0_logtau(1.5);
234 
235  phi0list.push_back(phi0_lead_);
236  phi0list.push_back(phi0_logtau_);
237 
238  // Limits of EOS
239  limits.Tmin = 2.1768;
240  limits.Tmax = 2000.0;
241  limits.pmax = 1000000.0;
242  limits.rhomax = 141.22*params.molemass;
243 
244  EOSReference.assign("Ortiz-Vega, D.O., Hall, K.R., Arp, V.D., and Lemmon, E.W.,"
245  "Interim equation to be published in Int. J. Thermophys., 2010."
246  "\n\nNote: Using the EOS constants from REFPROP by permission while awaiting Ortiz-Vega publication in JPCRD");
247 
248  TransportReference.assign("Viscosity: Arp, V.D., McCarty, R.D., and Friend, D.G., "
249  "\"Thermophysical Properties of Helium-4 from 0.8 to 1500 K with Pressures to 2000 MPa\", "
250  "NIST Technical Note 1334 (revised), 1998.\n\n"
251  "Thermal Conductivity: Hands, B.A. and Arp, V.D., "
252  "\"A Correlation of Thermal Conductivity Data for Helium,\" "
253  "Cryogenics, 21(12):697-703, 1981. \n\n"
254  "Warning: Critical enhancement of conductivity not included");
255 
256  name.assign("Helium");
257  aliases.push_back("helium");
258  aliases.push_back("HELIUM");
259  aliases.push_back("He");
260 
261  BibTeXKeys.EOS = "OrtizVega-2010";
262  BibTeXKeys.VISCOSITY = "ARP-NIST-1998";
263  BibTeXKeys.CONDUCTIVITY = "Hands-CRYO-1981";
264  BibTeXKeys.SURFACE_TENSION = "Mulero-JPCRD-2012";
265 }
266 
267 double HeliumClass::viscosity_Trho(double T, double rho)
268 {
269  double eta_0,eta_0_slash, eta_E_slash, B,C,D,ln_eta,x;
270  //
271  // Arp, V.D., McCarty, R.D., and Friend, D.G.,
272  // "Thermophysical Properties of Helium-4 from 0.8 to 1500 K with Pressures to 2000 MPa",
273  // NIST Technical Note 1334 (revised), 1998.
274  //
275  // Using Arp NIST report
276  // Report is not clear on viscosity, referring to REFPROP source code for clarity
277 
278  // Density in g/cm^3; kg/m^3 --> g/cm^3, divide by 1000
279  // Yields viscosity in micro g/(cm-s); to get Pa-s, divide by 10 to get micro Pa-s, then another 1e6 to get Pa-s
280 
281  rho /= 1000.0;
282  if (T <= 300){
283  x = log(T);
284  }
285  else{
286  x = log(300.0);
287  }
288  // Evaluate the terms B,C,D
289  B = -47.5295259/x+87.6799309-42.0741589*x+8.33128289*x*x-0.589252385*x*x*x;
290  C = 547.309267/x-904.870586+431.404928*x-81.4504854*x*x+5.37008433*x*x*x;
291  D = -1684.39324/x+3331.08630-1632.19172*x+308.804413*x*x-20.2936367*x*x*x;
292  eta_0_slash = -0.135311743/x+1.00347841+1.20654649*x-0.149564551*x*x+0.012520841*x*x*x;
293  eta_E_slash = rho*B+rho*rho*C+rho*rho*rho*D;
294 
295  if (T<=100)
296  {
297  ln_eta = eta_0_slash + eta_E_slash;
298  return exp(ln_eta)/10.0/1e6;
299  }
300  else
301  {
302  ln_eta = eta_0_slash + eta_E_slash;
303  eta_0 = 196*pow(T,0.71938)*exp(12.451/T-295.67/T/T-4.1249);
304  return (exp(ln_eta)+eta_0-exp(eta_0_slash))/10.0/1e6;
305  }
306 }
307 double HeliumClass::conductivity_Trho(double T, double rho)
308 {
309  /*
310  What an incredibly annoying formulation! Implied coefficients?? Not cool.
311  */
312  double rhoc = 68.0, lambda_e, lambda_c;
313  double summer = 3.739232544/T-2.620316969e1/T/T+5.982252246e1/T/T/T-4.926397634e1/T/T/T/T;
314  double lambda_0 = 2.7870034e-3*pow(T,7.034007057e-1)*exp(summer);
315  double c[]={ 1.862970530e-4,
316  -7.275964435e-7,
317  -1.427549651e-4,
318  3.290833592e-5,
319  -5.213335363e-8,
320  4.492659933e-8,
321  -5.924416513e-9,
322  7.087321137e-6,
323  -6.013335678e-6,
324  8.067145814e-7,
325  3.995125013e-7};
326  // Equation 17
327  lambda_e = (c[0]+c[1]*T+c[2]*pow(T,1/3.0)+c[3]*pow(T,2.0/3.0))*rho
328  +(c[4]+c[5]*pow(T,1.0/3.0)+c[6]*pow(T,2.0/3.0))*rho*rho*rho
329  +(c[7]+c[8]*pow(T,1.0/3.0)+c[9]*pow(T,2.0/3.0)+c[10]/T)*rho*rho*log(rho/rhoc);
330 
331  lambda_c = 0.0;
332  return lambda_0+lambda_e+lambda_c;
333 }
334 double HeliumClass::psat(double T)
335 {
336  const double ti[]={0,1.0,1.5,1.85,2.7};
337  const double ai[]={0,-0.399865e+01,0.870145e+00,0.171451e+00, 0.120927e+01};
338  double summer=0;
339  int i;
340  for (i=1;i<=4;i++)
341  {
342  summer=summer+ai[i]*pow(1-T/reduce.T,ti[i]);
343  }
344  return reduce.p.Pa*exp(reduce.T/T*summer);
345 }
346 double HeliumClass::rhosatL(double T)
347 {
348  const double ti[]={0, 1.17, 7.0, 15.0, 20.0};
349  const double ai[]={0, 0.140808e+01, -0.543843e+00, 0.177220e+01, -0.344056e+01};
350  double summer=0;
351  int i;
352  for (i=1;i<=4;i++)
353  {
354  summer += ai[i]*pow(pow(1.0-T/reduce.T,1.0/3.0),ti[i]);
355  }
356  return reduce.rho*(1.0+summer);
357 }
358 double HeliumClass::rhosatV(double T)
359 {
360  const double ti[]={0,0.263, 1.04, 3.25, 8.5};
361  const double ai[]={0,-0.126074e+01, -0.363425e+01, -0.487998e+01, -0.130581e+02};
362  double summer=0;
363  int i;
364  for (i=1;i<=4;i++)
365  {
366  summer=summer+ai[i]*pow(1.0-T/reduce.T,ti[i]);
367  }
368  return reduce.rho*exp(summer);
369 }
371 {
372  // From Mulero, 2012, JPCRD
373  return 0.0004656*pow(1-T/reduce.T,1.04)+0.001889*pow(1-T/reduce.T,2.468)+-0.002006*pow(1-T/reduce.T,2.661);
374 }
std::vector< phi_BC * > phirlist
Definition: FluidClass.h:178
struct FluidLimits limits
Definition: FluidClass.h:219
std::string EOS
Definition: FluidClass.h:120
std::string VISCOSITY
Definition: FluidClass.h:122
PressureUnit p
Definition: FluidClass.h:50
std::string name
A container to hold the cache for residual Helmholtz derivatives.
Definition: FluidClass.h:151
virtual double viscosity_Trho(double, double)
Definition: Helium.cpp:267
std::string TransportReference
A std::string that contains a reference for thermo properties for the fluid.
Definition: FluidClass.h:158
double surface_tension_T(double T)
Definition: Helium.cpp:370
double Pa
Definition: Units.h:22
std::vector< std::string > aliases
The REFPROP-compliant name if REFPROP-"name" is not a compatible fluid name. If not included...
Definition: FluidClass.h:153
struct CriticalStruct reduce
A pointer to the point that is used to reduce the T and rho for EOS.
Definition: FluidClass.h:222
double Tmax
Definition: FluidClass.h:54
std::string EOSReference
The critical qd parameter for the Olchowy-Sengers cross-over term.
Definition: FluidClass.h:157
std::vector< double > x(ncmax, 0)
std::string SURFACE_TENSION
Definition: FluidClass.h:126
HeliumClass()
Definition: Helium.cpp:46
double pmax
Definition: FluidClass.h:54
params
struct CriticalStruct crit
Definition: FluidClass.h:218
double rhosatL(double)
Definition: Helium.cpp:346
BibTeXKeysStruct BibTeXKeys
Definition: FluidClass.h:175
virtual double conductivity_Trho(double, double)
Definition: Helium.cpp:307
std::vector< phi_BC * > phi0list
A vector of instances of the phi_BC classes for the residual Helmholtz energy contribution.
Definition: FluidClass.h:179
This is the abstract base class upon which each residual Helmholtz energy class is built...
Definition: Helmholtz.h:24
double psat(double)
Definition: Helium.cpp:334
double Tmin
Definition: FluidClass.h:54
double rhomax
Definition: FluidClass.h:54
std::string CONDUCTIVITY
Definition: FluidClass.h:123
double rhosatV(double)
Definition: Helium.cpp:358