every isometry is a homeomorphism

We defined an isometry to be a bijection $f:X\rightarrow X'$ such that $d'(f(x_1),f(x_2))=d(x_1,x_2)$ $\forall x_1,x_2\in X$. Show that any isometry is a homeomorphism.

So my definition of homeomorphism is that a function $f:X\rightarrow X'$ is a homeomorphism if $f$ is a bijection and $f^{-1}$ is continuous. So I have to show that

(a) $f$ is continuous.

$\forall\epsilon>0$ pick $\delta=f^{-1}(\epsilon)$. Then it follows that $d(x_1,x_2)<\delta\implies d'(f(x_1),f(x_2))<\epsilon.$

(b) $f^{-1}$ is continuous. Is this just a reverse of (a)?


$f^{-1}(\epsilon)$ does not make sense: $f^{-1}$ is a function that maps from $X$ to $X$, not from $\mathbb{R}$ to $\mathbb{R}$. So you certainly cannot pick $\delta=f^{-1}(\epsilon)$.

To show that $f$ is continuous, note that given $\epsilon\gt 0$ if $d(x_1,x_2)\lt\epsilon$ then $d'(f(x_1),f(x_2))=d(x_1,x_2) \lt \epsilon$; this proves that $f$ is (uniformly) continuous (with $\delta=\epsilon$).

To show that $f^{-1}$ is continuous, simply note that it is an isometry, so by the first part, it is continuous as well.