Expand description
§lake-elevation
Reservoir and lake elevation math: percent-of-pool, storage (acre-foot / cubic-meter) conversions, datum conversions (feet <-> meters), and the full-pool / conservation-pool calculations used by USACE, USGS, and Bureau of Reclamation reservoir operations.
The same math behind the LakeLevelNow water-level tracker.
Key conventions:
- Elevations are in feet or meters above a datum (e.g. NGVD29 / NAVD88).
- A reservoir’s conservation pool is the normal operating range between a minimum (dead/inactive pool) elevation and the full-pool (top of conservation) elevation.
- Percent of pool is the fraction of that usable range currently filled.
- Storage is measured in acre-feet (1 acre-foot = the volume covering 1 acre 1 ft deep, exactly 43,560 ft^3) or cubic meters (1 ft^3 = 0.028316846592 m^3, exact per 1959 international yard agreement: 1 ft = 0.3048 m exactly).
use lake_elevation::{percent_of_pool, feet_to_meters};
assert!((percent_of_pool(100.0, 0.0, 100.0) - 100.0).abs() < 1e-9); // at full pool
assert!((feet_to_meters(1.0) - 0.3048).abs() < 1e-12); // exact by definitionConstants§
- ACRE_
FEET_ PER_ CUBIC_ METER - Acre-feet per cubic meter (1 / (43,560 * 0.028316846592)).
- CUBIC_
FEET_ PER_ ACRE_ FOOT - Cubic feet in one acre-foot (43,560 exactly: 1 acre x 1 ft = 43,560 ft^2 x 1 ft).
- CUBIC_
METERS_ PER_ CUBIC_ FOOT - Cubic meters in one cubic foot (0.3048^3 = 0.028316846592 exactly, per 1959 yard agreement).
- FEET_
PER_ METER - Exact feet per meter (1 / 0.3048).
- METERS_
PER_ FOOT - Exact meters per foot under the 1959 international yard agreement (1 ft = 0.3048 m exactly).
Functions§
- acre_
feet_ to_ cubic_ meters - Convert acre-feet to cubic meters.
- conservation_
pool_ storage_ acre_ feet - Total conservation-pool storage (acre-feet) under the prismatic approximation.
- cubic_
meters_ to_ acre_ feet - Convert cubic meters to acre-feet.
- feet_
below_ full - Deficit to full pool in feet. Negative means the lake is above full (flood pool).
- feet_
to_ meters - Convert an elevation in feet to meters (exact: 1 ft = 0.3048 m).
- is_
below_ min_ pool - Whether the lake is below its minimum (inactive / dead) pool elevation.
- is_
in_ flood_ pool - Whether the lake is in its flood pool (above full / top of conservation).
- meters_
to_ feet - Convert an elevation in meters to feet (exact inverse).
- percent_
of_ pool - Percent of the conservation pool currently filled.
- shift_
datum_ feet - Apply a datum shift expressed in feet. A positive
offset_ftraises the elevation; e.g. converting NGVD29 -> NAVD88 on the US west coast often subtracts ~2-3 ft (negative offset). - shift_
datum_ meters - Apply a datum shift expressed in meters.
- storage_
in_ pool_ acre_ feet - Linear storage estimate within the conservation pool assuming a prismatic (constant
surface-area) approximation. Returns the approximate volume in acre-feet between
minandcurrent, capped atfullso a positive number never exceeds total storage.