Package org.ddogleg.clustering.misc
Class EuclideanSqArrayF64
java.lang.Object
org.ddogleg.clustering.misc.EuclideanSqArrayF64
- All Implemented Interfaces:
Serializable
,PointDistance<double[]>
Returns Euclidean distance squared for double[] points.
- See Also:
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiondouble
distance
(double[] a, double[] b) Computes the distance between the two input pointsPointDistance<double[]>
Creates a new instance which has the same configuration and can be run in parallel.
-
Constructor Details
-
EuclideanSqArrayF64
public EuclideanSqArrayF64(int arrayLength)
-
-
Method Details
-
distance
public double distance(double[] a, double[] b) Description copied from interface:PointDistance
Computes the distance between the two input points- Specified by:
distance
in interfacePointDistance<double[]>
- Parameters:
a
- pointb
- point- Returns:
- distance
-
newInstanceThread
Description copied from interface:PointDistance
Creates a new instance which has the same configuration and can be run in parallel. Some components can be shared as long as they are read only and thread safe.- Specified by:
newInstanceThread
in interfacePointDistance<double[]>
-