$\large a! + b! + c! = a! \cdot b!$

If $a,b,c$ are nonnegative integers, then there are a finite number of solutions to the above equation. Let them be $(a_1, b_1, c_1), (a_2, b_2, c_2), (a_3, b_3, c_3), \ldots, (a_n, b_n, c_n)$ in some order. Find the value of

$n + \displaystyle \sum_{i=1}^n (a_i+b_i+c_i ).$

(If $n = 0$ , then the sum is zero, so you should write 0 as the answer.)

The answer is 11.

**
This section requires Javascript.
**

You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.

Relevant wiki: General Diophantine Equations - Problem SolvingFirstly, $a,b > 1$ , which can be proven by trivially checking these cases. Now, we will prove that $c \geq a, b$ . We have the following

$\begin{aligned} a!+b!+c!&=a!b!\\ \implies c!+1&=a!b!-a!-b!+1\\ \implies c!+1&=(a!-1)(b!-1)\\ \implies a!-1 &\mid c!+1\\ \implies a!-1 &\leq c!+1\\ \implies a!-2 &\leq c!\\ \implies a &\leq c \quad \forall a\geq 3 \end{aligned}$

Similarly, this can be proved for $b$ . Thus, $c \geq a, b$ if they are both $\geq 3$ . If $a=2$ , we have $b!-1 = c!+1$ , which isn't satisfied for any integral $b, c$ . Same applies if $b=2$ . Thus, $a, b > 2$ . We will now prove $a=b$ . We have

$\begin{aligned}a!+b!+c!&=a!b!\\ \implies b!+c!&=a!b!-a!\\ \implies b!(1+\frac{c!}{b!})&=a!(b!-1)\\ \gcd (b!, b!-1)=1 \implies b! &\mid a! \end{aligned}$

Similarly, we can prove $a! \mid b!$ . Thus, $a!=b!$ , so $a=b$ . We now have

$\begin{aligned} 2a! + c! &= a!^2\\ c! &= a!(a!-2) \end{aligned}$

Firstly, note that $a < c$ . Next, we will prove that the product of $n$ consecutive numbers is divisible by $n!$ . But this is almost trivially true by looking at binomial coefficients:

$\begin{aligned} \dbinom{k+n}{k} &= \dfrac {(k+n)!}{k!n!}\\ &= \dfrac {(k+1)(k+2)\ldots(k+n)}{n!} \end{aligned}$

Since all binomial coefficients are integers, it follows that the product of $n$ consecutive numbers is divisible by $n!$ .

Using this, we have

$\begin{aligned} \dfrac {c!}{a!} &= a! - 2\\ (a+1)(a+2)\ldots (c) &= a!-2\\ \implies (c-a)! &\mid a!-2 \end{aligned}$

However, we have that $a!-2 \geq (c-a)!$ , so $c-a \leq a$ . Thus, we also have $(c-a)! \mid a!$ , so $(c-a)! \mid 2$ . Thus, we have $c=a+1, a+2$ . We will now consider both cases.

However, we have that $a! - 2 \equiv 2 \pmod{4}$ if $a \geq 4$ . Thus, $4 \not \mid (c-a)!$ , so $c-a \leq 3$ . We will now consider each of the cases:

Case 1:$c=a+1$We have

$\begin{aligned} a+1 &= a!-2\\ 3 &= a((a-1)!-1)\\ \implies a &= 3 \end{aligned}$

The value of $a$ we pertain from the factorisation of the LHS, using $a \geq 3$ . Checking, we find this to be true, so we get $c=4$ . Thus, one such solution is $(3, 3, 4)$ .

Case 2:$c=a+2$We have

$\begin{aligned} (a+1)(a+2) &= a! - 2\\ 4 &= a((a-1)! - a - 3)\\ \implies a&= 4 \end{aligned}$

However, when we check the inside of the bracket in the RHS, we find that the value of $a$ doesn't satisfy. Thus, no solutions in this case.

Thus, the only solution is $(3, 3, 4)$ . Therefore, the answer is $1+3+3+4=11$ .

Note: We do not consider the alternate case when $a < 4$ , since it implies $a=3$ , which is covered above.