OpenSWMM Engine  6.0.0-alpha.3
Data-oriented, plugin-extensible SWMM Engine (6.0.0-alpha.3)
Loading...
Searching...
No Matches
Global Subcatchments Methods

Global subcatchment methods. More...

Collaboration diagram for Global Subcatchments Methods:

Functions

int subcatch_readParams (int subcatchIndex, char *tok[], int ntoks)
 Reads subcatchment parameters from a tokenized line of input data.
 
int subcatch_readSubareaParams (char *tok[], int ntoks)
 Rreads subcatchment's subarea parameters from a tokenized line of input data.
 
int subcatch_readLanduseParams (char *tok[], int ntoks)
 Reads assignment of landuses to subcatchment from a tokenized line of input data.
 
int subcatch_readInitBuildup (char *tok[], int ntoks)
 Reads initial pollutant buildup on subcatchment from tokenized line of input data.
 
void subcatch_validate (int subcatchIndex)
 Checks for valid subcatchment input parameters.
 
void subcatch_initState (int subcatchIndex)
 Initializes state of a subcatchment.
 
void subcatch_setOldState (int subcatchIndex)
 Replaces old state of subcatchment with new state.
 
double subcatch_getFracPerv (int subcatchIndex)
 Determines what fraction of subcatchment area, including any LID area, is pervious.
 
double subcatch_getEvapRate (int subcatchIndex)
 Returns the potential evaporation rate for a subcatchment.
 
double subcatch_getStorage (int subcatchIndex)
 Finds total volume of water stored on a subcatchment's surface and its LIDs at the current time.
 
double subcatch_getDepth (int subcatchIndex)
 Finds average depth of water over the non-LID portion of a subcatchment.
 
void subcatch_getRunon (int subcatchIndex)
 Routes runoff from a subcatchment to its outlet subcatchment or between its subareas.
 
void subcatch_addRunonFlow (int subcatchIndex, double flow)
 Updates the total runon flow (ft/s) seen by a subcatchment that receives runon flow from an upstream subcatchment.
 
double subcatch_getRunoff (int subcatchIndex, double tStep)
 Computes runoff & new storage depth for subcatchment.
 
double subcatch_getWtdOutflow (int subcatchIndex, double wt)
 Computes weighted combination of old and new subcatchment runoff.
 
void subcatch_getResults (int subcatchIndex, double wt, float x[])
 Computes wtd. combination of old and new subcatchment results.
 

Detailed Description

Global subcatchment methods.

Function Documentation

◆ subcatch_addRunonFlow()

void subcatch_addRunonFlow ( int subcatchIndex,
double flow )

Updates the total runon flow (ft/s) seen by a subcatchment that receives runon flow from an upstream subcatchment.

Parameters
[in]subcatchIndexSubcatchment index
[in]flowRunon flow rate (cfs) to subcatchment subcatchIndex
Here is the caller graph for this function:

◆ subcatch_getDepth()

double subcatch_getDepth ( int subcatchIndex)

Finds average depth of water over the non-LID portion of a subcatchment.

Parameters
[in]subcatchIndexSubcatchment index
Returns
Returns average depth of ponded water (ft)
Here is the caller graph for this function:

◆ subcatch_getEvapRate()

double subcatch_getEvapRate ( int subcatchIndex)

Returns the potential evaporation rate for a subcatchment.

Parameters
[in]subcatchIndexSubcatchment index
Returns
Returns the externally prescribed PET rate (apiEvapRate) when set, otherwise the climate-derived Evap.rate subject to the DRY_ONLY option (ft/sec)

Returns the potential evaporation rate for a subcatchment.

Parameters
[in]subcatchIndexSubcatchment index

Returns the externally prescribed PET rate (apiEvapRate) when one has been set through the API; the prescribed rate is used as-is and bypasses the DRY_ONLY suppression and monthly adjustments already folded into Evap.rate. Otherwise returns the climate-derived Evap.rate subject to the DRY_ONLY option.

Here is the caller graph for this function:

◆ subcatch_getFracPerv()

double subcatch_getFracPerv ( int j)

Determines what fraction of subcatchment area, including any LID area, is pervious.

Parameters
[in]subcatchIndexSubcatchment index
Returns
Returns fraction of subcatchment area that is pervious cover
Here is the call graph for this function:
Here is the caller graph for this function:

◆ subcatch_getResults()

void subcatch_getResults ( int subcatchIndex,
double wt,
float x[] )

Computes wtd. combination of old and new subcatchment results.

Parameters
[in]subcatchIndexSubcatchment index
[in]wtWeighting factor
[out]xArray of subcatchment results
Here is the call graph for this function:

◆ subcatch_getRunoff()

double subcatch_getRunoff ( int subcatchIndex,
double tStep )

Computes runoff & new storage depth for subcatchment.

Parameters
[in]subcatchIndexSubcatchment index
[in]tStepTime step (sec)

The 'runoff' value returned by this function is the total runoff generated (in ft/sec) by the subcatchment before any internal re-routing is applied. It is used to compute pollutant washoff.

The 'outflow' value computed here (in cfs) is the surface runoff that actually leaves the subcatchment after any LID controls are applied and is saved to Subcatch[j].newRunoff.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ subcatch_getRunon()

void subcatch_getRunon ( int subcatchIndex)

Routes runoff from a subcatchment to its outlet subcatchment or between its subareas.

Parameters
[in]subcatchIndexSubcatchment index
Here is the call graph for this function:
Here is the caller graph for this function:

◆ subcatch_getStorage()

double subcatch_getStorage ( int subcatchIndex)

Finds total volume of water stored on a subcatchment's surface and its LIDs at the current time.

Parameters
[in]subcatchIndexSubcatchment index
Returns
Returns total volume of water stored on subcatchment's surface (ft3)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ subcatch_getWtdOutflow()

double subcatch_getWtdOutflow ( int subcatchIndex,
double f )

Computes weighted combination of old and new subcatchment runoff.

Parameters
[in]subcatchIndexSubcatchment index
[in]wtWeighting factor
Returns
Returns weighted runoff value (ft/sec)

◆ subcatch_initState()

void subcatch_initState ( int subcatchIndex)

Initializes state of a subcatchment.

Parameters
[in]subcatchIndexSubcatchment index
Here is the call graph for this function:
Here is the caller graph for this function:

◆ subcatch_readInitBuildup()

int subcatch_readInitBuildup ( char * tok[],
int ntoks )

Reads initial pollutant buildup on subcatchment from tokenized line of input data.

Parameters
[in]tokArray of string tokens
[in]ntoksNumber of tokens
Returns
Error code

Data has format: Subcatch pollut initLoad .... pollut initLoad

Here is the call graph for this function:

◆ subcatch_readLanduseParams()

int subcatch_readLanduseParams ( char * tok[],
int ntoks )

Reads assignment of landuses to subcatchment from a tokenized line of input data.

Parameters
[in]tokArray of string tokens
[in]ntoksNumber of tokens
Returns
Error code

Data has format: Subcatch landuse percent .... landuse percent

Here is the call graph for this function:

◆ subcatch_readParams()

int subcatch_readParams ( int subcatchIndex,
char * tok[],
int ntoks )

Reads subcatchment parameters from a tokenized line of input data.

Parameters
[in]subcatchIndexSubcatchment index
[in]tokArray of string tokens
[in]ntoksNumber of tokens
Returns
Error code

Data has format: Name RainGage Outlet Area Imperv Width Slope CurbLength Snowpack

Parameters
[in]subcatchIndexSubcatchment index
[in]tokArray of string tokens
[in]ntoksNumber of tokens
Returns
Error code

Data has format: Name RainGage Outlet Area Imperv Width Slope CurbLength [Snowpack] [RainScaleFactor] [SnowScaleFactor]

Snowpack (tok 8) may be given as "*" to hold the position when no snow pack is assigned but a scale factor follows (same convention the [RAINGAGES] FILE format uses for an omitted start date). RainScaleFactor (tok 9) and SnowScaleFactor (tok 10) default to 1.0.

Here is the call graph for this function:

◆ subcatch_readSubareaParams()

int subcatch_readSubareaParams ( char * tok[],
int ntoks )

Rreads subcatchment's subarea parameters from a tokenized line of input data.

Parameters
[in]tokArray of string tokens
[in]ntoksNumber of tokens
Returns
Error code

Data has format: Subcatch Imperv_N Perv_N Imperv_S Perv_S PctZero RouteTo (PctRouted)

Here is the call graph for this function:

◆ subcatch_setOldState()

void subcatch_setOldState ( int subcatchIndex)

Replaces old state of subcatchment with new state.

Parameters
[in]subcatchIndexSubcatchment index
Here is the call graph for this function:
Here is the caller graph for this function:

◆ subcatch_validate()

void subcatch_validate ( int subcatchIndex)

Checks for valid subcatchment input parameters.

Parameters
[in]subcatchIndexSubcatchment index
Here is the call graph for this function:
Here is the caller graph for this function: