mixing_ratio_from_relative_humidity¶
-
metpy.calc.
mixing_ratio_from_relative_humidity
(pressure, temperature, relative_humidity)[source]¶ Calculate the mixing ratio from relative humidity, temperature, and pressure.
- Parameters
pressure (
pint.Quantity
) – Total atmospheric pressuretemperature (
pint.Quantity
) – Air temperaturerelative_humidity (array_like) – The relative humidity expressed as a unitless ratio in the range [0, 1]. Can also pass a percentage if proper units are attached.
- Returns
pint.Quantity
– Mixing ratio (dimensionless)
Notes
Formula adapted from [Hobbs1977] pg. 74.
\[w = (rh)(w_s)\]\(w\) is mixing ratio
\(rh\) is relative humidity as a unitless ratio
\(w_s\) is the saturation mixing ratio
Changed in version 1.0: Changed signature from
(relative_humidity, temperature, pressure)