Sum of the first factorials a perfect power?

Consider the following sum:
$$F(n) = 1! + 2! + 3! + \cdots + n!$$ Can this sum ever be a perfect power? A perfect power here is defined as $x^n$ for some natural number $x$ and some natural number $n\geq 2$. Some observations immediately come to mind: $F(1) = 1$, and that’s trivially a perfect power. But $F(2) = 3$, which is a prime number and of course not a perfect power. Then there’s $F(3) = 1 + 2 + 6 = 9$, which is a perfect square.

Are there others? Let’s check a few more. $F(4) = 33 = 3\times 11$ and $F(5) = 153 = 3^2\times 17$, so those are not perfect powers. In fact, $F(n)$ is not a perfect power for any natural number $n > 3$. Why is this?

First, if $F(n)$ is ever a perfect power, it must be a perfect square. Why is that? If $n\geq 6$ then we have
$$\begin{align*}F(n) &= 1! + 2! + \cdots + 5! + 6! + \cdots + n!\\
&= 153 + 6! + \cdots + n!\\ &= 9(17 + 9(6!/9 + \cdots + n!/9)).\end{align*}$$ Here, we have used that $n!/9$ will be an integer for $n\geq 6$. Since $17$ is not a multiple of $9$, we see that $F(n)$ has at most two factors of $3$. Therefore, $F(n)$ is at most a perfect square.

Another thing we see is that $F(n)$ for $n\geq 4$ always ends in $3$. That is because $F(4) = 33$ and $n!$ ends in zero whenever $n\geq 5$. Now, a square integer can never end in $3$. The only possible endings are $0,1,4,5,6,9$. Therefore, $F(n)$ can never be a perfect power whenever $n\geq 4$. So $F(1)$ and $F(3)$ are the only perfect powers in the sequence $F(1), F(2), F(3),\dots$

Note: I found this problem in the interesting book 104 Number Theory Problems by Andreescu, Andrica, and Feng. I did not look at their solution until solving this problem, but upon looking at it, their solution is different and handles even and odd powers separately.

Leave a comment

Fields marked with * are required. LaTeX snippets may be entered by surrounding them with single dollar signs. Use double dollar signs for display equations.