How to show that $C=C[0,1]$ is a Banach space

Let $C=C[0,1]$ be the space of all continuous functions on $[0,1]$. Define $\|f \|=\max \ |f(x)|$. I want to show that $C$ is a Banach space.

Below is my attempt and I was wondering if it's ok.

I know I have to show that $C$ is a complete normed space.
Clearly, $\|f\| \geqslant 0$ and $\|f\|=0 \Leftrightarrow f=0$. $\|cf \|=\max~|cf(x)|=|c|\max |f(x)|=|c| \cdot \|f\|$.
$\|f+g\|=\max~|f(x)+g(x)|\leq \max~|f(x)|+\max~|g(x)|=\|f\|+ \|g\|$.
So $C$ is a normed space.

Next, I show that every Cauchy sequence in $C$ is convergent.
Let $\{f_n\}$ be a Cauchy sequence in $C$.
Let $\varepsilon \gt 0.$ Then $\exists$ an $N_1$ such that $$ \max~|f_n(x)-f_m(x)| \lt \frac{\varepsilon}{2}$$ for $n, m \gt N_1$ and $x\in[0,1]$.

But there is a subsequence $f_{k_n} $, which converges to $f$. So $\exists$ an $N_2$ such that $$ \max~\left|f_{k_n} - f\right|\lt \frac{\varepsilon}{2}$$ for each $n\gt N_2$.

Now Let $N = \max\{N_1, N_2\}$, if $n \gt N$ then $k_n \geqslant n\gt N$. So we have $$ \max~\left|f_n(x) - f(x)\right| \leqslant \max~\left|f_n - f_{k_n}\right| + \max~\left| f_{k_n} - f\right| \lt\frac{\varepsilon}{2} + \frac{\varepsilon}{2} = \varepsilon.$$ Thus, $\|f_n-f\| \to 0$ as $n\to \infty$. $\quad \square$

Thanks.


Where do you get this subsequence $\{f_{n_k}\}_k$? Since a Cauchy sequence is convergent if and only if it has a convergent subsequence, you're essentially assuming the result is true here.

Here's a proof that $C[0,1]$ is complete (and thus a Banach space):

Suppose $\{f_n\}$ is Cauchy in $C[0,1]$. We must show that $f_n$ converges in the $C[0,1]$ norm to an $f$ in $C[0,1]$.

We first identify the "natural candidate" for $f$:

Since $\{f_n\}$ is Cauchy in $C[0,1]$, it follows that $\{f_n(x)\}$ is Cauchy in $\Bbb R$ for each $x\in[0,1]$. This observation, together with the fact that $\Bbb R$ is complete, gives us the well-defined function $f:[0,1]\rightarrow\Bbb R$ whose rule is $f(x)=\lim f_n(x)$.

Since the terms of $\{f_n\}$ get uniformly close to each other, we expect $f$ to be uniformly close to $f_m$ for large $m$:

Now let $\epsilon>0$ and choose $M$ so that $\|f_n-f_m\|_{C[0,1]}<\epsilon$ for $n, m\ge M$. Then for each $m>M$ and for any $x\in[0,1]$: $$ \tag{1} |f(x)-f_m(x)|=\lim_{n\rightarrow\infty}|f_n(x)-f_m(x)|\le \lim_{n\rightarrow\infty}\|f_m-f_n \|_{C[0,1]}\le\epsilon. $$

And, we finish up with some hand waving that should not seem arcane to someone studying Banach spaces:

From $(1)$, it follows that $f_n$ converges uniformly to $f$ on $[0,1]$. From this, it follows that $f\in C[0,1]$ (a uniform limit of continuous functions is continuous) and that $f_n$ converges to $f$ in $C[0,1]$.


Edit: A comment above leads me to remark:

$f$ is indeed continuous: Given $x\in[0,1]$ and $\epsilon>0$, choose $m$ so that $||f_n-f\,||_{C[0,1]}<\epsilon/3$ for $n\ge m$ and choose $\delta>0$ such that $|f_m(x)-f_m(y)|\le \epsilon/3$ for all $y$. Then if $|x-y|<\delta$: $$ |f(x)-f(y)| \le|f(x)-f_m(x)|+|f_m(x)-f_m(y)|+|f_m(y)-f(y)|<\epsilon. $$


The usual way to prove that $X$ compact Hausdorff $\implies C(X,\mathbb K)$ is a Banach space over $\mathbb K$ goes in two steps:

  1. Show that $B(X) := \ell^\infty(X,\mathbb K) = \{f \in \mathbb K^X \mid f$ is bounded $\}$ is a Banach space w.r.t. the sup-norm.
  2. Show that the uniform limit of a sequence of functions that are continuous at a point is continuous at that point as well. From this it follows that $C(X)$ is closed in $B(X)$.

Let $f_{n}$ be arbitrary Cauchy sequence in $C[0,1]$.

Then for a fixed $t\in C[0,1]$ $$|f_{n}(t)-f_{m}(t)|< \epsilon \text{ for all $m,n>N$ a natural number}$$

That means $f_{n}$ is a Cauchy sequence in the set of real numbers. And since the set of reals is complete, there exist $f(t_{0})\in \Bbb R$ such that $f_{n}\to f(t_{0})$ as $n\to \infty$ with $t_{0}$ arbitrary in $C[0,1]$.

For $m\ge n$, and allowing n to go to infinity, we have $$\max_{t \in{[0,1]}}|f(t)-f_{m}(t)|<\epsilon$$ $$\implies \|f-f_{m}\|<\epsilon$$

For all $n$ bigger than a natural number $N$.

Thus, $f_{n}\to f$ as $n \to \infty$.

From here you can use the uniform convergence to show that $f$ is in $C[0,1]$