source: trunk/src/dew_temp_airt_rel_humidity_jv.pro @ 85

Last change on this file since 85 was 85, checked in by pinsard, 13 years ago

restart consolidation of paper01 software

  • Property svn:executable set to *
File size: 1.2 KB
Line 
1;+
2;
3; =============================
4; dew_temp_airt_rel_humidity_jv
5; =============================
6;
7; .. function:: 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 ${PROJECT_ID}
30;
31; coding rules
32;
33; EVOLUTIONS
34; ==========
35;
36; $Id$
37;
38; $URL$
39;
40; - fplod 20101214T093615Z aedon.locean-ipsl.upmc.fr (Darwin)
41;
42;   * minimal header
43;
44; - pbk 2008
45;
46;   * creation
47;
48;-
49function dew_temp_airt_rel_humidity_jv, t,td
50
51if (not keyword_set(t)) then t=28            ; air temperature in degC
52if (not keyword_set(td)) then td=23           ; dew point temperature in degC
53es0=6.11        ; reference saturation vapor pressure (hPa)
54
55;; calculating fields.  First saturation vapor pressure (Es) and
56;; actual vapor pressure are calculated.  The ratio (E/Es)*100
57;; gives the relative humidity
58
59e=es0*10^(7.5*td/(237.7+td))
60es=es0*10^(7.5*t/(237.7+T))
61
62rh=(e/es)*100
63;;;print, 'RH = ',rh
64
65return, rh
66
67end
Note: See TracBrowser for help on using the repository browser.