# Prove that $[a,b]$ is compact

Let $a<b$ be real numbers. Prove that $[a,b]$ is compact.

Below I present my solution. I thought it's good enough, but my TA said it's incorrect. I don't see where there is a problem. Could you help me find it?

My proof:

Let $\{U_i\}_{i\in I}$ be an open cover of $[a,b]$. Let $$S=\{x\in [a,b]: x>a \mbox{ and } [a,x] \mbox{ is covered by a finite union of sets from }\{U_i\} \} \mbox{.}$$

It is clear that $S$ is bounded. Moreover, $S$ is not empty because there is $j\in I$ such that $a\in U_j$. Since $U_j$ is open, there is some $\epsilon>0$ such that $[a,\epsilon) \subset U_j$, therefore $a+\frac{\epsilon}{2}\in S$.

We have showed that $S$ is bounded and not empty so there exists $\sup S$. We claim that $\sup S=b\in S$.

It's obvious that $\sup S \in U_k$ for some $k\in I$ and $\sup S \le b$. Assume $c=\sup S<b$. Then there is $\delta>0$ such that $[c, c + \delta)\subset U_k$ and $[c, c + \delta)\subset [a,b]$. But this means that we can cover $[a,c + \frac{\delta}{2}]$ by finitely many sets from $\{U_i\}$, so $c$ is not the supremum. Thus it must be the case that $\sup S=b$.

• Did your TA not show you? Perhaps you have been given a problem to find the error in the proof...?
– Paul
Commented Dec 16, 2015 at 13:32
• No, it was an assignment to prove this fact. He did not say what is wrong. Commented Dec 16, 2015 at 13:34
• Is it obvious that S includes all points in [a, b] so that S is [a, b]?
– Paul
Commented Dec 16, 2015 at 13:45
• @Paul Good point. Commented Dec 16, 2015 at 14:02

You have showed that $S$ is a subset of $[a,b]$ with minimum $a$ and supremum $b.$ By definition of $S,$ one can (and should) prove that either $S=[a,b)$ or $S=[a,b].$ You must rule out $S=[a,b).$

• This is straightforward, since $b$ is in some open $U_k$. But it is a good remark. Commented Dec 16, 2015 at 13:59
• In other words, showing $b \in S$ will make the proof correct.
– Qian
Commented Dec 16, 2015 at 14:06

Let $$G_\alpha$$ be an open cover of $$[a,b]$$ with no finite subcover. Then divide this interval in exactly two halves and assume that one of them is not covered by finitely many $$G_\alpha$$'s since otherwise we will have a finite subcover. Now call this interval $$A_1$$ and $$A_0=[a,b]$$. Now divide $$A_1$$ in exactly two halves and by same argument we can the interval $$A_3$$ with no finite subcover . continuing in this way we get a sequence of nested intervals $$A_0 , A_1 , A_2$$, and so on. We see that if $$x , y \in A_n$$, then $$|x-y| \le \frac{|a-b|}{2^n}$$.

By the nested interval property there is a point in the intersection of $$A_n$$'s, then $$m \in \mathbb{N}$$ for which $$A_m$$ is contained in some $$G_\alpha$$ (why?) And this is a contradiction

• Thanks, this is the standard argument - I have seen it on wikipedia in general proof. Commented Dec 17, 2015 at 10:40

A subset of $$\mathbb{R}$$ is compact iff it is closed and bounded. If we set $$M=\max \{|a|,|b|\},$$ then $$\forall\, x \in[a, b]$$ it automatically follows $$|x| \leq M$$, with which we have already shown that the set $$[a, b]$$ is bounded.

Now let the interval $$[a, b]$$ be closed. We have to prove $$x \in[a, b]$$, that is $$a \leq x \leq b$$. Since $$x_n \in[a, b]$$, that is $$a \leq x_n \leq b$$, holds for every $$n \in \mathbb{N}$$, by the sandwich criterion for sequences at the limit $$n \rightarrow+\infty$$ it just follows $$a \leq \lim _n x_n \leq b$$ and therefore $$x \in[a, b]$$ as desired. Thus the interval $$[a, b]$$ is compact.

(Sandwich Criterion) Let $$I$$ be an interval containing a value $$a$$. Let $$f, g$$ and $$h$$ be functions defined on $$I \backslash\{a\}$$. If for each $$x \neq a$$ from $$I$$ holds $$g(x) \leq f(x) \leq h(x),$$ as well as $$\lim _{x \rightarrow a} g(x)=\lim _{x \rightarrow a} h(x)=L,$$ then $$\lim _{x \rightarrow a} f(x)=L .$$