Related: Can a sum of square roots be an integer?

Except for the obvious cases $n=0,1$, are there any values of $n$ such that $\sum_{k=1}^n\sqrt k$ is an integer? How does one even approach such a problem? (This is not homework - just a problem I thought up.)

Mario Carneiro
  • 26,030
  • 4
  • 59
  • 119
  • 1
    @RahulNarain If you look, you'll notice that my question is related to, but not the same as the link you have suggested as a duplicate. (Although it may be possible to prove this statement from that one...) – Mario Carneiro Jul 12 '13 at 18:35
  • 1
    It's a special case of that one (after you eliminate the square roots of perfect squares, which don't change the integer-ness of the sum). –  Jul 12 '13 at 18:46
  • 1
    @RahulNarain Apologies; My first reading of the question made me think that it was about the sum of only two roots. However, as demonstrated by Jyrki Lahtonen below, my question has a decidedly simpler solution (and I don't see a solution along these lines in the answers to the linked question), and even if this question is a simple case of a more complex result, future users will be better served by Jyrki's answer than those on the other page. This is why I vote to reopen. By analogy, is Euler's elementary proof of FLT for $n=3$ irrelevant since the full proof is now known? – Mario Carneiro Jul 12 '13 at 18:58
  • 1
    Fair enough. Voting to reopen –  Jul 12 '13 at 19:22
  • 1
    [Related](http://math.stackexchange.com/q/442470/462). – Andrés E. Caicedo Jul 13 '13 at 07:13
  • Even $ \sqrt k+\sqrt m$ is never integer, not square number k,m – Takahiro Waki Mar 22 '18 at 12:38

1 Answers1


No, it is not an integer.

Let $p_1=2<p_2<p_3<\cdots <p_k$ be all the primes $\le n$. It is known that $$K=\mathbb{Q}(\sqrt{p_1},\sqrt{p_2},\ldots,\sqrt{p_k})$$ is a Galois extension of the rationals of degree $2^k$. The Galois group $G$ is an elementary abelian 2-group. An automorphism $\sigma\in G$ is fully determined by a sequence of $k$ signs $s_i\in\{+1,-1\}$, $\sigma(\sqrt{p_i})=s_i\sqrt{p_i}$, $i=1,2,\ldots,k$.

See this answer/question for a proof of the dimension of this field extension. There are then several ways of getting the Galois theoretic claims. For example we can view $K$ as a compositum of linearly disjoint quadratic Galois extensions, or we can use the basis given there to verify that all the above maps $\sigma$ are distinct automorphisms.

For the sum $S_n=\sum_{\ell=1}^n\sqrt{\ell}\in K$ to be a rational number, it has to be fixed by all the automorphisms in $G$. This is one of the basic ideas of Galois correspondence. But clearly $\sigma(S_n)<S_n$ for all the non-identity automorphisms $\sigma\in G$, so this is not the case.

Jyrki Lahtonen
  • 123,594
  • 24
  • 249
  • 599