# Is it always possible to find a “pre-metric” from a metric?

Problem

Let $X$ be a non-empty set. Let $f:X\times X\to \mathbb{R}$ satisfying the following properties,

• $f(x,y)=0\iff x=y$ for all $x,y\in X$.

• $f(x,y)=-f(y,x)$ for all $x,y\in X$.

• $f(x,y)=f(x,z)+f(z,y)$ for all $x,y,z\in X$.

If such a function exists, call the function $f$ to be a pre-metric on $X$. Prove that,

1. The function $d(x,y)=|f(x,y)|$ defined a metric on $X$ where $|\cdot|$ is the absolute value function of $\mathbb{R}$.

2. From the previous result you can conclude that we can always get a metric from a pre-metric but is the converse always true?

3. If the converse doesn't hold in general, what condition(s) on $d$ are needed to ensure that the converse also holds?

The first part of the problem is easy and I have proved it but for the second and third part I got nowhere. Can anyone help me?

• What about the unit triangle? – Henricus V. Jan 31 '16 at 5:46
• @HenryW: What is an unit triangle? – user 170039 Jan 31 '16 at 5:47
• A metric space with only three elements. The distance between each pair of elements is $1$. – Henricus V. Jan 31 '16 at 5:47
• "Set equipped with a pre-metric" seems very similar to "one-dimensional real affine space." – goblin Jan 31 '16 at 5:59
• @goblin: Yes, you are right. When I asked my friend who gave me this exercise, he told me that the motivation for the problem came from "one-dimensional real affine space". – user 170039 Jan 31 '16 at 6:33

## 1 Answer

A necessary and sufficient condition on a metric space $(X,d)$ for $d$ to come from some pre-metric is that $(X,d)$ be isometric to a subspace of the metric space $\mathbb{R}$ with the ordinary distance.

We may assume $X \ne \varnothing$. (When $X = \varnothing$, both conditions are true.)

Let $f$ be a pre-metric on $X$, and fix an "origin" $a \in X$. Write $g(x) = f(a,x)$. For any $x,y \in X$, we have $f(x,y) = f(x,a) + f(a,y) = - f(a,x) + f(a,y) = g(y) - g(x)$. Moreover, if $g(x) = g(y)$, then by the foregoing, $f(x,y) = 0$, so $x = y$.

Thus $g$ is a bijection between $X$ and a subset of $\mathbb{R}$, and $f(x,y) = g(y) - g(x)$. The distance $d(x,y)=|f(x,y)|$ corresponds via the bijection $g$ to the ordinary distance on $\mathbb{R}$.

Conversely, if $g$ is an isometry of some metric space $X$ onto a subset of $\mathbb{R}$, the distance function on $X$ is obtained from the pre-metric $f(x,y) = g(y) - g(x)$.

• Of course, there's nothing to stop one from trying to find characterizations of metric spaces isometric to subspaces of $\mathbb{R}$. – David Jan 31 '16 at 6:55
• Interestingly enough, if we define a "pre-pseudometric" as a function $f:X\times X\to \mathbb{R}$ on a non-empty set $X$ such that, (1) $x=y\implies f(x,y)=0$, (2) $f(x,y)=-f(y,x)$ for all $x,y\in X$ and (3) $f(x,y)=f(x,z)+f(z,y)$ for all $x,y,z\in X$ then we can say that every pseudometric can be obtained from a pre-pseudometric and vice versa. – user 170039 Feb 3 '16 at 14:57