# Real Analysis

Continuous Functions

# Continuity

Let $$X$$ and $$Y$$ be metric spaces, $$E \subset X$$, $$p \in E$$, $$f : E \rightarrow Y$$. Say function $$f$$ is continuous at $$p$$ if for any $$\epsilon > 0$$, there exists $$\delta > 0$$ such that for any $$x \in E$$, $$d(x, p) < \delta$$ implies $$d(f(x), f(p)) < \epsilon$$.

Theorem. If $$p$$ is a limit point of $$E$$ then $$f$$ is continuous at $$p$$ if and only if $$\lim\limits_{x \rightarrow p} f(x) = f(p)$$. Also, if $$x_n$$ is a convergent sequence then $$f$$ is continuous if and only if $$\lim\limits_{n \rightarrow \infty} f(x_n) = f\left(\lim\limits_{n \rightarrow \infty} x_n\right)$$.

Corollary. Given $$Y \subset \mathbb{R}$$, sums and products of continuous functions are continuous; quotients $$\frac{f}{q}$$ are continuous when $$g \neq 0$$.

Corollary. $$f, g : X \rightarrow \mathbb{R}^k$$ such that $$f = (f_1, f_2, \dots, f_k)$$.

1. $$f$$ is continuous if and only if each $$f_i$$ is continuous.
2. $$f + g$$ and $$f \cdot g$$ are continuous.

Theorem. $$f : X \rightarrow Y$$ is continuous if and only if for any open set $$U \subset Y$$, $$f^{-1}(U)$$ is open in $$X$$.

Proof.

($$\Rightarrow$$): Given $$U$$ which is open in $$Y$$, consider $$x \in f^{-1}(U)$$. We’ll show $$x$$ is an interior point. Since $$U$$ is open and $$f(x) \in U$$, there exists an open ball $$B_\epsilon(f(x)) \subset U$$. By continuity of $$f$$, there exists an open ball $$B_\delta(x)$$ that maps into $$B_\epsilon(f(x)) \subset U$$. This means $$B_\delta(x) \subset f^{-1}(U)$$. So $$x$$ is an interior point of $$f^{-1}(U)$$.

($$\Leftarrow$$): Fix arbitrary $$x \in X$$ and $$\epsilon > 0$$. Consider $$B_\epsilon(f(x))$$. So, $$x \in f^{-1}(B_\epsilon(f(x)))$$, which is open by assumption. So $$p$$ is an interior point. Hence, there exists an open ball $$B_\delta(x) \subset f^{-1}(B_\epsilon(f(x)))$$. This $$\delta$$ has the required property. So $$f$$ is continuous. QED.

## Consequences

Theorem. If $$f : X \rightarrow Y$$, $$g : Y \rightarrow Z$$, $$f$$ and $$g$$ are continuous then $$g \circ f$$ is continuous.

Proof. Given $$U$$ open in $$Z$$, $$g^{-1}(U)$$ is open in $$Y$$, by continuity of $$g$$. So $$f^{-1}(g^{-1}(U))$$ is open in $$X$$, by continuity of $$f$$. But $$f^{-1}(g^{-1}(U)) = (g \circ f)^{-1}(U)$$. QED.

Theorem. $$f : X \rightarrow Y$$ is continuous if and only if for any closed set $$K \subset Y$$, $$f^{-1}(K)$$ is closed in $$X$$.

Theorem. If $$f : X \rightarrow Y$$, $$f$$ is continuous, and $$X$$ is compact, then $$f(X)$$ is compact.

Proof. Consider any open cover $$\{V_\alpha\}$$ of $$f(X)$$. Let $$U_\alpha = f^{-1}(V_\alpha)$$. By compactness of $$X$$, there exists a finite subcover $$\{U_1, \dots, U_n\}$$. Then the corresponding $$\{V_1, \dots V_n\}$$ is a finite subcover for $$f(X)$$, as desired. QED.

Corollary. If $$f : X \rightarrow \mathbb{R}^k$$ and $$X$$ is compact then $$f(X)$$ is closed and bounded.

Corollary. If $$f : X \rightarrow \mathbb{R}$$ and $$X$$ is compact then $$f$$ achieves its maximum and minimum.

Theorem. If $$f : X \rightarrow Y$$, $$f$$ is a bijection and is continuous, and $$X$$ is compact then $$f^{-1}$$ is continuous.

Proof. Suppose $$U$$ is open in $$X$$. So, $$U^c$$ is closed. Since $$U^c$$ is closed in a compact set $$X$$, $$U^c$$ is compact. Then its image $$f(U^c)$$ compact. Since $$f(U^c)$$ is compact, it is also closed. Hence $$f(U)$$ is open. Thus, $$f^{-1}$$ is continuous. QED.

Theorem. If $$f : X \rightarrow Y$$ is continuous, $$E$$ is a connected subset of $$X$$, then $$f(E)$$ is connected.

Proof (by contradiction). Suppose $$f(E)$$ is not connected. Then $$f(E) = A \cup B$$, a separation (i.e. $$A \neq \emptyset$$, $$B \neq \emptyset$$, and $$\overline{A} \cap B = A \cap \overline{B} = \emptyset$$). Notice $$K_A = f^{-1}(\overline{A})$$ and $$K_B = f^{-1}(\overline{B})$$ are closed since $$f$$ is continuous. Also notice $$E_1 = f^{-1}(A) \cap E$$ and $$E_2 = f^{-1}(B) \cap E$$ are disjoint and non-empty. Since $$E_1 \subset K_A$$, $$\overline{E_1} \subset K_A$$. Similarly, $$\overline{E_2} \subset K_B$$. Since $$K_A = f^{-1}(\overline{A})$$, $$E_2 \subset f^{-1}(B)$$, and $$\overline{A} \cap B = \emptyset$$, $$K_A \cap E_2 = \emptyset$$. Similarly, $$K_B \cap E_1 = \emptyset$$. Hence, $$E$$ is separated, which is a contradiction. QED.

Theorem (Intermediate Value). Given a continuous function $$f : [a, b] \rightarrow \mathbb{R}$$, where $$f(a) < c < f(b)$$, then there exists $$x \in (a, b)$$ such that $$f(x) = c$$.

Proof (by contradiction). Notice $$[a, b]$$ is connected. So, $$f([a, b])$$ is connected. But if $$c$$ is not achieved, then $$((c, +\infty) \cap f([a, b])) \cup ((-\infty, c) \cap f([a, b]))$$ is a separation of $$f([a, b])$$, a contradiction. QED.

The converse of the intermediate value theorem is false. Consider the topologist’s sine curve \begin{align} f(x) = \begin{cases} 0 & \text{if } x = 0 \\ \sin\left(\frac{1}{x}\right) & \text{otherwise} \end{cases} \end{align} The topologist’s sine curve is not continuous at $$0$$ but it satisfies the intermediate value property.

# Uniform Continuity

A function $$f : X \rightarrow Y$$ is uniform continuous on $$X$$ if for every $$\epsilon > 0$$, there exists $$\delta > 0$$ such that for every $$x$$ and $$p$$ in $$X$$, $$d(x, p) < \delta$$ implies $$d(f(x), f(p)) < \epsilon$$.

If $$K$$ is closed, define $$d(x, K) := \inf\limits_{y \in K} d(x, y)$$. $$d(x, K)$$ is a continuous function of $$x$$.

Lebesgue Covering Lemma. If $$\{U_\alpha\}$$ is an open cover of a compact metric space $$X$$ then there exists $$\delta > 0$$ (called the Lebesgue number of the cover) such that for every $$x \in X$$, $$B_\delta(x)$$ is contained in some $$U_\widehat{\alpha}$$ of the cover.

Proof. Since $$X$$ is compact, there exists a finite subcover $$\{U_{\alpha_i}\}_{i = 1}^n$$. Define $$f(x) = \frac{1}{n} \sum\limits_{i = 1}^n d(x, U_{\alpha_i})$$. $$f$$ is a continuous function on a compact set, so it must attain its minimum value $$\delta$$. Hence, if $$f(x) \geq \delta$$ then at least one of $$d(x, U_{\alpha_i}) \geq \delta$$. So, for this $$i$$, $$B_\delta(x) \subset U_{\alpha_i}$$. Notice $$\delta > 0$$ because $$f(x) > 0$$ at each $$x$$ due to $$U_{\alpha_i}$$. QED.

Theorem. Given $$f : X \rightarrow Y$$ and $$X$$ compact, $$f$$ is uniformly continuous on $$X$$.