WMS:WMLibSubBasin: Difference between revisions

From XMS Wiki
Jump to navigationJump to search
(Created page with "== Description == The '''public class SubBasin''' class manages hydrologic information for a sub-basin attached to an outlet point in the hydrologic tree. == Functions == *'''...")
 
No edit summary
 
(2 intermediate revisions by 2 users not shown)
Line 12: Line 12:


After HEC-1 has been run, you can get the hydrograph at a sub-basin by calling '''GetHydrograph''', which returns a list of time series points.
After HEC-1 has been run, you can get the hydrograph at a sub-basin by calling '''GetHydrograph''', which returns a list of time series points.
*'''public double GetPeakFlow()'''
After HEC-1 has been run, you can get the peak hydrograph flow for the sub-basin by calling this function.
*'''public System.DateTime GetPeakTime()'''
After HEC-1 has been run, you can get the time of the peak hydrograph flow for the sub-basin by calling this function.


*'''public void SetArea(double a_area)'''
*'''public void SetArea(double a_area)'''
Line 48: Line 56:


{{WMLibMain}}
{{WMLibMain}}
[[Category:WMLib|Sub]]

Latest revision as of 19:09, 11 January 2017

Description

The public class SubBasin class manages hydrologic information for a sub-basin attached to an outlet point in the hydrologic tree.

Functions

  • public SubBasin(WMLib.OutletPoint a_basinOutlet, double a_area, double a_timeConc, WMLib.RainfallData a_rainfallData, double a_curveNumber, string a_name)

This function is the constructor function for an instance of a SubBasin class. When creating a SubBasin, pass this function the following information: the outlet the sub-basin will be attached to (a_basinOutlet), the sub-basin area (a_area, square miles), the sub-basin time of concentration (a_timeConc, minutes), the sub-basin rainfall data (a_rainfallData), the sub-basin NRCS curve number (a_curveNumber), and the sub-basin name (a_name). A sub-basin will be created with the specified name and attached to the specified outlet point. The time of concentration is converted to a lag time using the SCS equation and is used in the HEC-1 SCS Unit Hydrograph method for computing a hydrograph for the sub-basin. See the example in the introduction as an example of how this function is used.

  • public System.Collections.Generic.List<TimeSeriesPoint> GetHydrograph()

After HEC-1 has been run, you can get the hydrograph at a sub-basin by calling GetHydrograph, which returns a list of time series points.

  • public double GetPeakFlow()

After HEC-1 has been run, you can get the peak hydrograph flow for the sub-basin by calling this function.

  • public System.DateTime GetPeakTime()

After HEC-1 has been run, you can get the time of the peak hydrograph flow for the sub-basin by calling this function.

  • public void SetArea(double a_area)

Set the area (square miles) for the sub-basin by calling this function.

  • public void SetCurveNumber(double a_curveNumber)

Set the curve number for the sub-basin by calling this function.

  • public void SetRainfallData(WMLib.RainfallData a_data)

Set the rainfall data for the sub-basin by calling this function. See the SubBasin constructor description and the RainfallData class for more information about the RainfallData.

  • public void SetTimeConc(double a_timeConc)

Set the time of concentration (minutes) for the sub-basin by calling this function.

Accessible Member Variables

  • public double m_area { get; private set; }

The area of the sub-basin, in square miles. You are allowed to get the value of this variable, but not to set it. Use SetArea to set the area or set it in the SubBasin constructor.

  • public double m_timeConc { get; private set; }

The time of concentration for the sub-basin, in minutes. You are allowed to get the value of this variable, but not to set it. Use SetTimeConc to set the time of concentration.

  • public double m_curveNumber { get; private set; }

The sub-basin curve number. You are allowed to get the value of this variable, but not to set it. Use SetCurveNumber to set the curve number.

  • public string m_name { get; private set; }

The name of the sub-basin. You are allowed to get the value of this variable, but not to set it.