I am taking an online maths course and I got little confused on the concepts of open and closed intervals. In the lecture, professor says there is a big difference between $(a, b)$ and $[a, b]$. The reason isn't very clear. To me it looks like they are very similar. The interval $(a, b)$ has two numbers fewer than $[a, b]$. In other words $(a, b)$ has all members of $[a, b]$ except $a$ and $b$. Clearly my reasoning must be false since professor has emphasized there is a big difference. Can anyone give the reason why there is a big difference?
$\endgroup$ 72 Answers
$\begingroup$There is a HUGE difference between closed and open intervals. To explain why, I will make a list of some properties of continuous functions on $[a,b]$ and on $(a,b)$ (by "function" I always mean real-valued functions).
Every continuous function $f(x)$ on $[a,b]$ is bounded: there are numbers $m$ and $M$ such that $m \leq f(x) \leq M$ for all $x$ in $[a,b]$. This is false for some continuous functions on $(a,b)$, such as $1/(x-a)$, which leaks to $\infty$ on the left (vertical asymptote).
Every continuous function on $[a,b]$ is integrable (this assumes you have taken calculus, so you know what that means). This is not true for some continuous functions on $(a,b)$. That every continuous function on $[a,b]$ is integrable is closely related to every continuous function on $[a,b]$ satisfying a strong property called unform continuity, which is not satisfied by some continuous functions on $(a,b)$.
The image (set of all values) of every continuous function $f(x)$ on $[a,b]$ is also a closed interval $[c,d]$. This is not true of some continuous functions on $(a,b)$, such as $f(x) = (x-(a+b)/2)^2$, whose values are the half-open interval $[0,((a-b)/2)^2)$.
Mathematicians recognize all of these properties of the continuous functions on $[a,b]$ as being related to $[a,b]$ being what is called "compact". It is a subtle property to appreciate until you starting proving theorems about continuous functions. All the continuous functions on a compact set have a long list of attractive properties, which can fail for some continuous functions on a noncompact set. That $[a,b]$ is compact while $(a,b)$ is not is why $[a,b]$ and $(a,b)$ are regarded as enormously different from each other.
I once had a student in my office who said that the student's real analysis professor was going on and on about $[0,1]$ vs. $(0,1)$ and the student did not understand what the big deal was, since they seem to be practically the same sets except one contains its endpoints and the other doesn't. I laughed and said this seemingly minor distinction is in fact a HUGE distinction that accounts for the central role of closed bounded intervals in analysis. I do not know if the student ever came to appreciate this distinction.
It's not the case that open intervals are always terrible things. Indeed, continuous functions on all intervals (closed, open, half-open) have the nice property that their image is again an interval. In topology this is subsumed under the property that intervals are the "connected sets" in the real line. What makes $[a,b]$ better than $(a,b)$ is that $[a,b]$ is connected and compact, while $(a,b)$ is connected but not compact.
All the distinctions I have made above between $[a,b]$ and $(a,b)$ are related to the area of math called topology. In other areas of math the intervals $(a,b)$ and $[a,b]$ behave in very similar ways. For example, these two intervals have essentially the same properties as far as the subject called measure theory is concerned (I have in mind properties of Lebesgue measure on $[a,b]$ and $(a,b)$). In measure theory there is no profound difference between $[a,b]$ and $(a,b)$. Measure theory is generally studied after topology, not before it.
$\endgroup$ 1 $\begingroup$I don't know what kind of course this is, but differences occur, for example, at the topological level. Closed intervals are compact, which is an extremely useful property to have.
For example, suppose $I$ is some interval (either open, closed, or half-open) and $f$ is a continuous function. Does $f$ achieve a maximum and minimum value on $I$? The answer is "Yes if $I$ is closed", but this might not be the case otherwise. Consider, for example, $f(x)=1/x$ on the interval $(0,1)$.
Now, on each $[c,1]$ for $c>0$, $f$ achieves a maximum value. The problem is that, as $c$ gets closer and closer to $0$, these maximum values blow up and become arbitrarily large. So, the problem stems from the fact that we can, while living in the interval, get as close as we want to $0$ without actually touching the "problem point". This is not the case for the closed interval.
This type of situation occurs very frequently in analysis. You have some object that behaves more and more erratically as you get towards the boundary of whatever set your working in. However, if the boundary is contained in the set, and you know your object behaves well on the set, we avoid the problem altogether. This last paragraph is, of course, rather hand-wavy, but hopefully it provides some intuition.
$\endgroup$