# Find all $n\in \mathbb N$ such that $\sqrt{n+7}+\sqrt{n}$ is rational.

Find all $n\in \mathbb N$ such that $\sqrt{n+7}+\sqrt{n}$ is rational.

By inspection it is pretty easy to see that the only $n$ that will work is $n=9$. Because the distance between perfect squares grows infinitely bigger, after $n=9$ we will never have another number that you can add seven to and get a perfect square. I.e.

$25-7=18\quad$ (Need $16$, difference of $2$)
$36-7=29\quad$ (Need $25$, difference of $4$)
$49-7=42\quad$ (Need $36$, difference of $6$)
$64-7=57\quad$ (Need $49$, difference of $8$)

So on and so forth. It is easy to see we will never have another $n\in \mathbb N$ that will work but I am having trouble coming up with a sophisticated way to explain this.

I'm trying to find a way that uses something like:

For $a,b\in \mathbb Z, \sqrt{\frac{a}{b}}$ is rational if and only if $\sqrt{ab}$ is rational. And, for $m\in \mathbb Z, \sqrt{m}$ is rational if and only if $\sqrt{m}\in\mathbb N$.

I'm having trouble making the connection between knowing $n=9$ and the part with $a,b,$ and $m$.

Any suggestions are appreciated.

• We also have that for nonnegative integers $a, b$, $\sqrt{a} + \sqrt{b}$ is rational iff $a, b$ are perfect squares. This (which you might like to prove yourself) combined with your observation does the job. – Travis Willse Sep 24 '14 at 5:39

Once you've shown that for positive integers $x,y$, $\sqrt{x}+\sqrt{y}$ is rational iff $x,y$ are perfect squares, the following will help you show that the only perfect squares whose difference is $7$ are $16$ and $9$.

If $n+7$ and $n$ are both perfect squares, then, $n+7 = a^2$ and $n = b^2$ for positive integers $a,b$.

Then, we have $(a-b)(a+b) = a^2-b^2 = (n+7)-n = 7$.

So, $a-b$ and $a+b$ are two integers whose product is $7$. How many integer factors does $7$ have?

• Well, the only positive integers whose product is $7$ are $1$ and $7$. Then, either $(a-b)= 1$ or $(a-b)=7$ and the same goes for $(a+b)$. But, because $a,b \in \mathbb Z$, $(a+b)\ne 1$. So, $(a+b)=7$ and $(a-b)=1$. Then by substitution, $b=3$ which yields $a=4$ and $n=9$. – Vincent Sep 24 '14 at 6:01

$$\sqrt{n+7}=a-\sqrt n\implies n+7=a^2+n-2a\sqrt n\iff\sqrt n=\frac{a^2-7}{2a}$$

$$\implies n=\left(\frac{a^2-7}{2a}\right)^2$$ where $a$ is rational

$$n+7=\frac{(a^2-7)^2}{4a^2}+7=\frac{(a^2+7)^2}{4a^2}$$

• If I am not wrong didn't you missed an n. – Jasser Sep 24 '14 at 5:56
• @user291957, Please pinpoint the mistake – lab bhattacharjee Sep 24 '14 at 6:02
• Apologies for my bad observation that is all great. – Jasser Sep 24 '14 at 6:06

Hint : $\sqrt(n+7) +\sqrt(n)=a$ where a is an rational number. Now square on both sides and then simplify for n by again squaring and see the result.