edu.stanford.math.plex4.metric.impl
public class EuclideanMetricSpace extends ObjectSearchableFiniteMetricSpace<double[]>
elements| Constructor and Description |
|---|
EuclideanMetricSpace(double[][] array)
This constructor initializes the class with an array of elements.
|
| Modifier and Type | Method and Description |
|---|---|
double |
distance(double[] a,
double[] b)
This function returns the distance between two points.
|
distance, getClosedNeighborhood, getKNearestNeighbors, getNearestPointIndex, getOpenNeighborhood, getPoint, getPoints, sizepublic EuclideanMetricSpace(double[][] array)
array - the array of elements that will be the points in the metric spacepublic double distance(double[] a,
double[] b)
AbstractObjectMetricdistance in interface AbstractObjectMetric<double[]>distance in class ObjectSearchableFiniteMetricSpace<double[]>a - the first pointb - the second point