Curves and geodesics This is a very long problem of homework.
Definitions:
 We start by defining a curve as a continuous function  $
\phi :\left[ {a,b} \right] \to \left( {M,d} \right)
$ where M is a metric space with metric d. We define the length of the curve $
\phi :\left[ {a,b} \right] \to M
$ as $$
L\left( \varphi  \right) = \mathop {\sup }\limits_{p \in P} \sum\limits_{k = 1}^n {d\left( {\varphi \left( {p_{k - 1} } \right),\varphi \left( {p_k } \right)} \right)} 
$$
where p runs over all the partitions P of $[a,b]$ i.e a finite collection of points, of the form $
a = p_0  &lt p_1  &lt ... &lt p_n  = b
$   ( if not exist we just simply say that $
L\left( \varphi  \right) = \infty 
$ ) . 
First part of the Problem:
$i)$ Let $
\varphi 
$ be a curve that has finite length $L(\varphi)$ . Prove that there exist a function $s:[a,b] \to [0,L(\varphi)]$ such that $
s\left( t \right) = L\left( {\varphi \left| {_{\left[ {a,t} \right]} } \right.} \right)
$.  Prove that $s$ it´s non decreasing, continuous and surjective.
Solution to the first part (Not complete)
I proved that $s$ it´s non decreasing. I also proved that if I have a partition P, and I add a new point to the partition, then the sum over that new partition it´s $
 \leqslant 
$ than the original. Using that $$
L\left( {\varphi \left| {_{\left[ {a,t + \varepsilon } \right]} } \right.} \right) \leqslant L\left( {\varphi \left| {_{\left[ {a,t} \right]} } \right.} \right) + L\left( {\varphi \left| {_{\left[ {t,t + \varepsilon } \right]} } \right.} \right)
$$.
So to prove continuity it´s enough to prove that $$
\mathop {\lim }\limits_{x \to 0^ +  } L\left( {\varphi \left| {_{\left[ {j,j + x} \right]} } \right.} \right) = 0
$$
i.e given any $
\varepsilon  > 0
$ there exist a $\delta >0$ such that if $0&ltx&lt\delta$ then $
L\left( {\varphi \left| {_{\left[ {j,j + x} \right]} } \right.} \right) &lt \varepsilon 
$
What I did here it´s trying to use the continuity of $\varphi$ but wasn´t work. For example choosing $\delta$>0 such that $|x-j|&lt\delta$ $
 \Rightarrow 
$ $
d\left( {\varphi \left( x \right),\varphi \left( \delta  \right)} \right) &lt \frac{\varepsilon }
{2}
$
So with this given a partition with "n" elements of the interval $
\left[ {j,j + \delta } \right]
$ , we know that $
\sum\limits_{n\,sums} {d\left( {\varphi \left( {p_k } \right),\varphi \left( {p_{k - 1} } \right)} \right)}  &lt n\varepsilon 
$
But that was all that I can do :/!!! I need help with this.
This is not the problem. Someone has a book about metric geometry? ( involving geodesics , and others) . 
Part 2 and final of the problem
Prove that there exist a function $
\widetilde\varphi :\left[ {0,L\left( \varphi  \right)} \right]: \to X
$ such that:
$i)$ $
\widetilde\varphi \left( {s\left( t \right)} \right) = s\left( t \right)\,\,\forall \,\,t \in \left[ {a,b} \right]
$, $
$ii)$be continuous
$iii)$ $
L\left( {\widetilde\varphi _{\left| {\left[ {x,y} \right]} \right.} } \right) = \left| {x - y} \right|
$
* Try*
Here I don´t know what I can do. Maybe consider the inverse function, of the $s(t)$ function, and composing, but I´m not sure if the $s(t)$ has also an inverse ( it´s injective) . Anyway, if the inverse exist, how can I prove that this function is the function that I want?
Sorry for this stupid question :/!!
 A: Define, for $\alpha &lt \beta$, $L(\alpha,\beta):= L\left(\phi|_{[\alpha, \beta]}\right)$. Then we have the following
Lemma. For any $\alpha &lt \beta &lt \gamma\in[a,b]$, we have $L(\alpha, \beta) + L(\beta,\gamma) = L(\alpha,\gamma)$.
Proof. Given any partition $P$ of $[\alpha,\beta]$ and $Q$ of $[\beta, \gamma]$, $P\cup Q$ gives a partition of $[\alpha, \gamma]$. Indicating the sum over a partition $R$ by $\sum_R$, we have:
$$\sum_{P\cup Q} = \sum_P + \sum_Q,$$
which obviously implies $L(\alpha,\gamma)\geq L(\alpha,\beta) + L(\beta,\gamma)$. 
Conversely, if $R$ is a partition of $[\alpha,\gamma]$, $R\cup\{\beta\}$ is also a partition of $[\alpha,\gamma]$, and
$$\sum_R \leq \sum_{R\cup\{\beta\}}\leq \sum_P + \sum_Q,$$
where $P$ is the partition $\left(R\cup\{\beta\}\right)\bigcap [\alpha,\beta]$, and $Q$ is the partition $\left(R\cup\{\beta\}\right)\bigcap[\beta,\gamma]$. Hence, since $\sum_P\leq L(\alpha,\beta)$ and $\sum_Q\leq L(\beta,\gamma)$, we must have
$$\sum_R\leq L(\alpha,\beta) + L(\beta,\gamma),$$
which implies $L(\alpha,\gamma)\leq L(\alpha,\beta) + L(\beta,\gamma)$. The lemma is proved. $\square$
Now fix $m\in [a,b]$, $m &lt b$. Fix $\epsilon > 0$ and let $0 &lt \epsilon_0 &lt \epsilon/4$. Let $P$ be a partition of $[m, b]$ such that
$$L(m, b) - \sum_P &lt \epsilon_0$$
(this is possible since $L(\phi) &lt \infty$, hence, by the lemma above, $L(m, b) &lt \infty$). Let $\{x_n\}$ be a sequence in $[a, b]$ decreasing monotonically to $m$, such that $x_0 &lt \min\{x\in P: x\neq m\}$. Define the sequence of partitions $P_n$, $n\in\mathbb{N}$, by
$$P_n := P\cup\{x_0,\dots,x_n, m\}.$$
Observe that the sequence $\sum_{P_n\setminus \{m\}}$ is a sequence of partial sums of a convergent infinite series. Hence the tails of this series must converge to zero. In other words, there exists $N\in\mathbb{N}$, such that for any $k>l\geq N$, we have $\sum_{Q_{(l,k)}} &lt \epsilon_0$, where $Q_{(l,k)}$ is the partition of $[x_l, m]$ given by $\{x_l, x_{l+1},\dots,x_k, m\}$. Indeed, this follows since $\sum_{i = l}^{k-1} d(\phi(x_i), \phi(x_{i+1}))$ is a tail of the aforementioned infinite series, and $d(\phi(x_k), \phi(m))$ can be made arbitrarily small by ensuring that $k$ is large enough, by continuity of $\phi$.
Since $L(m,b) - \sum_P &lt \epsilon_0$, for each $n$ we must have $L(m,b) - \sum_{P_n} &lt \epsilon_0$, and by the lemma above we can conclude (work this out!) that $L(m, \phi(x_l)) - \sum_{Q_{(l, k)}} &lt 2\epsilon_0$. On the other hand, since $\sum_{Q_{(l,k)}} &lt \epsilon_0$, we must have $L(m, \phi(x_l)) &lt 4\epsilon_0 &lt \epsilon$. 
