earthkit.meteo.thermo.array.vapour_pressure_from_mixing_ratio

earthkit.meteo.thermo.array.vapour_pressure_from_mixing_ratio(w, p)

Compute the vapour pressure from mixing ratio.

Parameters:
  • w (number or array-like) – Mixing ratio (kg/kg)

  • p (number or array-like) – Pressure (Pa)

Returns:

Vapour pressure (Pa)

Return type:

number or array-like

The computation is based on the following formula:

\[e = \frac{pw}{\epsilon + w}\]

with \(\epsilon = R_{d}/R_{v}\) (see earthkit.meteo.constants.epsilon).