Analytically determine all possible triplets (p, q, r) of positive integers that satisfy q≤r and p≤13 and p!= q²+r².
The solutions are 2! = 1^2 + 1^2 and 6! = 12^2 + 24^2
These are easy enough to find. The first is rather trivial but the second provides some insight.
6! = 2^4 * 3^2 * 5 = 12^2 * (1 + 4) = 12^2 + 4*12^2 =
12^2 + 24^2
The point being it is the product of a perfect square and a number that can be written as the sum of two squares.
It isn't very difficult to do the same with other factorials:
7! = 2^4 * 3^2 * 5 * 7 but 35 is not the sum of two squares.
For 8! and 9!, 70 is not the sum of two squares.
For 10!, 11!, 12! and 13! the numbers that don't work are 7, 77, 231 and 3003 respectively.

Posted by Jer
on 20070404 12:10:54 