TITLE: Isometry map on a compact metric space
QUESTION [5 upvotes]: Let $X$ be a compact metric space and $f : X\rightarrow X$ such that $d (x,y)\le d (f(x),f(y))$ for all $x,y\in X$. Prove that $f$ is an isometry. I am getting stuck on this question. Can any one help me ?

REPLY [2 votes]: Here is another approach that uses only very basic ideas: 
Pick $x,y\in X$ and take $x_0=x, y_0=y$ and then $x_n=f(x_{n-1}), y_n=f(y_{n-1})$.
Then, for all integers $n$, we have 
$\tag1 d(x,y)\leq \cdots \leq d(x_n,y_n)\leq d(x_{n+1},y_{n+1})\leq \cdots $ 
Now, there are convergent subsequences $x_{n_{k}}, y_{n_{k}}$ and these are of course, Cauchy.
Let $\epsilon >0$. Then, if $k$ is large enough, 
$\tag2 d(x_{n_{k+1}-n_{k}},x)\leq d(x_{n_{k+1}},x_{n_{k}})<\epsilon$
and $\tag3 d(y_{n_{k+1}-n_{k}},y)\leq d(y_{n_{k+1}},y_{n_{k}})<\epsilon$ 
where we have used $(1)$ successively. 
But now, using $(1), (2), (3)$ and the triangle inequality, we have 
$\tag4 d(f(x),f(y))=d(x_1,y_1)\leq \cdots \leq d(x_{n_{k+1}-n_{k}},y_{n_{k+1}-n_{k}})\leq d(x_{n_{k+1}-n_{k}},x)+d(x,y)+d(y_{n_{k+1}-n_{k}},y)<d(x,y)+2\epsilon$ 
so $d(f(x),f(y))\leq d(x,y)$ and we are done.