3 !------------------------------------------------------------------------------!
4 ! Collection of functions to compute h, p and t using standard atmosphere
5 ! t is the temperaure in K,
6 ! h is the height in m (h=0 at 1013.25hPa)
11 ! Vasiljevic et al. 1992: ECMWF 3D Variational data assimilation
12 ! of conventional observations
13 ! In proceedings of the ECMWF Workshop on Variational assimilation, with
14 ! special emphasis on three dimensional aspects. 9-12 November 1992, pp 389-435
16 ! F. VANDENBERGHE, March 2001
17 !------------------------------------------------------------------------------!
19 include 'constants.inc'
22 REAL, PARAMETER :: p_0 = 101325., & ! ICAO reference pressure Pa
23 t_0 = 288., & ! ICAO reference temperature K
24 lambda = 0.0065, & ! ICAO temperature lapse rate K/m
25 alpha = lambda * gasr / g ! ICAO constant (no unit)
27 REAL :: height_max_icao
31 !------------------------------------------------------------------------------!
32 FUNCTION t_from_h_icao (h) RESULT (t)
39 END FUNCTION t_from_h_icao
40 !------------------------------------------------------------------------------!
41 FUNCTION t_from_p_icao (p) RESULT (t)
46 t = t_0 *(p / p_0) ** alpha
48 END FUNCTION t_from_p_icao
49 !------------------------------------------------------------------------------!
50 FUNCTION h_from_p_icao (p) RESULT (h)
55 h = t_0 / lambda * (1. - (p / p_0) ** alpha)
57 END FUNCTION h_from_p_icao
58 !------------------------------------------------------------------------------!
59 FUNCTION p_from_h_icao (h) RESULT (p)
62 REAL :: p, h, one_over_alpha
64 one_over_alpha = 1. /alpha
66 p = p_0 * (1. - lambda * h / t_0)** one_over_alpha
68 END FUNCTION p_from_h_icao
69 !------------------------------------------------------------------------------!
70 END MODULE MODULE_ICAO