There are several alternative ways to define a distance between two points P1, = (x1, Yl) and P2
= (x2, Y2) in the Cartesian plane. In particular, the so-called Manhattan distance is defined as
Prove that dM satisfies the following axioms which every distance function must satisfy:
i. dM(P1, P2)
0 for any two points P1
and P2
and dM(P1, P2) = 0 if and only if P1
= P2;
ii. dM(P1, P2
) = dM(P2, P1);
iii. dM(P1, P2)
dM(P1, P3) + dM(P3, P2) for any P1, P2, and P3.
b. Sketch all the points in the x, y coordinate plane whose Manhattan distance to the origin (0,0) is equal to 1. Do the same for the Euclidean distance.
c. True or false: A solution to the closest -pair problem does not depend on which of the two metrics-dE
(Euclidean) or dM
(Manhattan)-is used?