Sorry if this question is too simple.
I once read, on a number theory textbook - forget the title, in one of the problems list that all Pythagorean triplets when multiplied are divisible by 60.
I proved that using the generating functions (is this the correct name? I got the name from my Discrete Mathematics textbook):
\begin{align} a &= p^2 - q^2 \\\ b &= 2pq \\\ c &= p^2 + q^2. \end{align}
I proved it by proving all possible parities of $p$ and $q$. It's tedious because I have to prove some cases are not possible (like $a$, $b$, and $c$ can't be all even or odd).
My questions are:
Who and how someone came up with the generating functions?
If you don't know the generating functions or don't want to prove it like I did, is there any other way to prove it? Geometrically? Using Calculus? I mean there're many ways to prove Pythagorean theorem using Geometry, Number Theory, etc.