/** Compute the distance between two vectors according to the L<sub>2</sub> norm. * <p>Calling this method is equivalent to calling: * <code>p1.subtract(p2).getNorm()</code> except that no intermediate * vector is built</p> * @param p1 first vector * @param p2 second vector * @return the distance between p1 and p2 according to the L<sub>2</sub> norm */ public static double distance(Vector1D p1, Vector1D p2) { return p1.distance(p2); }
/** {@inheritDoc} * @deprecated as of 3.3, replaced with {@link #distance(Point)} */ @Deprecated public double distance(Vector<Euclidean1D> p) { return distance((Point<Euclidean1D>) p); }
/** Compute the distance between two vectors according to the L<sub>2</sub> norm. * <p>Calling this method is equivalent to calling: * <code>p1.subtract(p2).getNorm()</code> except that no intermediate * vector is built</p> * @param p1 first vector * @param p2 second vector * @return the distance between p1 and p2 according to the L<sub>2</sub> norm */ public static double distance(Vector1D p1, Vector1D p2) { return p1.distance(p2); }
/** {@inheritDoc} * @deprecated as of 3.3, replaced with {@link #distance(Point)} */ @Deprecated public double distance(Vector<Euclidean1D> p) { return distance((Point<Euclidean1D>) p); }