water_vapor_pressure2specific_humidity

typhon.physics.water_vapor_pressure2specific_humidity(e, p)[source]

Convert water vapor pressure into specific humidity.

\[\mathrm{q} = \frac{0.622 \cdot e}{p - 0.378 \cdot e}\]
Parameters:
  • e (float or ndarray) – Water vapour pressure [Pa],

  • p (float or ndarray) – Pressure [Pa].

Returns:

specific humidity.

Return type:

float or ndarray

Examples

>>> water_vapor_pressure2specific_humidity(2338, 101300)
0.01448208036795962