vmr2relative_humidity
- typhon.physics.vmr2relative_humidity(vmr, p, T, e_eq=None)[source]
Convert water vapor VMR into relative humidity.
\[\mathrm{RH} = \frac{x \cdot p}{e_s(T)}\]Note
By default, the relative humidity is calculated with respect to saturation over liquid water in accordance to the WMO standard for radiosonde observations. You can use
e_eq_mixed_mk()
to calculate relative humidity with respect to saturation over the mixed-phase following the IFS model documentation.- Parameters:
vmr (float or ndarray) – Volume mixing ratio,
p (float or ndarray) – Pressure [Pa].
T (float or ndarray) – Temperature [K].
e_eq (callable) – Function to calculate the equilibrium vapor pressure of water in Pa. The function must implement the signature
e_eq = f(T)
whereT
is temperature in Kelvin. IfNone
the functione_eq_water_mk()
is used.
- Returns:
Relative humidity [unitless].
- Return type:
float or ndarray
See also
relative_humidity2vmr()
Complement function (returns VMR for given RH).
e_eq_water_mk()
Used to calculate the equilibrium water vapor pressure.
Examples
>>> vmr2relative_humidity(0.025, 1013e2, 300) 0.71604995533615401