org.ddogleg.fitting.modelset
Class RandomDistanceModel
- java.lang.Object
-
- org.ddogleg.fitting.modelset.RandomDistanceModel
-
- All Implemented Interfaces:
- DistanceFromModel<double[],java.lang.Double>
public class RandomDistanceModel extends java.lang.Object implements DistanceFromModel<double[],java.lang.Double>
Returns a random distance
-
-
Constructor Summary
Constructors Constructor and Description RandomDistanceModel(double errorMagnitude, double errorMinimum)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description doublecomputeDistance(java.lang.Double pt)Computes the distance the point is from the model.voidcomputeDistance(java.util.List<java.lang.Double> points, double[] distance)Computes the distance a set of points is from the model and saves the results in the provided array.voidsetModel(double[] param)Sets the model parameters.
-
-
-
Constructor Detail
-
RandomDistanceModel
public RandomDistanceModel(double errorMagnitude, double errorMinimum)
-
-
Method Detail
-
setModel
public void setModel(double[] param)
Description copied from interface:DistanceFromModelSets the model parameters.- Specified by:
setModelin interfaceDistanceFromModel<double[],java.lang.Double>- Parameters:
param- Model parameters.
-
computeDistance
public double computeDistance(java.lang.Double pt)
Description copied from interface:DistanceFromModelComputes the distance the point is from the model.- Specified by:
computeDistancein interfaceDistanceFromModel<double[],java.lang.Double>- Parameters:
pt- Point being evaluated. Not modified.- Returns:
- Distance the point is from the model.
-
computeDistance
public void computeDistance(java.util.List<java.lang.Double> points, double[] distance)Description copied from interface:DistanceFromModelComputes the distance a set of points is from the model and saves the results in the provided array.- Specified by:
computeDistancein interfaceDistanceFromModel<double[],java.lang.Double>- Parameters:
points- Set of points which are to be evaluated.distance- Where model distance is stored.
-
-
DataMelt 3.0 © DataMelt by jWork.ORG