Derivation:
|
Reorganize x^2+y^2=z^2 to get x^2 equal to a product of two factors. Assign the factors on the right to two new variables. Then we have |
To make selecting the parameters u and v easier,
replace them with expressions that are divisible by 2
and such that u*v is a perfect square, since we want x, y, and z
to be integers. Then we finally have |
As for making primitive Pythagorean triples, observe that if s and t have a common divisor different from 1, then x, y, and z will be divisible by this factor. So we must choose s and t to be coprime. Also, if s and t are both odd, then x, y, and z will all be even which means they're divisible by 2, so s and t must not have the same parity.