| XSBaseRaw Class | 
 Inheritance Hierarchy
Inheritance HierarchyNamespace: DHI.Mike1D.CrossSectionModule
 Syntax
SyntaxThe XSBaseRaw type exposes the following members.
 Constructors
Constructors| Name | Description | |
|---|---|---|
|  | XSBaseRaw | 
            Constructor, making an open cross section.
             | 
|  | XSBaseRaw(Boolean) | 
            Constructor, making an open or closed cross section.
             | 
|  | XSBaseRaw(XSBaseRaw) | 
            Constructor, making a copy of the original cross section
             | 
 Properties
Properties| Name | Description | |
|---|---|---|
|  | Angle | 
            Angle of correction between perpendicular (to river) and cross section 
            orientation [radian].
             | 
|  | ApplyAngle | 
            Flag specifying whether to apply Angle of correction.
             | 
|  | AutoProcess | 
            Automatically calculate processed data if
            1) They are missing
            2) They are not up-to-date (ProcessedDataStatus is NotUpdated)
            (Inherited from XSBase.) | 
|  | BottomLevel | 
             Lowest level/depth of the processed data.
             Note: ProcessedLevels must be defined
            (Inherited from XSBase.) | 
|  | CrossSectionType | 
             Type of cross section
            (Inherited from XSBase.) | 
|  | EquidistantLevels | 
            Flag to indicate whether equidistant levels are used. 
            (Inherited from XSBase.) | 
|  | FlowDir | 
            Flow direction 
             | 
|  | FlowResistance | 
             Flow resistance. Contains information on flow resistance type 
             (ManningM or Chezy, Z dependence etc) and flow resistence values.
            (Inherited from XSBase.) | 
|  | HasProcessedData | (Inherited from XSBase.) | 
|  | Height | 
             Height of the cross section.
            (Inherited from XSBase.) | 
|  | Interpolated | 
            whether this cross section was generated from interpolation of neighboring
            cross sections
            (Overrides XSBaseInterpolated.) | 
|  | IsOpen | 
             Return true if cross section is open
             | 
|  | LeftCoordinateMarker | 
             Point at left side of the cross section where the coordinate marker is located.
             | 
|  | LeftLeveeBank | 
             Point at left side of the cross section where the left levee is located.
             | 
|  | LeftLowFlowBank | 
             Point at left side of the cross section where the lowest flow bank is located.
             | 
|  | LowestPoint | 
             Point at lowest part of the cross section.
             | 
|  | MaximumStorageWidth | 
             Maximum storage width of the cross section
            (Overrides XSBaseMaximumStorageWidth.) | 
|  | ModifiedFormulation | 
            Gets the Resistance Formulation that matches
            the GetResistanceFactor(Int32, Double) value.
            (Inherited from XSBase.) This is not necessarily the same as in FlowResistance. but can be different for several reasons: a) The raw and processed data differ, as for DarcyWeisbach. b) The resistance factors have been modified, and values used are those in ModifiedResistanceFactors. | 
|  | ModifiedResistanceFactors | 
             Modified resistance factors. These will be different than ProcessedResistanceFactors
             if one of the Multiply functions has been executed. This is matching the ModifiedFormulation(Inherited from XSBase.) | 
|  | MorphologicalDivision | 
            When MorphologicalDivisionType is Level,
            specifies the level of morphological division 
            (Inherited from XSBase.) For ST modeling only. Level is relative to raw data, and must not include any datum offset | 
|  | MorphologicalDivisionType | 
            Specifies the type of morphological division 
            that is applied.
            (Inherited from XSBase.) For ST modeling only. | 
|  | NumberOfProcessedLevels | 
            returns the number of processed levels (same as dimension of all processed data
            arrays). Returns 0 if processed data have not been calculated, yet.
            (Inherited from XSBase.) | 
|  | Points | 
             List of points defining polygon cross section.
             | 
|  | ProcessedAdditionalSurfaceAreas | 
             Processed additional storage area
            (Inherited from XSBase.) | 
|  | ProcessedAreas | 
             Processed geometric areas
            (Inherited from XSBase.) | 
|  | ProcessedDataProtected | 
            false: data are not protected and will be recomputed. 
            true: processed data are protected, data has been manually updated and will not be recomputed.
            (Inherited from XSBase.) | 
|  | ProcessedDataStatus | 
            ProcessingStatus defines the status of the processed data of this cross section.
            Whenever the user updates raw data of the cross section, its state must be changed
            to NotUpdated.
            (Inherited from XSBase.) | 
|  | ProcessedDerivatives | 
            Flag specifying whether processed derivatives are stored
            as processed data arrays, or calculated directly. If true,
            processed data arrays for the derivatives are created 
            (most accurate, smooth interpolation)
            (Inherited from XSBase.) | 
|  | ProcessedFlowAreas | 
             Processed flow areas
            (Inherited from XSBase.) | 
|  | ProcessedLevels | 
             Processed levels
            (Inherited from XSBase.) | 
|  | ProcessedRadii | 
             Processed radii
            (Inherited from XSBase.) | 
|  | ProcessedRadiiDerivatives | 
             Processed radii
            (Inherited from XSBase.) | 
|  | ProcessedResistanceFactors | 
             Processed resistance factors. Their type corresponds to the 
             Resistance formulation specified in FlowResistance.
            (Inherited from XSBase.) | 
|  | ProcessedStorageWidths | 
             Processed storage widths
            (Inherited from XSBase.) | 
|  | ProcessingLevelsSpecs | 
            Access to all level-related specifications for pre-processing of cross section
            data
            (Inherited from XSBase.) | 
|  | RadiusType | 
            some kind of hydraulic or resistance radius
             | 
|  | RelativeConveyanceCutoff | 
            If processed data has been modified to assure that conveyance
            never decrease with increasing water levels, this value indicates
            at which level (relative to height) that the change started.
            (Inherited from XSBase.) Only relevant for closed cross sections. Default value is 1. | 
|  | RightCoordinateMarker | 
             Point at right side of the cross section where the coordinate marker is located.
             | 
|  | RightLeveeBank | 
             Point at right side of the cross section where the right levee is located.
             | 
|  | RightLowFlowBank | 
             Point at right side of the cross section where the lowest flow bank is located.
             | 
|  | Selected | 
            whether this cross section is selected for some operation, e.g. saving.
             | 
|  | Symmetric | 
            Determines if the points in this cross sections makes up one side of a symmetric cross section
            Note: Not implemented yet
            Note: Not always possible.
             | 
|  | TopLevel | 
             Highest level/depth of the processed data. 
            (Inherited from XSBase.) | 
|  | TopoID | 
            The TopoID set that this cross section belongs to. TODO: See where for details?
            (Inherited from XSBase.) | 
 Methods
Methods| Name | Description | |
|---|---|---|
|  | AdjustProcessedLevels(Double) | 
             Adjust the processed levels. Used to ensure that _processedLevels[0] has a certain value
            (Inherited from XSBase.) | 
|  | AdjustProcessedLevelSpecs | 
             Adjust the processed level specification.
            (Inherited from XSBase.) | 
|  | BottomLevelFromCenter | 
            Return the bottom level of the cross section at a distance dx from 
            the center of the cross section. Throws an exception if dx is larger than 
            half the cross section width.
            (Overrides XSBaseBottomLevelFromCenter(Double).) | 
|  | CalculateProcessedData | 
            Calculate processed data
            (Overrides XSBaseCalculateProcessedData.) | 
|  | CalculateProcessedDataIfNeeded | 
            Calculate the processed levels, storage areas, radii, etc, ie, fill in all 
            ProcessedXXX properties if they are not up to date. Also called by getters for these properties if needed,
            so usually, this method doesn't have to be called explicitly.
            (Inherited from XSBase.) | 
|  | CheckProcessedData | 
            Validates that this cross sections is set up correctly.
            (Inherited from XSBase.) | 
|  | ClearOriginalProcessedData | 
            Clear any stored processed data arrays
            (Inherited from XSBase.) | 
|  | ClearZones | 
            clear section from vegetation and dead water, setting all zone info to Normal
             | 
|  | Clone | (Overrides XSBaseClone.) | 
|  | ConvertModifiedResistanceFactorsIfNecessary | 
            Converts the modified resistance data to another formulation. Returns false if the
            conversion could be performed. 
            Note: so far only few conversions are supported: 
            - from Manningsn to ManningsM;
            (Inherited from XSBase.) | 
|  | ConvertRelativeResistanceMultiZones | 
            Converts the ProcessedResistanceFactors according
            to a multizone set of absolute resistance values.
            
            Each input factor is applied between each level seperator, 
            the first factor from -infinity to the first level, the second factor
            from the first level to the second level, and the last factor
            from the last level to infinity, i.e., the levelSeperators defines where
            one factor takes over from the previous. 
            
            The factors array must be one longer than the levelSeperators array.
            
            The relative resistance factor is taken into account also.
            
            Results are stored in the ModifiedResistanceFactors
            and those are used in the calculation.
            (Inherited from XSBase.) | 
|  | CopyValuesToOther | 
            Copy the values of this cross section to another cross section
             | 
|  | CreateAllProcessedArrays | 
             Creates all processed data arrays with the given number of levels.
            (Inherited from XSBase.) | 
|   | CreateXSOpenCreateDefaultValues | 
            Creates a default cross section with 3 points, marked 1-3 from left to right,
            coordinates (0, 1); (1, 0); (2; 1). All points' resistance factors are set 
            to 1.0 and their zones are set to normal.
            The returned cross section is not made part of this collection.
             | 
|  | Equals | Determines whether the specified object is equal to the current object.(Inherited from Object.) | 
|  | Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.(Inherited from Object.) | 
|  | GetActualMorphologicalDivision | 
            Get actual morphological division or top of cross section if not defined.
            (Inherited from XSBase.) | 
|  | GetAdditionalSurfaceArea | 
            Additional storage area is a volume that the mass equation takes
            into account, but it does not influence the momentum equation. It
            could be a small pond next to the river that is filled/emptied as
            the water level in the river raises/falss.
            (Inherited from XSBase.) | 
|  | GetArea | 
            Return the cross sectional geometric area, 
            for index and fraction into the processed data. 
            (Inherited from XSBase.) | 
|  | GetAreaByIntegratingWidths | 
            Return the cross sectional geometric area, 
            integrating the storage widths
            (Inherited from XSBase.) | 
|  | GetCriticalDepth | 
            Gets the Critical depth for a given discharge - [m3/s]
            The critical depth is the depth where the flow changes 
            from supercritical to subcritical flow.
            (Inherited from XSBase.) | 
|  | GetCriticalDischarge | 
            Gets the Critical discharge for a given water level
            The critical discharge is the discharge where the flow changes 
            from supercritical to subcritical flow.
            (Inherited from XSBase.) | 
|  | GetFlowArea(Int32) | 
            Return the cross sectional flow area, 
            for index and fraction into the processed data. 
            
            This can be the total areas or the effective flow area
            hence the area does not necessarily correspond to the amount 
            of water in the system (volume)
            (Inherited from XSBase.) | 
|  | GetFlowArea(Int32, Double) | 
            Return the cross sectional flow area, 
            for index and fraction into the processed data. 
            
            This can be the total areas or the effective flow area
            hence the area does not necessarily correspond to the amount 
            of water in the system (volume)
            (Inherited from XSBase.) | 
|  | GetFlowAreaDerivative | 
            Get storagewidth as dA/dh from neighboring values in processed XS areas at waterLevel.
            (Inherited from XSBase.) | 
|  | GetHashCode | Serves as the default hash function. (Inherited from Object.) | 
|  | GetHydraulicRadius(Int32) | 
            Returns the hydraulic radius for index and fraction into the processed data
            (Inherited from XSBase.) | 
|  | GetHydraulicRadius(Int32, Double) | 
            Returns the hydraulic radius for index and fraction into the processed data
            (Inherited from XSBase.) | 
|  | GetHydraulicRadiusDerivative | 
            Get the derivate of the hydraulic radius for index and fraction into the processed data.
            (Inherited from XSBase.) | 
|  | GetLevelFromArea | 
            For a given area, find the level.
            (Inherited from XSBase.) | 
|  | GetLocalVelocity | 
            Calculates a local velocity for a given x along the cross sectional profile. The result must
            be divided by GetLocalVelocityFactor().
             The calculation is based on a parallel canal analysis, and if integrated up, matches the total discharge through the cross section. | 
|  | GetLocalVelocityFactor | 
            Calculate a local velocity factor for the provided water depth. This factor
            is used when calculating a transversally distributed flow velocity.
             | 
|  | GetLocalVelocityFactorFromIntegral | 
            Calculates the local velocity factor for use in GetLocalVelocity(Double, Double, Double).
             The method is seperated from the GetLocalVelocity(Double, Double, Double) method, since this can be an expensive method (integrating over the entire cross section), to be called once, and the result used many times by the GetLocalVelocity(Double, Double, Double) method. | 
|  | GetMarkerIndex | 
            Return index of a marker
             | 
|  | GetMarkerSequence | 
            Returns a sequence of markers and their indices.
             | 
|  | GetMarkersOfPoint | 
            For a given cross section point (at some index), return all markers on that point.
             | 
|  | GetMaximumValues | 
            Set maximum area, maximum hydraulic radius and maximum storage width.
            (Inherited from XSBase.) | 
|  | GetNaturalDepthOld | Obsolete. 
            Get the natural depth at a given discharge and slope
            (Inherited from XSBase.) | 
|  | GetResistanceFactor | 
            Returns the resistance factor. 
            (Inherited from XSBase.) | 
|  | GetResistanceFactorsDerivative | 
            Get the derivative of the resistance factor at the given water level
            (Inherited from XSBase.) | 
|  | GetStorageWidth(Int32) | 
            Returns the width from left bank to right bank for index and fraction into the processed data
            (Inherited from XSBase.) | 
|  | GetStorageWidth(Int32, Double) | 
            Returns the width from left bank to right bank for index and fraction into the processed data
            (Inherited from XSBase.) | 
|  | GetType | Gets the Type of the current instance.(Inherited from Object.) | 
|  | GetVolumeFromAdditionalSurfaceArea | 
            Return the integrated additional surface area from the bottom of the top slot to waterLevel
            (Inherited from XSBase.) | 
|  | InheritProcessedDataFrom | 
            Makes all processed data arrays point to the same arrays as in the other.
            (reference copy, not value copy)
            (Inherited from XSBase.) | 
|  | Initialize | 
             Calculate processed data if needed
            (Overrides XSBaseInitialize.) | 
|  | Level | 
            Get the actual processed level at the given index. Works
            regardless of the _equidistantLevels flag, 
            i.e., also when ProcessedLevels are not present. 
            
            Index must be between 0 and NumberOfProcessedLevels-1
            otherwise it will fail or give incorrect results
            (Inherited from XSBase.) | 
|  | MemberwiseClone | Creates a shallow copy of the current Object.(Inherited from Object.) | 
|  | Prepare | 
            Ensures that the resistance fomulation is not relative. If the resistance fomulation is 
            Mannings n it is changed to Mannings M and the data are changed accordingly if the resistance 
            formulation is Darcy Weisbach formulation and data are changed to Chezy.
            (Inherited from XSBase.) | 
|  | ProcessedLevel | 
            Get the raw processed level at the given index. Works
            regardless of the _equidistantLevels flag, 
            i.e., also when ProcessedLevels are not present. 
            
            Index must be between 0 and NumberOfProcessedLevels-1
            otherwise it will fail or give incorrect results
            (Inherited from XSBase.) | 
|  | RestoreModifiedResistanceFactors | 
            if Multiply... or Convert... or similar was called earlier, 
            reset the modified resistance factors 
            to the original processed resistance factors
            (Inherited from XSBase.) | 
|  | RestoreOriginalProcessedData | 
            Restores any stored processed data arrays previously 
            stored.
            (Inherited from XSBase.) | 
|  | SaveOriginalProcessedData | 
            Store the current processed data arrays (shallow copy). 
            If a set of original processed data already exists, the original 
            set is kept and not overwritten. 
            (Inherited from XSBase.) Updating the ProcessedLevels will still update the original processed data, unless new processed data has been provided, i.e. by using CreateAllProcessedArrays(Int32) or SetAllProcessedValues(Double, Double, Double, Double, Double, Double), due to the shallow copy. The original processed data arrays are kept when setting new processed data, using e.g. SetAllProcessedValues(Double, Double, Double, Double, Double, Double) | 
|  | SetAllProcessedValues | 
            set all the processed data (references to the member array).
            All values are in SI.
            (Inherited from XSBase.) | 
|  | SetMarkerAt | 
            Set a particular marker to a given 0-BASED index (within the list of points),
            or remove it (call with -1). If any other point had this marker before, it gets
            removed from that point.
            Throws IndexOutOfRangeException if list of points is empty or index is invalid.
             | 
|  | ToString | Returns a string that represents the current object.(Inherited from Object.) | 
|  | UpdateMarkersToDefaults | 
            clears the indicated existing markers and sets them to their default x location.
            (LeftLeveeBank: smallest x, RightLeveeBank: largest x, LowestPoint: x with
            the smallest z). Doesn't do anything for Circular, Rectangular.
             | 
|  | UpdatePointMarkerString | 
            Update the MarkerString for
            all cross section points with a marker. Used by the GUI.
             | 
|  | UpdatePointResistance | |
|  | Validate | 
            Validates the data. The constraints are that the levels and the areas after sorting must be monotonically increasing.
            (Overrides XSBaseValidate.) | 
 Fields
Fields| Name | Description | |
|---|---|---|
|  | _bAutoProcess | 
            Allow CalculateProcessedDataIfNeeded. Set to false to disable
            (Inherited from XSBase.) | 
|  | _bProcessedDataProtected | 
            false: data are not protected and will be recomputed. 
            true: processed data are protected, data has been manually updated and will not be recomputed.
            (Inherited from XSBase.) | 
|  | _crossSectionType | 
            Type of cross section.
            (Inherited from XSBase.) | 
|  | _distanceBetweenLevels | 
            The distance between levels if equidistant levels are ued.
            If equidistant levels are used, then getIndex and getFraction are faster.
            (Inherited from XSBase.) | 
|  | _equidistantLevels | 
            Flag to indicate whether equidistant levels are used. 
            If equidistant levels are used, then getIndex and getFraction are faster.
            Each derived cross section must set this flag to true (during construction), 
            if it does not store levels in the _processedLevels array.
            (Inherited from XSBase.) | 
|  | _flowResistance | 
            Flow resistance
            (Inherited from XSBase.) | 
|  | _height | (Inherited from XSBase.) | 
|  | _isInitialized | 
            Flag defining whether Initialize has been called.
            (Inherited from XSBase.) | 
|  | _isPrepared | 
            Flag defining whether Prepare(Diagnostics, HDParameterData, ILocation) has been called.
            (Inherited from XSBase.) | 
|  | _modifiedFormulation | 
            Flow resistance formulation
            (Inherited from XSBase.) | 
|  | _modifiedResistanceFactors | 
            Modified resistance factors. As default points to _processedResistanceFactors, 
            but during simulation contains resistance factors that are supported by the engine, which may
            differ from the original values.
            (Inherited from XSBase.) | 
|  | _modifiedResistanceFactorsDerivatives | 
            Processed resistance factor derivatives for the modified resistance factors.
            (Inherited from XSBase.) | 
|  | _numberOfProcessedLevels | 
            The number of processed levels
            (Inherited from XSBase.) | 
|  | _originalProcessedData | 
            A copy of original processed data, in case they have
            been modified by the engine during the simulation.
            (Inherited from XSBase.) | 
|  | _processedAdditionalSurfaceAreas | 
            Processed additional storage areas
            (Inherited from XSBase.) | 
|  | _processedAreas | 
            Processed geometric areas
            (Inherited from XSBase.) | 
|  | _processedCriticalDischarges | 
            Table with processed critical discharges, created automatically when required.
            (Inherited from XSBase.) | 
|  | _processedDataStatus | 
            ProcessingStatus defines the status of the processed data of this cross section.
            Whenever the user updates raw data of the cross section, its state must be changed
            to NotUpdated.
            (Inherited from XSBase.) | 
|  | _processedDerivatives | 
            Flag specifying whether processed derivatives are stored
            as processed data arrays, or calculated directly. If true,
            processed data arrays for the derivatives are created 
            (most accurate, smooth interpolation)
            (Inherited from XSBase.) | 
|  | _processedFlowAreas | 
            Processed flow ares
            (Inherited from XSBase.) | 
|  | _processedLevels | 
            Processed depths
            (Inherited from XSBase.) | 
|  | _processedRadii | 
            Processed radii
            (Inherited from XSBase.) | 
|  | _processedRadiiDerivatives | 
            Processed radius derivatives
            (Inherited from XSBase.) | 
|  | _processedResistanceFactors | 
            Processed resistance factors
            (Inherited from XSBase.) | 
|  | _processedStorageWidths | 
            Processed storage widths
            (Inherited from XSBase.) | 
|  | _resistenceDistri | 
            Resistance distribution
            (Inherited from XSBase.) | 
 Extension Methods
Extension Methods| Name | Description | |
|---|---|---|
|  | GetConveyance | 
            Get the conveyance at the specified processed level
            (Defined by CrossSectionExtensions.) | 
 See Also
See Also