Maths Olympiad Prep

Library / /9 of 18

Number theory Difficulty 5.7 AIME, harder Prove it Austria

Determine all pairs of positive integers (n,k)(n, k) for which
n!+n=nk n! + n = n^k
holds.

Solution

Answer. The only solutions are (2,2)(2, 2), (3,2)(3, 2) and (5,3)(5, 3).

Because of n!+n>nn! + n > n, we immediately get k2k \ge 2. We divide both sides of the equation by nn and get
(n1)!+1=nk1. (n - 1)! + 1 = n^{k-1}.
Now, we distinguish two cases:

* nn is not a prime.
Since nn is clearly not 11, we can write nn as n=abn = ab for integers a,ba, b with 1<a,b<n1 < a, b < n which implies 1<an11 < a \le n - 1 and therefore a(n1)!a \mid (n - 1)!. We conclude that a>1a > 1 is relatively prime to the left-hand side (n1)!+1(n - 1)! + 1, but aa divides the right-hand side nk1n^{k-1}. This is not possible, so there are no solutions in this case.

* nn is a prime.
We check n=2,3,5n = 2, 3, 5 and find the solutions (2,2)(2, 2), (3,2)(3, 2) and (5,3)(5, 3).
From now on, let n7n \ge 7. We get
(n1)!=nk11    (n1)!=(1+n+n2++nk2)(n1)    (n2)!=1+n+n2++nk2 \begin{align*} (n-1)! &= n^{k-1} - 1 \\ \implies (n-1)! &= (1 + n + n^2 + \dots + n^{k-2})(n-1) \\ \implies (n-2)! &= 1 + n + n^2 + \dots + n^{k-2} \end{align*}
Since nn is prime and bigger than 33, the number n1n-1 is even and not a prime. Furthermore, n1n-1 is not the square of a prime since 44 is the only even square of a prime and n16n-1 \ge 6. Therefore, we get n1=abn-1 = ab with 1<a,bn11 < a, b \le n-1 and aba \ne b. We obtain that (n2)!(n-2)! contains the separate factors aa and bb and is therefore divisible by ab=n1ab = n-1 which implies (n2)!0mod(n1)(n-2)! \equiv 0 \mod (n-1). Furthermore, n1mod(n1)n \equiv 1 \mod (n-1), and therefore
01+1+12++1k2k1mod(n1). 0 \equiv 1 + 1 + 1^2 + \dots + 1^{k-2} \equiv k - 1 \mod (n-1).
We conclude that n1n-1 divides k1k-1 and we write k1=l(n1)k-1 = l(n-1) for a positive integer ll. The case k=1k=1 and l=0l=0 has already been treated. Therefore, we get k1n1k-1 \ge n-1.
However,
(n1)!=123(n1)<(n1)(n1)(n1)n1 times=(n1)n1, (n-1)! = 1 \cdot 2 \cdot 3 \cdots (n-1) < \underbrace{(n-1) \cdot (n-1) \cdots (n-1)}_{n-1 \text{ times}} = (n-1)^{n-1},
and therefore
nk1=(n1)!+1(n1)n1<nn1nk1, n^{k-1} = (n-1)! + 1 \le (n-1)^{n-1} < n^{n-1} \le n^{k-1},
giving a contradiction. So there are no further solutions.

(Michael Reitmeir) \square

Want a route through all this instead of an archive? The track puts 2,000 problems in a working order, from AMC 10 level to the IMO shortlist.

Source: MathNet, licensed CC-BY-4.0. Statement and solution reproduced as published; topic and difficulty added by this site.