Proving a open and bounded subset of $\mathbb{R}$ is a union of disjoint open intervals Below is the proof I have written up. I would love to get some feedback on it as I have not been able to readily spot any logical holes, but that might be because I'm missing something. What's more, I would love to know if there is any way I can achieve more brevity in my argument!

Statement: An open and bounded subset of $\mathbb{R}$ is a union of disjoint open intervals.
Proof:
Let $S$ denote an open and bounded subset of $\mathbb{R}$. The empty set is both bounded and open, yet can impossibly be written as a union of disjoint open intervals, since each such is non-empty. So the statement is not true for $\varnothing$.
So suppose then $S \neq \varnothing$. Our $S$ is bounded and therefore bounded above and below. This furnishes $\sup S$ and $\inf S$. Neither of these are contained in $S$, since otherwise greater/lower elements than these would lie in $S$ and thus contradict their property of being extremities of $S$.
Take now some $x \in S$. Since $S$ is open, there is some positive real number $r(x)$ such that the open interval $\big(x - r(x), x + r(x)\big) \subset S$. In particular both halves of this open interval lie in $S$, which we state as $\big( x - r(x), x] \subset S$ and $[x, x + r(x)\big) \subset S$.
We have found an open interval containing $x$ and would now like to investigate how big we can make it before it leaves $S$.
Let's begin looking for its left extremity. The set $L_x = \{ r \in \mathbb{R} : (r, x] \subset S \}$ is not empty, owing to $\big( x - r(x), x] \subset S$. And if $r$ is a real number smaller than $\inf S$, then $(r, x] \not \subset S$. Therefore each element in $L_x$ is bounded below by $\inf S$. This furnishes $\inf L_x$.
The real number $\inf L_x$ has two properties:

*

*$\inf L_x \in L_x$
If not, then $( \inf L_x, x] \not \subset S$. So there is a $t \in (\inf L_x, x]$ such that $ t \not\in S$. But since $\inf L_x < t$, there is some $\alpha \in L_x$ such that $ \alpha < t$. All together: $\inf L_x < \alpha < t \leq x$, so for that reason $t \in (\alpha, x] \subset S$. But this contradicts $t \not \in S$.


*$\inf L_x \not \in S$
If not, then there is some real $\epsilon > 0$ such that $(\inf L_x - \epsilon, \inf L_x] \subset S$ (since $S$ is open). By property 1, $[\inf L_x, x] \subset S$ and therefore $[\inf L_x - \frac {\epsilon}2, x] \subset S$. But then $\inf L_x - \frac {\epsilon}2 \in L_x$, which contradicts the greatest lower bound property of $\inf L_x$.
So we have found the left extremity and conclude $(\inf L_x, x] \subset S$.
For the right extremity, the argument is analogous. We get $[x, \sup R_x) \subset S$, where $R_x = \{ r \in \mathbb{R} : [x, r) \subset S \}$.
Thus the largest interval containing $x$ is $I_x = (\inf L_x, \sup R_x) \subset S$.
We now know how to create a maximally large interval around any point in $S$. What remains to be checked is if these intervals are disjoint. If $I_x$ contains all elements of $S$, there is nothing left to prove. So suppose there is some other $y \in S$ such that $ y\not \in I_x$.
Then, without loss of generality, say $y > \sup R_x$. Then $L_y = \{r \in \mathbb{R} : (r, y] \subset S\}$ is bounded below by $\sup R_x$. From this it follows $\inf L_y \geq \sup R_x$. Thus the interval $I_y = (\inf L_y, \sup L_y)$ has no elements from $I_x$.
We can continue generating disjoint intervals in this fashion until we have captured all elements of $S$. Thus $S$ is a union of disjoint open intervals. $\blacksquare$

If it is logically correct: Is there anything I could improve, or perhaps shorten?
Thanks!
 A: Technically $\varnothing$ is an open interval, e.g., $(0,0)$, though some definitions of open interval exclude this case. At the end of your argument you can’t properly speak of continuing to generate these intervals unless you describe some recursive procedure for doing so. Fortunately, it’s not necessary to do so: your $x$ was an arbitrary element of $S$, so you have in fact constructed $I_x$ for each $x\in S$, and you’ve shown that these intervals are pairwise disjoint. Thus, your final paragraph is superfluous: you were done at the end of the penultimate paragraph.
Apart from those two reservations, the proof is fine.
There is an alternative approach that is a little shorter. Define an equivalence relation $\sim$ on $S$ by setting $x\sim y$ iff $x\le y$ and $[x,y]\subseteq S$, or $y\le x$ and $[y,x]\subseteq S$, and for each $x\in S$ let $I_x$ be the $\sim$-equivalence class of $x$. The family $\{I_x:x\in S\}$ is automatically pairwise disjoint, so we need only show that each $I_x$ is an open interval. It’s clear from the definition of $\sim$ that $I_x$ is order-convex, i.e., that if $a,c\in I_x$ and $a\le b\le c$, then $b\in I_x$, and the boundedness of $S$ ensures that it is not a ray or the whole line, so $I_x$ must be an interval. Your argument that $\inf L_x\notin S$ is easily adapted to show that the interval $I_x$ does not contain its endpoints and is therefore open.
A: As I commented above, your main issue is that it's not clear that your inductive procedure will in fact exhaust your set.  In fact, surprisingly, one could construct an adversarial example where you construct a sequence of disjoint maximal open intervals which fail to exhaust $ S $.  The order in which you construct them, surprisingly, matters.
To fix this issue, enumerate all of the rational points in $ S\cap\mathbb{Q} $, calling them $ r_1, r_2, r_3, \ldots $.  Since every open interval in $ S $ contains one of these, the maximal-sized open intervals $ I_{r_i} $ (which you constructed) are now guaranteed to exhaust $ S $.  See if you can fill in the details on why this is true.
(My claim above is very surprising, so let me provide an example: $ S = \bigcup_{n=1}^\infty{(\frac{1}{2n}, \frac{1}{2n+1})} $.  Your inductive procedure could easily produce the set $ T = \bigcup_{n=2}^\infty{(\frac{1}{2n}, \frac{1}{2n+1})} $, which fails to exhaust $ S $.)
