TITLE: Continuity of Monotone Functions
QUESTION [6 upvotes]: Let f be a monotone function on the open interval (a,b). Then f is continuous except possibly at a countable number of points in (a,b).
Assume f is increasing. Furthermore, assume (a,b) is bounded and f is increasing on the closed interval [a,b]. Otherwise, express (a,b) as the union of an ascending sequence of open, bounded intervals, the closures of which are contained in (a,b), and take the union of the discontinuities in each of this countable collection of intervals. 

I was a little confused about the last sentence, because I wasn't sure of what "closure" meant. This is how my textbook defines it,

For a set E of real number, a real number x is called a point of point of closure of E provided every open interval that contians x also contains a point in E. The collection of points of closure of E is called the closure of E and denoted by $\bar{E}$...It is clear that we always have $E \subseteq \bar{E}$. 

I'm not sure if I understood this theorem correctly, because...from what I understand the (a,b) needs to be included in the closures (since $E \subseteq \bar{E}$ ) of the ascending sequences, right? But it says the opposite ("closures of which are contained in (a,b)). So could anybody try the clarify this for me? 
Thanks in advance

REPLY [5 votes]: The idea is that you write $(a,b)$ as a union of smaller intervals, $(c_i,d_i)$, say, which each have their closure, $[c_i,d_i]$, contained in $(a,b)$. So, for example, if $a$ and $b$ are finite and $b-a>\frac 2N$, you could write
$$(a,b)=\bigcup_{i\ge N} (a+\frac{1}{i},b-\frac{1}{i}). \qquad (*)
$$
To see that $(*)$ is true, notice that if  a point $x$ is in $(a,b)$, both $x-a$ and $b-x$ must be positive.  Then, taking $i$ larger than both $1/(x-a)$ and $1/(b-x)$, $x\in(a+\frac 1i, b-\frac 1i)$.
The closure of $(a+\frac{1}{i},b-\frac{1}{i})$ is $[a+\frac 1i, b-\frac 1i]$, which is contained in $(a,b)$.  
If $a=-\infty$ and $b$ is finite, you can write
$$(a,b)=(-\infty,b)=\bigcup_{i\ge 2} (b-i, b-\frac{1}{i}).
$$
The closure of $(b-i, b-\frac 1i)$ is $[b-i, b-\frac 1i]$, which is again contained in $(a,b)=(-\infty,b)$.  The case where $b=+\infty$ and $a$ is finite, and the case $a=-\infty$ and $b=\infty$, where both $a$ and $b$ are infinite, are handled similarly.
After decomposing $(a,b)$ in this way, you can restrict attention to each of the subintervals $(c_i,d_i)$.  Since there are only a countable number of $(c_i,d_i)$s, if $f$ has only a countable number of discontinuities on each $(c_i,d_i)$, it will have only a countable number of discontinuities on all of $(a,b)$.