# Collection of open intervals $(a,b) \ a,b\in \mathbb{Q}$ is a basis for euclidean topology on $\mathbb{R}$

I'm not sure if this question hasn't already been asked here, but I couldn't find it.

I'm currently studying topology and I'm reading a book which unfortunately has no answers to the exercises.

Here it one:

Let $\mathcal{B}$ be the collection of all intervals $(a,b)$, $\ a<b, \ \ a,b \in \mathbb{Q}$.

Prove that $\mathcal{B}$ is a basis for euclidean topology on $\mathbb{R}$.

I know that if $a,b \in \mathbb{R}$ then the collection of such intervals would be a basis for euclidean topology on $\mathbb{R}$, because a subset of $\mathbb{R}$ is open iff it is a union of open intervals.

I also know that $\mathcal{B}$ is a basis for a topology on $X$ iff

(1) $X= \bigcup_{B \in \mathcal{B}}$ B

(2) $\forall B_1, B_2 \in \mathcal{B} \ : \ B_1 \cap B_2$ is a union of elements of $\mathcal{B}$.

But using this wouldn't lead anywhere because it only shows that $\mathcal{B}$ is a basis for a topology on $\mathbb{R}$ and not the euclidean one.

How can I use to prove the above lemma? Could you help me with that?

Thanks.

-
You need to show that for an open set $U$ in $\mathbb R$ and a point $x\in U$ there is an interval with rational end points $(a,b)$ such that $x\in(a,b)\subseteq U$. This implies that the collection $\mathcal B$ generates a topology finer than the euclidean. – Stefan Hamcke Mar 1 '13 at 21:41
So I just need to use the fact that the set of rational numbers is dense, is that right? – Hagrid Mar 1 '13 at 21:43
Yes, you are using the fact that $\mathbb Q$ is dense in $\mathbb R$. – Stefan Hamcke Mar 1 '13 at 21:46
(1) is what I'd call "really obvious." $$\mathbb R =\cup_{n\in\mathbb N}[-n,n]$$ – Thomas Andrews Mar 1 '13 at 22:09
Ok, but intersection of two intervals with rational endpoints is an interval with rational endpoints or an empty set (empty union).Either way, it belongs to the basis. – Hagrid Mar 1 '13 at 22:13