Package org.jreliability.function.common
Class SampledReliabilityFunction
- java.lang.Object
-
- org.jreliability.function.SequentialFunction
-
- org.jreliability.function.common.SampledReliabilityFunction
-
- All Implemented Interfaces:
Function
,ReliabilityFunction
public class SampledReliabilityFunction extends SequentialFunction implements ReliabilityFunction
TheSampledReliabilityFunction
approximates aReliabilityFunction
from a set of Samples.
-
-
Field Summary
Fields Modifier and Type Field Description protected java.util.List<java.lang.Double>
sortedSamples
Sorted list of all samples.protected double
step
The x-stepsize.protected double[]
yarray
Array from the x values (as positions) to the y values.
-
Constructor Summary
Constructors Constructor Description SampledReliabilityFunction(java.util.Collection<java.lang.Double> samples)
Constructs aSampledReliabilityFunction
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.List<java.lang.Double>
getSamples()
Returns all samples in an orderedList
.double
getY(double x)
Returns they
value fory = f(x)
.-
Methods inherited from class org.jreliability.function.SequentialFunction
getY
-
-
-
-
Constructor Detail
-
SampledReliabilityFunction
public SampledReliabilityFunction(java.util.Collection<java.lang.Double> samples)
Constructs aSampledReliabilityFunction
.- Parameters:
samples
- the collection of samples
-
-