Find all possible quadruplets (a,b,c,d) of positive integers, that satisfy this equation:
a!-b!-c! = d2.
Prove that no further quadruplet satisfies the given conditions.
for a=1:28
fa=factorial(sym(a));
for b=1:a-1
fb=factorial(sym(b));
tot1=fa-fb;
c=1;
while tot>=0 || c==1
fc=factorial(sym(c));
tot=tot1-fc;
sr=round(sqrt(tot));
if sr*sr==tot && tot>=0
disp([a b c sr tot])
end
c=c+1;
end
end
end
finds
(without proof of completeness)
a b c d d^2
[2, 1, 1, 0, 0] (d is not positive here -- ignore)
[3, 1, 1, 2, 4]
[4, 2, 3, 4, 16]
[4, 3, 2, 4, 16]
[6, 4, 5, 24, 576]
[6, 5, 4, 24, 576]
[7, 6, 6, 60, 3600]
|
Posted by Charlie
on 2023-09-21 09:20:34 |