12 #define _CRTDBG_MAP_ALLOC
13 #define _CRT_SECURE_NO_WARNINGS
14 #define _USE_MATH_DEFINES
31 static const double n[]={
56 static const double d[]={
81 static const double t[]={
106 static const double c[]={
131 static const double a0[]={
139 static const double t0[]={
156 params.molemass = 102.032;
159 params.accentricfactor = 0.32684;
182 EOSReference.assign(
"\"A International Standard Formulation for the Thermodynamic Properties of 1,1,1,2-Tetrafluoroethane"
183 "(HFC-134a) for Temperatures from 170 K to 455 K and Pressures up to 70 MPa\""
184 "by Reiner Tillner-Roth and Hans Dieter Baehr, J. Phys. Chem. Ref. Data, v. 23, 1994, pp 657-729");
185 TransportReference.assign(
"Viscosity: Marcia L. Huber, Arno Laesecke, and Richard A. Perkins, "
186 "\"Model for the Viscosity and Thermal Conductivity of Refrigerants,"
187 "Including a New Correlation for the Viscosity of R134a\"A Reference "
188 "Ind. Eng. Chem. Res. 2003, 42, 3163-3178\n\n"
189 "Conductivity: McLinden, M.O., and S.A. Klein and R.A. Perkins, \"An extended corresponding states model for the thermal conductivity of refrigerants and refrigerant mixtures\", International Journal of Refrigeration, 23 (2000) 43-63.\nSeveral typos: Table A1- a1 should be 8.00892e-5, R0 should be 1.03 . Eqn A5 - chi*(Tref,rho) should be multiplied by Tref/T. Eqn A4 - epsilon should be eta (viscosity)\n\n"
190 "Surface Tension: Mulero, JPCRD, 2012");
192 name.assign(
"R134a");
204 double a0=-1.05248e-2,
206 double lambda = (a0+a1*T);
215 lambda_reducing=2.055e-3;
216 double delta = rho/(5.049886*
params.molemass);
217 double lambda_r = lambda_reducing*(b1*delta+b2*pow(delta,2)+b3*pow(delta,3)+b4*pow(delta,4));
231 *e_k = 299.363; *sigma = 0.468932;
235 double eta_star, a[]={0.355404,-0.464337,0.257353e-1};
236 double e_k = 299.363, sigma = 0.468932, theta_star, Tstar;
238 theta_star = exp(a[0]*pow(log(Tstar),0)+a[1]*pow(log(Tstar),1)+a[2]*pow(log(Tstar),2));
239 eta_star = 0.021357*sqrt(
params.molemass*T)/(pow(sigma,2)*theta_star)/1e6;
244 double sum=0,delta_0,DELTA_H_eta,B_eta_star,B_eta,N_A=6.02214129e23,tau,delta;
245 double e_k = 299.363 , sigma = 0.468932, Tstar, eta_r;
246 double b[]={-19.572881,219.73999,-1015.3226,2471.0125,-3375.1717,2491.6597,-787.26086,14.085455,-0.34664158};
247 double t[]={0,-0.25,-0.50,-0.75,-1.00,-1.25,-1.50,-2.50,-5.50};
271 for (
unsigned int i=0;i<=8;i++){
272 sum += b[i]*pow(Tstar,t[i]);
275 B_eta = N_A*pow(sigma/1e9,3)*B_eta_star;
277 delta_0=c[10]/(1+c[8]*tau+c[9]*pow(tau,2));
278 DELTA_H_eta = c[1]*delta + (c[2]/pow(tau,6)+c[3]/pow(tau,2)+c[4]/sqrt(tau)+c[5]*pow(tau,2))*pow(delta,2)
279 +c[6]*pow(delta,3)+c[7]/(delta_0-delta)-c[7]/delta_0;
295 const double ti[]={0,1,1.5,2.3,3.6,5.2,7.3};
296 const double Ni[]={0,-7.6896400207782598, 2.0859760566425463, -2.6755347075503888, 0.3010493765467589, -5.8583601582059233, 3.4788072104059631};
297 double summer=0,theta;
302 summer=summer+Ni[i]*pow(theta,ti[i]);
308 const double ti[]={0,0.30476365788328746, 1.3693916347775943, 1.47181218204009};
309 const double Ni[]={0,1.4547755306897099, -1.8409578717703114, 1.7741041693195705};
310 double summer=0,theta;
315 summer=summer+Ni[i]*pow(theta,ti[i]);
321 const double ti[]={0,0.36671869805172808, 0.90909437225529799, 3.8975848316804713};
322 const double Ni[]={0,-2.5530620653554106, -3.260103853948312, -5.5500764019235618};
323 double summer=0,theta;
328 summer=summer+Ni[i]*pow(theta,ti[i]);
334 return 0.05801*pow(1-T/
crit.
T,1.241);
double viscosity_Trho(double, double)
std::vector< phi_BC * > phirlist
double surface_tension_T(double T)
struct FluidLimits limits
std::string name
A container to hold the cache for residual Helmholtz derivatives.
std::string TransportReference
A std::string that contains a reference for thermo properties for the fluid.
double conductivity_background(double T, double rho)
double conductivity_critical(double T, double rho, double qd=2e9, double GAMMA=0.0496, double zeta0=1.94e-10)
std::vector< std::string > aliases
The REFPROP-compliant name if REFPROP-"name" is not a compatible fluid name. If not included...
struct CriticalStruct reduce
A pointer to the point that is used to reduce the T and rho for EOS.
struct CriticalStruct * preduce
std::string EOSReference
The critical qd parameter for the Olchowy-Sengers cross-over term.
std::string ECS_LENNARD_JONES
std::string SURFACE_TENSION
struct CriticalStruct crit
double viscosity_residual(double T, double rho)
double viscosity_background(double T, double rho)
BibTeXKeysStruct BibTeXKeys
double viscosity_dilute(double T)
std::vector< phi_BC * > phi0list
A vector of instances of the phi_BC classes for the residual Helmholtz energy contribution.
double conductivity_Trho(double, double)
void ECSParams(double *e_k, double *sigma)
double conductivity_residual(double T, double rho)
double conductivity_dilute(double T)