Taxicab geometry
From Free net encyclopedia
Image:Manhattan distance bgiu.png
Taxicab geometry, considered by Hermann Minkowski in the 19th century, is a form of geometry in which the usual metric of Euclidean geometry is replaced by a new metric in which the distance between two points is the sum of the (absolute) differences of their coordinates.
Contents |
Manhattan distance
More formally, we can define the Manhattan distance, also known as the L1-distance, between two points in an Euclidean space with fixed Cartesian coordinate system as the sum of the lengths of the projections of the line segment between the points onto the coordinate axes.
For example, in the plane, the Manhattan distance between the point P1 with coordinates (x1, y1) and the point P2 at (x2, y2) is
- <math> \left|x_1 - x_2\right| + \left|y_1 - y_2\right|. </math>
Notice that the Manhattan distance depends on the choice on the rotation of the coordinate system, but does not depend on the translation of the coordinate system or its reflection with respect to a coordinate axis.
Manhattan distance is also known as city block distance or taxi-cab distance. It is named so because it is the shortest distance a car would drive in a city laid out in square blocks, like Manhattan (discounting the facts that in Manhattan there are one-way and oblique streets and that real streets only exist at the edges of blocks - there is no 3.14th Avenue). Any route from a corner to another one that is 3 blocks East and 6 blocks North, will cover at least 9 blocks. All direct routes cover exactly 9.
Taxicab geometry satisfies all of Euclid's axioms except for the side-angle-side axiom, as one can generate two triangles with two sides and the angle between the same and have them not be congruent. In particular, the parallel postulate holds.
A circle in taxicab geometry consists of those points that are a fixed Manhattan distance from the center. These circles are squares whose sides make a 45° angle with the coordinate axes.
Chess
In chess, the distance between squares on the chessboard for rooks is measured in Manhattan distance; kings and queens use Chebyshev distance, and bishops use the Manhattan distance (between squares of the same color) on the chessboard rotated 45 degrees, i.e., with its diagonals as coordinate axes. To reach from one square to another, only kings require the number of moves equal to the distance; rooks, queens and bishops require one or two moves (on an empty board, and assuming that the move is possible at all in the bishop's case).