Simplify pint unit conversion

master
Dan Howe 6 years ago
parent cfa82f4426
commit 2c36ff7a9d

@ -9,7 +9,7 @@ def _convert(x, length_scale_factor, from_unit, to_unit):
# Calculate unit conversion factor
from_unit = ureg(from_unit)
to_unit = ureg(to_unit)
unit_conversion_factor = (1 * from_unit).to(to_unit).magnitude
unit_conversion_factor = from_unit.to(to_unit).magnitude
# Define Froude scaling relationships
froude_l_exponent = 1

Loading…
Cancel
Save