Index: Ringtoets/Common/src/Ringtoets.Common.Service/RingtoetsCommonDataCalculationService.cs
===================================================================
diff -u -re182f6f394aa75e739467a77e7bcacd9a8b25429 -rd56bec747401ad6676fac64af5eef6d5fd89c47c
--- Ringtoets/Common/src/Ringtoets.Common.Service/RingtoetsCommonDataCalculationService.cs (.../RingtoetsCommonDataCalculationService.cs) (revision e182f6f394aa75e739467a77e7bcacd9a8b25429)
+++ Ringtoets/Common/src/Ringtoets.Common.Service/RingtoetsCommonDataCalculationService.cs (.../RingtoetsCommonDataCalculationService.cs) (revision d56bec747401ad6676fac64af5eef6d5fd89c47c)
@@ -43,5 +43,31 @@
CalculationConvergence.CalculatedConverged :
CalculationConvergence.CalculatedNotConverged;
}
+
+ ///
+ /// Gets the reqiured probability which is needed in profile specific calculations.
+ ///
+ /// The assessment section norm.
+ /// The failure mechanism contribution
+ /// the 'N' parameter used to factor in the 'length effect'.
+ /// The profile specific required probability.
+ /// Thrown when
+ /// or is null.
+ public static double ProfileSpecificRequiredProbability(double norm, double failureMechanismContribution, int n)
+ {
+ if (!(failureMechanismContribution > 0))
+ {
+ throw new ArgumentOutOfRangeException("failureMechanismContribution", failureMechanismContribution,
+ "De bijdrage van dit toetsspoor is nul. " +
+ "Daardoor is de doorsnede-eis onbepaald en kunnen de berekeningen niet worden uitgevoerd.");
+ }
+ if (!(n > 0))
+ {
+ throw new ArgumentOutOfRangeException("n", n, "De N-waarde van dit toetsspoor is nul. " +
+ "Daardoor is de doorsnede-eis onbepaald en kunnen de berekeningen niet worden uitgevoerd.");
+ }
+
+ return norm*(failureMechanismContribution/100)/n;
+ }
}
}
\ No newline at end of file