# Is there a rational number between any two irrationals?

Suppose $i_1$ and $i_2$ are distinct irrational numbers with $i_1 < i_2$. Is it necessarily the case that there is a rational number $r$ in the interval $[i_1, i_2]$? How would you construct such a rational number?

[I posted this only so that the useful answers at https://math.stackexchange.com/questions/414036/rationals-and-irrationals-on-the-real-number-line/414048#414048 could be merged here before that question was deleted.]

• Yes, there is. This is known as the "density of the rationals in the reals", which says in fact that between any two reals numbers there is a rational number. – Avi Steiner Jun 16 '13 at 2:24
• – MJD Jun 16 '13 at 2:37
• So, wait... you asked the question, pointed to another question that already answers this... and then answered this question several days before asking it? TIME TRAVELER!!! – BlueRaja - Danny Pflughoeft Jun 16 '13 at 5:25
• @BlueRaja-DannyPflughoeft yeah, I thought that, then I read the [bit in brackets in the question]. – Lucas Jun 16 '13 at 5:53

Let $x,y\in\mathbb{R}$, $x\neq y$. Without loss of generality, suppose $x<y$. Then there exists a positive $z$ such that $y-x=z$.

By Archimedes' axiom, there exists a natural number $n$ such that $$n > \dfrac{1}{z}$$ $$nz > 1$$ $$ny - nx > 1$$ So there exists an integer $m$ such that $$nx < m < ny$$ $$x < \frac{m}{n} < y$$ i.e. $m/n$ is a rational number between $x$ and $y$.

Since $x$ and $y$ can be any real numbers, in particular they can be irrationals.

• How do you know $\exists m\in\mathbb Z:nx<m<ny$? – Alex D Feb 18 '18 at 18:24
• Hadn't really worked it out formally, but I think this works. Seems a bit complicated -- I'd be happy to hear an improvement. Let $a=nx, b=ny$. We want to show $b-a>1\implies\exists m\in\mathbb{Z},\ a<m<b$. Assume $b\in\mathbb{Z}$. Then $\lfloor b \rfloor=b$, so $\lfloor b \rfloor-y>1$ and $\lfloor b \rfloor-1>y$ is your $m$. Now assume $b\notin\mathbb{Z}$, so $\lfloor b \rfloor<b<\lfloor b \rfloor+1$. Then $b-a>1\implies b>a+1\implies \lfloor b \rfloor+1>a+1$ and $\lfloor b \rfloor>y$ is your $m$. – joeA Feb 18 '18 at 23:33
• @AlexD It seems I mixed in a $y$ in a few places where there should be an $a$. Sorry about that. Too late to edit. Hopefully it is still clear. – joeA Feb 19 '18 at 3:01
• No worries, I was asking because I was trying to understand the proof myself for my intro to analysis class. I found the step in another proof: $nx\in\mathbb R\implies\exists w\in\mathbb Z:w\le nx<w+1\implies w+1\le nx+1<(nx+(ny-nx)=ny)\implies nx<w+1<ny.$ Then $\exists m\in\mathbb Z:m=w+1\implies nx<m<ny$. – Alex D Feb 19 '18 at 3:48
• we can specifically choose $n = \lceil \frac{1}{z} \rceil$, and $m = \lceil n \times x \rceil$ – micsthepick May 9 '18 at 1:22

Let $a$ and $b$ be distinct irrationals; we lose no generality to suppose $a<b$. Assume they have equal integer parts, since otherwise there is an integer between them and the question is trivial. They have infinite decimal expansions, $.a_1a_2a_3\ldots$ and $.b_1b_2b_3\ldots$. These cannot agree in every position since otherwise $a=b$. So say they agree up to the $n-1$th position and differ at the $n$th. Then $$x= \;.b_1b_2b_3\ldots b_n 0000000\ldots$$

is a rational number strictly between $a$ and $b$:

\begin{align} a &= \;.a_1a_2\ldots a_{n-1}a_n\ldots \\& <\; .a_2a_2\ldots a_{n-1}b_n000\ldots &= x \end{align}

because $a_n < b_n$, and

\begin{align} x & = \;.b_1b_2b_3\ldots b_n 0000000\ldots \\ & < \;.b_1b_2b_3\ldots b_nb_{n+1}\ldots & = b \end{align}

because not all of $b_{n+1}, b_{n+2}, \ldots$ can be zero.

For example, there is a rational number betwen $\sqrt2 = 1.4142\ldots$ and $\sqrt3 -\frac14 = 1.482\ldots$; this method produces the rational number $1.48000\ldots = \frac{37}{25}$. You can of course do the same thing in base 2; then you get $x = 1._20111000\ldots = \frac{23}{16}$, which also works.

It would also be fairly easy to produce a similar argument based on the continued fraction expansions of $a$ and $b$, but I think this is simpler.

• Your proof contradicts itself by not allowing integers but allowing integers up to b_n. – Daniel Margolis Jun 7 '13 at 18:32
• One of us is confused, and I bet it's you. $b_n$ is not an integer. It is a decimal digit. And my proof doesn't "disallow" integers; it observes that if $a$ and $b$ have different integer parts then there is no need for a proof because there is an integer between them and the question is answered. – MJD Jun 7 '13 at 18:33
• I guess this shows that you can lead a horse to water, but you can't make him drink. – MJD Jun 7 '13 at 18:49
• @Daniel: There is no "infinite number place." Your conception of the notation "$\infty$" as a number (or occasionally a cardinality) seems to be at the root of all of your confusion. – Cameron Buie Jun 15 '13 at 3:14
• @JensSchauder If a has integer part 2 and b has integer part 3 and b is irrational, then 3 is indeed between a and b. – Chris Brooks Jun 16 '13 at 5:44

We can construct one explicitly. Assume $0\lt a \lt b$. Let $n= \max(2,\lceil \frac 2{b-a}\rceil)$. Then let $m=\lceil na \rceil$ and $a \lt \frac m n \lt b$

• @DanielMargolis: in the standard reals, there are no such. You (or the problem poser) have to specify them first and the difference will not be infinitesimal. It may be small, which makes $n$ large, but that is OK. Even if $a=\sqrt 2, b=\sqrt 2 + 10^{-100}$ this works. – Ross Millikan Jun 8 '13 at 2:06
• @DanielMargolis: Yes, it is. In fact, if you extend $\Bbb R$ with infinitesimals, it becomes incomplete. If you have an infinitesimal $\epsilon$, the set $\{\frac 1n|n \in \Bbb N\}$ has $0$ as a lower bound, but it has no greatest lower bound. – Ross Millikan Jun 8 '13 at 13:05
• If you are working in some number system that includes infinitesimals, you should say that. There is no indication in the question that you are, and all the answers to this and your other question are in the real numbers. I know very little about such systems. You seem to have an intuitive sense of how you want the infinitesimals to behave, but I don't think they can act that way. – Ross Millikan Jun 8 '13 at 13:33
• @CameronBuie: yes, he is including infinitesimals, which comes out late in this discussion, as well as another question he asks. Then he wants to lump all infinitesimals with the standard irrationals. I am not sure if it is confusion or trolling. – Ross Millikan Jun 15 '13 at 15:55
• @Daniel: Noone is claiming that irrationals have finite decimal expansions--their definitions do indeed have infinitely many decimal places. What do you mean by "an infinite decimal place," though? – Cameron Buie Jun 16 '13 at 2:32

You can apply an "argument from authority" here :). As we all know, Dedekind constructed a one-to-one correspondence between the real numbers and certain sets of rational numbers, which he called "cuts". We all accept that Dedekind's construction of the real numbers is mathematically flawless. By the way these cuts are constructed (see his 1872 paper), if there would be two irrational numbers without a rational number in between, then these two irrational numbers would correspond to the same Dedekind Cut. That would imply that there is no one-to-one correspondence between the real numbers and his cuts, hence Dedekind's construction of the reals would be incorrect (--> contradiction).

• +1 That's a really interesting argument. Never thought of that before. – SpiralRain Oct 26 '17 at 9:23

Be $a$ and $b$ two irrational numbers, with $a<b$. Since $a<b$, we have $b-a>0$. Now there are rational numbers arbitrary close to $0$, and therefore there's a rational number $q<b-a$. Now consider the set $M=\{qn: n\in \mathbb{Z}\}$. Now be $q_l$ the largest element of $M$ less than $a$, and $q_r$ the smallest element of $M$ greater than $b$. Clearly $q_r-q_l > b-a$. However, if there's no rational number between $a$ and $b$, then there's especially no element of $M$ between $a$ and $b$, because all elements of $M$ are rational. But then $q_r$ is the element of $M$ following $q_l$, that is, $q_r-q_l = q$. But by construction, $q<b-a$, so we have $b-a < q_l-q_r = q < b-a$ which is a contradiction. Therefore there's at least one element of $M$, which is a rational number, in between $a$ and $b$.

• @DanielMargolis: I didn't claim it is. – celtschk Jun 7 '13 at 23:16
• The real numbers are totally ordered, that means exactly one of $a-b>0$, $a-b=0$, $a-b<0$ is true. $a-b=0$ would mean $a=b$, but by assumption, $a$ and $b$ are different (were $a=b$, quite trivially there would be no rational number between $a$ and $b$). So this leaves $a-b>0$ and $a-b<0$. I further assumed that $a$ denotes the smaller of the two, i.e. $a<b$, which is equivalent to $b-a>0$. So $b-a>0$ by the initial assumption (but that's just a wlog assumption; if we had $a<b$, you could just use $a-b$ instead). – celtschk Jun 8 '13 at 8:39
• @DanielMargolis: There cannot be such an $R$ because all sequences of rational numbers whose absolute value eventually stays beyond any given rational number converge to $0$. So any number that is closer to $0$ than any rational number cannot be the limit of a sequence of rational numbers, in contradiction to $\mathbb{R}$ being the completion of $\mathbb{Q}$. – celtschk Jun 8 '13 at 9:19
• $1/n*irr$ is not an irrational number, it is a whole sequence of irrational numbers. And not a single one is closer to $0$ than all rational numbers. Yes, for every rational number (with the exception of $0$ itself, of course), there's an irrational number that's closer to $0$. But there's no irrational number which is closer to $0$ than every rational number, because for each irrational number there's a rational number which is even closer to $0$. – celtschk Jun 8 '13 at 10:13
• Do you really not know the difference between "thhere is no irraltional number closer to $0$ than any rational number" (true) and "for any rational number there is no irrational number closer to it" (false)? In that case, do yourself a favour and learn elementary logic. – celtschk Jun 8 '13 at 11:17

## protected by Asaf Karagila♦Jan 15 '14 at 21:21

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).