diff --git a/lib/xmet/thermo.py b/lib/xmet/thermo.py index c382794..c1424a9 100644 --- a/lib/xmet/thermo.py +++ b/lib/xmet/thermo.py @@ -101,7 +101,8 @@ def moist_lapse_rate(temp: float, pressure: float) -> float: def loft_parcel(start_temp: float, start_pressure: float, - lapse_rate: Callable): + lapse_rate: Callable, + step: float=10.0): """ Loft a parcel of air from a given pressure, at a given temperature, yielding a Tuple containing the temperature and pressure of that parcel @@ -136,7 +137,7 @@ def loft_parcel(start_temp: float, if pressure == PRESSURE_MIN: break - elif pressure - 10.0 < PRESSURE_MIN: + elif pressure - step < PRESSURE_MIN: pressure = PRESSURE_MIN else: - pressure -= 10.0 + pressure -= step