Exemplo n.º 1
0
        private IEnumerable <OrderedDictionary> GetSectionsConfiguration()
        {
            var orderedDictionaries = new List <OrderedDictionary>();

            foreach (HydraRingCalculationInput hydraRingCalculationInput in hydraRingInputs)
            {
                HydraRingSection hydraRingSection = hydraRingCalculationInput.Section;

                orderedDictionaries.Add(new OrderedDictionary
                {
                    {
                        "SectionId", hydraRingSection.SectionId
                    },
                    {
                        "PresentationId", 1 // Fixed: no support for combination of multiple sections
                    },
                    {
                        "MainMechanismId", 1 // Fixed: no support for combination of multiple sections
                    },
                    {
                        "Name", hydraRingSection.SectionId // Just use the section id
                    },
                    {
                        "Description", hydraRingSection.SectionId // Just use the section id
                    },
                    {
                        "RingCoordinateBegin", defaultHydraRingValue // No support for coordinates
                    },
                    {
                        "RingCoordinateEnd", defaultHydraRingValue // No support for coordinates
                    },
                    {
                        "XCoordinate", defaultHydraRingValue // No support for coordinates
                    },
                    {
                        "YCoordinate", defaultHydraRingValue // No support for coordinates
                    },
                    {
                        "StationId1", hydraRingCalculationInput.HydraulicBoundaryLocationId
                    },
                    {
                        "StationId2", hydraRingCalculationInput.HydraulicBoundaryLocationId // Same as "StationId1": no support for coupling two hydraulic boundary locations
                    },
                    {
                        "Relative", 100.0 // Fixed: no support for coupling two hydraulic boundary locations
                    },
                    {
                        "Normal", GetHydraRingValue(hydraRingSection.CrossSectionNormal)
                    },
                    {
                        "Length", GetHydraRingValue(hydraRingSection.SectionLength)
                    }
                });
            }

            return(orderedDictionaries);
        }
Exemplo n.º 2
0
        /// <summary>
        /// Creates a new instance of the <see cref="PipingCalculationInput"/> class, taking into account the precense of a coverage layer.
        /// </summary>
        /// <param name="hydraulicBoundaryLocationId">The id of the hydraulic boundary location.</param>
        /// <param name="sectionLength">The length of the section.</param>
        /// <param name="phreaticLevelExitMean">The mean of the phreatic level at the exit point.</param>
        /// <param name="phreaticLevelExitStandardDeviation">The standard deviation of the phreatic level at the exit point.</param>
        /// <param name="waterVolumetricWeight">The volumetric weight of water.</param>
        /// <param name="effectiveThicknessCoverageLayerMean">The mean of the effective thickness of the coverage layers at the exit point.</param>
        /// <param name="effectiveThicknessCoverageLayerStandardDeviation">The standard deviation of the effective thickness of the coverage layers at the exit point.</param>
        /// <param name="saturatedVolumicWeightOfCoverageLayerMean">The mean of the volumic weight of the saturated coverage layer.</param>
        /// <param name="saturatedVolumicWeightOfCoverageLayerStandardDeviation">The standard deviation of the volumic weight of the saturated coverage layer.</param>
        /// <param name="saturatedVolumicWeightOfCoverageLayerShift">The shift of the volumic weight of the saturated coverage layer.</param>
        /// <param name="upliftModelFactorMean">The mean of the distribution used to account for uncertainty in the model for uplift.</param>
        /// <param name="upliftModelFactorStandardDeviation">The standard deviation of the distribution used to account for uncertainty in the model for uplift.</param>
        /// <param name="dampingFactorExitMean">The mean of the damping factor at the exit point.</param>
        /// <param name="dampingFactorExitStandardDeviation">The standard deviation of the damping factor at the exit point.</param>
        /// <param name="seepageLengthMean">The mean of the horizontal distance between entry and exit point.</param>
        /// <param name="seepageLengthCoefficientOfVariation">The coefficient of variation of the horizontal distance between entry and exit point.</param>
        /// <param name="thicknessAquiferLayerMean">The mean of the total thickness of the aquifer layers at the exit point.</param>
        /// <param name="thicknessAquiferLayerStandardDeviation">The standard deviation of the total thickness of the aquifer layers at the exit point.</param>
        /// <param name="sandParticlesVolumicWeight">The (lowerbound) volumic weight of sand grain material of a sand layer under water.</param>
        /// <param name="sellmeijerModelFactorMean">The mean of the distribution used to account for uncertainty in the model for Sellmeijer.</param>
        /// <param name="sellmeijerModelFactorStandardDeviation">The standard deviation of the distribution used to account for uncertainty in the model for Sellmeijer.</param>
        /// <param name="beddingAngle">The angle of the force balance representing the amount in which sand grains resist rolling.</param>
        /// <param name="whitesDragCoefficient">The White's drag coefficient.</param>
        /// <param name="waterKinematicViscosity">The kinematic viscosity of water at 10 °C.</param>
        /// <param name="darcyPermeabilityMean">The mean of the Darcy-speed with which water flows through the aquifer layer.</param>
        /// <param name="darcyPermeabilityCoefficientOfVariation">The coefficient of variation of the Darcy-speed with which water flows through the aquifer layer.</param>
        /// <param name="diameter70Mean">The mean of the sieve size through which 70% of the grains of the top part of the aquifer pass.</param>
        /// <param name="diameter70CoefficientOfVariation">The coefficient of variation of the sieve size through which 70% of the grains of the top part of the aquifer pass.</param>
        /// <param name="gravity">The gravitational acceleration.</param>
        /// <param name="criticalHeaveGradientMean">The mean of the critical exit gradient for heave.</param>
        /// <param name="criticalHeaveGradientStandardDeviation">The standard deviation of the critical exit gradient for heave.</param>
        public PipingCalculationInput(long hydraulicBoundaryLocationId,
                                      double sectionLength,
                                      double phreaticLevelExitMean, double phreaticLevelExitStandardDeviation,
                                      double waterVolumetricWeight,
                                      double effectiveThicknessCoverageLayerMean, double effectiveThicknessCoverageLayerStandardDeviation,
                                      double saturatedVolumicWeightOfCoverageLayerMean, double saturatedVolumicWeightOfCoverageLayerStandardDeviation,
                                      double saturatedVolumicWeightOfCoverageLayerShift,
                                      double upliftModelFactorMean, double upliftModelFactorStandardDeviation,
                                      double dampingFactorExitMean, double dampingFactorExitStandardDeviation,
                                      double seepageLengthMean, double seepageLengthCoefficientOfVariation,
                                      double thicknessAquiferLayerMean, double thicknessAquiferLayerStandardDeviation,
                                      double sandParticlesVolumicWeight,
                                      double sellmeijerModelFactorMean, double sellmeijerModelFactorStandardDeviation,
                                      double beddingAngle,
                                      double whitesDragCoefficient,
                                      double waterKinematicViscosity,
                                      double darcyPermeabilityMean, double darcyPermeabilityCoefficientOfVariation,
                                      double diameter70Mean, double diameter70CoefficientOfVariation,
                                      double gravity,
                                      double criticalHeaveGradientMean,
                                      double criticalHeaveGradientStandardDeviation)
            : base(hydraulicBoundaryLocationId)
        {
            hasCoverageLayer = true;

            Section = new HydraRingSection(1, sectionLength, double.NaN);
            this.phreaticLevelExitMean = phreaticLevelExitMean;
            this.phreaticLevelExitStandardDeviation = phreaticLevelExitStandardDeviation;
            this.waterVolumetricWeight = waterVolumetricWeight;
            this.effectiveThicknessCoverageLayerMean = effectiveThicknessCoverageLayerMean;
            this.effectiveThicknessCoverageLayerStandardDeviation       = effectiveThicknessCoverageLayerStandardDeviation;
            this.saturatedVolumicWeightOfCoverageLayerMean              = saturatedVolumicWeightOfCoverageLayerMean;
            this.saturatedVolumicWeightOfCoverageLayerStandardDeviation = saturatedVolumicWeightOfCoverageLayerStandardDeviation;
            this.saturatedVolumicWeightOfCoverageLayerShift             = saturatedVolumicWeightOfCoverageLayerShift;
            this.upliftModelFactorMean = upliftModelFactorMean;
            this.upliftModelFactorStandardDeviation = upliftModelFactorStandardDeviation;
            this.dampingFactorExitMean = dampingFactorExitMean;
            this.dampingFactorExitStandardDeviation = dampingFactorExitStandardDeviation;
            this.seepageLengthMean = seepageLengthMean;
            this.seepageLengthCoefficientOfVariation    = seepageLengthCoefficientOfVariation;
            this.thicknessAquiferLayerMean              = thicknessAquiferLayerMean;
            this.thicknessAquiferLayerStandardDeviation = thicknessAquiferLayerStandardDeviation;
            this.sandParticlesVolumicWeight             = sandParticlesVolumicWeight;
            this.sellmeijerModelFactorMean              = sellmeijerModelFactorMean;
            this.sellmeijerModelFactorStandardDeviation = sellmeijerModelFactorStandardDeviation;
            this.beddingAngle            = beddingAngle;
            this.whitesDragCoefficient   = whitesDragCoefficient;
            this.waterKinematicViscosity = waterKinematicViscosity;
            this.darcyPermeabilityMean   = darcyPermeabilityMean;
            this.darcyPermeabilityCoefficientOfVariation = darcyPermeabilityCoefficientOfVariation;
            this.diameter70Mean = diameter70Mean;
            this.diameter70CoefficientOfVariation = diameter70CoefficientOfVariation;
            this.gravity = gravity;
            this.criticalHeaveGradientMean = criticalHeaveGradientMean;
            this.criticalHeaveGradientStandardDeviation = criticalHeaveGradientStandardDeviation;
        }
Exemplo n.º 3
0
        public void Constructor_WithoutCoverageLayerParameters_ExpectedValues()
        {
            // Setup
            const int    hydraulicBoundaryLocationId = 1000;
            const double sectionLength         = 1.1;
            const double phreaticLevelExitMean = 2.2;
            const double phreaticLevelExitStandardDeviation = 3.3;
            const double waterVolumetricWeight = 4.4;
            const double upliftModelFactorMean = 10.0;
            const double upliftModelFactorStandardDeviation = 11.1;
            const double dampingFactorExitMean = 12.2;
            const double dampingFactorExitStandardDeviation = 13.3;
            const double seepageLengthMean = 14.4;
            const double seepageLengthCoefficientOfVariation    = 15.5;
            const double thicknessAquiferLayerMean              = 16.6;
            const double thicknessAquiferLayerStandardDeviation = 17.7;
            const double sandParticlesVolumicWeight             = 18.8;
            const double sellmeijerModelFactorMean              = 19.9;
            const double sellmeijerModelFactorStandardDeviation = 20.0;
            const double beddingAngle            = 21.1;
            const double whitesDragCoefficient   = 22.2;
            const double waterKinematicViscosity = 23.3;
            const double darcyPermeabilityMean   = 24.4;
            const double darcyPermeabilityCoefficientOfVariation = 25.5;
            const double diameter70Mean = 26.6;
            const double diameter70CoefficientOfVariation = 27.7;
            const double gravity = 28.8;
            const double criticalHeaveGradientMean = 29.9;
            const double criticalHeaveGradientStandardDeviation = 30.0;

            // Call
            var pipingCalculationInput = new PipingCalculationInput(
                hydraulicBoundaryLocationId, sectionLength, phreaticLevelExitMean, phreaticLevelExitStandardDeviation,
                waterVolumetricWeight, upliftModelFactorMean, upliftModelFactorStandardDeviation, dampingFactorExitMean,
                dampingFactorExitStandardDeviation, seepageLengthMean, seepageLengthCoefficientOfVariation,
                thicknessAquiferLayerMean, thicknessAquiferLayerStandardDeviation, sandParticlesVolumicWeight,
                sellmeijerModelFactorMean, sellmeijerModelFactorStandardDeviation, beddingAngle, whitesDragCoefficient,
                waterKinematicViscosity, darcyPermeabilityMean, darcyPermeabilityCoefficientOfVariation, diameter70Mean,
                diameter70CoefficientOfVariation, gravity, criticalHeaveGradientMean, criticalHeaveGradientStandardDeviation);

            // Assert
            Assert.IsInstanceOf <ExceedanceProbabilityCalculationInput>(pipingCalculationInput);
            Assert.AreEqual(1, pipingCalculationInput.CalculationTypeId);
            Assert.AreEqual(HydraRingFailureMechanismType.Piping, pipingCalculationInput.FailureMechanismType);
            Assert.AreEqual(58, pipingCalculationInput.VariableId);
            Assert.AreEqual(3014, pipingCalculationInput.FaultTreeModelId);
            Assert.AreEqual(hydraulicBoundaryLocationId, pipingCalculationInput.HydraulicBoundaryLocationId);
            HydraRingDataEqualityHelper.AreEqual(GetDefaultPipingVariables(false).ToArray(), pipingCalculationInput.Variables.ToArray());
            Assert.IsNaN(pipingCalculationInput.Beta);

            HydraRingSection hydraRingSection = pipingCalculationInput.Section;

            Assert.AreEqual(1, hydraRingSection.SectionId);
            Assert.AreEqual(sectionLength, hydraRingSection.SectionLength);
            Assert.IsNaN(hydraRingSection.CrossSectionNormal);
        }
Exemplo n.º 4
0
        public void Constructor_ExpectedValues()
        {
            // Call
            var hydraRingSection = new HydraRingSection(1, 2.2, 3.3);

            // Assert
            Assert.AreEqual(1, hydraRingSection.SectionId);
            Assert.AreEqual(2.2, hydraRingSection.SectionLength);
            Assert.AreEqual(3.3, hydraRingSection.CrossSectionNormal);
        }
Exemplo n.º 5
0
 /// <summary>
 /// Creates a new instance of the <see cref="StructuresOvertoppingCalculationInput"/> class.
 /// </summary>
 /// <param name="hydraulicBoundaryLocationId">The id of the hydraulic boundary location.</param>
 /// <param name="sectionNormal">The normal of the section.</param>
 /// <param name="forelandPoints">The foreland points.</param>
 /// <param name="breakWater">The break water.</param>
 /// <param name="gravitationalAcceleration">The gravitational acceleration.</param>
 /// <param name="modelFactorOvertoppingFlowMean">The mean of the model factor overtopping flow.</param>
 /// <param name="modelFactorOvertoppingFlowStandardDeviation">The standard deviation of the model factor overtopping flow.</param>
 /// <param name="levelCrestStructureMean">The mean of the crest level of the structure.</param>
 /// <param name="levelCrestStructureStandardDeviation">The standard deviation of the crest level of the structure.</param>
 /// <param name="structureNormalOrientation">The orientation of the normal of the structure.</param>
 /// <param name="modelFactorSuperCriticalFlowMean">The mean of the model factor super critical flow.</param>
 /// <param name="modelFactorSuperCriticalFlowStandardDeviation">The standard deviation of the model factor super critical flow.</param>
 /// <param name="allowedLevelIncreaseStorageMean">The mean of the allowed level of increase for storage.</param>
 /// <param name="allowedLevelIncreaseStorageStandardDeviation">The standard deviation of the allowed level of increase for storage.</param>
 /// <param name="modelFactorStorageVolumeMean">The mean of the model factor storage volume.</param>
 /// <param name="modelFactorStorageVolumeStandardDeviation">The standard deviation of the model factor storage volume.</param>
 /// <param name="storageStructureAreaMean">The mean of the storage structure area.</param>
 /// <param name="storageStructureAreaVariation">The variation of the storage structure area.</param>
 /// <param name="modelFactorInflowVolume">The model factor inflow volume.</param>
 /// <param name="flowWidthAtBottomProtectionMean">The mean of the flow width at bottom protection.</param>
 /// <param name="flowWidthAtBottomProtectionStandardDeviation">The standard deviation of the flow width at bottom protection.</param>
 /// <param name="criticalOvertoppingDischargeMean">The mean of the critical overtopping discharge.</param>
 /// <param name="criticalOvertoppingDischargeVariation">The variation of the critical overtopping discharge.</param>
 /// <param name="failureProbabilityStructureWithErosion">The failure probability structure with erosion.</param>
 /// <param name="widthFlowAperturesMean">The mean of the width flow apertures.</param>
 /// <param name="widthFlowAperturesStandardDeviation">The standard deviation of the width flow apertures.</param>
 /// <param name="deviationWaveDirection">The deviation of the wave direction.</param>
 /// <param name="stormDurationMean">The mean of the storm duration.</param>
 /// <param name="stormDurationVariation">The variation of the storm duration.</param>
 public StructuresOvertoppingCalculationInput(long hydraulicBoundaryLocationId,
                                              double sectionNormal,
                                              IEnumerable <HydraRingForelandPoint> forelandPoints,
                                              HydraRingBreakWater breakWater,
                                              double gravitationalAcceleration,
                                              double modelFactorOvertoppingFlowMean, double modelFactorOvertoppingFlowStandardDeviation,
                                              double levelCrestStructureMean, double levelCrestStructureStandardDeviation,
                                              double structureNormalOrientation,
                                              double modelFactorSuperCriticalFlowMean, double modelFactorSuperCriticalFlowStandardDeviation,
                                              double allowedLevelIncreaseStorageMean, double allowedLevelIncreaseStorageStandardDeviation,
                                              double modelFactorStorageVolumeMean, double modelFactorStorageVolumeStandardDeviation,
                                              double storageStructureAreaMean, double storageStructureAreaVariation,
                                              double modelFactorInflowVolume,
                                              double flowWidthAtBottomProtectionMean, double flowWidthAtBottomProtectionStandardDeviation,
                                              double criticalOvertoppingDischargeMean, double criticalOvertoppingDischargeVariation,
                                              double failureProbabilityStructureWithErosion,
                                              double widthFlowAperturesMean, double widthFlowAperturesStandardDeviation,
                                              double deviationWaveDirection,
                                              double stormDurationMean, double stormDurationVariation)
     : base(hydraulicBoundaryLocationId)
 {
     Section        = new HydraRingSection(1, double.NaN, sectionNormal);
     ForelandPoints = forelandPoints;
     BreakWater     = breakWater;
     this.gravitationalAcceleration      = gravitationalAcceleration;
     this.modelFactorOvertoppingFlowMean = modelFactorOvertoppingFlowMean;
     this.modelFactorOvertoppingFlowStandardDeviation = modelFactorOvertoppingFlowStandardDeviation;
     this.levelCrestStructureMean = levelCrestStructureMean;
     this.levelCrestStructureStandardDeviation          = levelCrestStructureStandardDeviation;
     this.structureNormalOrientation                    = structureNormalOrientation;
     this.modelFactorSuperCriticalFlowMean              = modelFactorSuperCriticalFlowMean;
     this.modelFactorSuperCriticalFlowStandardDeviation = modelFactorSuperCriticalFlowStandardDeviation;
     this.allowedLevelIncreaseStorageMean               = allowedLevelIncreaseStorageMean;
     this.allowedLevelIncreaseStorageStandardDeviation  = allowedLevelIncreaseStorageStandardDeviation;
     this.modelFactorStorageVolumeMean                  = modelFactorStorageVolumeMean;
     this.modelFactorStorageVolumeStandardDeviation     = modelFactorStorageVolumeStandardDeviation;
     this.storageStructureAreaMean        = storageStructureAreaMean;
     this.storageStructureAreaVariation   = storageStructureAreaVariation;
     this.modelFactorInflowVolume         = modelFactorInflowVolume;
     this.flowWidthAtBottomProtectionMean = flowWidthAtBottomProtectionMean;
     this.flowWidthAtBottomProtectionStandardDeviation = flowWidthAtBottomProtectionStandardDeviation;
     this.criticalOvertoppingDischargeMean             = criticalOvertoppingDischargeMean;
     this.criticalOvertoppingDischargeVariation        = criticalOvertoppingDischargeVariation;
     this.failureProbabilityStructureWithErosion       = failureProbabilityStructureWithErosion;
     this.widthFlowAperturesMean = widthFlowAperturesMean;
     this.widthFlowAperturesStandardDeviation = widthFlowAperturesStandardDeviation;
     this.deviationWaveDirection = deviationWaveDirection;
     this.stormDurationMean      = stormDurationMean;
     this.stormDurationVariation = stormDurationVariation;
 }
 /// <summary>
 /// Creates a new instance of the <see cref="OvertoppingCalculationInput"/> class.
 /// </summary>
 /// <param name="hydraulicBoundaryLocationId">The id of the hydraulic boundary location.</param>
 /// <param name="sectionNormal">The normal of the section.</param>
 /// <param name="profilePoints">The profile points.</param>
 /// <param name="forelandPoints">The foreland points.</param>
 /// <param name="breakWater">The break water.</param>
 /// <param name="dikeHeight">The dike height.</param>
 /// <param name="modelFactorCriticalOvertopping">The model factor critical overtopping.</param>
 /// <param name="factorFbMean">The mean of the factor Fb</param>
 /// <param name="factorFbStandardDeviation">The standard deviation of the factor Fb.</param>
 /// <param name="factorFbLowerBoundary">The lower boundary of the factor Fb.</param>
 /// <param name="factorFbUpperBoundary">The upper boundary of the factor Fb.</param>
 /// <param name="factorFnMean">The mean of the factor Fn.</param>
 /// <param name="factorFnStandardDeviation">The standard deviation of the factor Fn.</param>
 /// <param name="factorFnLowerBoundary">The lower boundary of the factor Fn.</param>
 /// <param name="factorFnUpperBoundary">The upper boundary of the factor Fn.</param>
 /// <param name="modelFactorOvertopping">The factor overtopping.</param>
 /// <param name="criticalOvertoppingMean">The mean of the critical overtopping.</param>
 /// <param name="criticalOvertoppingStandardDeviation">The standard deviation of the critical overtopping.</param>
 /// <param name="modelFactorFrunupMean">The mean of the factor frunup.</param>
 /// <param name="modelFactorFrunupStandardDeviation">The standard deviation of the factor frunup.</param>
 /// <param name="modelFactorFrunupLowerBoundary">The lower boundary of the factor frunup.</param>
 /// <param name="modelFactorFrunupUpperBoundary">The upper boundary of the factor frunup.</param>
 /// <param name="exponentModelFactorShallowMean">The mean of the exponent model factor shallow.</param>
 /// <param name="exponentModelFactorShallowStandardDeviation">The standard deviation of the exponent model factor shallow.</param>
 /// <param name="exponentModelFactorShallowLowerBoundary">The lower boundary of the exponent model factor shallow.</param>
 /// <param name="exponentModelFactorShallowUpperBoundary">The upper boundary of the exponent model factor shallow.</param>
 public OvertoppingCalculationInput(long hydraulicBoundaryLocationId,
                                    double sectionNormal,
                                    IEnumerable <HydraRingRoughnessProfilePoint> profilePoints,
                                    IEnumerable <HydraRingForelandPoint> forelandPoints,
                                    HydraRingBreakWater breakWater,
                                    double dikeHeight,
                                    double modelFactorCriticalOvertopping,
                                    double factorFbMean, double factorFbStandardDeviation,
                                    double factorFbLowerBoundary, double factorFbUpperBoundary,
                                    double factorFnMean, double factorFnStandardDeviation,
                                    double factorFnLowerBoundary, double factorFnUpperBoundary,
                                    double modelFactorOvertopping,
                                    double criticalOvertoppingMean, double criticalOvertoppingStandardDeviation,
                                    double modelFactorFrunupMean, double modelFactorFrunupStandardDeviation,
                                    double modelFactorFrunupLowerBoundary, double modelFactorFrunupUpperBoundary,
                                    double exponentModelFactorShallowMean, double exponentModelFactorShallowStandardDeviation,
                                    double exponentModelFactorShallowLowerBoundary, double exponentModelFactorShallowUpperBoundary)
     : base(hydraulicBoundaryLocationId)
 {
     Section         = new HydraRingSection(1, double.NaN, sectionNormal);
     ProfilePoints   = profilePoints;
     ForelandPoints  = forelandPoints;
     BreakWater      = breakWater;
     this.dikeHeight = dikeHeight;
     this.modelFactorCriticalOvertopping = modelFactorCriticalOvertopping;
     this.factorFbMean = factorFbMean;
     this.factorFbStandardDeviation = factorFbStandardDeviation;
     this.factorFbLowerBoundary     = factorFbLowerBoundary;
     this.factorFbUpperBoundary     = factorFbUpperBoundary;
     this.factorFnMean = factorFnMean;
     this.factorFnStandardDeviation                   = factorFnStandardDeviation;
     this.factorFnLowerBoundary                       = factorFnLowerBoundary;
     this.factorFnUpperBoundary                       = factorFnUpperBoundary;
     this.modelFactorOvertopping                      = modelFactorOvertopping;
     this.criticalOvertoppingMean                     = criticalOvertoppingMean;
     this.criticalOvertoppingStandardDeviation        = criticalOvertoppingStandardDeviation;
     this.modelFactorFrunupMean                       = modelFactorFrunupMean;
     this.modelFactorFrunupStandardDeviation          = modelFactorFrunupStandardDeviation;
     this.modelFactorFrunupLowerBoundary              = modelFactorFrunupLowerBoundary;
     this.modelFactorFrunupUpperBoundary              = modelFactorFrunupUpperBoundary;
     this.exponentModelFactorShallowMean              = exponentModelFactorShallowMean;
     this.exponentModelFactorShallowStandardDeviation = exponentModelFactorShallowStandardDeviation;
     this.exponentModelFactorShallowLowerBoundary     = exponentModelFactorShallowLowerBoundary;
     this.exponentModelFactorShallowUpperBoundary     = exponentModelFactorShallowUpperBoundary;
 }
Exemplo n.º 7
0
 /// <summary>
 /// Creates a new instance of <see cref="StructuresClosureCalculationInput"/>.
 /// </summary>
 /// <param name="hydraulicBoundaryLocationId">The id of the hydraulic boundary location.</param>
 /// <param name="sectionNormal">The normal of the section.</param>
 /// <param name="forelandPoints">The foreland points.</param>
 /// <param name="breakWater">The break water.</param>
 /// <param name="gravitationalAcceleration">The gravitational acceleration.</param>
 /// <param name="factorStormDurationOpenStructure">The factor of the storm duration for an open structure.</param>
 /// <param name="failureProbabilityOpenStructure">The failure probability for an open structure.</param>
 /// <param name="failureProbabilityReparation">The reparation failure probability.</param>
 /// <param name="identicalApertures">The number of identical apertures.</param>
 /// <param name="allowedLevelIncreaseStorageMean">The mean of the allowed level of increase for storage.</param>
 /// <param name="allowedLevelIncreaseStorageStandardDeviation">The standard deviation of the allowed level of increase for storage.</param>
 /// <param name="modelFactorStorageVolumeMean">The mean of the model factor storage volume.</param>
 /// <param name="modelFactorStorageVolumeStandardDeviation">The standard deviation of the model factor storage volume.</param>
 /// <param name="storageStructureAreaMean">The mean of the storage structure area.</param>
 /// <param name="storageStructureAreaVariation">The variation of the storage structure area.</param>
 /// <param name="modelFactorInflowVolume">The model factor inflow volume.</param>
 /// <param name="flowWidthAtBottomProtectionMean">The mean of the flow width at bottom protection.</param>
 /// <param name="flowWidthAtBottomProtectionStandardDeviation">The standard deviation of the flow width at bottom protection.</param>
 /// <param name="criticalOvertoppingDischargeMean">The mean of the critical overtopping discharge.</param>
 /// <param name="criticalOvertoppingDischargeVariation">The variation of the critical overtopping discharge.</param>
 /// <param name="failureProbabilityStructureWithErosion">The failure probability structure with erosion.</param>
 /// <param name="stormDurationMean">The mean of the storm duration.</param>
 /// <param name="stormDurationVariation">The variation of the storm duration.</param>
 /// <param name="probabilityOpenStructureBeforeFlooding">The probability of an open structure before flooding.</param>
 protected StructuresClosureCalculationInput(long hydraulicBoundaryLocationId,
                                             double sectionNormal,
                                             IEnumerable <HydraRingForelandPoint> forelandPoints,
                                             HydraRingBreakWater breakWater,
                                             double gravitationalAcceleration,
                                             double factorStormDurationOpenStructure,
                                             double failureProbabilityOpenStructure,
                                             double failureProbabilityReparation,
                                             int identicalApertures,
                                             double allowedLevelIncreaseStorageMean, double allowedLevelIncreaseStorageStandardDeviation,
                                             double modelFactorStorageVolumeMean, double modelFactorStorageVolumeStandardDeviation,
                                             double storageStructureAreaMean, double storageStructureAreaVariation,
                                             double modelFactorInflowVolume,
                                             double flowWidthAtBottomProtectionMean, double flowWidthAtBottomProtectionStandardDeviation,
                                             double criticalOvertoppingDischargeMean, double criticalOvertoppingDischargeVariation,
                                             double failureProbabilityStructureWithErosion,
                                             double stormDurationMean, double stormDurationVariation,
                                             double probabilityOpenStructureBeforeFlooding)
     : base(hydraulicBoundaryLocationId)
 {
     Section        = new HydraRingSection(1, double.NaN, sectionNormal);
     ForelandPoints = forelandPoints;
     BreakWater     = breakWater;
     this.gravitationalAcceleration        = gravitationalAcceleration;
     this.factorStormDurationOpenStructure = factorStormDurationOpenStructure;
     this.failureProbabilityOpenStructure  = failureProbabilityOpenStructure;
     this.failureProbabilityReparation     = failureProbabilityReparation;
     this.identicalApertures = identicalApertures;
     this.allowedLevelIncreaseStorageMean = allowedLevelIncreaseStorageMean;
     this.allowedLevelIncreaseStorageStandardDeviation = allowedLevelIncreaseStorageStandardDeviation;
     this.modelFactorStorageVolumeMean = modelFactorStorageVolumeMean;
     this.modelFactorStorageVolumeStandardDeviation = modelFactorStorageVolumeStandardDeviation;
     this.storageStructureAreaMean        = storageStructureAreaMean;
     this.storageStructureAreaVariation   = storageStructureAreaVariation;
     this.modelFactorInflowVolume         = modelFactorInflowVolume;
     this.flowWidthAtBottomProtectionMean = flowWidthAtBottomProtectionMean;
     this.flowWidthAtBottomProtectionStandardDeviation = flowWidthAtBottomProtectionStandardDeviation;
     this.criticalOvertoppingDischargeMean             = criticalOvertoppingDischargeMean;
     this.criticalOvertoppingDischargeVariation        = criticalOvertoppingDischargeVariation;
     this.failureProbabilityStructureWithErosion       = failureProbabilityStructureWithErosion;
     this.stormDurationMean      = stormDurationMean;
     this.stormDurationVariation = stormDurationVariation;
     this.probabilityOpenStructureBeforeFlooding = probabilityOpenStructureBeforeFlooding;
 }
        /// <summary>
        /// Creates a new instance of the <see cref="WaveConditionsCalculationInput"/> class.
        /// </summary>
        /// <param name="sectionId">The id of the section.</param>
        /// <param name="sectionNormal">The normal of the section.</param>
        /// <param name="hydraulicBoundaryLocationId">The id of the hydraulic boundary location.</param>
        /// <param name="targetProbability">The target probability.</param>
        /// <param name="forelandPoints">The foreland points.</param>
        /// <param name="breakWater">The break water.</param>
        /// <param name="waterLevel">The water level to calculate the wave conditions for.</param>
        /// <param name="a">The a-value.</param>
        /// <param name="b">The b-value.</param>
        /// <remarks>As a part of the constructor, the <paramref name="targetProbability"/> is automatically converted into a reliability index.</remarks>
        protected WaveConditionsCalculationInput(int sectionId,
                                                 double sectionNormal,
                                                 long hydraulicBoundaryLocationId,
                                                 double targetProbability,
                                                 IEnumerable <HydraRingForelandPoint> forelandPoints,
                                                 HydraRingBreakWater breakWater,
                                                 double waterLevel,
                                                 double a,
                                                 double b)
            : base(hydraulicBoundaryLocationId)
        {
            Section        = new HydraRingSection(sectionId, double.NaN, sectionNormal);
            Beta           = StatisticsConverter.ProbabilityToReliability(targetProbability);
            ForelandPoints = forelandPoints;
            BreakWater     = breakWater;

            this.waterLevel = waterLevel;
            this.a          = a;
            this.b          = b;
        }
        public void Constructor_ExpectedValues()
        {
            // Setup
            const double targetProbability           = 1.0 / 10000;
            const int    sectionId                   = 1;
            const long   hydraulicBoundaryLocationId = 1234;

            // Call
            var waveHeightCalculationInput = new WaveHeightCalculationInput(sectionId, hydraulicBoundaryLocationId, targetProbability);

            // Assert
            double expectedBeta = StatisticsConverter.ProbabilityToReliability(targetProbability);

            Assert.IsInstanceOf <ReliabilityIndexCalculationInput>(waveHeightCalculationInput);
            Assert.AreEqual(HydraRingFailureMechanismType.WaveHeight, waveHeightCalculationInput.FailureMechanismType);
            Assert.AreEqual(9, waveHeightCalculationInput.CalculationTypeId);
            Assert.AreEqual(28, waveHeightCalculationInput.VariableId);
            Assert.AreEqual(11, waveHeightCalculationInput.FaultTreeModelId);
            Assert.AreEqual(hydraulicBoundaryLocationId, waveHeightCalculationInput.HydraulicBoundaryLocationId);
            Assert.IsNotNull(waveHeightCalculationInput.Section);
            CollectionAssert.IsEmpty(waveHeightCalculationInput.ProfilePoints);
            CollectionAssert.IsEmpty(waveHeightCalculationInput.ForelandPoints);
            Assert.IsNull(waveHeightCalculationInput.BreakWater);
            Assert.AreEqual(expectedBeta, waveHeightCalculationInput.Beta);

            HydraRingSection section = waveHeightCalculationInput.Section;

            Assert.AreEqual(sectionId, section.SectionId);
            Assert.IsNaN(section.SectionLength);
            Assert.IsNaN(section.CrossSectionNormal);

            HydraRingVariable[] variables = waveHeightCalculationInput.Variables.ToArray();
            Assert.AreEqual(1, variables.Length);
            HydraRingVariable waveHeightVariable = variables.First();

            Assert.IsInstanceOf <DeterministicHydraRingVariable>(waveHeightVariable);
            Assert.AreEqual(28, waveHeightVariable.VariableId);
            Assert.AreEqual(0.0, waveHeightVariable.Value);
        }
Exemplo n.º 10
0
        public void Constructor_ExpectedValues()
        {
            // Setup
            const double targetProbability           = 1.0 / 10000;
            const int    sectionId                   = 1;
            const long   hydraulicBoundaryLocationId = 1234;

            // Call
            var dunesBoundaryConditionsCalculationInput = new DunesBoundaryConditionsCalculationInput(sectionId, hydraulicBoundaryLocationId, targetProbability);

            // Assert
            double expectedBeta = StatisticsConverter.ProbabilityToReliability(targetProbability);

            Assert.IsInstanceOf <AssessmentLevelCalculationInput>(dunesBoundaryConditionsCalculationInput);
            Assert.AreEqual(HydraRingFailureMechanismType.DunesBoundaryConditions, dunesBoundaryConditionsCalculationInput.FailureMechanismType);
            Assert.AreEqual(2, dunesBoundaryConditionsCalculationInput.CalculationTypeId);
            Assert.AreEqual(26, dunesBoundaryConditionsCalculationInput.VariableId);
            Assert.AreEqual(8, dunesBoundaryConditionsCalculationInput.FaultTreeModelId);
            Assert.AreEqual(hydraulicBoundaryLocationId, dunesBoundaryConditionsCalculationInput.HydraulicBoundaryLocationId);
            Assert.IsNotNull(dunesBoundaryConditionsCalculationInput.Section);
            CollectionAssert.IsEmpty(dunesBoundaryConditionsCalculationInput.ProfilePoints);
            CollectionAssert.IsEmpty(dunesBoundaryConditionsCalculationInput.ForelandPoints);
            Assert.IsNull(dunesBoundaryConditionsCalculationInput.BreakWater);
            Assert.AreEqual(expectedBeta, dunesBoundaryConditionsCalculationInput.Beta);

            HydraRingSection section = dunesBoundaryConditionsCalculationInput.Section;

            Assert.AreEqual(sectionId, section.SectionId);
            Assert.IsNaN(section.SectionLength);
            Assert.IsNaN(section.CrossSectionNormal);

            HydraRingVariable[] hydraRingVariables = dunesBoundaryConditionsCalculationInput.Variables.ToArray();
            Assert.AreEqual(1, hydraRingVariables.Length);
            HydraRingVariable waterLevelVariable = hydraRingVariables.First();

            Assert.IsInstanceOf <DeterministicHydraRingVariable>(waterLevelVariable);
            Assert.AreEqual(26, waterLevelVariable.VariableId);
            Assert.AreEqual(0.0, waterLevelVariable.Value);
        }
        public void Constructor_Always_ExpectedValues()
        {
            // Setup
            const int hydraulicBoundaryLocationId = 1000;

            const double sectionNormal = 22.2;
            const double dikeHeight    = 1.1;
            const double modelFactorCriticalOvertopping = 2.2;
            const double factorFbMean = 3.3;
            const double factorFbStandardDeviation = 4.4;
            const double factorFbLowerBoundary     = 14.4;
            const double factorFbUpperBoundary     = 15.5;
            const double factorFnMean = 5.5;
            const double factorFnStandardDeviation                   = 6.6;
            const double factorFnLowerBoundary                       = 16.6;
            const double factorFnUpperBoundary                       = 17.7;
            const double modelFactorOvertopping                      = 7.7;
            const double criticalOvertoppingMean                     = 8.8;
            const double criticalOvertoppingStandardDeviation        = 9.9;
            const double modelFactorFrunupMean                       = 10.0;
            const double modelFactorFrunupStandardDeviation          = 11.1;
            const double modelFactorFrunupLowerBoundary              = 18.8;
            const double modelFactorFrunupUpperBoundary              = 19.9;
            const double exponentModelFactorShallowMean              = 12.2;
            const double exponentModelFactorShallowStandardDeviation = 13.3;
            const double exponentModelFactorShallowLowerBoundary     = 20.0;
            const double exponentModelFactorShallowUpperBoundary     = 21.1;

            var expectedRingProfilePoints = new List <HydraRingRoughnessProfilePoint>
            {
                new HydraRingRoughnessProfilePoint(1.1, 2.2, 3.3)
            };
            var expectedRingForelandPoints = new List <HydraRingForelandPoint>
            {
                new HydraRingForelandPoint(2.2, 3.3)
            };
            var expectedRingBreakWater = new HydraRingBreakWater(2, 3.3);

            // Call
            var overtoppingCalculationInput = new OvertoppingCalculationInput(
                hydraulicBoundaryLocationId, sectionNormal,
                expectedRingProfilePoints, expectedRingForelandPoints, expectedRingBreakWater,
                dikeHeight,
                modelFactorCriticalOvertopping,
                factorFbMean, factorFbStandardDeviation,
                factorFbLowerBoundary, factorFbUpperBoundary,
                factorFnMean, factorFnStandardDeviation,
                factorFnLowerBoundary, factorFnUpperBoundary,
                modelFactorOvertopping,
                criticalOvertoppingMean, criticalOvertoppingStandardDeviation,
                modelFactorFrunupMean, modelFactorFrunupStandardDeviation,
                modelFactorFrunupLowerBoundary, modelFactorFrunupUpperBoundary,
                exponentModelFactorShallowMean, exponentModelFactorShallowStandardDeviation,
                exponentModelFactorShallowLowerBoundary, exponentModelFactorShallowUpperBoundary);

            // Assert
            Assert.IsInstanceOf <ExceedanceProbabilityCalculationInput>(overtoppingCalculationInput);
            Assert.AreEqual(1, overtoppingCalculationInput.CalculationTypeId);
            Assert.AreEqual(HydraRingFailureMechanismType.DikesOvertopping, overtoppingCalculationInput.FailureMechanismType);
            Assert.AreEqual(1, overtoppingCalculationInput.VariableId);
            Assert.AreEqual(1017, overtoppingCalculationInput.FaultTreeModelId);
            Assert.AreEqual(hydraulicBoundaryLocationId, overtoppingCalculationInput.HydraulicBoundaryLocationId);
            HydraRingDataEqualityHelper.AreEqual(GetDefaultOvertoppingVariables().ToArray(), overtoppingCalculationInput.Variables.ToArray());
            CollectionAssert.AreEqual(expectedRingProfilePoints, overtoppingCalculationInput.ProfilePoints);
            CollectionAssert.AreEqual(expectedRingForelandPoints, overtoppingCalculationInput.ForelandPoints);
            Assert.AreEqual(expectedRingBreakWater, overtoppingCalculationInput.BreakWater);
            Assert.IsNaN(overtoppingCalculationInput.Beta);

            HydraRingSection hydraRingSection = overtoppingCalculationInput.Section;

            Assert.AreEqual(1, hydraRingSection.SectionId);
            Assert.IsNaN(hydraRingSection.SectionLength);
            Assert.AreEqual(sectionNormal, hydraRingSection.CrossSectionNormal);
        }
Exemplo n.º 12
0
        public void Constructor_ExpectedValues()
        {
            // Setup
            const int hydraulicBoundaryLocationId = 1000;
            IEnumerable <HydraRingForelandPoint> forelandPoints = Enumerable.Empty <HydraRingForelandPoint>();
            var breakWater = new HydraRingBreakWater(1, 1.1);

            const double sectionNormal                                        = 52.2;
            const double volumicWeightWater                                   = 1.1;
            const double gravitationalAcceleration                            = 2.2;
            const double levelCrestStructureMean                              = 3.3;
            const double levelCrestStructureStandardDeviation                 = 4.4;
            const double structureNormalOrientation                           = 5.5;
            const double factorStormDurationOpenStructure                     = 6.6;
            const double thresholdHeightOpenWeirMean                          = 7.7;
            const double thresholdHeightOpenWeirStandardDeviation             = 8.8;
            const double insideWaterLevelFailureConstructionMean              = 9.9;
            const double insideWaterLevelFailureConstructionStandardDeviation = 10.10;
            const double failureProbabilityRepairClosure                      = 11.11;
            const double failureCollisionEnergyMean                           = 12.12;
            const double failureCollisionEnergyVariation                      = 13.13;
            const double modelFactorCollisionLoadMean                         = 14.14;
            const double modelFactorCollisionLoadVariation                    = 15.15;
            const double shipMassMean          = 16.16;
            const double shipMassVariation     = 17.17;
            const double shipVelocityMean      = 18.18;
            const double shipVelocityVariation = 19.19;
            const int    levellingCount        = 20;
            const double probabilityCollisionSecondaryStructure = 21.21;
            const double flowVelocityStructureClosableMean      = 22.22;
            const double flowVelocityStructureClosableVariation = 23.23;
            const double insideWaterLevelMean = 24.24;
            const double insideWaterLevelStandardDeviation            = 25.25;
            const double allowedLevelIncreaseStorageMean              = 26.26;
            const double allowedLevelIncreaseStorageStandardDeviation = 27.27;
            const double modelFactorStorageVolumeMean = 28.28;
            const double modelFactorStorageVolumeStandardDeviation = 29.29;
            const double storageStructureAreaMean        = 30.30;
            const double storageStructureAreaVariation   = 31.31;
            const double modelFactorInflowVolume         = 32.32;
            const double flowWidthAtBottomProtectionMean = 33.33;
            const double flowWidthAtBottomProtectionStandardDeviation = 34.34;
            const double criticalOvertoppingDischargeMean             = 35.35;
            const double criticalOvertoppingDischargeVariation        = 36.36;
            const double failureProbabilityStructureWithErosion       = 37.37;
            const double stormDurationMean            = 38.38;
            const double stormDurationVariation       = 39.39;
            const double modelFactorLongThresholdMean = 40.40;
            const double modelFactorLongThresholdStandardDeviation = 41.41;
            const double bankWidthMean = 42.42;
            const double bankWidthStandardDeviation             = 43.43;
            const double evaluationLevel                        = 44.44;
            const double modelFactorLoadEffectMean              = 45.45;
            const double modelFactorLoadEffectStandardDeviation = 46.46;
            const double waveRatioMaxHN = 47.47;
            const double waveRatioMaxHStandardDeviation = 48.48;
            const double verticalDistance = 49.49;
            const double modificationFactorWavesSlowlyVaryingPressureComponent = 50.50;
            const double modificationFactorDynamicOrImpulsivePressureComponent = 51.51;

            // Call
            var input = new TestStructuresStabilityPointCalculationInput(hydraulicBoundaryLocationId, sectionNormal,
                                                                         forelandPoints, breakWater,
                                                                         volumicWeightWater,
                                                                         gravitationalAcceleration,
                                                                         levelCrestStructureMean, levelCrestStructureStandardDeviation,
                                                                         structureNormalOrientation,
                                                                         factorStormDurationOpenStructure,
                                                                         thresholdHeightOpenWeirMean, thresholdHeightOpenWeirStandardDeviation,
                                                                         insideWaterLevelFailureConstructionMean, insideWaterLevelFailureConstructionStandardDeviation,
                                                                         failureProbabilityRepairClosure,
                                                                         failureCollisionEnergyMean, failureCollisionEnergyVariation,
                                                                         modelFactorCollisionLoadMean, modelFactorCollisionLoadVariation,
                                                                         shipMassMean, shipMassVariation,
                                                                         shipVelocityMean, shipVelocityVariation,
                                                                         levellingCount,
                                                                         probabilityCollisionSecondaryStructure,
                                                                         flowVelocityStructureClosableMean, flowVelocityStructureClosableVariation,
                                                                         insideWaterLevelMean, insideWaterLevelStandardDeviation,
                                                                         allowedLevelIncreaseStorageMean, allowedLevelIncreaseStorageStandardDeviation,
                                                                         modelFactorStorageVolumeMean, modelFactorStorageVolumeStandardDeviation,
                                                                         storageStructureAreaMean, storageStructureAreaVariation,
                                                                         modelFactorInflowVolume,
                                                                         flowWidthAtBottomProtectionMean, flowWidthAtBottomProtectionStandardDeviation,
                                                                         criticalOvertoppingDischargeMean, criticalOvertoppingDischargeVariation,
                                                                         failureProbabilityStructureWithErosion,
                                                                         stormDurationMean, stormDurationVariation,
                                                                         modelFactorLongThresholdMean, modelFactorLongThresholdStandardDeviation,
                                                                         bankWidthMean, bankWidthStandardDeviation,
                                                                         evaluationLevel,
                                                                         modelFactorLoadEffectMean, modelFactorLoadEffectStandardDeviation,
                                                                         waveRatioMaxHN, waveRatioMaxHStandardDeviation,
                                                                         verticalDistance,
                                                                         modificationFactorWavesSlowlyVaryingPressureComponent,
                                                                         modificationFactorDynamicOrImpulsivePressureComponent);

            // Assert
            Assert.IsInstanceOf <ExceedanceProbabilityCalculationInput>(input);
            Assert.AreEqual(1, input.CalculationTypeId);
            Assert.AreEqual(HydraRingFailureMechanismType.StructuresStructuralFailure, input.FailureMechanismType);
            Assert.AreEqual(58, input.VariableId);
            Assert.AreEqual(4607, input.FaultTreeModelId);
            Assert.AreEqual(6, input.IterationMethodId);
            Assert.AreEqual(hydraulicBoundaryLocationId, input.HydraulicBoundaryLocationId);

            HydraRingSection section = input.Section;

            Assert.AreEqual(1, section.SectionId);
            Assert.IsNaN(section.SectionLength);
            Assert.AreEqual(sectionNormal, section.CrossSectionNormal);
            Assert.AreSame(forelandPoints, input.ForelandPoints);
            Assert.AreSame(breakWater, input.BreakWater);
            HydraRingDataEqualityHelper.AreEqual(GetDefaultVariables().ToArray(), input.Variables.ToArray());
        }
Exemplo n.º 13
0
 /// <summary>
 /// Creates a new instance of the <see cref="WaveHeightCalculationInput"/> class.
 /// </summary>
 /// <param name="sectionId">The id of the section.</param>
 /// <param name="hydraulicBoundaryLocationId">The id of the hydraulic boundary location.</param>
 /// <param name="targetProbability">The target probability.</param>
 public WaveHeightCalculationInput(int sectionId, long hydraulicBoundaryLocationId, double targetProbability)
     : base(hydraulicBoundaryLocationId, targetProbability)
 {
     Section = new HydraRingSection(sectionId, double.NaN, double.NaN);
 }
Exemplo n.º 14
0
        public void Constructor_Always_ExpectedValues()
        {
            // Setup
            const int hydraulicBoundaryLocationId = 1000;

            IEnumerable <HydraRingForelandPoint> forelandPoints = Enumerable.Empty <HydraRingForelandPoint>();
            var breakWater = new HydraRingBreakWater(1, 1.1);

            const double sectionNormal                  = 26.6;
            const double gravitationalAcceleration      = 1.1;
            const double modelFactorOvertoppingFlowMean = 2.2;
            const double modelFactorOvertoppingFlowStandardDeviation = 3.3;
            const double levelCrestStructureMean = 4.4;
            const double levelCrestStructureStandardDeviation          = 5.5;
            const double structureNormalOrientation                    = 6.6;
            const double modelFactorSuperCriticalFlowMean              = 7.7;
            const double modelFactorSuperCriticalFlowStandardDeviation = 8.8;
            const double allowedLevelIncreaseStorageMean               = 9.9;
            const double allowedLevelIncreaseStorageStandardDeviation  = 10.0;
            const double modelFactorStorageVolumeMean                  = 11.1;
            const double modelFactorStorageVolumeStandardDeviation     = 12.2;
            const double storageStructureAreaMean        = 13.3;
            const double storageStructureAreaVariation   = 14.4;
            const double modelFactorInflowVolume         = 15.5;
            const double flowWidthAtBottomProtectionMean = 16.6;
            const double flowWidthAtBottomProtectionStandardDeviation = 17.7;
            const double criticalOvertoppingDischargeMean             = 18.8;
            const double criticalOvertoppingDischargeVariation        = 19.9;
            const double failureProbabilityStructureWithErosion       = 20.0;
            const double widthFlowAperturesMean = 21.1;
            const double widthFlowAperturesStandardDeviation = 22.2;
            const double deviationWaveDirection = 23.3;
            const double stormDurationMean      = 24.4;
            const double stormDurationVariation = 25.5;

            // Call
            var input = new StructuresOvertoppingCalculationInput(hydraulicBoundaryLocationId,
                                                                  sectionNormal,
                                                                  forelandPoints, breakWater,
                                                                  gravitationalAcceleration,
                                                                  modelFactorOvertoppingFlowMean, modelFactorOvertoppingFlowStandardDeviation,
                                                                  levelCrestStructureMean, levelCrestStructureStandardDeviation,
                                                                  structureNormalOrientation,
                                                                  modelFactorSuperCriticalFlowMean, modelFactorSuperCriticalFlowStandardDeviation,
                                                                  allowedLevelIncreaseStorageMean, allowedLevelIncreaseStorageStandardDeviation,
                                                                  modelFactorStorageVolumeMean, modelFactorStorageVolumeStandardDeviation,
                                                                  storageStructureAreaMean, storageStructureAreaVariation,
                                                                  modelFactorInflowVolume,
                                                                  flowWidthAtBottomProtectionMean, flowWidthAtBottomProtectionStandardDeviation,
                                                                  criticalOvertoppingDischargeMean, criticalOvertoppingDischargeVariation,
                                                                  failureProbabilityStructureWithErosion,
                                                                  widthFlowAperturesMean, widthFlowAperturesStandardDeviation,
                                                                  deviationWaveDirection,
                                                                  stormDurationMean, stormDurationVariation);

            // Assert
            Assert.IsInstanceOf <ExceedanceProbabilityCalculationInput>(input);
            Assert.AreEqual(1, input.CalculationTypeId);
            Assert.AreEqual(HydraRingFailureMechanismType.StructuresOvertopping, input.FailureMechanismType);
            Assert.AreEqual(60, input.VariableId);
            Assert.AreEqual(4404, input.FaultTreeModelId);
            Assert.AreEqual(6, input.IterationMethodId);
            Assert.AreEqual(hydraulicBoundaryLocationId, input.HydraulicBoundaryLocationId);

            HydraRingSection section = input.Section;

            Assert.AreEqual(1, section.SectionId);
            Assert.IsNaN(section.SectionLength);
            Assert.AreEqual(sectionNormal, section.CrossSectionNormal);
            Assert.AreSame(forelandPoints, input.ForelandPoints);
            Assert.AreSame(breakWater, input.BreakWater);
            HydraRingDataEqualityHelper.AreEqual(GetDefaultOvertoppingVariables().ToArray(), input.Variables.ToArray());
        }
 /// <summary>
 /// Creates a new instance of <see cref="StructuresStabilityPointCalculationInput"/>.
 /// </summary>
 /// <param name="hydraulicBoundaryLocationId">The id of the hydraulic boundary location.</param>
 /// <param name="sectionNormal">The normal of the section.</param>
 /// <param name="forelandPoints">The foreland points.</param>
 /// <param name="breakWater">The break water.</param>
 /// <param name="volumicWeightWater">The volumic weight of water.</param>
 /// <param name="gravitationalAcceleration">The gravitational acceleration.</param>
 /// <param name="levelCrestStructureMean">The mean of the crest level of the structure.</param>
 /// <param name="levelCrestStructureStandardDeviation">The standard deviation of the crest level of the structure.</param>
 /// <param name="structureNormalOrientation">The orientation of the normal of the structure.</param>
 /// <param name="factorStormDurationOpenStructure">The factor of the storm duration for an open structure.</param>
 /// <param name="thresholdHeightOpenWeirMean">The mean of the threshold height open weir.</param>
 /// <param name="thresholdHeightOpenWeirStandardDeviation">The standard deviation of the threshold height open weir.</param>
 /// <param name="insideWaterLevelFailureConstructionMean">The mean of the inside water level at failure of construction.</param>
 /// <param name="insideWaterLevelFailureConstructionStandardDeviation">The standard deviation of the inside water level at failure of construction.</param>
 /// <param name="failureProbabilityRepairClosure">The failure probability repair closure.</param>
 /// <param name="failureCollisionEnergyMean">The mean of the failure collision energy.</param>
 /// <param name="failureCollisionEnergyVariation">The variation of the failure collision energy.</param>
 /// <param name="modelFactorCollisionLoadMean">The mean of the model factor collision load.</param>
 /// <param name="modelFactorCollisionLoadVariation">The variation of the model factor collision load.</param>
 /// <param name="shipMassMean">The mean of the ship mass.</param>
 /// <param name="shipMassVariation">The variation of the ship mass.</param>
 /// <param name="shipVelocityMean">The mean of the ship velocity.</param>
 /// <param name="shipVelocityVariation">The variation of the ship velocity.</param>
 /// <param name="levellingCount">The levelling count.</param>
 /// <param name="probabilityCollisionSecondaryStructure">The probability of collision of the secondary structure.</param>
 /// <param name="flowVelocityStructureClosableMean">The mean of the flow velocity structure closable.</param>
 /// <param name="flowVelocityStructureClosableVariation">The variation of the flow velocity structure closable.</param>
 /// <param name="insideWaterLevelMean">The mean of the inside water level.</param>
 /// <param name="insideWaterLevelStandardDeviation">The standard deviation of the inside water level.</param>
 /// <param name="allowedLevelIncreaseStorageMean">The mean of the allowed level of increase for storage.</param>
 /// <param name="allowedLevelIncreaseStorageStandardDeviation">The standard deviation of the allowed level of increase for storage.</param>
 /// <param name="modelFactorStorageVolumeMean">The mean of the model factor storage volume.</param>
 /// <param name="modelFactorStorageVolumeStandardDeviation">The standard deviation of the model factor storage volume.</param>
 /// <param name="storageStructureAreaMean">The mean of the storage structure area.</param>
 /// <param name="storageStructureAreaVariation">The variation of the storage structure area.</param>
 /// <param name="modelFactorInflowVolume">The model factor inflow volume.</param>
 /// <param name="flowWidthAtBottomProtectionMean">The mean of the flow width at bottom protection.</param>
 /// <param name="flowWidthAtBottomProtectionStandardDeviation">The standard deviation of the flow width at bottom protection.</param>
 /// <param name="criticalOvertoppingDischargeMean">The mean of the critical overtopping discharge.</param>
 /// <param name="criticalOvertoppingDischargeVariation">The variation of the critical overtopping discharge.</param>
 /// <param name="failureProbabilityStructureWithErosion">The failure probability structure with erosion.</param>
 /// <param name="stormDurationMean">The mean of the storm duration.</param>
 /// <param name="stormDurationVariation">The variation of the storm duration.</param>
 /// <param name="modelFactorLongThresholdMean">The mean of the model factor long threshold.</param>
 /// <param name="modelFactorLongThresholdStandardDeviation">The standard deviation of the model factor long threshold.</param>
 /// <param name="bankWidthMean">The mean of the bank width.</param>
 /// <param name="bankWidthStandardDeviation">The standard deviation of the bank width.</param>
 /// <param name="evaluationLevel">The evaluation level.</param>
 /// <param name="modelFactorLoadEffectMean">The mean of the model factor load effect.</param>
 /// <param name="modelFactorLoadEffectStandardDeviation">The standard deviation of the model factor load effect.</param>
 /// <param name="waveRatioMaxHN">The N of the wave ratio max h.</param>
 /// <param name="waveRatioMaxHStandardDeviation">The standard deviation of the wave ratio max h.</param>
 /// <param name="verticalDistance">The vertical distance.</param>
 /// <param name="modificationFactorWavesSlowlyVaryingPressureComponent">The modification factor waves slowly-varying pressure component.</param>
 /// <param name="modificationFactorDynamicOrImpulsivePressureComponent">The modification factor dynamic or impulsive pressure component.</param>
 protected StructuresStabilityPointCalculationInput(long hydraulicBoundaryLocationId,
                                                    double sectionNormal,
                                                    IEnumerable <HydraRingForelandPoint> forelandPoints,
                                                    HydraRingBreakWater breakWater,
                                                    double volumicWeightWater,
                                                    double gravitationalAcceleration,
                                                    double levelCrestStructureMean, double levelCrestStructureStandardDeviation,
                                                    double structureNormalOrientation,
                                                    double factorStormDurationOpenStructure,
                                                    double thresholdHeightOpenWeirMean, double thresholdHeightOpenWeirStandardDeviation,
                                                    double insideWaterLevelFailureConstructionMean, double insideWaterLevelFailureConstructionStandardDeviation,
                                                    double failureProbabilityRepairClosure,
                                                    double failureCollisionEnergyMean, double failureCollisionEnergyVariation,
                                                    double modelFactorCollisionLoadMean, double modelFactorCollisionLoadVariation,
                                                    double shipMassMean, double shipMassVariation,
                                                    double shipVelocityMean, double shipVelocityVariation,
                                                    int levellingCount,
                                                    double probabilityCollisionSecondaryStructure,
                                                    double flowVelocityStructureClosableMean, double flowVelocityStructureClosableVariation,
                                                    double insideWaterLevelMean, double insideWaterLevelStandardDeviation,
                                                    double allowedLevelIncreaseStorageMean, double allowedLevelIncreaseStorageStandardDeviation,
                                                    double modelFactorStorageVolumeMean, double modelFactorStorageVolumeStandardDeviation,
                                                    double storageStructureAreaMean, double storageStructureAreaVariation,
                                                    double modelFactorInflowVolume,
                                                    double flowWidthAtBottomProtectionMean, double flowWidthAtBottomProtectionStandardDeviation,
                                                    double criticalOvertoppingDischargeMean, double criticalOvertoppingDischargeVariation,
                                                    double failureProbabilityStructureWithErosion,
                                                    double stormDurationMean, double stormDurationVariation,
                                                    double modelFactorLongThresholdMean, double modelFactorLongThresholdStandardDeviation,
                                                    double bankWidthMean, double bankWidthStandardDeviation,
                                                    double evaluationLevel,
                                                    double modelFactorLoadEffectMean, double modelFactorLoadEffectStandardDeviation,
                                                    double waveRatioMaxHN, double waveRatioMaxHStandardDeviation,
                                                    double verticalDistance,
                                                    double modificationFactorWavesSlowlyVaryingPressureComponent,
                                                    double modificationFactorDynamicOrImpulsivePressureComponent)
     : base(hydraulicBoundaryLocationId)
 {
     Section                                                    = new HydraRingSection(1, double.NaN, sectionNormal);
     ForelandPoints                                             = forelandPoints;
     BreakWater                                                 = breakWater;
     this.volumicWeightWater                                    = volumicWeightWater;
     this.gravitationalAcceleration                             = gravitationalAcceleration;
     this.levelCrestStructureMean                               = levelCrestStructureMean;
     this.levelCrestStructureStandardDeviation                  = levelCrestStructureStandardDeviation;
     this.structureNormalOrientation                            = structureNormalOrientation;
     this.factorStormDurationOpenStructure                      = factorStormDurationOpenStructure;
     this.thresholdHeightOpenWeirMean                           = thresholdHeightOpenWeirMean;
     this.thresholdHeightOpenWeirStandardDeviation              = thresholdHeightOpenWeirStandardDeviation;
     this.insideWaterLevelFailureConstructionMean               = insideWaterLevelFailureConstructionMean;
     this.insideWaterLevelFailureConstructionStandardDeviation  = insideWaterLevelFailureConstructionStandardDeviation;
     this.failureProbabilityRepairClosure                       = failureProbabilityRepairClosure;
     this.failureCollisionEnergyMean                            = failureCollisionEnergyMean;
     this.failureCollisionEnergyVariation                       = failureCollisionEnergyVariation;
     this.modelFactorCollisionLoadMean                          = modelFactorCollisionLoadMean;
     this.modelFactorCollisionLoadVariation                     = modelFactorCollisionLoadVariation;
     this.shipMassMean                                          = shipMassMean;
     this.shipMassVariation                                     = shipMassVariation;
     this.shipVelocityMean                                      = shipVelocityMean;
     this.shipVelocityVariation                                 = shipVelocityVariation;
     this.levellingCount                                        = levellingCount;
     this.probabilityCollisionSecondaryStructure                = probabilityCollisionSecondaryStructure;
     this.flowVelocityStructureClosableMean                     = flowVelocityStructureClosableMean;
     this.flowVelocityStructureClosableVariation                = flowVelocityStructureClosableVariation;
     this.insideWaterLevelMean                                  = insideWaterLevelMean;
     this.insideWaterLevelStandardDeviation                     = insideWaterLevelStandardDeviation;
     this.allowedLevelIncreaseStorageMean                       = allowedLevelIncreaseStorageMean;
     this.allowedLevelIncreaseStorageStandardDeviation          = allowedLevelIncreaseStorageStandardDeviation;
     this.modelFactorStorageVolumeMean                          = modelFactorStorageVolumeMean;
     this.modelFactorStorageVolumeStandardDeviation             = modelFactorStorageVolumeStandardDeviation;
     this.storageStructureAreaMean                              = storageStructureAreaMean;
     this.storageStructureAreaVariation                         = storageStructureAreaVariation;
     this.modelFactorInflowVolume                               = modelFactorInflowVolume;
     this.flowWidthAtBottomProtectionMean                       = flowWidthAtBottomProtectionMean;
     this.flowWidthAtBottomProtectionStandardDeviation          = flowWidthAtBottomProtectionStandardDeviation;
     this.criticalOvertoppingDischargeMean                      = criticalOvertoppingDischargeMean;
     this.criticalOvertoppingDischargeVariation                 = criticalOvertoppingDischargeVariation;
     this.failureProbabilityStructureWithErosion                = failureProbabilityStructureWithErosion;
     this.stormDurationMean                                     = stormDurationMean;
     this.stormDurationVariation                                = stormDurationVariation;
     this.modelFactorLongThresholdMean                          = modelFactorLongThresholdMean;
     this.modelFactorLongThresholdStandardDeviation             = modelFactorLongThresholdStandardDeviation;
     this.bankWidthMean                                         = bankWidthMean;
     this.bankWidthStandardDeviation                            = bankWidthStandardDeviation;
     this.evaluationLevel                                       = evaluationLevel;
     this.modelFactorLoadEffectMean                             = modelFactorLoadEffectMean;
     this.modelFactorLoadEffectStandardDeviation                = modelFactorLoadEffectStandardDeviation;
     this.waveRatioMaxHN                                        = waveRatioMaxHN;
     this.waveRatioMaxHStandardDeviation                        = waveRatioMaxHStandardDeviation;
     this.verticalDistance                                      = verticalDistance;
     this.modificationFactorWavesSlowlyVaryingPressureComponent = modificationFactorWavesSlowlyVaryingPressureComponent;
     this.modificationFactorDynamicOrImpulsivePressureComponent = modificationFactorDynamicOrImpulsivePressureComponent;
 }
Exemplo n.º 16
0
 private static void AreEqual(HydraRingSection expectedSection, HydraRingSection actualSection)
 {
     Assert.AreEqual(expectedSection.SectionId, actualSection.SectionId);
     Assert.AreEqual(expectedSection.SectionLength, actualSection.SectionLength, accuracy);
     Assert.AreEqual(expectedSection.CrossSectionNormal, actualSection.CrossSectionNormal, accuracy);
 }
        public void Constructor_Always_ExpectedValues()
        {
            // Setup
            const double targetProbability           = 1.0 / 10000;
            const int    hydraulicBoundaryLocationId = 1000;

            const double sectionNormal = 19.9;
            const double modelFactorCriticalOvertopping = 1.1;
            const double factorFbMean = 2.2;
            const double factorFbStandardDeviation = 3.3;
            const double factorFbLowerBoundary     = 4.4;
            const double factorFbUpperBoundary     = 5.5;
            const double factorFnMean = 6.6;
            const double factorFnStandardDeviation                   = 7.7;
            const double factorFnLowerBoundary                       = 8.8;
            const double factorFnUpperBoundary                       = 9.9;
            const double modelFactorOvertopping                      = 10.0;
            const double modelFactorFrunupMean                       = 11.1;
            const double modelFactorFrunupStandardDeviation          = 12.2;
            const double modelFactorFrunupLowerBoundary              = 13.3;
            const double modelFactorFrunupUpperBoundary              = 14.4;
            const double exponentModelFactorShallowMean              = 15.5;
            const double exponentModelFactorShallowStandardDeviation = 16.6;
            const double exponentModelFactorShallowLowerBoundary     = 17.7;
            const double exponentModelFactorShallowUpperBoundary     = 18.8;

            var expectedRingProfilePoints = new List <HydraRingRoughnessProfilePoint>
            {
                new HydraRingRoughnessProfilePoint(1.1, 2.2, 3.3)
            };
            var expectedRingForelandPoints = new List <HydraRingForelandPoint>
            {
                new HydraRingForelandPoint(2.2, 3.3)
            };
            var expectedRingBreakWater = new HydraRingBreakWater(2, 3.3);

            // Call
            var input = new HydraulicLoadsCalculationInputImplementation(hydraulicBoundaryLocationId, targetProbability, sectionNormal,
                                                                         expectedRingProfilePoints, expectedRingForelandPoints, expectedRingBreakWater,
                                                                         modelFactorCriticalOvertopping,
                                                                         factorFbMean, factorFbStandardDeviation,
                                                                         factorFbLowerBoundary, factorFbUpperBoundary,
                                                                         factorFnMean, factorFnStandardDeviation,
                                                                         factorFnLowerBoundary, factorFnUpperBoundary,
                                                                         modelFactorOvertopping,
                                                                         modelFactorFrunupMean, modelFactorFrunupStandardDeviation,
                                                                         modelFactorFrunupLowerBoundary, modelFactorFrunupUpperBoundary,
                                                                         exponentModelFactorShallowMean, exponentModelFactorShallowStandardDeviation,
                                                                         exponentModelFactorShallowLowerBoundary, exponentModelFactorShallowUpperBoundary);

            // Assert
            double expectedBeta = StatisticsConverter.ProbabilityToReliability(targetProbability);

            Assert.IsInstanceOf <ReliabilityIndexCalculationInput>(input);
            Assert.AreEqual(9, input.CalculationTypeId);
            Assert.AreEqual(1017, input.FaultTreeModelId);
            Assert.AreEqual(hydraulicBoundaryLocationId, input.HydraulicBoundaryLocationId);
            Assert.IsNotNull(input.Section);
            HydraRingDataEqualityHelper.AreEqual(GetDefaultHydraulicLoadsVariables().ToArray(), input.Variables.ToArray());
            CollectionAssert.AreEqual(expectedRingProfilePoints, input.ProfilePoints);
            CollectionAssert.AreEqual(expectedRingForelandPoints, input.ForelandPoints);
            Assert.AreEqual(expectedRingBreakWater, input.BreakWater);
            Assert.AreEqual(expectedBeta, input.Beta);

            HydraRingSection hydraRingSection = input.Section;

            Assert.AreEqual(1, hydraRingSection.SectionId);
            Assert.IsNaN(hydraRingSection.SectionLength);
            Assert.AreEqual(sectionNormal, hydraRingSection.CrossSectionNormal);
        }
Exemplo n.º 18
0
        public void Constructor_ExpectedValues()
        {
            // Setup
            const int hydraulicBoundaryLocationId = 1000;
            IEnumerable <HydraRingForelandPoint> forelandPoints = Enumerable.Empty <HydraRingForelandPoint>();
            var breakWater = new HydraRingBreakWater(1, 1.1);

            const double sectionNormal                                = 21.1;
            const double gravitationalAcceleration                    = 1.1;
            const double factorStormDurationOpenStructure             = 2.2;
            const double failureProbabilityOpenStructure              = 3.3;
            const double failureProbabilityReparation                 = 4.4;
            const int    identicalApertures                           = 5;
            const double allowedLevelIncreaseStorageMean              = 6.6;
            const double allowedLevelIncreaseStorageStandardDeviation = 7.7;
            const double modelFactorStorageVolumeMean                 = 8.8;
            const double modelFactorStorageVolumeStandardDeviation    = 9.9;
            const double storageStructureAreaMean                     = 10.0;
            const double storageStructureAreaVariation                = 11.1;
            const double modelFactorInflowVolume                      = 12.2;
            const double flowWidthAtBottomProtectionMean              = 13.3;
            const double flowWidthAtBottomProtectionStandardDeviation = 14.4;
            const double criticalOvertoppingDischargeMean             = 15.5;
            const double criticalOvertoppingDischargeVariation        = 16.6;
            const double failureProbabilityStructureWithErosion       = 17.7;
            const double stormDurationMean                            = 18.8;
            const double stormDurationVariation                       = 19.9;
            const double probabilityOpenStructureBeforeFlooding       = 20.0;

            // Call
            var input = new TestStructuresClosureCalculationInput(hydraulicBoundaryLocationId,
                                                                  sectionNormal,
                                                                  forelandPoints, breakWater,
                                                                  gravitationalAcceleration,
                                                                  factorStormDurationOpenStructure,
                                                                  failureProbabilityOpenStructure,
                                                                  failureProbabilityReparation,
                                                                  identicalApertures,
                                                                  allowedLevelIncreaseStorageMean, allowedLevelIncreaseStorageStandardDeviation,
                                                                  modelFactorStorageVolumeMean, modelFactorStorageVolumeStandardDeviation,
                                                                  storageStructureAreaMean, storageStructureAreaVariation,
                                                                  modelFactorInflowVolume,
                                                                  flowWidthAtBottomProtectionMean, flowWidthAtBottomProtectionStandardDeviation,
                                                                  criticalOvertoppingDischargeMean, criticalOvertoppingDischargeVariation,
                                                                  failureProbabilityStructureWithErosion,
                                                                  stormDurationMean, stormDurationVariation,
                                                                  probabilityOpenStructureBeforeFlooding);

            // Assert
            Assert.IsInstanceOf <ExceedanceProbabilityCalculationInput>(input);
            Assert.AreEqual(1, input.CalculationTypeId);
            Assert.AreEqual(HydraRingFailureMechanismType.StructuresClosure, input.FailureMechanismType);
            Assert.AreEqual(58, input.VariableId);
            Assert.AreEqual(4505, input.FaultTreeModelId);
            Assert.AreEqual(6, input.IterationMethodId);
            Assert.AreEqual(hydraulicBoundaryLocationId, input.HydraulicBoundaryLocationId);

            HydraRingSection section = input.Section;

            Assert.AreEqual(1, section.SectionId);
            Assert.IsNaN(section.SectionLength);
            Assert.AreEqual(sectionNormal, section.CrossSectionNormal);
            Assert.AreSame(forelandPoints, input.ForelandPoints);
            Assert.AreSame(breakWater, input.BreakWater);
            HydraRingDataEqualityHelper.AreEqual(GetDefaultVariables().ToArray(), input.Variables.ToArray());
        }