12  Continuous Maps

We have been building topology in order to do analysis. This chapter is where the connection becomes explicit.

A metric space topology was defined in terms of open balls. Topological continuity was defined via preimages of open sets. These two definitions are designed to agree — and do — but the agreement is a theorem, not a tautology. The \(\varepsilon\)-\(\delta\) definition comes from calculus; the open-set definition comes from topology. That they describe the same functions is the central fact of this chapter.

12.1 Limits of functions

The correct notion of limit does not require the function to be defined at the limit point.

Definition 12.1 (Limit of a function) Let \((X, d_X)\) and \((Y, d_Y)\) be metric spaces, \(E \subset X\), \(p\) a limit point of \(E\), and \(f : E \to Y\). We say \(f(x) \to q\) as \(x \to p\), or \(\lim_{x \to p} f(x) = q\), if:

for every \(\varepsilon > 0\) there exists \(\delta > 0\) such that \[ d_X(x, p) < \delta \text{ and } x \in E \setminus \{p\} \implies d_Y(f(x), q) < \varepsilon. \]

Two features deserve emphasis. The condition \(x \neq p\) is not an afterthought — it is essential. The value \(f(p)\) (if it exists) plays no role in the definition; the limit concerns what \(f\) does near \(p\), not at \(p\). And \(p\) must be a limit point of \(E\) for the definition to be non-vacuous: we need points of \(E\) near \(p\) for the condition to have content.

NoteLimits in \(\mathbb{R}\)

The familiar case \(X = Y = \mathbb{R}\), \(E = (a,b) \setminus \{p\}\): \(\lim_{x \to p} f(x) = q\) iff for every \(\varepsilon > 0\) there exists \(\delta > 0\) with \(0 < |x - p| < \delta \Rightarrow |f(x) - q| < \varepsilon\). The \(0 <\) in \(0 < |x-p|\) is the quantitative form of \(x \neq p\).

The sequential characterisation of limits is often more convenient.

Proposition 12.1 (Sequential characterisation of limits) Let \(f : E \to Y\) and \(p\) a limit point of \(E\). Then \(\lim_{x \to p} f(x) = q\) if and only if for every sequence \((x_n) \subset E \setminus \{p\}\) with \(x_n \to p\), we have \(f(x_n) \to q\).

Proof. \((\Rightarrow)\) Suppose \(\lim_{x\to p} f(x) = q\) and let \(x_n \to p\) with \(x_n \neq p\). Given \(\varepsilon > 0\), choose \(\delta > 0\) from the limit definition. Since \(x_n \to p\), eventually \(d(x_n, p) < \delta\), so eventually \(d(f(x_n), q) < \varepsilon\).

\((\Leftarrow)\) Suppose the \(\varepsilon\)-\(\delta\) condition fails. Then there exists \(\varepsilon > 0\) such that for every \(\delta > 0\) there exists \(x \in E \setminus \{p\}\) with \(d(x,p) < \delta\) but \(d(f(x),q) \geq \varepsilon\). Taking \(\delta = 1/n\) gives a sequence \(x_n \to p\) with \(d(f(x_n),q) \geq \varepsilon\) for all \(n\), so \(f(x_n) \not\to q\). \(\square\)

Exercise. Let \(f, g : E \to \mathbb{R}\) with \(\lim_{x \to p} f(x) = A\) and \(\lim_{x \to p} g(x) = B\).

  1. Show \(\lim_{x \to p} (f + g)(x) = A + B\).
  2. Show \(\lim_{x \to p} (fg)(x) = AB\).
  3. If \(B \neq 0\), show \(\lim_{x \to p} (f/g)(x) = A/B\).

In each case, use the sequential characterisation: for any \(x_n \to p\) with \(x_n \neq p\), \(f(x_n) \to A\) and \(g(x_n) \to B\). The limit laws for real sequences then give (a) \(f(x_n)+g(x_n) \to A+B\), (b) \(f(x_n)g(x_n) \to AB\), and (c) \(f(x_n)/g(x_n) \to A/B\) (since \(g(x_n) \to B \neq 0\), eventually \(g(x_n) \neq 0\)). Since the choice of sequence was arbitrary, the sequential characterisation gives the result. \(\square\)

Limits are unique when they exist, as a consequence of Hausdorffness of metric spaces.

Proposition 12.2 (Uniqueness of limits) If \(\lim_{x \to p} f(x) = q\) and \(\lim_{x \to p} f(x) = r\), then \(q = r\).

Proof. Since \(p\) is a limit point of \(E\), there exists a sequence \(x_n \to p\) with \(x_n \neq p\). By hypothesis \(f(x_n) \to q\) and \(f(x_n) \to r\). Limits of sequences in a metric space are unique (proved earlier as a consequence of Hausdorffness), so \(q = r\). \(\square\)

12.2 Continuity at a point

Definition 12.2 (Continuity at a point) Let \((X, d_X)\) and \((Y, d_Y)\) be metric spaces, \(E \subset X\), \(f : E \to Y\), and \(p \in E\). Then \(f\) is continuous at \(p\) if for every \(\varepsilon > 0\) there exists \(\delta > 0\) such that \[ d_X(x, p) < \delta \text{ and } x \in E \implies d_Y(f(x), f(p)) < \varepsilon. \]

The difference from Definition 12.1: the condition now includes \(x = p\), so the definition is non-vacuous even at isolated points. At an isolated point of \(E\), every function is automatically continuous: for small enough \(\delta\), the only \(x \in E\) with \(d(x,p) < \delta\) is \(p\) itself, so the implication holds vacuously.

When \(p\) is a limit point of \(E\), continuity at \(p\) is exactly the condition \(\lim_{x \to p} f(x) = f(p)\): the limit exists and equals the value.

Figure 12.1: Left: \(f\) is continuous at \(p\): the image of \(B_\delta(p)\) lies inside \(B_\varepsilon(f(p))\). Right: \(f\) is discontinuous at \(p\): no \(\delta\) works for the given \(\varepsilon\).

In the left panel, whatever \(\varepsilon\) is given, the depicted \(\delta\) works: the graph does not escape the horizontal band. In the right panel, \(f\) has a jump at \(p\): no matter how small a \(\delta\) we try, the image of \((p-\delta, p+\delta)\) escapes the band of half-width \(\varepsilon\) around \(f(p)\).

Proposition 12.3 (Sequential characterisation of continuity) Let \(f : E \to Y\) and \(p \in E\). Then \(f\) is continuous at \(p\) if and only if for every sequence \((x_n) \subset E\) with \(x_n \to p\), we have \(f(x_n) \to f(p)\).

Proof. Identical to the proof of Proposition 12.1, now allowing \(x_n = p\), which contributes nothing to the conclusion. \(\square\)

Exercise. Let \(f : \mathbb{R} \to \mathbb{R}\) be defined by \(f(x) = \sin(1/x)\) for \(x \neq 0\) and \(f(0) = 0\). Show that \(f\) is not continuous at \(0\).

The sequence \(x_n = 1/(n\pi)\) satisfies \(x_n \to 0\) and \(f(x_n) = \sin(n\pi) = 0 \to 0 = f(0)\). But \(y_n = 2/(4n+1)\pi\) also satisfies \(y_n \to 0\) with \(f(y_n) = \sin((4n+1)\pi/2) = 1 \not\to 0\). Since two sequences converging to \(0\) give different limits for \(f\), the sequential characterisation says \(f\) is not continuous at \(0\). \(\square\)

Contrast this with \(g(x) = x\sin(1/x)\) for \(x \neq 0\) and \(g(0) = 0\): for any \(x_n \to 0\), \(|g(x_n)| = |x_n||\sin(1/x_n)| \leq |x_n| \to 0\), so \(g\) is continuous at \(0\).

12.3 Continuity and open sets

Definition 12.3 (Continuous function) A function \(f : X \to Y\) between metric spaces is continuous if it is continuous at every point of \(X\).

The topological characterisation of continuity — via preimages of open sets — is not merely equivalent; it reveals the essential structure of the definition.

Theorem 12.1 (Topological characterisation of continuity) Let \((X, d_X)\) and \((Y, d_Y)\) be metric spaces and \(f : X \to Y\). The following are equivalent.

  1. \(f\) is continuous.
  2. For every open set \(V \subset Y\), the preimage \(f^{-1}(V)\) is open in \(X\).
  3. For every closed set \(F \subset Y\), the preimage \(f^{-1}(F)\) is closed in \(X\).
  4. For every \(A \subset X\), \(f(\overline{A}) \subset \overline{f(A)}\).

Proof. (a) \(\Rightarrow\) (b). Let \(V \subset Y\) be open and \(x \in f^{-1}(V)\). Then \(f(x) \in V\), so there exists \(\varepsilon > 0\) with \(B_\varepsilon(f(x)) \subset V\). By continuity at \(x\), there exists \(\delta > 0\) with \(f(B_\delta(x)) \subset B_\varepsilon(f(x)) \subset V\), so \(B_\delta(x) \subset f^{-1}(V)\). Since \(x\) was arbitrary, \(f^{-1}(V)\) is open.

(b) \(\Rightarrow\) (a). Let \(x \in X\) and \(\varepsilon > 0\). The ball \(B_\varepsilon(f(x))\) is open in \(Y\), so \(f^{-1}(B_\varepsilon(f(x)))\) is open in \(X\) and contains \(x\). Hence there exists \(\delta > 0\) with \(B_\delta(x) \subset f^{-1}(B_\varepsilon(f(x)))\), i.e. \(f(B_\delta(x)) \subset B_\varepsilon(f(x))\).

(b) \(\Leftrightarrow\) (c). Preimages commute with complementation: \(f^{-1}(Y \setminus F) = X \setminus f^{-1}(F)\).

(a) \(\Rightarrow\) (d). Let \(x \in \overline{A}\). By the sequential characterisation, there exist \(a_n \in A\) with \(a_n \to x\). Continuity gives \(f(a_n) \to f(x)\). Since \(f(a_n) \in f(A)\), this says \(f(x)\) is a limit of points of \(f(A)\), so \(f(x) \in \overline{f(A)}\).

(d) \(\Rightarrow\) (b). Let \(F \subset Y\) be closed and \(A = f^{-1}(F)\). Then \(f(A) \subset F\), so \(f(\overline{A}) \subset \overline{f(A)} \subset \overline{F} = F\). Hence \(\overline{A} \subset f^{-1}(F) = A\), so \(A\) is closed. \(\square\)

Condition (d) — continuity pulls closures forward — is worth dwelling on. It says that continuous maps are “closure-preserving” in the forward direction. The reverse inclusion \(\overline{f(A)} \subset f(\overline{A})\) does not hold in general: take \(f(x) = 1/x\) on \((0,1)\); then \(f((0,1)) = (1,\infty)\) with closure \([1,\infty)\), while \(f(\overline{(0,1)}) = f([0,1])\) is not even defined at \(0\).

Figure 12.2: Continuity via preimages: \(f^{-1}(V)\) is open whenever \(V\) is open. The preimage of the ball \(B_\varepsilon(f(p))\) is an open neighbourhood of \(p\).

The equivalence (a) \(\Leftrightarrow\) (b) holds for maps between arbitrary topological spaces — exactly the definition stated in the topological spaces chapter. For metric spaces, the \(\varepsilon\)-\(\delta\) definition and the open-set definition are the same thing.

Exercise. Let \(A \subset X\). Show that \(f : X \to Y\) is continuous iff for every \(x \in X\) and every open \(V \ni f(x)\) in \(Y\), there exists an open \(U \ni x\) in \(X\) with \(f(U) \subset V\).

This is a direct restatement of (b) in local form. If \(f^{-1}(V)\) is open in \(X\) and contains \(x\), take \(U = f^{-1}(V)\). Conversely, if for each \(x \in f^{-1}(V)\) there exists open \(U_x \ni x\) with \(U_x \subset f^{-1}(V)\), then \(f^{-1}(V) = \bigcup_{x \in f^{-1}(V)} U_x\) is open. \(\square\)

12.4 Compositions and restrictions

Proposition 12.4 (Composition of continuous maps) Let \(f : X \to Y\) and \(g : Y \to Z\) be continuous. Then \(g \circ f : X \to Z\) is continuous.

Proof. For any open \(W \subset Z\), \(g^{-1}(W)\) is open in \(Y\) by continuity of \(g\), and \((g \circ f)^{-1}(W) = f^{-1}(g^{-1}(W))\) is open in \(X\) by continuity of \(f\). The identity \((g \circ f)^{-1}(W) = f^{-1}(g^{-1}(W))\) was proved in the functions chapter. \(\square\)

Proposition 12.5 (Restrictions) Let \(f : X \to Y\) be continuous and \(A \subset X\). Then the restriction \(f|_A : A \to Y\) is continuous (where \(A\) carries the subspace topology).

Proof. For any open \(V \subset Y\), \((f|_A)^{-1}(V) = f^{-1}(V) \cap A\), which is open in the subspace topology on \(A\) by definition. \(\square\)

12.5 Examples

Example 12.1 (Continuous functions)  

  1. Polynomial maps. Any polynomial \(p : \mathbb{R}^n \to \mathbb{R}\) is continuous, since it is built from continuous coordinate functions by addition and multiplication, which are continuous operations.

  2. The distance function. For any fixed \(A \subset X\), the function \(x \mapsto d(x, A) := \inf_{a \in A} d(x,a)\) is continuous (in fact, \(1\)-Lipschitz): \[ |d(x, A) - d(y, A)| \leq d(x, y). \] Proof of the Lipschitz bound: For any \(a \in A\), \(d(x, A) \leq d(x,a) \leq d(x,y) + d(y,a)\). Taking the infimum over \(a\) gives \(d(x,A) \leq d(x,y) + d(y,A)\), so \(d(x,A) - d(y,A) \leq d(x,y)\). Symmetry gives the other direction.

  3. Linear maps between normed spaces. A linear map \(T : (V, \|\cdot\|_V) \to (W, \|\cdot\|_W)\) between normed spaces is continuous iff it is bounded: iff there exists \(C > 0\) with \(\|Tv\|_W \leq C\|v\|_V\) for all \(v\). This is a cornerstone of functional analysis, developed in the Linear Maps chapter.

  4. Coordinate projections. The projections \(\pi_k : \mathbb{R}^n \to \mathbb{R}\) given by \(\pi_k(x_1,\ldots,x_n) = x_k\) are continuous, since \(|\pi_k(x) - \pi_k(y)| = |x_k - y_k| \leq \|x - y\|_2\).

Exercise. Show that \(f : \mathbb{R}^n \to \mathbb{R}^m\) is continuous if and only if each component function \(f_i := \pi_i \circ f\) is continuous.

If \(f\) is continuous, each \(f_i = \pi_i \circ f\) is a composition of continuous maps, hence continuous.

Conversely, suppose each \(f_i\) is continuous. For any \(x_n \to x\) in \(\mathbb{R}^n\), each coordinate \(f_i(x_n) \to f_i(x)\) by continuity. Coordinatewise convergence in \(\mathbb{R}^m\) implies convergence in the Euclidean metric: \(\|f(x_n) - f(x)\|_2 = (\sum_i |f_i(x_n) - f_i(x)|^2)^{1/2} \to 0\). So \(f(x_n) \to f(x)\), and \(f\) is continuous at \(x\). \(\square\)

12.6 Continuous maps on connected and compact spaces

The real payoff of working topologically is that properties of the domain are directly inherited by the image.

Theorem 12.2 (Continuous images of connected spaces) Let \(f : X \to Y\) be continuous. If \(X\) is connected, then \(f(X)\) is connected.

This was proved in the Connectedness and Compactness chapter. Its analytic content is the intermediate value theorem (Corollary 10.1): any continuous real-valued function on a connected space takes every intermediate value.

Theorem 12.3 (Continuous images of compact spaces) Let \(f : X \to Y\) be continuous. If \(X\) is compact, then \(f(X)\) is compact.

Likewise proved earlier. Its main consequence for real-valued functions:

Corollary 12.1 (Extreme value theorem) Let \(K\) be compact and \(f : K \to \mathbb{R}\) continuous. Then \(f\) attains its maximum and minimum.

Both theorems have a common structure: a topological property of \(X\) passes to \(f(X)\) via continuity. The proof in each case is direct: pull back an open cover of \(f(X)\) via \(f\) to get an open cover of \(X\), use the property of \(X\), and push forward.

Exercise. Let \(f : [a,b] \to \mathbb{R}\) be continuous and injective. Show that \(f\) is strictly monotone.

Since \([a,b]\) is connected, \(f([a,b])\) is connected, hence an interval. Since \(f\) is injective, the intermediate value theorem forces \(f\) to be monotone on any two-point set: if \(f(x) < f(y)\) and \(f(u) > f(v)\) for some \(x < y\) and \(u < v\) in \([a,b]\), an application of IVT on each sub-interval would produce a point mapping to a value already taken, contradicting injectivity.

More directly: suppose \(f\) is not monotone. Then there exist \(a \leq x < y < z \leq b\) with \(f(y)\) not between \(f(x)\) and \(f(z)\) — i.e. either \(f(y) > \max(f(x),f(z))\) or \(f(y) < \min(f(x),f(z))\). By IVT, the value \(f(y)\) is achieved again on \([x,y]\) or \([y,z]\), contradicting injectivity. \(\square\)

12.7 Homeomorphisms

A bijection that is continuous in both directions is the correct notion of isomorphism between topological spaces.

Definition 12.4 (Homeomorphism) A map \(f : X \to Y\) is a homeomorphism if it is a continuous bijection with continuous inverse \(f^{-1} : Y \to X\). Two spaces are homeomorphic, written \(X \cong Y\), if a homeomorphism between them exists.

Homeomorphic spaces are topologically indistinguishable: any topological property of \(X\) holds of \(Y\) and vice versa. In particular, connectedness, compactness, the separation axioms, and second-countability are all homeomorphism invariants.

A continuous bijection is not automatically a homeomorphism — the inverse need not be continuous. Requiring continuity of \(f^{-1}\) separately is not redundant.

Example 12.2 (A continuous bijection that is not a homeomorphism) Define \(f : [0, 2\pi) \to S^1\) by \(f(t) = (\cos t, \sin t)\). This is a continuous bijection. But \(f^{-1}\) is not continuous at \((1, 0) = f(0)\): the sequence \(f(2\pi - 1/n) \to (1,0)\) but \(f^{-1}(f(2\pi - 1/n)) = 2\pi - 1/n \to 2\pi \neq 0 = f^{-1}(1,0)\).

The compact-to-Hausdorff theorem removes the need to verify continuity of the inverse explicitly in the most important case.

Theorem 12.4 (Continuous bijections from compact spaces to Hausdorff spaces are homeomorphisms) Let \(f : X \to Y\) be a continuous bijection, where \(X\) is compact and \(Y\) is Hausdorff. Then \(f\) is a homeomorphism.

Proof. It suffices to show \(f^{-1}\) is continuous, equivalently that \(f\) maps closed sets to closed sets. If \(F \subset X\) is closed, then \(F\) is compact (closed subset of a compact space). Then \(f(F)\) is compact (continuous image of a compact set), hence closed in the Hausdorff space \(Y\). Since \(f\) is a bijection, \((f^{-1})^{-1}(F) = f(F)\) is closed, so \(f^{-1}\) is continuous. \(\square\)

This theorem is used repeatedly: to recognise a homeomorphism, one exhibits a continuous bijection and checks compactness of the domain and Hausdorffness of the codomain.

Exercise. Show that \([0,1]\) is not homeomorphic to \((0,1)\).

\([0,1]\) is compact and \((0,1)\) is not (it is bounded but not closed). Compactness is a homeomorphism invariant, so they cannot be homeomorphic. \(\square\)

Alternatively: \([0,1]\) has a point (either endpoint) whose removal leaves a connected space; \((0,1)\) has no such point (removing any interior point leaves a disconnected space). Removing corresponding points from homeomorphic spaces produces homeomorphic spaces, so the spaces cannot be homeomorphic. This “cut-point” argument works in contexts where compactness is harder to apply.

Exercise. Show that \(\mathbb{R}\) is not homeomorphic to \(\mathbb{R}^2\).

\(\mathbb{R} \setminus \{p\}\) is disconnected for any \(p\): it splits into \((-\infty, p)\) and \((p, \infty)\). But \(\mathbb{R}^2 \setminus \{q\}\) is path-connected for any \(q\) (go around \(q\)), hence connected.

If \(f : \mathbb{R} \to \mathbb{R}^2\) were a homeomorphism, then \(f|_{\mathbb{R}\setminus\{p\}} : \mathbb{R}\setminus\{p\} \to \mathbb{R}^2 \setminus \{f(p)\}\) would also be a homeomorphism (it’s a bijection and continuous; its inverse is the restriction of \(f^{-1}\)). But a disconnected space cannot be homeomorphic to a connected space. \(\square\)

This argument — removing a point and counting connected components — is a fundamental technique in low-dimensional topology. It distinguishes \(\mathbb{R}^n\) from \(\mathbb{R}^m\) for \(n \neq m\) in dimension \(1\), and handles all dimensions via more sophisticated invariants.

12.8 Lipschitz and uniform continuity

Continuity makes a local guarantee: for each \(\varepsilon > 0\) and each \(x\), a \(\delta > 0\) exists. The \(\delta\) is allowed to depend on both \(\varepsilon\) and \(x\). Removing the dependence on \(x\) gives a stronger condition.

Definition 12.5 (Uniform continuity) A map \(f : X \to Y\) between metric spaces is uniformly continuous if for every \(\varepsilon > 0\) there exists \(\delta > 0\) such that \[ d_X(x, x') < \delta \implies d_Y(f(x), f(x')) < \varepsilon \] for all \(x, x' \in X\).

Uniform continuity implies continuity. The converse fails: \(f(x) = x^2\) on \(\mathbb{R}\) is continuous but not uniformly continuous (\(|f(x) - f(x')| = |x+x'||x-x'|\) can be large even when \(|x - x'|\) is small, if \(x\) and \(x'\) are large).

The class that lies strictly between the two:

Definition 12.6 (Lipschitz map) A map \(f : X \to Y\) is Lipschitz with constant \(L \geq 0\) if \[ d_Y(f(x), f(x')) \leq L \cdot d_X(x, x') \] for all \(x, x' \in X\). A map with \(L < 1\) is called a contraction.

Every Lipschitz map is uniformly continuous (take \(\delta = \varepsilon/L\)). The example \(f(x) = \sqrt{x}\) on \([0,\infty)\) is uniformly continuous but not Lipschitz (the derivative blows up at \(0\)).

Figure 12.3: Hierarchy of continuity conditions for maps between metric spaces.

The fundamental theorem connecting uniform continuity to compactness:

Theorem 12.5 (Continuity on compact sets implies uniform continuity) Let \(K\) be compact and \(f : K \to Y\) continuous. Then \(f\) is uniformly continuous.

The proof appears in the Connectedness and Compactness chapter. The argument is clean: if \(f\) fails to be uniformly continuous, one extracts a sequence \((x_n), (x_n')\) with \(d(x_n, x_n') < 1/n\) but \(d(f(x_n), f(x_n')) \geq \varepsilon\); compactness gives a convergent subsequence, continuity forces both to the same limit, and the bound \(\geq \varepsilon\) provides the contradiction.

Exercise. Show that \(f(x) = 1/x\) is not uniformly continuous on \((0,1)\) but is uniformly continuous on \([a, 1]\) for any \(a > 0\).

Not uniformly continuous on \((0,1)\): Take \(x_n = 1/n\) and \(x_n' = 1/(n+1)\). Then \(|x_n - x_n'| = 1/(n(n+1)) \to 0\) but \(|f(x_n) - f(x_n')| = n - (n+1) \cdot 1 = 1\) wait, \(|1/x_n - 1/x_n'| = |n - (n+1)| = 1\) for all \(n\). So no \(\delta\) works for \(\varepsilon = 1/2\).

Uniformly continuous on \([a,1]\): \([a,1]\) is compact and \(f\) is continuous on it (since \(a > 0\)), so uniform continuity follows from the theorem above. Explicitly, \(|1/x - 1/x'| = |x' - x|/(xx') \leq |x' - x|/a^2\), so taking \(\delta = a^2 \varepsilon\) works. \(\square\)

12.9 Pointwise and uniform limits

One of the central questions of analysis is when a limit of continuous functions is continuous. The answer requires specifying what type of convergence is in play.

Definition 12.7 (Pointwise and uniform convergence) A sequence \((f_n)\) of functions \(f_n : X \to Y\) (with \(Y\) a metric space):

  • converges pointwise to \(f\) if for every \(x \in X\), \(d(f_n(x), f(x)) \to 0\);

  • converges uniformly to \(f\) if \(\sup_{x \in X} d(f_n(x), f(x)) \to 0\).

Uniform convergence implies pointwise convergence. The converse fails. The key theorem:

Theorem 12.6 (Uniform limit of continuous functions is continuous) Let \((f_n)\) be a sequence of continuous functions \(f_n : X \to Y\), and suppose \(f_n \to f\) uniformly. Then \(f\) is continuous.

Proof. Let \(x \in X\) and \(\varepsilon > 0\). Choose \(N\) such that \(d(f_N(y), f(y)) < \varepsilon/3\) for all \(y\). By continuity of \(f_N\) at \(x\), choose \(\delta > 0\) with \(d(f_N(x), f_N(x')) < \varepsilon/3\) for \(d(x,x') < \delta\). Then for \(d(x,x') < \delta\): \[ d(f(x), f(x')) \leq d(f(x), f_N(x)) + d(f_N(x), f_N(x')) + d(f_N(x'), f(x')) < \varepsilon. \qquad\square \]

The proof is the standard \(\varepsilon/3\) argument. It works because uniform convergence gives control over \(d(f_N, f)\) everywhere at once, while continuity of \(f_N\) controls the oscillation of \(f_N\) near \(x\).

The failure for pointwise convergence is a fundamental phenomenon. The sequence \(f_n(x) = x^n\) on \([0,1]\) converges pointwise to the function \(f(x) = 0\) for \(x < 1\) and \(f(1) = 1\) — a discontinuous limit of continuous functions. The convergence is not uniform: \(\sup_{x \in [0,1]} |x^n - f(x)| = \sup_{x \in [0,1)} x^n = 1\) for all \(n\).

Figure 12.4: The sequence \(f_n(x) = x^n\) on \([0,1]\) converges pointwise but not uniformly to the discontinuous limit \(f(x) = \mathbf{1}_{\{1\}}(x)\).

Exercise. Let \(f_n : [0,1] \to \mathbb{R}\) be defined by \(f_n(x) = nx(1-x)^n\). Show that \(f_n \to 0\) pointwise but \(\int_0^1 f_n(x)\,dx \not\to 0\). What does this say about interchanging limits and integrals?

Pointwise: Fix \(x \in [0,1]\). If \(x = 0\) or \(x = 1\), \(f_n(x) = 0\). For \(x \in (0,1)\), \((1-x)^n \to 0\) exponentially, and \(n(1-x)^n \to 0\) (since \(n/a^n \to 0\) for \(a = 1/(1-x) > 1\)). So \(f_n(x) \to 0\) pointwise.

Integral: By the substitution \(u = nx\), \[ \int_0^1 nx(1-x)^n\,dx = n\int_0^1 x(1-x)^n\,dx = n \cdot \frac{1}{(n+1)(n+2)} \to 1 \neq 0. \] (The integral is computed via the Beta function or integration by parts.)

So \(\int f_n \not\to \int \lim f_n\). This shows that pointwise convergence does not in general allow interchange of limit and integral — uniform convergence, or dominated convergence (from measure theory), is needed. \(\square\)