|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectsbrt.kernel.math.geom.comp.EuclideanDist
public final class EuclideanDist
This class is used to compute Euclidean distances. All provided numbers are converted to double precision via the method Number.doubleValue().
Constructor Summary | |
---|---|
EuclideanDist()
|
Method Summary | |
---|---|
double |
getDist(java.util.Collection<? extends java.lang.Number> x,
java.util.Collection<? extends java.lang.Number> y)
Computes and returns the Euclidean distance between the provided collections. |
double |
getDist(java.util.Map<?,? extends java.lang.Number> x,
java.util.Map<?,? extends java.lang.Number> y)
Computes and returns the Euclidean distance between the provided maps. |
double |
getDist(java.lang.Number[] x,
java.lang.Number[] y)
Computes and returns the Euclidean distance between the provided arrays. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public EuclideanDist()
Method Detail |
---|
public double getDist(java.lang.Number[] x, java.lang.Number[] y)
x
- an array of numbers.y
- another array of numbers.
java.lang.IllegalArgumentException
- if the lengths of the provided arrays
are not equal.public double getDist(java.util.Collection<? extends java.lang.Number> x, java.util.Collection<? extends java.lang.Number> y)
x
- a collection of numbers.y
- another collection of numbers.
java.lang.IllegalArgumentException
- if the lengths of the provided collections
are not equal.public double getDist(java.util.Map<?,? extends java.lang.Number> x, java.util.Map<?,? extends java.lang.Number> y)
x
- a map.y
- another map.
java.lang.IllegalArgumentException
- if the lengths of the provided maps
or the key sets are not equal.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |