|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectmath.PostOfficeMetric
public class PostOfficeMetric
The Post Office metric (i.e., a notion of distance that makes sense if, to travel between two points, you have to go through a central post office located at the origin) This is sometimes also called the British Rail metric and/or the shuttle metric.
| Constructor Summary | |
|---|---|
PostOfficeMetric()
|
|
| Method Summary | |
|---|---|
double |
distance(double[] x,
double[] y)
Calculate the distance between two n-dimensional points (required by Metric) Note: For simplicity, this method does not confirm that the two arrays are the same size. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public PostOfficeMetric()
| Method Detail |
|---|
public double distance(double[] x,
double[] y)
distance in interface Metricx - One n-dimensional pointy - Another n-dimensional point
|
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||