Find all possible triplets (A,B,C) of positive integers satisfying this system of simultaneous equations:
- A2 + B2 - C2 = A+B-C, and:
- A+B+C = 82
Rearrange the second equation into C=82-A-B and substitute into the first equation to yield A^2 + B^2 - (82 - A - B)^2 = A + B - (82 - A - B)
This equation simplifies into A*B - 81A - 81B + 3321 = 0. Then some factoring makes (A-81) * (B-81) = 3240.
3240 has 40 factorizations into integers, including negative factorizations. Only two of those factorizations result in positive (A,B,C). 3240 = -54 * -60 generates the solution (27,21,34) and 3240 = -72 * -45 generates the solution (9,36,37).