# Why is a continuous mapping from a compact metric space to another metric space is uniformly continuous? [duplicate]

Why is a continuous mapping from a compact metric space to another metric space is uniformly continuous? This theorem is from Rudin Real Analysis Page 202.

• What is the definition of compact mapping? – user99914 Jun 11 '16 at 23:16
• In particular, I cannot find your theorem in Rudin "real analysis" (all three of them). Can you state precisely the reference, including the edition? – user99914 Jun 11 '16 at 23:26
• Sorry, typo. It should be continuous mapping. Updated the question. – user1559897 Jun 11 '16 at 23:37
• It goes by the name of Heine-Cantor theorem. – user228113 Jun 12 '16 at 3:51

Let $f:X\rightarrow Y$ be a continuous map defined on metric spaces such that $X$ is compact. Suppose it is not uniformly continuous, there exists $c>0$ such that for every integer $n$, there exists $x_n,y_n$ such that $d(x_n,y_n)<1/n$ and $d(f(x_n),f(y_n))>c$, you can extract a subsequence $(x_{n_k})$ from $(x_n)$ which converges towards $x$, $(y_{n_k})$ converges towards $x$, this implies that $lim_nd(f(x_{n_k}),f(y_{n_k})=0$. This is impossible since $d(f(x_{n_k},f(y_{n_k})\geq c$
• I believe a continuous map $f:X\rightarrow Y$ such that $X$ is compact – Tsemo Aristide Jun 11 '16 at 23:23