# Show that the metric space C[a,b] is complete. [duplicate]

Prove that the metric space $C[a,b]$ is complete.

Where $C[a,b]$ is the collection of continuous $f:[a,b] → R$ and $||f|| = sup_{x \in [a,b]} |f(x)|$, such that $\rho (f,g) = ||f - g||$ is a metric on $C[a,b]$.

attempt in proof:

Recall that a metric space X is said to be complete if and only if every Cauchy sequence $x_n \in X$ converges to some point in $X$.

Let $f_n$ be a Cauchy sequence in $C[a,b]$, then $\forall \epsilon > 0,$ there is $N$ such that $||f_n - f_m|| < \epsilon$ for $n , m \geq N$ implies $||f_n - f_m || = sup |f_n - f_m | < \epsilon$.

Now for

$x \in [a,b]$, $|f_n - f_m | \leq sup_{x \in [a,b]} |f_n(x) - f_m(x)| < \epsilon$ for $n \geq N$.

Thus $f_n(x)$ converges uniformly to $f(x)$ .

And each $f_n$ is continous on $[a,b]$, and $f_n → f$ uniformly on $[a,b]$.

Thus, $f \in C[a,b]$. So $C[a,b]$ is complete.

Can someone please give some feedback? I don't know if I can conclude that $f_n$ converges uniformly to $f$. Can someone please help? Thank you in advance.

## marked as duplicate by Pedro Tamaroff♦Apr 8 '15 at 3:10

• You almost proved that there exists a function f to which f converges pointwise. You need to prove that f is continuous! – mich95 Apr 8 '15 at 3:06
• – Jonas Meyer Apr 8 '15 at 3:07

I don't think your argument works. There are two key ideas in this type of argument. One is to begin by finding the limit, and then prove it has whatever property we want. The other is the "$\varepsilon/3$" trick, which helps you relate regularity of the limit back to regularity of the members of the sequence.

In this case, the first idea goes through smoothly. You define $f$ to be the pointwise limit of the $f_n$. This exists because each sequence of numbers $f_n(x)$ is Cauchy (specifically, $|f_n(x)-f_m(x)| \leq \| f_n - f_m \|_\infty$), and the real numbers are complete. Now we use the second idea, by noting that for any $n$ we have

$$|f(x)-f(y)| \leq |f(x)-f_n(x)|+|f_n(x)-f_n(y)|+|f_n(y)-f(y)|.$$

Now how can you control these three terms?

• So since $f_n$ is continuous , there is an $\delta > 0$ such that $|x - y| < \delta$ implies $|f_n(x) - f_n(y)| < \epsilon /3$ . If $|x - y| < \delta$ then $|f(x) - f(y)| \leq |f(x) - f_n(x) | + | f_n(x) - f_n(y)| + |f_n(y) - f(y)| < \epsilon/3 + \epsilon/3 + \epsilon/3 = \epsilon$ And so for $| x- y| < \delta$ we have $|f(x)- f(y)| < \epsilon$? Then I can conclude the proof? – Mahidevran Apr 8 '15 at 3:15
• @Mahidevran You have controlled the second term correctly. You need to use the convergence to control the first and third terms. Hint: you control the first and third terms in the exact same way. – Ian Apr 8 '15 at 3:16
• So I just mention before the inequalities for example for the first term , since $f_n$ is continuous, there is an $\delta > 0$ such that $|x - y| < \delta$ implies $|f(x) - f_n(x) | < \epsilon/3$. Then in conclusion since $f$ is continuous, $C[a,b]$ is complete? – Mahidevran Apr 8 '15 at 3:20
• For the first and third terms you get no help from continuity, because $f$ and $f_n$ are different functions. You need to use the convergence assumption. Remember that you will get $N$ so that for $n \geq N$ you have an inequality. – Ian Apr 8 '15 at 3:20
• Since the sequence converges uniformly to some $x$ say, there is some $N$ such that $n \geq N$ implies $|f(x) - f_n(x)| < \epsilon/3$ for all $x \in [a,b]$. Set $n = N +1$ , so $|f(x) - f_n(x)| < \epsilon/3$ for all x in [a,b]. – Mahidevran Apr 8 '15 at 3:25