[Math] Rudin mathematical analysis chapter 4 exercise 6 solution

compactnesscontinuityreal-analysis

Exercise 6, chapter 4 Rudin's "Principles of Mathematical Analysis":

If $f$ is defined on $E$, the graph of $f$ is the set of points $(x, f(x))$, for $x \in E$. In particular, if $E$ is a set of real numbers, and $f$ is rea-valued, the graph of $f$ is a subset of the plane.

Suppose E is compact, and prove that f is continuous on E if and only if its graph is compact.

The following is my solution.

Let $g(x)={(x,f(x)):x\in E}$. For every $\epsilon >0$ there exists $\delta > 0$ such that $d(g(x), g(p))=\sqrt{(x-p)^2+(f(x)-f(p))^2} < \epsilon$ for all points $x \in E$ for which $|x-p|<min(\frac{\epsilon}{\sqrt{2}}, \delta)$. For all points $x \in E$ for which $|x-p|<\delta$, we have $|f(x)-f(p)|<\frac{\epsilon}{\sqrt{2}}$. We can surely find such $\delta$ since $f$ is continuous. We can conclude that $g$ is continuous at $p$, and therefore $g(E)$, the graph is compact.

I would like to ask two questions:

  1. Is my solution to the forward part correct?
  2. How to prove the inverse part?

Thank you in advance.

Best Answer

Your proof in the forward direction looks fine. For the reverse, suppose that $E$ is compact but $f$ is not continuous. Then we can find a sequence $\{x_n,f(x_n)\}$ so that $\{x_n\}$ converges to $x$ but $\{f(x_n)\}$ does not converge to $f(x)$. By compactness of $E$ we extract a convergent subsequence $\{x_{n_k}, f(x_{n_k})\}$. We know that $f(x_{n_k})$ does not converge to $f(x)$, say it converges to some other value $y$. Then the point $(x,y)$ is the limit point of $\{x_{n_k}, f(x_{n_k})\}$ but is also not contained in $E$ a contradiction.