I know that $\mathcal B=\{\,\mathopen]a,b\mathclose[\mid a,b\in\mathbb Q\,\}$ is a countable basis of $\mathbb R$ (for the Euclidean metric), but I don't really understand why it's countable. I tried to find a bijection between $\mathcal B$ and $\mathbb N$ but didn't work. Could someone explain?
2026-04-17 18:51:28.1776451888
On
Why is the set $\mathcal B=\{\,\mathopen]a,b\mathclose[\mid a,b\in\mathbb Q\,\}$ countable?
359 Views Asked by Bumbble Comm https://math.techqa.club/user/bumbble-comm/detail At
2
There are 2 best solutions below
1
On
Each set $\mathopen]a,b\mathclose[$ is uncountable, but this is not of a concern: the set $\mathcal{B}$ is countable, because there is an injection $$ f\colon\mathcal{B}\to\mathbb{Q}\times\mathbb{Q} \qquad f(\mathopen]a,b\mathclose[)=(a,b) $$ (because it is assumed $a<b$) and $\mathcal{B}$ is obviously infinite.
The set $\mathbb{Q}$ is countable (see How to prove that $\mathbb{Q}$ ( the rationals) is a countable set), so $\mathbb{Q}\times\mathbb{Q}$ is countable as well.
$$\mathcal B=\bigcup_{\substack{(a,b)\in \mathbb Q\times \mathbb Q\\ a\leq b}}\big\{(a,b)\big\}.$$