# Relation between Q and R

please how to prove these two properties:

$$(1)\quad\forall x\in\mathbb{R},\ \forall \varepsilon>0,\ \exists r\in\mathbb{Q},\ |x-r|\leq\varepsilon$$

$$(2)\quad \forall x\in\mathbb{R},\ \exists (r_n)\in\mathbb{Q},\ \displaystyle\lim_{n\to\infty} r_n=x$$

• It refers to density. – Wuestenfux Jan 11 at 9:37
• What are your definitions of $\Bbb Q$ and of $\Bbb R$? Because the details of the proof will depend on exactly how these two sets are related to one another. – Arthur Jan 11 at 9:37
• The second property is how my professor in mathematics defined $\mathbb{R}$. And the first property is a consequence of the second one – Damien Jan 11 at 10:27

We can show $$(1)$$ as follows. Let $$N > \frac{1}{\varepsilon}$$ be an integer. Then we observe that $$Nx - \left \lfloor{Nx}\right \rfloor < 1 \Leftrightarrow x - \frac{\left \lfloor{Nx}\right \rfloor}{N} < \frac{1}{N} < \varepsilon$$ So taking $$r = \frac{\left \lfloor{Nx}\right \rfloor}{N}$$, we are done.
$$(2)$$ follows from $$(1)$$ by considering a sequence $$\varepsilon_1,\varepsilon_2,...$$ with $$\varepsilon_n > 0$$ and $$\lim_{n \rightarrow \infty}\varepsilon_n = 0$$ (for instance $$\varepsilon_n = \frac{1}{n}$$). Then we can find a sequence $$r_n \in \mathbb{Q}$$ such that $$|x - r_n| < \varepsilon_n$$, from which $$\lim_{n \rightarrow \infty} r_n = x$$ follows since $$\forall \varepsilon > 0$$ there is an $$N$$ such that $$n > N$$ implies $$|x - r_n| < \varepsilon_n < \varepsilon$$ as required.