|
Re: computing wet-bulb temperature [message #46776 is a reply to message #46621] |
Mon, 19 December 2005 01:15  |
wmconnolley
Messages: 106 Registered: November 2000
|
Senior Member |
|
|
Tom Over <tmover@hotmail.com> wrote:
> Does anybody have an IDL routine to compute wet-bulb temperature?
No, but this computes the vapour pressure and might help...
function vp,t1,degc=degc
@comm_error
; Return vapour pressure (hPa) of water given temperature
; Constants
ts=373.16
ews=1013.246
; In K (default) or oC?
if (keyword_set(degc)) then t=t1+273.15 else t=t1
; Check
if (min(t) lt 100) then message,'dew temp < 100'
; Calculate
p= 10.0 ^ ( -7.90298 * ( ts / t - 1.0 ) $
+ 5.02808 * alog10 ( ts / t ) $
- 1.3816e-7 * ( 10 ^ ( 11.344 * ( 1-ts/t ) ) -1 ) $
+ 8.1328e-3 * ( 10 ^ ( -3.4915 * ( ts/t-1 ) ) -1 ) $
+ alog10 ( ews ) )
return,p
end
-W.
--
William M Connolley | wmc@bas.ac.uk | http://www.antarctica.ac.uk/met/wmc/
Climate Modeller, British Antarctic Survey | Disclaimer: I speak for myself
I'm a .signature virus! copy me into your .signature file & help me spread!
|
|
|