Prove if $x$ and $y$ are real numbers with $x \lt y$, then there are infinitely many rational numbers in the interval $[x,y]$.

What I got so far:

Let $x,y \in \Bbb R$ with $x \lt y$

Let $S = [x,y]$

By the density of $\Bbb Q$ in $\Bbb R$, $\exists r \in \Bbb Q$ such that $x \lt r \lt y$ where $r \in S$.

This is where I got stuck.

  • $\begingroup$ do the same with the interval $[x,r]$... and repeat and repeat infinitely many times (use induction if you prefer) $\endgroup$ – Tito Eliatron Mar 12 at 19:20
  • 1
    $\begingroup$ @dmtri This is not the correct way to do it. Example : $x=0$ and $y=2$. You will pick a rational in every $[1/n, 2-1/n]$, but how can you know that you are not picking the rational $1$ at each step ? Therefore, this does not tell you that $[0,2]$ contains an infinity of rationals. $\endgroup$ – TheSilverDoe Mar 12 at 19:24
  • $\begingroup$ @TheSivlerDoe, you are right, $\endgroup$ – dmtri Mar 12 at 19:34

If you have only $n$ finitely many rational numbers between $x$ and $y$, put them in order, $x, r_1, r_2, \ldots r_n, y$. Can you now prove that there were more than $n$ rational numbers between $x$ and $y$? If so, you have contradicted your original assumption that there were only $n$ such numbers, which means no such $n$ can exists and there must be infinitely many rational numbers between $x$ and $y$.

  • $\begingroup$ I wrote out a new proof on this thread. Care to critique? $\endgroup$ – Ash Mar 12 at 20:35

Just find two distinct rational numbers $p,q\in[x,y]$. Now the rational number $p+(q-p)/n$ is in $[x,y]$ for all $n\in \Bbb N_{>0}$.

(And you can find such $p,q$ in the intervals $[x,x+(y-x)/3]$ and $[x+2(y-x)/3,y]$.)


Okay, so I'll give it another shot given the feedback.


Let $x,y \in \Bbb R$ with $x \lt y$ and $S = [x,y]$

Suppose there are only $n$ rational numbers between $x$ and $y$ such that:$$x \lt r_1 \lt \cdot \cdot \cdot \lt r_n \lt y$$

But since $\Bbb Q$ is dense in $\Bbb R$, there exists $r_{n+1} \in \Bbb Q$ such that: $$ x \lt r_{n+1} \lt r_1 \lt \cdot \cdot \cdot \lt r_n \lt y$$

which contradicts our assumption that there are only $n$ rational numbers in $[x,y]$.

Therefore, there must be infinitely many rational numbers in the interval $[x,y]$.

  • $\begingroup$ @Robert Shore, how's this? $\endgroup$ – Ash Mar 12 at 20:34
  • $\begingroup$ Slightly sloppy but fundamentally correct. As framed, it only works if $n \geq 2$, because you need that in order to know that there are $r_k$ and $r_{k+1}$ to stuff the new rational between. Better to simply put the new rational between $x$ and $r_1$. Finally, I think you know that $x \lt r_1$, not just that $x \leq r_1$. $\endgroup$ – Robert Shore Mar 12 at 20:39
  • 1
    $\begingroup$ @RobertShore thank you for the feedback $\endgroup$ – Ash Mar 12 at 20:45
  • $\begingroup$ With your newest edits, it's now correct. As a matter of exposition, I'd probably elaborate a little (a phrase or a sentence) on the contradiction that you've demonstrated but your math and your logic are both correct. $\endgroup$ – Robert Shore Mar 12 at 20:48

Consider the interval $[x,y]$. Find two rational numbers $q_{min}$ and $q_{max}$ such that $x < q_{min} < q_{max} < y$. Let $r=q_{min}-q_{max}$. Now make a new number: $q_1 = q_{min} + r/2$. Let $r_1=q_{max}-q_1$. Now make a new number: $q_2=q_1+r_1/2$. Let $r_2=q_{max}-q_2$. Follow the pattern. Each of these numbers is a rational number; each number is unique. The set constructed is countably infinite in size.

  • 2
    $\begingroup$ We are not given that $x$ and $y$ are rational. So your numbers will not in general be rational. $\endgroup$ – TonyK Mar 12 at 19:30
  • $\begingroup$ @TonyK Did I fix it? $\endgroup$ – NicNic8 Mar 12 at 21:12
  • $\begingroup$ Yes, I think so. But that $q^{(1)}$ notation is hard on the eyes! $\endgroup$ – TonyK Mar 12 at 21:24
  • $\begingroup$ @TonyK Tough customer. :) $\endgroup$ – NicNic8 Mar 13 at 15:37
  • $\begingroup$ And now you have two different $q_1$'s... $\endgroup$ – TonyK Mar 13 at 15:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.