A distance function $d: \mathbb{R} \times \mathbb{R} \rightarrow [0,\infty)$ that is defined by a smooth Riemannian metric on the real line satisfies the following properties:


1. $d$ is a length metric (a.k.a. intrinsic metric, inner metric, Menger-convex ...);
2. $d$ is continuous;
3. for every $x,y \in \mathbb{R}$, the function $t \mapsto d(x+t,y+t)$ is smooth as a function of $t$.


Is the converse true? In other words:



> 
> Given a distance function $d: \mathbb{R} \times \mathbb{R} \rightarrow [0,\infty)$ that satisfies these three properties, is it the distance function of a Riemannian metric on the real line?
> 
> 
> 


**Remarks.**


**1.** If you eliminate condition (3), the metric may not come from a Riemannian metric no matter how little regularity you're prepared to accept. Take for example $f : \mathbb{R} \rightarrow \mathbb{R}$ to be the Cantor function extended continuously as a constant function outside the interval $[0,1]$ plus the function $x \mapsto x$. The function $f$ is continuous and strictly increasing.Therefore, $d(x,y) = |f(y) - f(x)|$ defines a continuous length metric on the real line, but the distance does not come from any Lebesgue integrable Riemannian metric on the line. 


**2.** The point where I'm stuck: It is not hard to come up with the candidate Riemannian metric by considering 
$$
\sqrt{g\_x(v,v)} := \lim\_{t \rightarrow 0^+} d(x,x + tv)/t
$$
that can be shown to exist for all $(x,v)$ because $d(x, x + tv)$ is continuous and monotone in $t$ and hence differentiable almost everywhere and because condition (3) implies that if the limit exists for a point, then it will exist for all points.


However, I can't see whether $\sqrt{g\_x(\cdot,\cdot)} = \nu(x) |dx|$ is Riemann or Lebesgue integrable and, much less, continuous, etc. 


Hopefully, this is all very simple and I'm just overlooking something really obvious.


**3.** In general, I'm trying to understand the class of distance functions on a manifold that can be uniformly approximated on compact sets by distance functions coming from Riemannian or Finsler metrics. If you have any references on this, I'd be glad to know of them.



Riemannian distance functions on the real line
[Moved from the comments/chat.]


Define $D(x)$ by
$$
\begin{align\*}
D(x) = 
\begin{cases}
d(0,x), & \text{ if } x\geq 0;\\
-d(x,0), & \text{ if } x< 0.
\end{cases}
\end{align\*}
$$
Function $D(x)$ is non-decreasing. It defines a measure $\nu$ on $\mathbb R$ such that $\nu[a,b] = D(b) - D(a)$ for every $b > a$.


Apply the Lebesgue Decomposition Theorem to $\nu$:
$$\nu (x) = \nu\_{ac}(x) + \nu\_s(x) + \nu\_d(x),$$
where $\nu\_{ac}$ is an absolutely continuous measure, $\nu\_s$ is a singular measure, $\nu\_d$ is a discrete measure. Note that the decomposition is unique.


Now we use condition (3). We consider $\alpha(t) = d(x+t,y+t) = D(y+t) - D(x+t)$, which is smooth. Let $\mu(t)$ be the signed measure with density $\alpha'(t)$. Note that $\mu$ is absolutely continuous.


We have $\nu(y+t) - \nu(x+t) = \mu(t)$. Thus,
$$(\nu\_{ac}(y+t) - - \nu\_{ac}(x+t)) + (\nu\_s(y+t) - \nu\_s(x+t)) + (\nu\_d(y+t) - \nu\_d(x+t))$$
is an absolutely continuous signed measure. Therefore, its singular and discrete parts are equal to 0:
\begin{align\*}
\nu\_s(y+t) - \nu\_s(x+t) = 0,\\
\nu\_d(y+t) - \nu\_d(x+t) = 0.
\end{align\*}
That is, signed measures $\nu\_s$ and $\nu\_d$ are invariant under shifts by $y-x$ for every $x < y$. Thus, they are identically equal to $0$ (up to normalization, only the standard Lebesgue measure is invariant under all shifts; but it is absolutely continuous). We get that $\nu(x)$ is an absolutely continuous measure. Let $f(x)$ be its Radon—Nikodym derivative w.r.t. to the standard Lebesgue measure. Then
$$d(a,b) = \int\_a^b f(t) dt,$$
for every $a<b$, which is what we want.


In this proof, we used only that $d(x+t,y+t)$ is absolutely continuous on every segment. E.g., it is sufficient to assume in condition (3) that $d(x+t,y+t)$ is Lipschitz on every segment.


