0

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?

egreg
  • 238,574
Peter
  • 1,005

2 Answers2

4

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.

egreg
  • 238,574
  • I guess your answer and Surb one are the same. I really like your answer, but Surb answer is more visual for me (and thus more understandable), that's why I accepted his answer. But your answer is also a very good one (but unfortunately I can't accept both). – Peter Aug 24 '18 at 22:05
1

$$\mathcal B=\bigcup_{\substack{(a,b)\in \mathbb Q\times \mathbb Q\\ a\leq b}}\big\{(a,b)\big\}.$$

Surb
  • 55,662
  • The right hand side is a set of ordered pairs, whereas $\mathcal{B}$ is a set of intervals. – egreg Aug 24 '18 at 21:43
  • @egreg: This is exactly the problem with english notation for the open interval $(a,b):={x\mid a<x<b}$. I'm french, and I usually use $]a,b[$ for the open interval ${x\mid a<x<b}$. But since here people dislike this notation, I used the english notation that is very confusing in this situation... So what I was thinking is of course $\displaystyle\mathcal B=\bigcup_{\substack{(a,b)\in \mathbb Q\times \mathbb Q\ a\leq b}}\big{]a,b[\big}$ (using french notation) – Surb Aug 24 '18 at 21:47
  • @Surb: I'm from Belgium, and we also use $]a,b[$ for the open interval. – Peter Aug 24 '18 at 22:07
  • @Surb: But under the $\bigcup$, you use $(a,b)$ in a sense where it's a element of $\mathbb Q\times\mathbb Q$, intervals aren't. - And for the record, I'm danish and use $]a,b[$ for open sets and find the notation with parentheses confusing and hard to read. – Henrik supports the community Aug 25 '18 at 08:25
  • @Henrik: Indeed, and that's the problem (for me) with english notation for open interval... – Surb Aug 25 '18 at 08:40
  • 1
    Note: That's more an argument for why the notation with parentheses for open intervals is confusing than a critique of @Surb, I can't see how he could have done any better. – Henrik supports the community Aug 25 '18 at 08:42