// LInf.java // Computes relative distances in the L_infinity metric. // Actually returns the distances scaled by sqrt(2). public class LInf extends Metric { public double distance(Shape s, double x, double y) { return s.rotate().lOne(PointShape.rotate(x, y).getPoint()); } }