Skip to content
michaelnaderiPublic

About

This Julia code runs a Hetero-Functional Network minimum-cost flow optimization problem for Mono Lake, located in Northern California. The hetero-functional incidence matrice in the HFNMCF code is obtained through running provided HFGT XML file by HFGT-toolbox.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

3 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Mono Lake Hydrologic System — MBSE-HFGT Model

This repository contains the MBSE-HFGT (Model-Based Systems Engineering — Hetero-Functional Graph Theory) model of the Mono Lake hydrologic system. The model simulates the long-term water balance of Mono Lake under historical exogenous forcing (precipitation, temperature, Sierra Nevada gauged runoff) and anthropogenic withdrawals (export to Los Angeles, groundwater withdrawal). It accompanies the paper:

Naderi, M., Farid, A. M., & Schoonenberg, W. P. M. H. "A Hetero-Functional Graph Theory Approach to Modeling the Mono Lake Hydrologic System." Environmental Modelling & Software, 2026. https://doi.org/10.1016/j.envsoft.2026.106438


Table of Contents


Background

Mono Lake is a terminal saline lake located in the Eastern Sierra Nevada, California, at approximately 6,380 ft elevation. Since the 1940s, the Los Angeles Department of Water and Power (LADWP) has diverted water from streams that feed into the lake basin, causing a prolonged decline in lake volume and surface elevation. This diversion, combined with natural processes of evaporation, precipitation, and groundwater exchange, makes Mono Lake a canonical test case for integrated hydrological modeling under competing water demands.

This work applies Hetero-Functional Graph Theory (HFGT) — a systems-theoretic framework originally developed for engineering systems — to model the lake's dynamic water balance. HFGT represents a physical system as a network of resources acting on operands through discrete capabilities, enabling a rigorous, topology-aware state-space formulation. The Mono Lake System is cast as a Layered Flow Engineering System (LFES), with water as the sole operand flowing among two buffers (lake and aquifer) via six elementary processes.


Conceptual Model

The figure below illustrates the physical processes of the Mono Lake hydrologic system:

Conceptual illustration of the Mono Lake hydrologic system

The system is driven by two external (exogenous) inputs:

  • Precipitation falling directly onto the lake surface
  • Sierra Gauged Runoff entering via streams, reduced by the flow diverted to Los Angeles at the diversion point

Internal processes govern water redistribution between the lake and the underlying aquifer:

  • Percolation: slow downward seepage from the lake into the Mono Aquifer (rate proportional to lake volume)
  • Groundwater Discharge: return flow from the aquifer back to the lake (historically near zero)

Three outputs remove water from the system:

  • Evaporation: the dominant water loss pathway, modulated by lake surface area, salinity (specific gravity), and temperature
  • Groundwater Withdrawal: direct extraction from the aquifer for municipal and agricultural use
  • Export to LA: the diverted Sierra runoff that bypasses the lake entirely

MBSE Formalism: BDD and ACT Diagrams

The system is formally specified using SysML (Systems Modeling Language) as part of the MBSE workflow.

Block Definition Diagram (BDD)

The BDD defines the type hierarchy of the Mono Lake System within the HFGT ontology:

SysML BDD of the Mono Lake System

The top-level Engineering System decomposes into:

  • Operand L — the physical substance being processed. Here the single operand is Water, classified as a Physical Flow.
  • Resource R — the physical infrastructure that acts upon water. Resources are further classified as:
    • Buffer B_S — storage elements that hold the operand:
      • Transformation Resource M: the Lake (Mono Lake), which can change the state of water (accept inputs, eject evaporated water). Attributes include water volume, surface area, freshwater evaporation rate, total dissolved solids (TDS), and specific gravity.
      • Independent Buffer B: the Aquifer (Mono Aquifer), which stores water and supports groundwater withdrawal. Attributes include water volume and groundwater withdrawal rate.
    • Transportation Resource H — elements that move water between buffers without transforming it:
      • Percolator (Mono Lake Percolator): transports water downward from the lake to the aquifer at a rate proportional to lake volume.
      • Groundwater Discharger (Mono Groundwater Discharger): transports water upward from the aquifer back to the lake.

System instance blocks at the bottom of the BDD (Mono Lake : Lake, Mono Aquifer : Aquifer, etc.) bind the generic type definitions to the specific physical entities of the Mono Lake basin.

Activity Diagram (ACT)

The ACT specifies the six elementary capabilities (processes) of the system, allocated to the physical resources that execute them:

SysML ACT of the Mono Lake System

Process Capability Allocated Resource Direction
$u_1$ Accept precipitated water Mono Lake External → Lake
$u_2$ Accept water from flow past diversion point Mono Lake External → Lake
$u_3$ Eject evaporated water Mono Lake Lake → External
$u_4$ Withdraw water (groundwater) Mono Aquifer Aquifer → External
$u_5$ Transport water (percolation) Mono Lake Percolator Lake → Aquifer
$u_6$ Transport water (groundwater discharge) Mono Groundwater Discharger Aquifer → Lake

Exogenous inputs (Precipitation, Sierra Gauged Runoff) enter from the left; system outputs (Evaporated water, Groundwater Withdrawal, Exported water to LA) exit on the right. The join bars in the ACT depict synchronization of concurrent flows before they are processed.


Hetero-Functional Incidence Matrix

The six capabilities and two buffers yield a $2 \times 6$ hetero-functional incidence matrix $\mathbf{M}$ that encodes the directed topology of the system:

$$\mathbf{M} = \mathbf{M}^+ - \mathbf{M}^- = \begin{bmatrix} 1 & 1 & -1 & 0 & -1 & 1 \ 0 & 0 & 0 & -1 & 1 & -1 \end{bmatrix}$$

where rows correspond to buffers (Mono Lake, Mono Aquifer) and columns to capabilities $u_1, \ldots, u_6$. A $+1$ entry indicates that capability $u_j$ deposits water into buffer $b_i$; a $-1$ entry indicates withdrawal; $0$ indicates no direct interaction.

The discrete-time state transition is:

$$\mathbf{Q}_B(t + \Delta t) = \mathbf{Q}_B(t) + \mathbf{M} \cdot \mathbf{U}(t) \cdot \Delta t$$

where $\mathbf{Q}B \in \mathbb{R}^2$ is the vector of buffer volumes (in KAF) and $\mathbf{U}(t) \in \mathbb{R}^6{\geq 0}$ is the firing vector of process rates at time $t$.

Device Models

Several capabilities are governed by nonlinear device models that express the firing rate as a function of buffer state and exogenous inputs:

Capability Device Model
$u_1$ (Precipitation) $u_1 = r_{\text{precip}}(t) \cdot A_S(Q_{B,1})$
$u_2$ (Sierra Runoff) $u_2 = r_{\text{Sierra}}(t) - r_{\text{ExLA}}$
$u_3$ (Evaporation) $u_3 = \lambda_{\text{evap}}(Q_{B,1}, T(t)) \cdot A_S(Q_{B,1})$
$u_5$ (Percolation) $u_5 = \rho_{\text{perc}} \cdot Q_{B,1}$
$u_6$ (GW Discharge) $u_6 = 0$ (historically negligible)

The surface area $A_S$ and evaporation coefficient $\lambda_{\text{evap}}$ are themselves linearized functions of lake volume and temperature:

$$A_S = 0.008 \cdot Q_{B,1} + 15.44 \quad \text{(kilo-acres)}$$

$$\lambda_{\text{evap}} = \lambda_{\text{FW}} \cdot \eta_{\text{SG}}(Q_{B,1}) \cdot \eta_T(T)$$

where $\lambda_{\text{FW}} = 3.75$ ft/yr is the freshwater evaporation rate, $\eta_{\text{SG}}$ accounts for the suppression of evaporation by elevated salinity (specific gravity), and $\eta_T$ is a temperature scaling factor.


Repository Contents

MonoLake/
├── OptimizeMonoLake.jl       # Julia simulation script (JuMP + Gurobi)
├── MonoLake.xml              # HFGT system specification (LFES XML format)
├── ExogenousValues/          # Time-series data helpers (not shown)
│   └── calculateTimeSeries.jl
├── figures/
│   ├── MonoLake_conceptual.jpg   # Conceptual illustration of the hydrologic system
│   ├── MonoLake_BDD.jpg          # SysML Block Definition Diagram
│   └── MonoLake_ACT.jpg          # SysML Activity Diagram
├── LICENSE
└── README.md

OptimizeMonoLake.jl

The Julia simulation script sets up and solves the state-space model using JuMP with the Gurobi optimizer. It performs a feasibility-mode simulation (objective = 0) over a 100-year horizon with a quarterly time step ($\Delta t = 0.25$ yr, giving 400 time steps). Decision variables include buffer volumes $\mathbf{Q}_B$, firing vectors $\mathbf{U}$, and auxiliary state variables for surface area, specific gravity, and evaporation rate. The script enforces:

  • The HFGT state transition constraint at each time step
  • Initial conditions for lake volume (2,228 KAF) and aquifer volume (3,400,000 KAF)
  • Device models for all six capabilities
  • Non-negativity of all physical quantities

MonoLake.xml

The HFGT XML specification encodes the system topology in the Layered Flow Engineering System (LFES) schema. It lists each machine, transporter, operand, and method-pair abstraction. This file serves as the machine-readable input to the HFGT toolbox and was used to generate the hetero-functional incidence matrix $\mathbf{M}$ programmatically.


Model Parameters

Parameter Symbol Value Units
Simulation horizon $T$ 100 years
Time step $\Delta t$ 0.25 years
Initial lake volume $Q_{B,1}(0)$ 2,228 KAF
Initial aquifer volume $Q_{B,2}(0)$ 3,400,000 KAF
Export to LA $r_{\text{ExLA}}$ 16 KAF/yr
Groundwater withdrawal rate $r_{\text{GWwith}}$ 6,800 KAF/yr
Percolation rate coefficient $\rho_{\text{perc}}$ 0.01 yr⁻¹
Freshwater evaporation rate $\lambda_{\text{FW}}$ 3.75 ft/yr
Surface area: slope — 0.008 kacres/KAF
Surface area: intercept — 15.44 kacres
Specific gravity: slope — −5×10⁻⁵ (KAF)⁻¹
Specific gravity: intercept — 1.2 —
Evap. suppression: slope $\eta_{\text{SG}}$ slope −0.9 —
Evap. suppression: intercept $\eta_{\text{SG}}$ intercept 1.9 —
Temperature scaling: slope $\eta_T$ slope 0.06 °F⁻¹
Temperature scaling: intercept $\eta_T$ intercept −0.08 —

Running the Model

Prerequisites

  • Julia ≥ 1.9
  • JuMP.jl (Pkg.add("JuMP"))
  • Gurobi.jl — requires a valid Gurobi license (Pkg.add("Gurobi"))
  • Exogenous time-series data files (precipitation, temperature, Sierra gauged runoff) placed in ExogenousValues/

Execution

# From the Julia REPL or command line
julia OptimizeMonoLake.jl

The script prints the optimized buffer volume trajectories QB (KAF) and firing vectors U (KAF/yr) at each time step. Results can be post-processed to reproduce the lake level and salinity projections reported in the paper.

Note: The model uses Gurobi as its LP/QP solver. If Gurobi is unavailable, the optimizer can be replaced with an open-source alternative such as HiGHS (using HiGHS; model = Model(HiGHS.Optimizer)) for linear (non-nonlinear) variants, though some device model constraints involving bilinear products may require reformulation.


Citation

If you use this model or code in your research, please cite:

@article{naderi2026monolake,
  title   = {A Hetero-Functional Graph Theory Approach to Modeling
             the Mono Lake Hydrologic System},
  author  = {Naderi, Mehdi and Farid, Amro M. and
             Schoonenberg, Wester P. M. H.},
  journal = {Environmental Modelling \& Software},
  year    = {2026},
  doi     = {10.1016/j.envsoft.2026.106438},
  url     = {https://www.sciencedirect.com/science/article/pii/S1364815226003063}
}

Acknowledgments

This work was supported by the Thayer School of Engineering at Dartmouth College and the Marston Research Group. The authors gratefully acknowledge the Mono Lake Committee for publicly available lake-level and hydrological data, and the HFGT toolbox development team for the LFES XML schema.


License

MIT License — see LICENSE for details.

Copyright © 2026 Mehdi Naderi

About

This Julia code runs a Hetero-Functional Network minimum-cost flow optimization problem for Mono Lake, located in Northern California. The hetero-functional incidence matrice in the HFNMCF code is obtained through running provided HFGT XML file by HFGT-toolbox.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages