33
$\begingroup$

How to prove that the number $1!+2!+3!+...+n! \ \forall n \geq 4$ is never square?

I was told to count permutations but I cannot figure out what we are permuting.... Thanks!

  • 3
    My apologies, for n>32011-04-19

3 Answers 3

56

The first few cases are easily dealt with: $1!=1$ and $1!+2!+3!=9$ are squares, while $1!+2!=3$ is not.

For $n \ge 4$, $1!+2!+3!+ \ldots + n!$ is congruent to 3 mod 5. But all squares are congruent to 0, 1, or 4 mod 5.

  • 21
    Or in simpler terms, a perfect square never ends in 3 (i.e talking mod 10 instead of mod 5).2011-04-19
15

Firstly, it's only true for n > 3. Secondly, I don't see how to do it with permutations.

But the key is to consider residue classes mod 10. $ 1! + 2! + ... + n! $ is congruent to either 3 or 8 mod 10, but no square ends in either 3 or 8.

  • 1
    Oh, it was already answered!2011-04-19
  • 1
    It is always $3$, never $8$, when $n>3$, isn't it?2012-05-31
4

You can also use mod $7$ to solve this.

Firstly, manually checking $n=1,2,3,4,5$ gives only the solutions $n=1$, $n=3$.

If $n\ge 6$, then $$1!+2!+\cdots+n!$$

$$\equiv 1!+2!+3!+4!+5!+6!\pmod{7}$$

$$\equiv 5\equiv m^2\pmod{7},$$

contradiction, because $5$ is not a quadratic residue mod $7$ (notice $(7k\pm 1)^2\equiv 1\pmod{7}$, $(7k\pm 2)^2\equiv 4\pmod{7}$, $(7k\pm 3)^2\equiv 2\pmod{7}$).

mod $13$ would also work analogously. If $n\ge 12$, then $$1!+2!+\cdots+n!$$ $$\equiv 1!+2!+\cdots+12!\equiv 11\pmod{13}$$

and $11$ is not a quadratic residue mod $13$.

Using this method mod $9$ or mod $11$ wouldn't work (the residues would be $0$, which is a square mod every integer).

mod $17$ would also work -- the residue would be $12$, which is not quadratic mod $17$.

  • 0
    By your method it is quite evident that we can use other congruences than $\pmod7$....2016-06-15
  • 0
    @tatan mod $9$ or mod $11$ would give $0$ and wouldn't work analogously ($0$ is a quadratic residue mod everything).2016-06-15
  • 0
    yeah....nicely pointed out...you may add this in your answer....2016-06-15
  • 0
    (+1)...good answer in addition to the ones ones already existing.....2016-06-15