# How can I prove that the set (a,b) is open

A little background on me. I graduated with a degree in statistics, but I am returning to take a few more rigorous mathematics courses in hopes to pursue probability/statistics at a more rigorous level. I am currently having trouble getting comfortable proving that a set is open. My professor has given us some more complex (at least to me) examples, such as proving the set $$\{f:[0,1] \longrightarrow \mathbb{R}; f \ is \ continuous\}$$ Along with other examples.

I do understand that in order to prove that a set is an open set, you need to prove/show that for each element in that set, there exists an open ball centred around that element that is contained in the set.

However, I would like to start proving sets are open with the most basic of examples (and I have been having trouble finding some online). Would anyone be able to provide some very basic examples of proving that a set is open, so I can gain some comfort with these types of proofs. For example, how would I prove that (a,b) is an open set by showing that for each $$x \in (a,b)$$, there exists $$r>0$$ such that $$(x-r,x+r) \subset (a,b)$$

• Pick $r=\min\{x-a,b-x\}$ and contemplate why that works. Sep 23, 2020 at 19:43
• In the last line need the containment symbol $\subset$ not $\in$. Sep 23, 2020 at 19:48
• For your set with functions, we need to know what the topology is. Presumably he's using $\|f\| = \max_{x\in [0,1]} |f(x)|$ to define a norm. Sep 23, 2020 at 21:10

Here's a detailed answer for you. Let $$x \in (a,b)$$ be arbitrary. Let $$r= \frac{1}{2}\min\{x-a,b-x\}$$. Let us show that the open ball $$(x-r,x+r)$$ is contained in $$(a,b)$$ Remember that $$(x-r,x+r)$$ is the set of all $$y \in \mathbb{R}$$ such that $$x-r < y < x+r$$. Thus, if $$y \in (x-r,x+r)$$ then $$y-x < r , so that $$y < b$$; analogously, $$-r < y-x$$. But $$r< x-a$$, so that $$-r > -x+a$$, so that $$-x+a< -r < y-x$$ and, consequently, $$a < y$$. We proved that $$a< y < b$$ and, thus, $$y \in (a,b)$$. Because $$y$$ was arbitrary, every $$y \in (x-r,x+r)$$ is also an element of $$(a,b)$$. In other words, $$(x-r,x+r) \subset (a,b)$$.
Note: the term 'open ball' is somewhat paradoxical in the present context because, well, you call $$(x-r,x+r)$$ open ball because you know that it is an open set, and this is because you know that open intervals are open sets. But this turns out to be a standard terminology in real analysis, even when the notion of open set is not yet defined.