How this calculator works
Manhattan distance adds the absolute change on each coordinate axis. It models an unobstructed axis-aligned grid route, rather than a diagonal shortcut. With a missing final coordinate, subtract the known axes from the total distance. The remaining absolute difference gives two positions, or one if it is zero. All coordinates must use compatible units and equally scaled axes.
Formula
d1(A,B) = sum |Ai-Bi|. If the last coordinate is missing, Bn = An plus or minus (d1 - sum of known absolute differences).
Worked example
From (0, 0) to (3, 4), Manhattan distance is 3 + 4 = 7, while Euclidean distance is 5. If A = (0, 0), Bx = 3 and distance is 7, By can be -4 or 4.
Advertisement
Frequently asked questions
Does this account for blocked streets?
No. Barriers, one-way streets and unequal travel costs require a routing model.
Can I use negative coordinates?
Yes. Absolute differences make the distance nonnegative regardless of the signs.
Can the answer be smaller than Euclidean distance?
With the same coordinates and scale, Manhattan distance is at least the Euclidean distance.