# Thread: example of a set

1. ## example of a set

Can anyone think of an example of a set $\displaystyle B$ of real numbers such that $\displaystyle B \subseteq [0,1]$, $\displaystyle B$ is dense, countable and consists entirely of irrational numbers? I can't think of any.

(Let $\displaystyle X$ be a set and let $\displaystyle \leq$ be a total order on $\displaystyle X$. We say that $\displaystyle X$ is dense if for any two $\displaystyle x,y \in X$ with $\displaystyle x < y$ there exists $\displaystyle z \in X$ such that $\displaystyle x<z<y$)

2. Originally Posted by Jason Bourne
Can anyone think of an example of a set $\displaystyle B$ of real numbers such that $\displaystyle B \subseteq [0,1]$, $\displaystyle B$ is dense, countable and consists entirely of irrational numbers
It is clearly true that such a set must exist.
But I do not know how to give a ‘constructive’ proof of the set.
I hope someone else can do it. I can show it using the axiom of choice.
Here is an outline.
The set of ordered pairs of rational numbers $\displaystyle \left( {p,q} \right)\,,\,0 < p < q < 1\,$ is countable.
Between any two numbers there is an irrational number.
Thus using that we can produce the required set.
Such a set is clearly dense in $\displaystyle \left[ {0,1} \right]$ and must be countable.

3. Originally Posted by Jason Bourne
Can anyone think of an example of a set $\displaystyle B$ of real numbers such that $\displaystyle B \subseteq [0,1]$, $\displaystyle B$ is dense, countable and consists entirely of irrational numbers? I can't think of any.

(Let $\displaystyle X$ be a set and let $\displaystyle \leq$ be a total order on $\displaystyle X$. We say that $\displaystyle X$ is dense if for any two $\displaystyle x,y \in X$ with $\displaystyle x < y$ there exists $\displaystyle z \in X$ such that $\displaystyle x<z<y$)
Consider the set $\displaystyle B \subseteq [0,1]$ where the elements of $\displaystyle B$ consist of $\displaystyle \frac{p}{\pi q}$ where $\displaystyle \frac{p}{q}$ is rational and between 0 and 1.

Since we define $\displaystyle 0 \leq \frac{p}{q} \leq 1$, then $\displaystyle 0 \leq \frac{p}{\pi q} \leq 1$ as well. That verifies the first requirement.

It is countable because there exists a bijection from the rationals of $\displaystyle [0,1]$ (which are countable) to the set $\displaystyle B$. Specifically, the bijection just takes an element of the rationals of $\displaystyle [0,1]$ and divides it by pi.

It is irrational since there is no way to express any $\displaystyle \frac{p}{\pi q},p \in Z, q \in Z$ as a ratio between two integers.

And it is dense because the rationals are dense, so too will $\displaystyle B$

$\displaystyle QED$

Note that this could have worked with any irrational number, such as $\displaystyle \sqrt{2}$ or $\displaystyle e$ or whatever.

Also note that if a set is dense, it cannot be finite. So by definition, it must be countably infinite or uncountable infinite anyway.

4. Originally Posted by Last_Singularity
Consider the set $\displaystyle B \subseteq [0,1]$ where the elements of $\displaystyle B$ consist of $\displaystyle \frac{p}{\pi q}$ where $\displaystyle \frac{p}{q}$ is rational and between 0 and 1.

Since we define $\displaystyle 0 \leq \frac{p}{q} \leq 1$, then $\displaystyle 0 \leq \frac{p}{\pi q} \leq 1$ as well. That verifies the first requirement.

It is countable because there exists a bijection from the rationals of $\displaystyle [0,1]$ (which are countable) to the set $\displaystyle B$. Specifically, the bijection just takes an element of the rationals of $\displaystyle [0,1]$ and divides it by pi.

It is irrational since there is no way to express any $\displaystyle \frac{p}{\pi q},p \in Z, q \in Z$ as a ratio between two integers.

And it is dense because the rationals are dense, so too will $\displaystyle B$

$\displaystyle QED$

Note that this could have worked with any irrational number, such as $\displaystyle \sqrt{2}$ or $\displaystyle e$ or whatever.

Also note that if a set is dense, it cannot be finite. So by definition, it must be countably infinite or uncountable infinite anyway.
you need to be careful here: if $\displaystyle r_n=\frac{p_n}{q_n} \in [0,1],$ then $\displaystyle \frac{r_n}{\pi} \in [0, 1/\pi]$ and therefore they can't be dense in $\displaystyle [0,1].$ to fix this problem you need to choose $\displaystyle r_n \in [0, \pi].$

5. Thank you for the good catch, NonCommAlg

Sorry for the mistake, Jason Bourne.

6. Originally Posted by Last_Singularity
Thank you for the good catch, NonCommAlg

Sorry for the mistake, Jason Bourne.
No worries, it's easily done. Thanks for all the help.