skip to main content
Water Quality : Reservoir Water Quality : Solution / Dispatching
Solution / Dispatching
Beginning of Water Quality Run
The function following functionality is executed one time at the beginning of the run. It is called from within beginning of run behavior on the Reservoir object.
• If using layered methods
– If modeling Temperature
1. Check for initial epilimnion and hypolimnion temperatures. If not input, then flag an error and exit
2. Check Specific Heat slot for input. If not input, then set to standard value of 4.186 KJ/g C.
3. Check Reservoir Geometry Coefficients for data. If not input, then execute utility method cubicFit.
4. Check Release Elevation, Reservoir Length, Thickness of Epilimnion, and Thickness of Metalimnion for input. If not input, then flag an error and exit.
5. If the Withdrawal Zone Coefficient is not valid, set it to 1.0.
6. Check for Air Temperature, Dewpoint Temperature, and Solar Radiation data. If data is incomplete, then flag error and exit.
7. If Wind Velocity data is incomplete, set is to zero
8. If Thermo Diffusion Coefficient Adjust data is incomplete, then fill values to 1.0.
9. If Diversion, Return Flow, or Inflow are not linked and not valid, set corresponding temperatures to zero.
10. For a Slope Power Reservoir, if Inflow2 is not linked and not valid, set corresponding temperatures to zero.
– If modeling Salinity
1. Check for initial epilimnion and hypolimnion salt concentrations. If not valid, then flag an error and exit.
2. If Diversion, Return Flow, or Inflow are not linked and not valid, set corresponding salt concentrations to zero.
3. For a Slope Power Reservoir, if Inflow2 is not linked and not valid, set corresponding salt mass to zero.
– If modeling Dissolved Oxygen,
1. check for initial epilimnion and hypolimnion detritus, dissolved organics, ammonia, and dissolved oxygen concentrations. If not input, then flag and error.
2. If Diversion, Return Flow, or Inflow are not linked and not valid, set corresponding detritus, dissolved organics, ammonia, and dissolved oxygen concentrations to zero.
3. Check for data in following slots: Detritus Parameters, Dissolved Organics Parameters, Ammonia Parameters, SOD Parameters, Photosynthesis Parameters, Respiration Parameters. If any data is missing, flag error and exit.
4. For a Slope Power Reservoir, if Inflow2 is not linked and not valid, set Inflow 2 detritus, dissolved organics, ammonia, and dissolved oxygen concentrations to zero.
• If using Well Mixed Salt method
1. Check for initial Reservoir Salt Concentration, initial Bank Storage Salt Concentration, and Dead Storage. If not input, then set to zero.
2. If Hydrologic Inflow Salt Concentration, Return Flow Salt Mass, or Diversion Salt Concentration are not linked and not input, then set to zero.
• If using Segmented 2 Layer method
1. Check the Agg Series Slots and Table slots to ensure they contain the number of rows or columns which correspond to the number of segments.
2. Check for initial Epilimnion Salt Concentration by Segment, Hypolimnion Salt Concentration by Segment, and initial Bank Storage Salt Concentration. If not input, then set to zero.
3. If Hydrologic Inflow Salt Concentration, Return Flow Salt Mass, or Diversion Salt Concentration are not linked and not input, then set to zero.
4. Check the Segment Parameters Table to ensure all proportions sum to 1.
5. Calculate initial values for Epilimnion Volume by Segment, Hypolimnion Volume by Segment, Bank Storage by Segment and Reservoir Salt Mass.
• If modeling TDG
1. Check for valid values in the slots: Tailwater Bottom Elevation, TDG c1, TDG Entrainment b1, TDG Entrainment b3, TDG Spill b2, TDG Spill and Turbine Release Limits.
2. If the Opt Outflow TDG Tailwater Depth is selected, make sure a valid Tailwater method is selected. See “Optimization Total Dissolved Gas category” for details.
Revised: 11/11/2019