I learned this method of generating Pythagorean triples in a graduate class at MIT taught by Victor Kac. I’m blogging about it now because I just discussed generating Pythagorean triples with a student (using the method of parametrizing rational points on the unit circle centered at the origin by the slope of a line passing through (-1, 0)) and because it is a really nifty approach accessible to students who have learned about matrix multiplication.
Take the following ten 3 by 3 matrices:
(There are 10 matrices because the middle one represents all 8 possible sign choices.)
Start with the vector
and apply the 10 matrices to get more and more vectors. For example, if you apply the tenth matrix to the above vector, you will get
And if you apply the same matrix again, you will get
If you keep on going applying the matrices in various ways, you will eventually get all the primitive Pythagorean triples. Can you prove it?
Stop reading if you don’t want any hints.
Hint 1. Show that any vector that arises will satisfy
- that , , and are all integers with no common factor greater than 1.
- the Pythagorean identity .
Hint 2. Suppose , with . Show that it is possible to apply some of the matrices above to to obtain a vector with .