Is irrational number set on $\mathbb{R}$ disconnected

connectednessirrational-numbersreal-analysis

I thought that irrational numbers on $\mathbb{R}$ must be disconnected, since for every pair of irrational numbers, we have infinitely many rational numbers between this two hence they do not touch each other at all. But I couldn't form a disconnection between them. Is my reasoning true, and if it is false could you provide me why? Thanks in advance.

Best Answer

Consider the sets $(-\infty,0)\setminus\mathbb Q$ and $(0,\infty)\setminus\mathbb Q$. Each of these sets is a non-empty open subset of $\mathbb R\setminus\mathbb Q$ and they are disjoint. Therefore, $\mathbb R\setminus\mathbb Q$ is disconnected.