Add docstrings for better readability

This commit is contained in:
XANTRONIX 2025-02-26 22:47:17 -05:00
parent c61846ea1c
commit a8d1e75216

View file

@ -21,8 +21,16 @@ def saturated_mixing_ratio(temp: float, pressure: float) -> float:
return 621.97 * (es / (pressure - es))
"""
Return the height, in meters, at which a parcel of the given temperature is
cooled to the given dewpoint.
"""
def lcl(temp: float, dewpoint: float) -> float:
return (temp - dewpoint) / 0.008
"""
Return the temperature of a parcel cooled at either the dry or moist lapse
rate for a given increase in height (in meters).
"""
def lapse(temp: float, rate: float, delta: float) -> float:
return temp - (rate * (delta / 1000))