[GRASS-SVN] r32608 - in grass-addons/gipe: i.eb.h_iter i.eb.netrad
svn_grass at osgeo.org
svn_grass at osgeo.org
Thu Aug 7 05:57:53 EDT 2008
Author: ychemin
Date: 2008-08-07 05:57:53 -0400 (Thu, 07 Aug 2008)
New Revision: 32608
Modified:
grass-addons/gipe/i.eb.h_iter/fixed_deltat.c
grass-addons/gipe/i.eb.netrad/r_net.c
Log:
bug fixing
Modified: grass-addons/gipe/i.eb.h_iter/fixed_deltat.c
===================================================================
--- grass-addons/gipe/i.eb.h_iter/fixed_deltat.c 2008-08-07 07:47:31 UTC (rev 32607)
+++ grass-addons/gipe/i.eb.h_iter/fixed_deltat.c 2008-08-07 09:57:53 UTC (rev 32608)
@@ -53,10 +53,10 @@
}
xm = pow(1.0-16.0*((100-disp)/length),0.25);
xh = pow(1.0-16.0*((hu-disp)/length),0.25);
- if((1.0+xm)/2.0==0.0||(1+xm*xm)-2*atan(xm)+0.5*PI==0.0){
- psim = 2.0*log((1.0+xm+0.00001)/2.0)+log((1+xm*xm)-2*atan(xm)+0.5*PI+0.00001);
+ if((1.0+xm)/2.0==0.0||(1+xm*xm)/2.0==0.0){
+ psim = 2.0*log((1.0+xm+0.00001)/2.0)+log((1+xm*xm)/2.0)-2*atan(xm)+0.5*PI+0.00001;
} else {
- psim = 2.0*log((1.0+xm)/2.0)+log((1+xm*xm)-2*atan(xm)+0.5*PI);
+ psim = 2.0*log((1.0+xm)/2.0)+log((1+xm*xm)/2.0)-2*atan(xm)+0.5*PI;
}
if((1.0+xh*xh)/2.0==0.0){
psih = 2.0*log((1.0+xh*xh+0.00001)/2.0);
Modified: grass-addons/gipe/i.eb.netrad/r_net.c
===================================================================
--- grass-addons/gipe/i.eb.netrad/r_net.c 2008-08-07 07:47:31 UTC (rev 32607)
+++ grass-addons/gipe/i.eb.netrad/r_net.c 2008-08-07 09:57:53 UTC (rev 32608)
@@ -20,7 +20,7 @@
// printf("**rnet: bbalb = %5.3f\n\tndvi = %5.3f\n\ttempk = %5.3f\n\te0 = %5.3f\n\ttsw = %5.3f\n\tdoy = %f\n\tutc = %5.3f\n\tsunzangle = %5.3f\n\tdtair = %5.3f\n",bbalb,ndvi,tempk,e0,tsw,doy,utc,sunzangle,dtair);
// Atmospheric emissivity (Bastiaanssen, 1995)
- e_atm = 1.08 * pow(-log(tsw_for_e_atm),0.265) ;
+ e_atm = 1.08 * pow(-log(tsw),0.265) ;
// Atmospheric emissivity (Pawan, 2004)
// e_atm = 0.85 * pow(-log(tsw),0.09);
// printf("rnet: e_atm = %5.3f\n",e_atm);
More information about the grass-commit
mailing list