- Timestamp:
- 12/14/10 11:26:45 (13 years ago)
- Location:
- trunk/src
- Files:
-
- 22 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/TropFlux_19890101_20091231.pro
r5 r6 1 ;------------------------------------------------------------ 1 ;+ 2 ; 3 ; .. _TropFlux_19890101_20091231.pro: 4 ; 5 ; ============================== 6 ; TropFlux_19890101_20091231.pro 7 ; ============================== 8 ; 9 ; This program computes net heat flux components on the 1° oaflux grid. 10 ; 11 ; all input variables are corrected for mean bias and variability. 12 ; 13 ; gustiness correction is applied for wind speed based on cronin's climatological 14 ; gustiness values. 15 ; 16 ; SEE ALSO 17 ; ======== 18 ; 19 ; EXAMPLES 20 ; ======== 21 ; 22 ; :: 23 ; 24 ; IDL> tropflux_19890101_20091231 25 ; 26 ; TODO 27 ; ==== 28 ; 29 ; hard coded directory - usage of ${TROPFLUX_ID} 30 ; 31 ; coding rules 32 ; 33 ; EVOLUTIONS 34 ; ========== 35 ; 36 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 37 ; 38 ; * minimal header 39 ; 40 ; - pbk 2008 41 ; 42 ; * creation 43 ; 44 ;- 45 ; 2 46 pro TropFlux_19890101_20091231 3 47 @common 4 48 ;------------------------------------------------------------ 5 49 ; 6 ; This program computes net heat flux components on the7 ; 1° oaflux grid8 ; all input variables are corrected for mean bias and variability9 ; gustiness correction is applied for wind speed based on cronin's climatological gustiness values10 50 11 51 da1=19880101 & da2=20101231 … … 27 67 initncdf, file_sst 28 68 29 ws=read_ncdf('ws',da1,da2,file=file_wind,/nostr) 69 ws=read_ncdf('ws',da1,da2,file=file_wind,/nostr) 30 70 wg=read_ncdf('wg',da1-1,da2,file=file_wg,/nostr) 31 71 tt=time & jpt=n_elements(time) 32 sst=read_ncdf('sst',da1,da2,file=file_sst,/nostr) 72 sst=read_ncdf('sst',da1,da2,file=file_sst,/nostr) 33 73 sst=reform(sst-273.15) 34 74 swd=read_ncdf('swr',da1,da2,file=file_sw,/nostr) … … 142 182 @ncdf_quickwrite 143 183 144 ;------------------------------------------------------------145 184 return 146 185 end 147 ;------------------------------------------------------------ -
trunk/src/TropFlux_NRT_ncdf.pro
r5 r6 1 ;+ 2 ; 3 ; .. _TropFlux_NRT_ncdf_v50.pro: 4 ; 5 ; ========================= 6 ; TropFlux_NRT_ncdf_v50.pro 7 ; ========================= 8 ; 9 ; SEE ALSO 10 ; ======== 11 ; 12 ; EXAMPLES 13 ; ======== 14 ; 15 ; :: 16 ; 17 ; IDL> tropFlux_nrt_ncdf_v50 18 ; 19 ; TODO 20 ; ==== 21 ; 22 ; hard coded directory - usage of ${TROPFLUX_ID} 23 ; 24 ; coding rules 25 ; 26 ; EVOLUTIONS 27 ; ========== 28 ; 29 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 30 ; 31 ; * minimal header 32 ; 33 ; - pbk 2008 34 ; 35 ; * creation 36 ; 37 ;- 1 38 pro TropFlux_NRT_ncdf_v50 2 39 @common … … 55 92 56 93 end 57 58 -
trunk/src/TropFlux_swr_BLND_19890101_20091231.pro
r5 r6 1 ;+ 2 ; 3 ; .. _TropFlux_swr_BLND_19890101_20091231.pro: 4 ; 5 ; ======================================= 6 ; TropFlux_swr_BLND_19890101_20091231.pro 7 ; ======================================= 8 ; 9 ; 10 ; SEE ALSO 11 ; ======== 12 ; 13 ; EXAMPLES 14 ; ======== 15 ; 16 ; :: 17 ; 18 ; IDL> tropflux_swr_blnd_19890101_20091231 19 ; 20 ; 21 ; TODO 22 ; ==== 23 ; 24 ; hard coded directory - usage of ${TROPFLUX_ID} 25 ; 26 ; coding rules 27 ; 28 ; EVOLUTIONS 29 ; ========== 30 ; 31 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 32 ; 33 ; * minimal header 34 ; 35 ; - pbk 2008 36 ; 37 ; * creation 38 ; 39 ;- 1 40 pro TropFlux_swr_BLND_19890101_20091231 2 41 @common … … 53 92 54 93 end 55 -
trunk/src/TropFlux_swr_DT_19890101_20071231.pro
r5 r6 1 ;+ 2 ; 3 ; .. _TropFlux_swr_DT_19890101_20071231.pro: 4 ; 5 ; ===================================== 6 ; TropFlux_swr_DT_19890101_20071231.pro 7 ; ===================================== 8 ; 9 ; 10 ; SEE ALSO 11 ; ======== 12 ; 13 ; EXAMPLES 14 ; ======== 15 ; 16 ; :: 17 ; 18 ; IDL> tropflux_swr_dt_19890101_20071231 19 ; 20 ; TODO 21 ; ==== 22 ; 23 ; hard coded directory - usage of ${TROPFLUX_ID} 24 ; 25 ; coding rules 26 ; 27 ; EVOLUTIONS 28 ; ========== 29 ; 30 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 31 ; 32 ; * minimal header 33 ; 34 ; - pbk 2008 35 ; 36 ; * creation 37 ; 38 ;- 1 39 pro TropFlux_swr_DT_19890101_20071231 2 40 @common … … 56 94 57 95 end 58 59 60 61 -
trunk/src/TropFlux_swr_NRT_19890101_20091231.pro
r5 r6 1 ;+ 2 ; 3 ; .. _TropFlux_swr_NRT_19890101_20091231.pro 4 ; 5 ; ====================================== 6 ; TropFlux_swr_NRT_19890101_20091231.pro 7 ; ====================================== 8 ; 9 ; 10 ; SEE ALSO 11 ; ======== 12 ; 13 ; EXAMPLES 14 ; ======== 15 ; 16 ; :: 17 ; 18 ; IDL> tropflux_swr_nrt_19890101_20091231 19 ; 20 ; TODO 21 ; ==== 22 ; 23 ; hard coded directory - usage of ${TROPFLUX_ID} 24 ; 25 ; coding rules 26 ; 27 ; EVOLUTIONS 28 ; ========== 29 ; 30 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 31 ; 32 ; * minimal header 33 ; 34 ; - pbk 2008 35 ; 36 ; * creation 37 ; 38 ;- 1 39 pro TropFlux_swr_NRT_19890101_20091231 2 40 @common … … 85 123 86 124 end 87 88 89 90 -
trunk/src/cor30a.pro
r5 r6 1 ;---------------------------------------------------------------------------------------------- 1 ;+ 2 ; 3 ; ====== 4 ; cor30a 5 ; ====== 6 ; 7 ; .. function: result=cor30a(u,us,ts,t,Qs,Q,Rs,Rl,rain,zi,P,zu,zt,zq,lat,jcool,jwave,twave,hwave) 8 ; 9 ; 10 ; COARE v3 algorithm to compute fluxes 11 ; 12 ; version with shortened iteration modified Rt and Rq 13 ; 14 ; uses wave information wave period in s and wave ht in m 15 ; no wave, standard coare 2.6 charnock: jwave=0 16 ; 17 ; Oost et al. zo=50/2/pi L (u*/c)^4.5 if jwave=1 18 ; 19 ; taylor and yelland zo=1200 h*(L/h)^4.5 jwave=2 20 ; 21 ; :param u: wind speed (m/s) at height zu (m) 22 ; :param us: surface current speed in the wind direction (m/s) 23 ; :param ts: bulk water temperature (C) if jcool=1, interface water T if jcool=0 24 ; :param t: bulk air temperature (C), height zt 25 ; :param Qs: bulk water spec hum (g/kg) if jcool=1, ... 26 ; :param Q: bulk air spec hum (g/kg), height zq 27 ; :param Rs: downward solar flux (W/m^2) (modified because of cool skin) 28 ; :param Rl: downard IR flux (W/m^2) (modified because of cool skin) 29 ; :param rain: rain rate (mm/hr) 30 ; :param zi: PBL depth (m) 31 ; :param P: Atmos surface pressure (mb) 32 ; :param zu: wind speed measurement height (m) 33 ; :param zt: air T measurement height (m) 34 ; :param zq: air q measurement height (m) 35 ; :param lat: latitude (deg, N=+) 36 ; :param jcool: implement cool calculation skin switch, 0=no, 1=yes 37 ; :param jwave: implement wave dependent roughness model 38 ; :param twave: wave period (s) 39 ; :param hwave: wave height (m) 40 ; 41 ; EXAMPLES 42 ; ======== 43 ; 44 ; :: 45 ; 46 ; u us ts ta qs qa Qsw IRd r pbl Ps zu zt zq lat 47 ; 48 ; IDL> x=cor30a(5.5,0,28.7,27.2,24.2,18.5,141.,419.,0.,600.,1010.,15.,15.,15.,0.,1,1,5.,1.) 49 ; 50 ; Result with these sample values with Matlab code:: 51 ; 52 ; 8.64830 101.640 0.0352910 2.17780e-05 0.000115000 0.000115000 53 ; -29.5800 0.175430 -0.0423670 -0.000205610 0.250950 0.000351300 54 ; 0.000969740 0.00000 8.11390e-05 0.000997340 0.00121410 0.00121400 55 ; 0.000941350 0.00107910 0.00107910 0.780060 56 ; 57 ; Result obtained with this idl routine:: 58 ; 59 ; 8.64829 101.640 0.0352913 2.17780e-05 0.000115000 0.000115000 60 ; -29.5802 0.175432 -0.0423667 -0.000205610 0.250948 0.000351304 61 ; 0.000969737 0.00000 8.11394e-05 0.000997343 0.00121407 0.00121400 62 ; 0.000941351 0.00107908 0.00107908 0.780056 63 ; 64 ; Maximum error on any parameter: .002 % validated! 65 ; 66 ; TODO 67 ; ==== 68 ; 69 ; hard coded directory - usage of ${TROPFLUX_ID} 70 ; 71 ; coding rules 72 ; 73 ; EVOLUTIONS 74 ; ========== 75 ; 76 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 77 ; 78 ; * minimal header 79 ; 80 ; - pbk 2008 81 ; 82 ; * creation 83 ; 84 ;- 2 85 function cor30a, u,us,ts,t,Qs,Q,Rs,Rl,rain,zi,P,zu,zt,zq,lat,jcool,jwave,twave,hwave 3 ;4 ; COARE v3 algorithm to compute fluxes5 ; version with shortened iteration modified Rt and Rq6 ; uses wave information wave period in s and wave ht in m7 ; no wave, standard coare 2.6 charnock: jwave=08 ; Oost et al. zo=50/2/pi L (u*/c)^4.5 if jwave=19 ; taylor and yelland zo=1200 h*(L/h)^4.5 jwave=210 ;11 ; u ;wind speed (m/s) at height zu (m)12 ; us ;surface current speed in the wind direction (m/s)13 ; ts ;bulk water temperature (C) if jcool=1, interface water T if jcool=014 ; t ;bulk air temperature (C), height zt15 ; Qs ;bulk water spec hum (g/kg) if jcool=1, ...16 ; Q ;bulk air spec hum (g/kg), height zq17 ; Rs ;downward solar flux (W/m^2) (modified because of cool skin)18 ; Rl ;downard IR flux (W/m^2) (modified because of cool skin)19 ; rain ;rain rate (mm/hr)20 ; zi ;PBL depth (m)21 ; P ;Atmos surface pressure (mb)22 ; zu ;wind speed measurement height (m)23 ; zt ;air T measurement height (m)24 ; zq ;air q measurement height (m)25 ; lat ;latitude (deg, N=+)26 ; jcool ;implement cool calculation skin switch, 0=no, 1=yes27 ; jwave ;implement wave dependent roughness model28 ; twave ;wave period (s)29 ; hwave ;wave height (m)30 ;31 ;Example of values:32 ; u us ts ta qs qa Qsw IRd r pbl Ps zu zt zq lat33 ;x=cor30a(5.5,0,28.7,27.2,24.2,18.5,141.,419.,0.,600.,1010.,15.,15.,15.,0.,1,1,5.,1.) ;sample data stream34 ;35 ;Result with these sample values with Matlab code:36 ; 8.64830 101.640 0.0352910 2.17780e-05 0.000115000 0.00011500037 ; -29.5800 0.175430 -0.0423670 -0.000205610 0.250950 0.00035130038 ; 0.000969740 0.00000 8.11390e-05 0.000997340 0.00121410 0.0012140039 ; 0.000941350 0.00107910 0.00107910 0.78006040 ;41 ;Result obtained with this idl routine:42 ; 8.64829 101.640 0.0352913 2.17780e-05 0.000115000 0.00011500043 ; -29.5802 0.175432 -0.0423667 -0.000205610 0.250948 0.00035130444 ; 0.000969737 0.00000 8.11394e-05 0.000997343 0.00121407 0.0012140045 ; 0.000941351 0.00107908 0.00107908 0.78005646 ;47 ; Maximum error on any parameter: .002 % validated!48 ;49 ;----------------------------------------------------------------------------------------------50 86 51 87 Qs=Qs/1000. … … 54 90 ;*********** set constants ************* 55 91 pi=!pi 56 Beta=1.2 57 von=0.4 58 fdg=1.00 59 tdk=273.16 60 ;grav=grv(lat) 92 Beta=1.2 93 von=0.4 94 fdg=1.00 95 tdk=273.16 96 ;grav=grv(lat) 61 97 grav=9.8 62 98 ;************* air constants ************ 63 Rgas=287.1 64 LLe=(2.501-.00237*ts)*1e6 65 cpa=1004.67 66 cpv=cpa*(1+0.84*Q) 67 rhoa=P*100/(Rgas*(t+tdk)*(1+0.61*Q)) 68 visa=1.326e-5*(1+6.542e-3*t+8.301e-6*t*t-4.84e-9*t*t*t) 99 Rgas=287.1 100 LLe=(2.501-.00237*ts)*1e6 101 cpa=1004.67 102 cpv=cpa*(1+0.84*Q) 103 rhoa=P*100/(Rgas*(t+tdk)*(1+0.61*Q)) 104 visa=1.326e-5*(1+6.542e-3*t+8.301e-6*t*t-4.84e-9*t*t*t) 69 105 ;************ cool skin constants ******* 70 Al=2.1e-5*(ts+3.2)^0.79 71 be=0.026 72 cpw=4000 73 rhow=1022 74 visw=1e-6 75 tcw=0.6 76 bigc=16*grav*cpw*(rhow*visw)^3/(tcw*tcw*rhoa*rhoa) 77 wetc=0.622*LLe*Qs/(Rgas*(ts+tdk)^2) 78 106 Al=2.1e-5*(ts+3.2)^0.79 107 be=0.026 108 cpw=4000 109 rhow=1022 110 visw=1e-6 111 tcw=0.6 112 bigc=16*grav*cpw*(rhow*visw)^3/(tcw*tcw*rhoa*rhoa) 113 wetc=0.622*LLe*Qs/(Rgas*(ts+tdk)^2) 114 79 115 ;*************** wave parameters ********* 80 lwave=grav/2/pi*twave^2 81 cwave=grav/2/pi*twave 82 116 lwave=grav/2/pi*twave^2 117 cwave=grav/2/pi*twave 118 83 119 ;************** compute aux stuff ******* 84 Rns=Rs*.945 85 Rnl=0.97*(5.67e-8*(ts-0.3*jcool+tdk)^4-Rl) 120 Rns=Rs*.945 121 Rnl=0.97*(5.67e-8*(ts-0.3*jcool+tdk)^4-Rl) 86 122 87 123 88 124 89 125 ;*************** Begin bulk loop ******* 90 126 91 127 ;*************** first guess ************ 92 du=u-us 93 dt=ts-t-.0098*zt 94 dq=Qs-Q 95 ta=t+tdk 96 ug=0.5 97 dter=0.3 98 dqer=wetc*dter 99 ut=sqrt(du*du+ug*ug) 100 u10=ut*alog(10./1e-4)/alog(zu/1e-4) 101 usr=.035*u10 102 zo10=0.011*usr*usr/grav+0.11*visa/usr 103 Cd10=(von/alog(10./zo10))^2 104 Ch10=0.00115 105 Ct10=Ch10/sqrt(Cd10) 106 zot10=10/exp(von/Ct10) 107 Cd=(von/alog(zu/zo10))^2 108 Ct=von/alog(zt/zot10) 109 CC=von*Ct/Cd 110 Ribcu=-zu/zi/.004/Beta^3 111 Ribu=-grav*zu/ta*((dt-dter*jcool)+.61*ta*dq)/ut^2 112 nits=3 128 du=u-us 129 dt=ts-t-.0098*zt 130 dq=Qs-Q 131 ta=t+tdk 132 ug=0.5 133 dter=0.3 134 dqer=wetc*dter 135 ut=sqrt(du*du+ug*ug) 136 u10=ut*alog(10./1e-4)/alog(zu/1e-4) 137 usr=.035*u10 138 zo10=0.011*usr*usr/grav+0.11*visa/usr 139 Cd10=(von/alog(10./zo10))^2 140 Ch10=0.00115 141 Ct10=Ch10/sqrt(Cd10) 142 zot10=10/exp(von/Ct10) 143 Cd=(von/alog(zu/zo10))^2 144 Ct=von/alog(zt/zot10) 145 CC=von*Ct/Cd 146 Ribcu=-zu/zi/.004/Beta^3 147 Ribu=-grav*zu/ta*((dt-dter*jcool)+.61*ta*dq)/ut^2 148 nits=3 113 149 ;;if (Ribu le 0.) then begin 114 ;; zetu=CC*Ribu/(1+Ribu/Ribcu) 150 ;; zetu=CC*Ribu/(1+Ribu/Ribcu) 115 151 ;;endif else begin 116 ;; zetu=CC*Ribu*(1+27./9*Ribu/CC) 117 ;;endelse 152 ;; zetu=CC*Ribu*(1+27./9*Ribu/CC) 153 ;;endelse 118 154 sw=(Ribu le 0.) 119 155 zetu=sw*(CC*Ribu/(1+Ribu/Ribcu))+(1-sw)*(CC*Ribu*(1+27./9*Ribu/CC)) 120 156 ;; 121 L10=zu/zetu 122 ;;if (zetu gt 50 ) then nits=1 123 usr=ut*von/(alog(zu/zo10)-psiu(zu/L10)) 124 tsr=-(dt-dter*jcool)*von*fdg/(alog(zt/zot10)-psit(zt/L10)) 125 qsr=-(dq-wetc*dter*jcool)*von*fdg/(alog(zq/zot10)-psit(zq/L10)) 126 127 tkt=.001 128 129 ;;charn=0.011 130 ;;if (ut gt 10.) then charn=0.011+(ut-10)/(18.-10)*(0.018-0.011) 131 ;;if (ut gt 18.) then charn=0.018 157 L10=zu/zetu 158 ;;if (zetu gt 50 ) then nits=1 159 usr=ut*von/(alog(zu/zo10)-psiu(zu/L10)) 160 tsr=-(dt-dter*jcool)*von*fdg/(alog(zt/zot10)-psit(zt/L10)) 161 qsr=-(dq-wetc*dter*jcool)*von*fdg/(alog(zq/zot10)-psit(zq/L10)) 162 163 tkt=.001 164 165 ;;charn=0.011 166 ;;if (ut gt 10.) then charn=0.011+(ut-10)/(18.-10)*(0.018-0.011) 167 ;;if (ut gt 18.) then charn=0.018 132 168 charn=(((0.011+(ut-10)/(18.-10)*(0.018-0.011)) > .011) < .018) 133 169 ;; 134 170 135 171 ;*************** bulk loop ************ 136 172 for i=1,nits do begin 137 zet=von*grav*zu/ta*(tsr*(1+0.61*Q)+.61*ta*qsr)/(usr*usr)/(1+0.61*Q) 173 zet=von*grav*zu/ta*(tsr*(1+0.61*Q)+.61*ta*qsr)/(usr*usr)/(1+0.61*Q) 138 174 case jwave of 139 0: zo=charn*usr*usr/grav+0.11*visa/usr 175 0: zo=charn*usr*usr/grav+0.11*visa/usr 140 176 1: zo=50./2/pi*lwave*(usr/cwave)^4.5+0.11*visa/usr ;Oost et al 141 177 2: zo=1200*hwave*(hwave/lwave)^4.5+0.11*visa/usr ;Taylor and Yelland 142 178 endcase 143 rr=zo*usr/visa 144 L=zu/zet 145 ;;zoq=min([1.15e-4,5.5e-5/rr^.6]) 179 rr=zo*usr/visa 180 L=zu/zet 181 ;;zoq=min([1.15e-4,5.5e-5/rr^.6]) 146 182 zoq=(5.5e-5/rr^.6 < 1.15e-4) 147 183 ;; 148 zot=zoq 149 usr=ut*von/(alog(zu/zo)-psiu(zu/L)) 150 tsr=-(dt-dter*jcool)*von*fdg/(alog(zt/zot)-psit(zt/L)) 151 qsr=-(dq-wetc*dter*jcool)*von*fdg/(alog(zq/zoq)-psit(zq/L)) 152 Bf=-grav/ta*usr*(tsr+.61*ta*qsr) 184 zot=zoq 185 usr=ut*von/(alog(zu/zo)-psiu(zu/L)) 186 tsr=-(dt-dter*jcool)*von*fdg/(alog(zt/zot)-psit(zt/L)) 187 qsr=-(dq-wetc*dter*jcool)*von*fdg/(alog(zq/zoq)-psit(zq/L)) 188 Bf=-grav/ta*usr*(tsr+.61*ta*qsr) 153 189 ;;if (Bf gt 0) then begin 154 ;; ug=Beta*(Bf*zi)^.333 190 ;; ug=Beta*(Bf*zi)^.333 155 191 ;;endif else begin 156 ;; ug=.2 157 ;;endelse 192 ;; ug=.2 193 ;;endelse 158 194 sw=(Bf gt 0) 159 195 ug=sw*(Beta*(Bf*zi)^.333)+(1-sw)*.2 160 196 ;; 161 ut=sqrt(du*du+ug*ug) 162 Rnl=0.97*(5.67e-8*(ts-dter*jcool+tdk)^4-Rl) 163 hsb=-rhoa*cpa*usr*tsr 164 hlb=-rhoa*LLe*usr*qsr 165 qout=Rnl+hsb+hlb 197 ut=sqrt(du*du+ug*ug) 198 Rnl=0.97*(5.67e-8*(ts-dter*jcool+tdk)^4-Rl) 199 hsb=-rhoa*cpa*usr*tsr 200 hlb=-rhoa*LLe*usr*qsr 201 qout=Rnl+hsb+hlb 166 202 dels=Rns*(.065+11*tkt-6.6e-5/tkt*(1-exp(-tkt/8.0e-4))) ; Eq.16 Shortwave 167 qcol=qout-dels 203 qcol=qout-dels 168 204 alq=Al*qcol+be*hlb*cpw/LLe ; Eq. 7 Buoy flux water 169 205 … … 172 208 ;; tkt=xlamx*visw/(sqrt(rhoa/rhow)*usr) ;Eq.11 Sub. thk 173 209 ;; endif else begin 174 ;; xlamx=6.0 210 ;; xlamx=6.0 175 211 ;;;; tkt=min([.01,xlamx*visw/(sqrt(rhoa/rhow)*usr)]) ;Eq.11 Sub. thk 176 212 ;; tkt=(xlamx*visw/(sqrt(rhoa/rhow)*usr) < .01) 177 213 ;;;; 178 ;; endelse 214 ;; endelse 179 215 sw=(alq gt 0) 180 216 xlamx=sw*(6./(1+(bigc*alq/usr^4)^.75)^.333)+(1-sw)*6.0 181 217 tkt=sw*(xlamx*visw/(sqrt(rhoa/rhow)*usr))+(1-sw)*(xlamx*visw/(sqrt(rhoa/rhow)*usr) < .01) 182 218 ;; 183 219 184 220 dter=qcol*tkt/tcw ; Eq.12 Cool skin 185 dqer=wetc*dter 186 221 dqer=wetc*dter 222 187 223 endfor ;bulk iter loop 188 224 … … 204 240 ;;**************** Webb et al. correection ************ 205 241 ;wbar=1.61*hlb/LLe/(1+1.61*Q)/rhoa+hsb/rhoa/cpa/ta ;formulation in hlb already includes webb 206 ;hl_webb=rhoa*wbar*Q*LLe 242 ;hl_webb=rhoa*wbar*Q*LLe 207 243 ;;************** compute transfer coeffs relative to ut @meas. ht ********** 208 244 ;;Cd=tau/rhoa/ut/max([.1,du]) 209 ;Cd=tau/rhoa/ut/(du > .1) 245 ;Cd=tau/rhoa/ut/(du > .1) 210 246 ;;; 211 Ch=-usr*tsr/ut/(dt-dter*jcool) 212 Ce=-usr*qsr/(dq-dqer*jcool)/ut 247 Ch=-usr*tsr/ut/(dt-dter*jcool) 248 Ce=-usr*qsr/(dq-dqer*jcool)/ut 213 249 ;;************ 10-m neutral coeff realtive to ut ******** 214 ;Cdn_10=von*von/alog(10./zo)/alog(10./zo) 215 ;Chn_10=von*von*fdg/alog(10./zo)/alog(10./zot) 216 ;Cen_10=von*von*fdg/alog(10./zo)/alog(10./zoq) 217 218 y=[[Rns],[-1.*Rnl],[-1.*hlb],[-1.*hsb],[-1.*RF],[tau],[Ch],[Ce]] 219 ;;y=[hsb,hlb,tau,zo,zot,zoq,L,usr,tsr,qsr,dter,dqer,tkt,RF,wbar,Cd,Ch,Ce,Cdn_10,Chn_10,Cen_10,ug ] 250 ;Cdn_10=von*von/alog(10./zo)/alog(10./zo) 251 ;Chn_10=von*von*fdg/alog(10./zo)/alog(10./zot) 252 ;Cen_10=von*von*fdg/alog(10./zo)/alog(10./zoq) 253 254 y=[[Rns],[-1.*Rnl],[-1.*hlb],[-1.*hsb],[-1.*RF],[tau],[Ch],[Ce]] 255 ;;y=[hsb,hlb,tau,zo,zot,zoq,L,usr,tsr,qsr,dter,dqer,tkt,RF,wbar,Cd,Ch,Ce,Cdn_10,Chn_10,Cen_10,ug ] 220 256 ; 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 221 257 ; hsb= sensible heat flux (w/m^2) … … 246 282 247 283 end 248 ;----------------------------------------------------------------------------------------------249 -
trunk/src/cronin_gustiness_ncdf.pro
r5 r6 1 ;+ 2 ; 3 ; .. _cronin_gustiness_ncdf.pro: 4 ; 5 ; ========================= 6 ; cronin_gustiness_ncdf.pro 7 ; ========================= 8 ; 9 ; SEE ALSO 10 ; ======== 11 ; 12 ; EXAMPLES 13 ; ======== 14 ; 15 ; :: 16 ; 17 ; IDL> cronin_gustiness_ncdf 18 ; 19 ; TODO 20 ; ==== 21 ; 22 ; hard coded directory - usage of ${TROPFLUX_ID} 23 ; 24 ; coding rules 25 ; 26 ; EVOLUTIONS 27 ; ========== 28 ; 29 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 30 ; 31 ; * minimal header 32 ; 33 ; - pbk 2008 34 ; 35 ; * creation 36 ; 37 ;- 1 38 pro cronin_gustiness_ncdf 2 39 @common … … 46 83 @ncdf_quickwrite 47 84 48 ;------------------------------------------------------------49 85 return 50 86 end 51 52 -
trunk/src/d2m_to_q2m_erai.pro
r5 r6 1 ;+ 2 ; 3 ; .. _d2m_to_q2m_erai.pro: 4 ; 5 ; =================== 6 ; d2m_to_q2m_erai.pro 7 ; =================== 8 ; 9 ; SEE ALSO 10 ; ======== 11 ; 12 ; EXAMPLES 13 ; ======== 14 ; 15 ; :: 16 ; 17 ; IDL> d2m_to_q2m_erai 18 ; 19 ; TODO 20 ; ==== 21 ; 22 ; hard coded directory - usage of ${TROPFLUX_ID} 23 ; 24 ; coding rules 25 ; 26 ; EVOLUTIONS 27 ; ========== 28 ; 29 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 30 ; 31 ; * minimal header 32 ; 33 ; - pbk 2008 34 ; 35 ; * creation 36 ; 37 ;- 1 38 pro d2m_to_q2m_erai 2 39 @common 3 ;----------------------------------------------------------------------4 40 ;; reading erai dew point temperature 5 41 d1=19881001 & d2=20101231 … … 25 61 ;---------------------------------------------------------------------- 26 62 ;; conversion of relative humidity to sp. humidity 27 ;; Ref.1 - Gill, Appendix 4, 63 ;; Ref.1 - Gill, Appendix 4, 28 64 ;; Ref.2 - http://efdl.cims.nyu.edu/project_aomip/forcing_data/atmosphere/humidity.html 29 65 … … 62 98 @ncdf_quickwrite 63 99 return 64 ;----------------------------------------------------------------------65 100 end -
trunk/src/dew_temp_airt_rel_humidity_jv.pro
r5 r6 1 ;+ 2 ; 3 ; ============================= 4 ; dew_temp_airt_rel_humidity_jv 5 ; ============================= 6 ; 7 ; .. function: result=dew_temp_airt_rel_humidity_jv(t, td) 8 ; 9 ; :param t: air temperature in degC 10 ; :param td: dew point temperature in degC 11 ; 12 ; 13 ; SEE ALSO 14 ; ======== 15 ; 16 ; EXAMPLES 17 ; ======== 18 ; 19 ; :: 20 ; 21 ; IDL> t=+todo+ 22 ; IDL> td=+todo+ 23 ; IDL> result=dew_temp_airt_rel_humidity_jv(t, td) 24 ; 25 ; 26 ; TODO 27 ; ==== 28 ; 29 ; hard coded directory - usage of ${TROPFLUX_ID} 30 ; 31 ; coding rules 32 ; 33 ; EVOLUTIONS 34 ; ========== 35 ; 36 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 37 ; 38 ; * minimal header 39 ; 40 ; - pbk 2008 41 ; 42 ; * creation 43 ; 44 ;- 1 45 function dew_temp_airt_rel_humidity_jv, t,td 2 46 ;---------------------------------------------------------------------- … … 19 63 return, rh 20 64 21 ;----------------------------------------------------------------------22 65 end -
trunk/src/interp_erai_dewt_1989_2009.pro
r5 r6 1 ;+ 2 ; 3 ; .. _interp_erai_dewt_1989_2009.pro: 4 ; 5 ; ============================== 6 ; interp_erai_dewt_1989_2009.pro 7 ; ============================== 8 ; 9 ; 10 ; SEE ALSO 11 ; ======== 12 ; 13 ; EXAMPLES 14 ; ======== 15 ; 16 ; :: 17 ; 18 ; IDL> interp_erai_dewt_1989_2009 19 ; 20 ; TODO 21 ; ==== 22 ; 23 ; hard coded directory - usage of ${TROPFLUX_ID} 24 ; 25 ; coding rules 26 ; 27 ; EVOLUTIONS 28 ; ========== 29 ; 30 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 31 ; 32 ; * minimal header 33 ; 34 ; - pbk 2008 35 ; 36 ; * creation 37 ; 38 ;- 1 39 pro interp_erai_dewt_1989_2009 2 40 @common -
trunk/src/interp_erai_lwr_1989_2009.pro
r5 r6 1 ;+ 2 ; 3 ; .. interp_erai_lwr_1989_2009.pro: 4 ; 5 ; ============================= 6 ; interp_erai_lwr_1989_2009.pro 7 ; ============================= 8 ; 9 ; 10 ; SEE ALSO 11 ; ======== 12 ; 13 ; EXAMPLES 14 ; ======== 15 ; 16 ; :: 17 ; 18 ; IDL> interp_erai_lwr_1989_2009 19 ; 20 ; TODO 21 ; ==== 22 ; 23 ; hard coded directory - usage of ${TROPFLUX_ID} 24 ; 25 ; coding rules 26 ; 27 ; EVOLUTIONS 28 ; ========== 29 ; 30 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 31 ; 32 ; * minimal header 33 ; 34 ; - pbk 2008 35 ; 36 ; * creation 37 ; 38 ;- 1 39 pro interp_erai_lwr_1989_2009 2 40 @common … … 75 113 @ncdf_quickwrite 76 114 77 ;------------------------------------------------------------78 115 return 79 116 end 80 81 -
trunk/src/interp_erai_sst_1989_2009.pro
r5 r6 1 ;+ 2 ; 3 ; .. _interp_erai_sst_1989_2009.pro: 4 ; 5 ; ============================= 6 ; interp_erai_sst_1989_2009.pro 7 ; ============================= 8 ; 9 ; SEE ALSO 10 ; ======== 11 ; 12 ; EXAMPLES 13 ; ======== 14 ; 15 ; :: 16 ; 17 ; IDL> interp_erai_sst_1989_2009 18 ; 19 ; TODO 20 ; ==== 21 ; 22 ; hard coded directory - usage of ${TROPFLUX_ID} 23 ; 24 ; coding rules 25 ; 26 ; EVOLUTIONS 27 ; ========== 28 ; 29 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 30 ; 31 ; * minimal header 32 ; 33 ; - pbk 2008 34 ; 35 ; 36 ; * creation 37 ; 38 ;- 1 39 pro interp_erai_sst_1989_2009 2 40 @common -
trunk/src/interp_erai_t2m_1989_2009.pro
r5 r6 1 ;+ 2 ; 3 ; .. interp_erai_t2m_1989_2009.pro: 4 ; 5 ; ============================= 6 ; interp_erai_t2m_1989_2009.pro 7 ; ============================= 8 ; 9 ; 10 ; SEE ALSO 11 ; ======== 12 ; 13 ; EXAMPLES 14 ; ======== 15 ; 16 ; :: 17 ; 18 ; IDL> interp_erai_t2m_1989_2009 19 ; 20 ; 21 ; TODO 22 ; ==== 23 ; 24 ; hard coded directory - usage of ${TROPFLUX_ID} 25 ; 26 ; coding rules 27 ; 28 ; EVOLUTIONS 29 ; ========== 30 ; 31 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 32 ; 33 ; * minimal header 34 ; 35 ; - pbk 2008 36 ; 37 ; * creation 38 ; 39 ;- 1 40 pro interp_erai_t2m_1989_2009 2 41 @common -
trunk/src/interp_erai_ws_1989_2009.pro
r5 r6 1 ;+ 2 ; 3 ; .. _interp_erai_ws_1989_2009.pro: 4 ; 5 ; ============================ 6 ; interp_erai_ws_1989_2009.pro 7 ; ============================ 8 ; SEE ALSO 9 ; ======== 10 ; 11 ; EXAMPLES 12 ; ======== 13 ; 14 ; :: 15 ; 16 ; IDL> interp_erai_ws_1989_2009 17 ; 18 ; 19 ; TODO 20 ; ==== 21 ; 22 ; hard coded directory - usage of ${TROPFLUX_ID} 23 ; 24 ; coding rules 25 ; 26 ; EVOLUTIONS 27 ; ========== 28 ; 29 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 30 ; 31 ; * minimal header 32 ; 33 ; - pbk 2008 34 ; 35 ; * creation 36 ; 37 ;- 1 38 pro interp_erai_ws_1989_2009 2 39 @common … … 83 120 @ncdf_quickwrite 84 121 85 ;------------------------------------------------------------86 122 return 87 123 end 88 89 -
trunk/src/interp_olr_30n30s_1989_2009.pro
r5 r6 1 ;+ 2 ; 3 ; .. _interp_olr_30n30s_1989_2009.pro: 4 ; 5 ; =============================== 6 ; interp_olr_30n30s_1989_2009.pro 7 ; =============================== 8 ; 9 ; 10 ; SEE ALSO 11 ; ======== 12 ; 13 ; EXAMPLES 14 ; ======== 15 ; 16 ; :: 17 ; 18 ; IDL> interp_olr_30n30s_1989_2009 19 ; 20 ; TODO 21 ; ==== 22 ; 23 ; hard coded directory - usage of ${TROPFLUX_ID} 24 ; 25 ; coding rules 26 ; 27 ; EVOLUTIONS 28 ; ========== 29 ; 30 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 31 ; 32 ; * minimal header 33 ; 34 ; - pbk 2008 35 ; 36 ; * creation 37 ; 38 ;- 1 39 pro interp_olr_30n30s_1989_2009 2 40 @common … … 12 50 olrin=read_ncdf("olr",19881231, 20091231, file=filein,/nostr) 13 51 14 mskin=glamt*0.+1. 15 52 mskin=glamt*0.+1. 53 16 54 timein=time & jptin=jpt 17 55 -
trunk/src/lwr_correction_ncdf.pro
r5 r6 1 ;+ 2 ; 3 ; .. _lwr_correction_ncdf.pro: 4 ; 5 ; ======================= 6 ; lwr_correction_ncdf.pro 7 ; ======================= 8 ; 9 ; SEE ALSO 10 ; ======== 11 ; 12 ; EXAMPLES 13 ; ======== 14 ; 15 ; :: 16 ; 17 ; IDL> lwr_correction_ncdf 18 ; 19 ; 20 ; TODO 21 ; ==== 22 ; 23 ; hard coded directory - usage of ${TROPFLUX_ID} 24 ; 25 ; coding rules 26 ; 27 ; EVOLUTIONS 28 ; ========== 29 ; 30 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 31 ; 32 ; * minimal header 33 ; 34 ; - pbk 2008 35 ; 36 ; * creation 37 ; 38 ;- 1 39 pro lwr_correction_ncdf 2 40 @common … … 67 105 68 106 end 69 70 -
trunk/src/q2m_correction_ncdf.pro
r5 r6 1 ;+ 2 ; 3 ; .. _q2m_correction_ncdf.pro: 4 ; 5 ; ======================= 6 ; q2m_correction_ncdf.pro 7 ; ======================= 8 ; 9 ; SEE ALSO 10 ; ======== 11 ; 12 ; EXAMPLES 13 ; ======== 14 ; 15 ; :: 16 ; 17 ; IDL> q2m_correction_ncdf 18 ; 19 ; TODO 20 ; ==== 21 ; 22 ; hard coded directory - usage of ${TROPFLUX_ID} 23 ; 24 ; coding rules 25 ; 26 ; EVOLUTIONS 27 ; ========== 28 ; 29 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 30 ; 31 ; * minimal header 32 ; 33 ; - pbk 2008 34 ; 35 ; * creation 36 ; 37 ;- 1 38 pro q2m_correction_ncdf 2 39 @common … … 66 103 67 104 end 68 69 -
trunk/src/rh_to_spechum.pro
r5 r6 1 ;+ 2 ; 3 ; ============= 4 ; rh_to_spechum 5 ; ============= 6 ; 7 ; .. function: result=rh_to_spechum(rh,ta,P) 8 ; 9 ; :param rh: in % 10 ; :param ta: air temperature in degC 11 ; :param P : pressure in hPa 12 ; 13 ; :returns: Air specific humidity (g/kg) 14 ; 15 ; EXAMPLES 16 ; ======== 17 ; 18 ; :: 19 ; 20 ; IDL> rh=+todo+ 21 ; IDL> ta=+todo+ 22 ; IDL> P=+todo+ 23 ; IDL> result=rh_to_spechum(rh,ta,P) 24 ; 25 ; TODO 26 ; ==== 27 ; 28 ; hard coded directory - usage of ${TROPFLUX_ID} 29 ; 30 ; coding rules 31 ; 32 ; EVOLUTIONS 33 ; ========== 34 ; 35 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 36 ; 37 ; * minimal header 38 ; 39 ; - pbk 2008 40 ; 41 ; * creation 42 ; 43 ;- 1 44 function rh_to_spechum, rh,ta,P 2 ;----------------------------------------------------------------------3 ; rh: in %4 ; ta: air temperature in degC5 ; P : pressure in hPa6 ;----------------------------------------------------------------------7 45 8 46 rhf=rh/100. 9 47 qw=qsat(ta,P)/1000. 10 q=(rhf*qw)/(1.-qw*(1-rhf))*1e3 ; Air specific humidity (g/kg) 48 49 ; Air specific humidity (g/kg) 50 q=(rhf*qw)/(1.-qw*(1-rhf))*1e3 11 51 12 52 return, q 13 53 14 ;----------------------------------------------------------------------15 54 end -
trunk/src/sst_correction_ncdf.pro
r5 r6 1 ;+ 2 ; 3 ; .. sst_correction_ncdf.pro: 4 ; 5 ; ======================= 6 ; sst_correction_ncdf.pro 7 ; ======================= 8 ; 9 ; 10 ; SEE ALSO 11 ; ======== 12 ; 13 ; EXAMPLES 14 ; ======== 15 ; 16 ; :: 17 ; 18 ; IDL> sst_correction_ncdf 19 ; 20 ; TODO 21 ; ==== 22 ; 23 ; hard coded directory - usage of ${TROPFLUX_ID} 24 ; 25 ; coding rules 26 ; 27 ; EVOLUTIONS 28 ; ========== 29 ; 30 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 31 ; 32 ; * minimal header 33 ; 34 ; - pbk 2008 35 ; 36 ; * creation 37 ; 38 ;- 1 39 pro sst_correction_ncdf 2 40 @common -
trunk/src/t2m_correction_ncdf.pro
r5 r6 1 ;+ 2 ; 3 ; .. _t2m_correction_ncdf.pro: 4 ; 5 ; ======================= 6 ; t2m_correction_ncdf.pro 7 ; ======================= 8 ; 9 ; SEE ALSO 10 ; ======== 11 ; 12 ; EXAMPLES 13 ; ======== 14 ; 15 ; :: 16 ; 17 ; IDL> t2m_correction_ncdf 18 ; 19 ; TODO 20 ; ==== 21 ; 22 ; hard coded directory - usage of ${TROPFLUX_ID} 23 ; 24 ; coding rules 25 ; 26 ; EVOLUTIONS 27 ; ========== 28 ; 29 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 30 ; 31 ; * minimal header 32 ; 33 ; - pbk 2008 34 ; 35 ; * creation 36 ; 37 ;- 1 38 pro t2m_correction_ncdf 2 39 @common … … 74 111 75 112 end 76 77 -
trunk/src/time_axe_modif_TropFlux.pro
r5 r6 1 ;+ 2 ; 3 ; .. _time_axe_modif_TropFlux.pro: 4 ; 5 ; =========================== 6 ; time_axe_modif_TropFlux.pro 7 ; =========================== 8 ; 9 ; SEE ALSO 10 ; ======== 11 ; 12 ; EXAMPLES 13 ; ======== 14 ; 15 ; :: 16 ; 17 ; IDL> time_axe_modif_tropflux 18 ; 19 ; TODO 20 ; ==== 21 ; 22 ; hard coded directory - usage of ${TROPFLUX_ID} 23 ; 24 ; coding rules 25 ; 26 ; EVOLUTIONS 27 ; ========== 28 ; 29 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 30 ; 31 ; * minimal header 32 ; 33 ; - pbk 2008 34 ; 35 ; * creation 36 ; 37 ;- 1 38 pro time_axe_modif_TropFlux 2 39 … … 26 63 ncdf_control, cdfid ,/REDEF ; put in define mode 27 64 ; 28 ; reading attributs of time 65 ; reading attributs of time 29 66 ; 30 67 varid=ncdf_varid(cdfid,'time') -
trunk/src/ws_correction_ncdf.pro
r5 r6 1 ;+ 2 ; 3 ; .. _ws_correction_ncdf.pro: 4 ; 5 ; ====================== 6 ; ws_correction_ncdf.pro 7 ; ====================== 8 ; 9 ; 10 ; SEE ALSO 11 ; ======== 12 ; 13 ; EXAMPLES 14 ; ======== 15 ; 16 ; :: 17 ; 18 ; IDL> ws_correction_ncdf 19 ; 20 ; TODO 21 ; ==== 22 ; 23 ; hard coded directory - usage of ${TROPFLUX_ID} 24 ; 25 ; coding rules 26 ; 27 ; EVOLUTIONS 28 ; ========== 29 ; 30 ; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin) 31 ; 32 ; * minimal header 33 ; 34 ; - pbk 2008 35 ; 36 ; * creation 37 ; 38 ;- 1 39 pro ws_correction_ncdf 2 40 @common … … 70 108 71 109 end 72 73
Note: See TracChangeset
for help on using the changeset viewer.