geometry

Definition

Manhattan Distance

The Manhattan distance (also known as city block distance or distance) is a metric defined as the sum of the absolute differences of the coordinates of two points. Formally, for two vectors , the Manhattan distance is:

Properties

Metric Axioms: The Manhattan distance satisfies all formal requirements of a metric, including the triangle inequality.

Taxicab Geometry: The distance corresponds to the length of a path between two points in a grid-based system where movement is restricted to axes-parallel steps.

Regularisation: In machine learning, the norm is frequently utilised in regularisation (e.g., Lasso) to promote sparsity in model parameters.