# Let $(X,d)$ be a compact metric space. Let $f: X \to X$ be such that $d(f(x),f(y)) = d(x,y)$ for all $x,y \in X$. Show that $f$ is onto (surjective).

Let $(X,d)$ be a compact metric space. Let $f: X \to X$ be such that $d(f(x),f(y)) = d(x,y)$ for all $x,y \in X$. Show that $f$ is onto (surjective).

If $f$ is not onto then there exist a $p \in X$ such that there does not exist any $y \in X$ such that $f(y) =p$. Then there exist $x \in X$ such that $d(p,f(x)) = d(p,x)$.

I am finding difficulty to do the proof please help!!

Is the result true if $X$ is not compact??

• What's a compact metric space? (I can guess it'd be the subspace topology applied to a compact subspace, which is metricisable - but I'd like to hear this) – Alec Teal Feb 13 '15 at 16:23
• @AlecTeal Sequential compactness can be formulated without reference to an ambient space. Completeness and total boundedness can also be defined without reference to an ambient space. – Ian Feb 13 '15 at 16:48
• @Ian is sequential something very different to normal compactness, because "normal" compactness requires an ambient space. – Alec Teal Feb 13 '15 at 16:53
• @AlecTeal It is true that sequential and compactness are rather different notions, although in a metric space they turn out to be equivalent. Also, I think one can indeed formulate the notion of a "compact topological space" without regard to an ambient space. Specifically, a topological space $X$ is compact if every $X$-open cover of $X$ has a finite subcover. – Ian Feb 13 '15 at 16:58
• @AlecTeal (Cont.) Moreover, a subset $A$ of an ambient space $X$ is compact (as a subset of $X$, meaning all $X$-open covers of $A$ have a finite subcover) if and only if $A$ with the subspace topology from $X$ is compact (as a subset of itself, meaning all $A$-open covers of $A$ have a finite subcover). These are trivially equivalent, because $\{ U_\alpha \}$ is a cover if and only if $\{ U_\alpha \cap A \}$ is a cover, and $U_\alpha \cap A$ will be open in $A$ if $U_\alpha$ was open in $X$. Are you sure this doesn't work? – Ian Feb 13 '15 at 17:03

## 4 Answers

Consider a point $p\in X$, and define the sequence $(x_n)_n$ inductively by setting $x_0=p$ and $x_{n+1}=f(x_n)$. Since $X$ is compact there exists a convergent sub-sequence $(x_{n_k})_k$. In particular we have $$\lim_{k\to\infty}d(x_{n_{k+1}},x_{n_k})=0$$ That is $$\lim_{k\to\infty}d(f^{n_{k+1}}(p),f^{n_{k}}(p))=0$$ Or, using the assumption $$\lim_{k\to\infty}d(f^{n_{k+1}-n_k}(p),p)=0$$ Since $n_{k+1}-n_k\ge1$ the above result is equivalent to $$\lim_{k\to\infty}d(f(y_k),p)=0\tag{1}$$ where $y_k=f^{n_{k+1}-n_k-1}(p)=x_{n_{k+1}-n_k-1}$. Now we can extract from $(y_k)_k$ a convergent sub-sequence $(y_{k_m})_m$ that converges to some $q\in X$, and $(1)$ then implies, (due to the continuity of $x\mapsto d(f(x),p)$), that $$\lim_{m\to\infty}d(f(y_{k_m}),p)=d(f(q),p)=0$$ So $p=f(q)\in f(X)$. This proves that $f$ is onto.

Remark. Note that we only need that $d(f(x),f(y))\ge d(x,y)$ for every $x,y$ in $X$.

• Excellent answer. I hope one day I could cook up an answer so fast as you did.. – Troy Woo Feb 13 '15 at 16:07
• @TroyWoo, Thanks, I hope also the you will. – Omran Kouba Feb 13 '15 at 16:09
• It's worth noting that $\lim_{m\to\infty} d(f(y_{k_m}),p)=d(f(q),p)$ holds due to continuity of $d(\cdot,p)$. – Math1000 Feb 13 '15 at 16:16
• @Math1000,Yes, I edited the answer accordingly, thank you. – Omran Kouba Feb 13 '15 at 16:21

you already got your 1st answer..for your 2nd question the result is not true if X is not compact...for an example define $f: \mathbb{N} -> \mathbb{N}$ s.t $f(n)=n+1$ is not surjective

If $f$ is not onto, take a point $p$ not in the image of $f$. Using sequential compactness, show that there is an open ball $B_\epsilon(p)$ centered at $p$ which is not contained in $f(X)$. Next, show that it cannot be the case that $B(p,\epsilon) \cap f(X) = \emptyset$ for some $\epsilon > 0$. Suppose to the contrary that it does. Then consider the sequence $a_1 = p$, $a_{n+1} = f(a_n)$, $n\ge 1$. Show that by compactness, there are $m$ and $n$, $n > m$, such that $d(a_m,a_n) < \epsilon$. By the isometry property of $f$, $d(f^{n-m}(p), p) < \epsilon$, which contradicts $B_\epsilon(p)\cap f(X) = \emptyset$.

Suppose $f$ is not an isometry. Pick $x \in X \setminus f[X]$. Then let $\epsilon > 0$ be such that $\epsilon < d(x, f[X])$. $X$ can be covered by finitely many open sets of diameter $< \epsilon$, by compactness. Let $N$ be the smallest size of such a covering, and $\mathcal{U} = \{O_1,\ldots,O_N\}$ a witnessing cover. If $x \in O_i$, then $f[X]$ does not intersect $O_i$, so $f[X]$ is already covered by $\mathcal{U} \setminus \{O_i\}$, which has $N-1$ elements. Then $\{f^{-1}[O_j]: j \neq i \}$ covers $X$, consists of open sets, and the isometry property guarantees that all diameters are $< \epsilon$. This contradicts the minimality of $N$, contradiction.