Computer models are used extensively for water quality management and Total Maximum Daily Load studies.
Models are tools used to predict how a water body will respond to changes in the amount of pollution loading a river or stream receives. This helps us identify specific strategies and numerical loading requirements in our effort to meet clean water standards across the state.
We offer the following downloadable models for public use:
QUAL2KW is a modeling framework for simulating river and stream water quality.
- Version 6 — Non-steady, non-uniform flow using kinematic wave flow routing. Continuous simulation with time-varying boundary conditions for periods of up to one year with option to use repeating diel conditions similar to Version 5 but with either steady or non-steady flows. Has optional transient storage zones (surface and hyporheic transient storage zones).
- Version 5 — Steady flows with repeating diel boundary conditions.
- One dimensional. The channel is well-mixed vertically and laterally. Also includes up to two optional transient storage zones connected to each main channel reach (surface and hyporheic transient storage zones).
- Dynamic heat budget. The heat budget and temperature are simulated as a function of meteorology on a continuously varying or repeating diel time scale.
- Dynamic water quality kinetics. All water quality state variables are simulated on a continuously varying or repeating diel time scale for biogeochemical processes.
- Heat and mass inputs. Point and nonpoint loads and abstractions are simulated.
- Phytoplankton and bottom algae in the water column, as well as sediment diagenesis, and heterotrophic metabolism in the hyporheic zone are simulated.
- Variable stoichiometry. Luxury uptake of nutrients by the bottom algae (periphyton) is simulated with variable stoichiometry of N and P.
- Automatic calibration. Includes a genetic algorithm to automatically calibrate the kinetic rate parameters.
- Monte Carlo simulation. Ready-to-run simulations with either the YASAIw add-in (below) or Crystal Ball, including an example using YASAIw.
YASAIw is a Monte Carlo simulation add-in for Microsoft Excel. This add-in is a free open-source framework for Monte Carlo simulation. YASAIw is a modification of the original YASAI add-in that was developed by Rutgers University. The modified version adds several new features, including more distributions, correlated random variables, sensitivity analysis, and the ability to run user-defined macros during simulation. See an example using YASAIw with QUAL2Kw.
PIKAIA is a general purpose function optimization subroutine based on a genetic algorithm written in Excel/VBA. PIKAIA was originally developed in fortran by Charbonneau and Knapp.
Foodweb is a generalized modeling framework for bioaccumulation of hydrophobic organic chemicals in aquatic food webs. This Excel/VBA program is based on the model theory of Arnot and Gobas (2004).The present version builds on the model application that was developed by Condon (2007) for the Strait of Georgia, British Columbia.
SolRad is a solar position and solar radiation calculator for Excel/VBA.
Sunrise/Sunset is an Excel workbook with seven VBA functions for sunrise/sunset and solar position: dawn, sunrise, solar noon, sunset, dusk, solar azimuth, and solar elevation.
Shade is an Excel/VBA tool for estimating shade from riparian vegetation.
tTools for ArcGIS is an ArcMap Python add-in with tools that analyze stream-channel attributes and near-stream topography and vegetation to estimate effective shade inputs for use in temperature modeling programs. An older version of tTools for ArcGIS 9.x (Build 7.5.3) is also available for download.
rTemp is a simple model written in Excel/VBA to predict a time-series of water temperatures in response to heat fluxes determined by meteorological data, groundwater inflow, hyporheic exchange, and conduction between the water and sediment.
River Metabolism Analyzer (RMA) is an Excel workbook tool to apply four methods to analyze continuous monitoring data from a stream for stream metabolism and reaeration. This tool can be used to solve for gross primary production, respiration, reaeration, and limitation due to light, temperature, nutrients, and to predict response to parameter changes with the following methods:
- Delta method to solve for reaeration, gross primary production, and respiration.
- Night-time regression to solve for reaeration and respiration.
- Inverse modeling to solve for gross primary production, respiration, reaeration, light limitation, and temperature limitation.
- Predictive modeling to evaluate model response to changes in any model parameters, including nutrient limitation.
The "Delta method" was developed by Chapra and DiToro (1991)
as a way to estimate stream reaeration, primary production, and respiration from diel dissolved oxygen data. The Delta method is described in detail in Chapra (1997)
. This Excel/VBA program uses the algorithms of McBride and Chapra (2005)
to calculate the parameters of the Delta method. The nighttime regression method for estimation of reaeration and respiration is described by Grace and Imberger (2006). The inverse modeling method solves for up to five parameters of a simple model for dissolved oxygen and/or total inorganic carbon: maximum gross primary production, ecosystem respiration, reaeration, light limitation, and temperature limitation.
SedFlux is an Excel/VBA model of sediment nutrient fluxes and sediment oxygen demand from diagenesis based on a method that was originally developed by Dominic DiToro.
CO2SYS is an Excel/VBA calculator for the CO2 system in seawater. This program takes any two parameters of the CO2 system in seawater (alkalinity, total inorganic carbon, pH, and fugacity or partial pressure of CO2) and calculates the other two parameters for given input and output conditions of temperature and pressure. Calcium solubility is also calculated for both calcite and aragonite. This application is based on the original DOS program named CO2SYS by Lewis and Wallace (1998). The following versions, starting with the current version, are available for immediate download. Contact Greg Pelletier if you need a copy of an earlier version.
COARE — Coupled Ocean Atmosphere Response Experiment. Bulk air-sea heat flux algorithm, version 3.0b (Excel/VBA translation of Fortran 77 program from Chris Fairall's FTP site at NOAA).
Seawater properties — Properties of water (and seawater) for Excel/VBA, using the UNESCO equation of state. VBA functions include potential temperature (theta), in-situ density (rho), sigma-t, sigma-theta, thermal expansion coefficient (alpha), saline contraction coefficient (beta), compressibility, freezing temperature, and specific heat.
Manning's n calculator is an Excel/VBA program to calculate Manning's n (or depth) from cross-section data for trapezoidal or rectangular channels based on equation 14.32 in Chapra's Surface water quality modeling textbook.