Metric space (source code)

= Metric space
{title2=$(X,d)$}
{wiki}

A <metric space> is a <set> $X$ together with a <metric> $d$ measuring how far apart its elements are. The elements can be positions, <functions>, or other objects: what matters is that the <metric> obeys the same basic rules. This lets one discuss <convergence in a metric space>, <continuous maps>, and <Cauchy sequences> without first assigning <Cartesian coordinates>. The useful abstraction is that many arguments require only comparisons of distances, rather than the particular objects being compared.

Even the same <set> can support several informative <metrics>. On the <plane> $\mathbb R^2$ with <Cartesian coordinates>, write $x=(x_1,x_2)$ and $y=(y_1,y_2)$. Three standard choices are <Manhattan distance>, <Euclidean distance>, and <Chebyshev distance>:
$$
\begin{aligned}
d_1(x,y)&=|x_1-y_1|+|x_2-y_2|,\\
d_2(x,y)&=\sqrt{(x_1-y_1)^2+(x_2-y_2)^2},\\
d_\infty(x,y)&=\max\{|x_1-y_1|,|x_2-y_2|\}.
\end{aligned}
$$
They come from the <L1 norm>, <Euclidean norm>, and <maximum norm>, respectively, through $d(x,y)=\|x-y\|$. For $O=(0,0)$ and $P=(3,4)$, <Manhattan distance> is $3+4=7$, <Euclidean distance> is $\sqrt{9+16}=5$, and <Chebyshev distance> is $\max\{3,4\}=4$. All three answers are correct for their respective <metrics>.

The choice encodes the question being asked. <Manhattan distance> models travel along a rectangular street grid. <Euclidean distance> measures unrestricted travel along a <line segment>. <Chebyshev distance> measures the time needed when two <Cartesian coordinates> can change simultaneously, each at speed at most one. Thus choosing a <metric> is part of modelling, rather than a consequence of knowing the endpoints. These examples have the same <metric topology>, but different <metric path lengths> and different collections of <metric geodesics>.

A historical reference for the general study of <metric spaces> is <Maurice Fréchet>'s 1906 paper Sur quelques points du calcul fonctionnel, published in volume 22 of the Rendiconti del Circolo Matematico di Palermo. https://link.springer.com/article/10.1007/BF03018603[Fréchet, Sur quelques points du calcul fonctionnel, 1906]{ref}