Note that Vegetation_Env::getPenMonET() is an identical copy.
This function has hard-coded physical constants (heat capacity of dry air, air density, etc) that should be extracted to the constants header file. It also needs an explanatory Doxygen comment, some cleanup of the existing comments (formatting and spelling), and possibly a rename to something clearer.
Explanatory comment:
New name:
penman, monteith
Typos:
raiative
convectie
Formatting:
Random spacing choices
Constants:
CP =1004.64 ; // specific heat capacity of dry air [J/kgK)
in header, SHCAIR
pa = 101300;// pressure , Pa
in header, Pstd, but 101325
rho = 1.292- (0.00428 * ta); // air density kg/m3
Constants?
EPS=0.6219; // ratio of mole weights
Also defined in Vegetation_Env.cpp
SBC= 5.67e-8; //Stefan-boltzmann constant W/m2K4
in header, STFBOLTZ
rr = rho CP /(4.0 SBC tk tk*tk);
What is 4?
lhvap = 2.5023e6 -2430.54 *ta; (latent heat of vaporization)
Constants?
Header has LHVAP, 2.501e6
pvs1 = 610.7 exp(17.38 t1/(239.+t1)); (saturated vapor pressure at t1)
Note that Vegetation_Env::getPenMonET() is an identical copy.
This function has hard-coded physical constants (heat capacity of dry air, air density, etc) that should be extracted to the constants header file. It also needs an explanatory Doxygen comment, some cleanup of the existing comments (formatting and spelling), and possibly a rename to something clearer.
Explanatory comment:
New name: penman, monteith
Typos: raiative convectie
Formatting: Random spacing choices
Constants: