# The sum of square roots of non-perfect squares is never integer [duplicate]

My question looks quite obvious, but I'm looking for a strict proof for this:

Why can't the sum of two square roots of non-perfect squares be an integer?

For example: $\sqrt8+\sqrt{15}$ isn't an integer. Well, I know this looks obvious, but I can't prove it...

## marked as duplicate by punctured dusk, Community♦Apr 6 '15 at 9:30

• Hint: $\sqrt{a}=n-\sqrt{b}$ implies $a = n^2 + b - 2n\sqrt{b}$. – Peter Košinár Jul 6 '13 at 9:27
• @PeterKošinár: Sorry, I did not see your comment while writing an answer. I did not want to spoil your educational hint! (But this is my first answer in this forum :-) – Martin R Jul 6 '13 at 9:32
• @MartinR Nothing wrong with that! It's quite common that new questions get attention from multiple people at the same time :-) Congratulations to the first answer; it's both neat and correct! – Peter Košinár Jul 6 '13 at 9:40
• See this answer. – Bill Dubuque Jul 22 '16 at 21:26

Assume that $a, b \in \mathbb N$ are not perfect squares and $\sqrt a + \sqrt b = n \in \mathbb N$. Then $$a = (n - \sqrt b)^2 = n^2 - 2 n \sqrt b + b$$ which means that $\sqrt b$ is a rational number. This contradicts the fact that the square root of an integer is either an integer or a irrational number.

More generally, for $n\in\mathbb N$ let $a_1,\ldots,a_n\in\mathbb N$ be distinct and square-free and let $c_1,\ldots,c_n\in\mathbb Q$. Then the number $s=\sum_{k=1}^nc_k\sqrt{a_k}$ is rational if and only if $c_1=\ldots=c_n=0$.

In other words, even something like $\sqrt n+\sqrt m-\sqrt k\in\mathbb Q$ has only "trivial" solutions such as $\sqrt 2+\sqrt 8-\sqrt{18}=0$, which is derived from $\sqrt 2\cdot(1+2-3)=0$.

Proof: The "if" part is trivial, so we only need to show the "only if" part. Let $\alpha_k=\sqrt{a_k}$. Then $\alpha_k$ is irrational. If $n=1$, we immediately get that $s=c_1\alpha_1\notin \mathbb Q$ unless $c_1=0$. Therefore, we may assume $n\ge 2$. For a proof by induction assume that the claim is true when $n$ is replaced by any smaller natural number. Let $\beta={\alpha_1}{\alpha_2}=\sqrt{a_1a_2}$. Since $a_1\ne a_2$ and $a_1,a_2$ are squarefree, $a_1a_2$ is not a perfect square. Thus $\beta^2\in\mathbb Q$, but $\beta\notin \mathbb Q$. Consider the fields $K:=\mathbb Q[\beta]$ and $L:=\mathbb Q[\alpha_1,\ldots,\alpha_n]$. Then $\mathbb Q\subseteq K\subseteq L$ and the extensions $L/K$ and $K/\mathbb Q$ are Galois (the only conjugates of $\alpha_k$ and $\beta$ are $-\alpha_k$ and $-\beta$ and are also $\in L$ and $\in K$, respectively). Therefore, the automorphism of $K$ that is induced by $\beta\mapsto-\beta$ can be extended to an automorphism $\phi$ of $L$. Then $\phi(\alpha_k)\in\{\alpha_k,-\alpha_k\}$ for each $k$. Let $$A_+=\{k\mid 1\le k\le n,\phi(\alpha_k)=\alpha_k\},\qquad A_-=\{k\mid 1\le k\le n,\phi(\alpha_k)=-\alpha_k\}.$$ Then $$\phi(s)=\sum_{k=1}^ nc_k\phi(\alpha_k)=\sum_{k\in A_+}c_k\alpha_k-\sum_{k\in A_-}c_k\alpha_k.$$ From $\phi(\beta)=-\phi(\beta)$ we conclude: if $1\in A_+$ then $2\in A_-$, and if $1\in A_-$ then $2\in A_+$. Hence neither $A_+$ nor $A_-$ are empty and we have $1\le |A_+|<n$ and $1\le |A_-|<n$. If we assume $s\in\mathbb Q$, then $s=\phi(s)$ and hence $$\sum_{k\in A_+}2c_k\sqrt{a_k}=s+\phi(s)=2s \in\mathbb Q,$$ $$\sum_{k\in A_-}2c_k\sqrt{a_k}=s-\phi(s)=0 \in\mathbb Q.$$ By induction hypothesis, we conclude that $c_k=0$ for all $k\in A_+$ and also $c_k=0$ for all $k\in A_-$, that is $c_k=0$ for all $k$ as was to be shown.

Remark: The essential step here is that there is an automorphism $\phi$ of $L$ with $\phi(\beta)\ne\beta$. This may not require the full sledgehammer of Galois theory.

• Wow! But isn't your condition "$a_i$ square-free" slightly different from the condition "a, b not perfect squares" in the question? For example, $\sqrt{8} + \sqrt{27}$ is not rational, but I do not see how that can be derived from the theorem. (Sorry if this is a dumb remark, my math education is long ago ...) – Martin R Jul 6 '13 at 12:04
• That problem is solved with these numbers $c$: You can bring them into the square roots. In your case: $\sqrt8+\sqrt{27}$ becomes $2\sqrt2+3\sqrt3$. Note that this always gives the possibility to make the $a$'s square-free. – punctured dusk Jul 6 '13 at 15:06
• @barto: Oh yes, you are right of course. – Martin R Jul 6 '13 at 16:46

Suppose $\sqrt{x}+\sqrt{y}=n\in\mathbb{N}$, then $x+y+2\sqrt{xy}=n^2$ i.e. $\sqrt{xy}=m\in\mathbb{N}$. Thus $xy=m^2$, $y=\frac{m^2}{x}$ and hence $x+m=n\sqrt{x}$. This proves that $x$ is a perfect square and thus $y$ has to be one as well.