Show that if \(f: A\to B\) is a continuous map between metric spaces and \(K\subset A\) is compact, then \(\restrictionof{f}{K}\) is uniformly continuous.
Solution
Goal: Show that if \(f: A \to B\) is a continuous map between metric spaces and \(K \subset A\) is compact, then the restriction \(\restrictionof{f}{K}\) is uniformly continuous.
1. Assume, toward a contradiction, that \(\restrictionof{f}{K}\) is not uniformly continuous.
Then there is \(\varepsilon > 0\) and sequences \(x_n, y_n \in K\) with \(d(x_n, y_n) \to 0\) but \(d(f(x_n), f(y_n)) \geq \varepsilon\) for all \(n\).
2. \(K\) is sequentially compact.
In metric spaces, compactness implies sequential compactness (every sequence has a convergent subsequence); \(K\) is compact by hypothesis.
3. \((x_n)\) has a subsequence \((x_{n_j})\) converging to some \(x \in K\).
2.
4. \(y_{n_j} \to x\) as well.
\(d(y_{n_j}, x) \leq d(y_{n_j}, x_{n_j}) + d(x_{n_j}, x) \to 0 + 0 = 0\) using 1 and 3.
5. \(f(x_{n_j}) \to f(x)\) and \(f(y_{n_j}) \to f(x)\).
Continuity of \(f\) at \(x\), applied to the sequences 3 and 4.
6. \(d(f(x_{n_j}), f(y_{n_j})) \to 0\).
Triangle inequality: \(d(f(x_{n_j}), f(y_{n_j})) \leq d(f(x_{n_j}), f(x)) + d(f(x), f(y_{n_j})) \to 0\) by 5.
7. Contradiction.
6 contradicts \(d(f(x_n), f(y_n)) \geq \varepsilon > 0\) from 1.
8. Q.E.D.
The assumption 1 leads to a contradiction, so \(\restrictionof{f}{K}\) is uniformly continuous.