Triples

SUMMARY:

We introduced today's lesson by showing a clip from the Simpson's involving the Pythagorean Theorem. Here is an excerpt from the clip.

Introduction:

Mr. Burns: Thank you for visiting our plant, Dr. Kissinger.
Henry Kissinger: It was fun.
Smithers: We'll let you know if your glasses turn up.
Henry Kissinger: Yes, well, I'm sure I left them in the car.
[thinking]
Henry Kissinger: No one must know I dropped my glasses in the toilet. Not I, the man who drafted the Paris Peace Accords.

[Homer finds a pair of horn-rimmed glasses floating in a toilet bowl. He puts them on, then puts a finger to his head, a la the Scarecrow in "The Wizard of Oz."]
Homer: [rapidly] The sum of the square roots of the two sides of an isoceles triange is equal to the square root of the opposing side.
Man in Stall: That's a right triangle, ya idiot!
Homer: D'oh!

Pythagorean Theorem

History

The Pythagorean Theorem comes from the Greek mathematician Pythagoras, who lived in the 6th century BC. Legend has it that upon completion of his famous theorem, Pythagoras sacrificed 100 oxen. Although he is credited with the discovery of the famous theorem, it is not possible to tell if Pythagoras is the actual author. The Pythagoreans wrote many geometric proofs, but it is difficult to determine who proved what, as the group wanted to keep their findings secret. This vow of secrecy prevented an important mathematical idea from being made public.

  • Pythagorean Theorem: Let x, y, and z be positive reals. Then z is the length of the hypotenuse of a right triangle with side lengths x, y, and z if and only if x² + y² = z²

PROOF
This Proof was given by Bhaskara
To look at a diagram of the two squares with one inscribed in the other, you can visit the website: http://mathforum.org/isaac/problems/pythagthm.html
From the picture we can conclude that
the area of the outer square is (a + b)(a + b) or just (a + b)2,
the area of one of the four right triangles is (1/2)ab,
and the area of the square inscribed the outer square is c2.
Thus from the picture we can gather that the area of the outer square is equal to the area of the inner square plus the area of all four small triangles.
This means c2 + 4(1/2)ab = (a + b)2, which simplifies to c2 + 2ab = a2 + 2ab + b2. Then by combining like terms, we end up with c2 = a2 + b2.

Pythagorean Triples

  • Pythagorean Triples: Pythagorean triple is a triple of positive integers a, b, and c such that a right triangle exists with legs a, b, and hypotenuse c. By the Pythagorean theorem, this is equivalent to finding positive integers a, b , and c satisfying a²+b²=c².

You may remember a few from high school, including: 3, 4, 5 since 3² + 4² =5². Also, 5, 12, and 13 since 5² + 12² = 13².

  • Properties:
  1. Integers in a Pythagorean triple must all be positive by definition
      • EX. The triples -3, 4, & 5 and 0, 1, & 1 are solutions of the Pythagorean Thm. but not Pythagorean triples.
  2. Any positive integral multiple of a Pythagorean triple is a Pythagorean triple.
      • EX. 6, 8, & 10 is a Pythagorean triple since it is twice the triple of the triple 3, 4, & 5.
  3. It is clear that is x, y, z is a Pythagorean triple, and (x,y,z)=d then (x/d), (y/d) and (z/d) is also a Pythagorean Triple.
  1. For any Pythagorean triple, the product of the two non-hypotenuse legs (i.e., the two smaller numbers) is always divisible by 12, and the product of all three sides is divisible by 60.
      • EX. 6, 8, 10 6 x 8 =48 12|48? YES and 6 x 8 x 10 = 480 60|480? YES

Next we’ll move onto Primitive Pythagorean Triples. We’re interested in these because all Pythagorean triples come from primitive Pythagorean triples. So if you can understand these, then you are able to understand all Pythagorean triples!

Primitive Pythagorean Triples

  • Primitive Pythagorean Triples: A Pythagorean triple x, y, and z, where (x,y,z)=1.
          • Ex. 3, 4, 5 is a primitive triple but 6, 8, 10 is not.
  • Propostion: If x, y, and z is a Primitive Pythagorean Triple, then one of x and y has to be even and one has to be odd.

PROOF:
Case 1: x,y even. This implies that z is even. Since we have x² + y² = z² and we have x and y even we get (even)² + (odd)² = even. This means z² is even. However, we know that z is even since if z were odd, then z² would have to be odd. Therefore, we have that all 3 ( x, y and z) would be even. This can not happen since by definition of Primitive Pythagorean Triple, (x, y, z)=1 and if they were all even they would have a gcd of at least 2.

Case 2: x, y odd. This also implies that z is even. Again, since we have x² + y² = z² and we have x and y odd we get (odd)² + (odd)² = odd + odd = even. Again, this implies z² is even, but we also know z is even by the same logic used in case 1.

Now, we know that if x² is odd, then x² ≡ 1 mod 4 (By Homework from Ch 2). So, if we take the Pythagorean Theorem and mod it by 4, we get x² + y² ≡ z² mod 4. This would then imply that 1 + 1 ≡ 0 mod 4, a Contradiction!

Therefore, exactly one of x and y has to be even and one has to be odd.

Next, we considered several questions that always seem to pop up when we learn a new concept.
Q: How many Pythagorean triples are there?
A: Infinitely many! We can take a Pythagorean triple such as 3,4,5 and multiply each number by any positive integer that we want.
- This makes sense, but it isn't terribly interesting. Let's look at primitive Pythagorean triples.
Q: How many primitive Pythagorean triples are there?
Q: Is there an easy way to generate primitive triples?

As it turns out, there is a great theorem in the book that answers both of these questions for us. Here is a rephrasing of what the book tells us:

  • Theorem 6.3: x,y,z is a primitive Pythagorean triple with y even <=> we have 2 integers m,n such that m>n>0 , (m,n)=1 , exactly 1 of m and n is even, and x,y,z can be expressed as follows:
          1. x = m² - n²
          2. y = 2mn
          3. z = m² + n²
  • It may seem like there is a lot going on here, but this is actually a very cool theorem. It tells us that we can pick m and n that satisfy the above conditions, plug them in for x,y,z and generate our own primitive Pythagorean triples! Let's look at a few examples:
  • Ex 1 :m = 2 and n = 1 satisfy the conditions on m and n of Thm 6.3. Substituting these values for m and n in the equations for x, y, and in Thm 6.3, we obtain the primitive Pythagorean triple 3, 4, &5.
  • Ex 2:m = 3 and n = 2 satisfy the conditions on m and n of Thm 6.3. Substituting these values for m and n in the equations for x, y, and in Thm 6.3, we obtain the primitive Pythagorean triple 5, 12, &13.

PROOF
In class, we only proved one direction of this theorem. The other direction is on page 163 of the text if you are interested. Here's the proof for the <= direction.
For this, we get to assume that everything on the right side of the <=> and use it to show the following three things:
We need to show that, given m,n as described,

  • x,y,z is a Pythagorean triple
  • y is even
  • x,y,z is a primitive Pythagorean triple
  • First up, let's show that we have a Pythagorean triple.

We see that x² + y² = (m² - n²)² + (2mn)² = m4 + 2m²n² + n4
Similarly, we get that z² = (m² + n²)² = m4 + 2m²n² + n4
So it checks out, and we do have a Pythagorean triple.

  • Next, we need to show that y is even. We know it is since y = 2mn
  • Finally, we need to show that x,y,z is a primitive Pythagorean triple, i.e. (x,y,z)=1

Let (x,y,z) = d
Since y is even, this means that x must be odd by an earlier proposition. This means that z must be odd as well, since (odd)² + (even)² = (odd)²
Because d is the gcd of x,y,z and x,z are odd, we see that d must be odd. We can break this into 2 cases:

Case 1: d=1. If this happens, we get (x,y,z) = 1. This means x,y,z is a primitive Pythagorean triple, and we're happy.

Case 2: There is an odd prime p such that $p \mid d$. This makes sense, since every positive integer can be broken down into its prime factors. If d is odd and greater than 1, it follows that this p must exist. Since $p \mid d$, we know that $p \mid x$, $p \mid y$ $p \mid z$. One of our favorite results from chapter 1 says that if p divides x and z, it must divide any linear combination of x and z. Specifically, we see that $p \mid z-x$ and $p \mid z+x$. Putting this in terms of m & n and simplifying, we see that $p \mid z-x$ => $p \mid m^{2} + n^{2} - (m^{2} - n^{2})$ => $p \mid 2n^{2}$ By Euclid's Lemma, we see that $p \mid n^{2}$ since p can't divide 2. Using Euclid's Lemma again, we see that we must have $p \mid n$. By a similar strategy, we get that $p \mid m$ too. This is bad news though, since (m,n) = 1 by assumption. This is a contradiction, and shows us that (x,y,z) = 1 , which means we have a primitive Pythagorean triple!

Pythagorean Triple Siblings

  • Pythagorean Triple Siblings: Two triples are siblings if they have a common hypotenuse.
                  • Ex: The first such pair of primitive triples stem from the hypotenuse 65.

(332 + 562 = 632 + 162 = 652):

x y z r s
33 56 65 4 3
63 16 65 1 7

where r = n and m= r + s, since m² + n² = z. By substituting r in for m and r+s in for n we get: 65 = 4² + (4 + 3)² where r = 4 and s = 4 + 3
(We will discuss how to find r and s at the end of the lecture!)

  • In general, the number of primitive Pythagorean triples of hypotenuse n is dependent on the number of prime factors of n that are congruent to 1 modulo 4. It turns out that only powers of 2 appear as these numbers.

Why do primitive triples form only in sets of 2α, and what is the connection to primes p ≡ 1 mod 4?

  • Definition Let ω(n) be the number of distinct prime factors of a given integer n congruent to 1 mod 4. Then n is the hypotenuse of exactly 2(ω(n) – 1) primitive Pythagorean triples.

Ex 1 We know that 5 is the hypotenuse of only the 3,4,5 triple. Then w(5) = 1, and 2(1 – 1) = 1, so it checks out!
Ex 2 We saw that there are 2 sets of triples with hypotenuse 65. Note that 65 = 5*13, so ω(65) = 2. Then 2(2 – 1)= 2, which is what we were looking for!

Note: If n has any prime factors p ≡ 2 or 3 mod 4, then n is not the hypotenuse of any primitive triples.

In order to be able to prove HOW to find r and s, we need to know the Fibonacci Identity first!

  • Fibonacci Identity: Let a, b, c, and d be positive integers. Then (a² + b²)(c² + d²) = (ac-bd)² + (bc+ad)².
          • EX. Let a = 1, b = 2, c = 3, and d= 4. Then by substituting these values in we get:

(1² + 2²)(3² + 4²) = (1*3 + 2*4)² + (2*3 + 1*4)²
(5)(25) = (5)² + (10)² So, 125 = 125? YES!

  • Theorem (Fermat): Let p be a prime such that p ≡ 1 mod 4. Then p can be expressed uniquely as a sum of two squares. (By uniquely we mean there exists unique integers a and b such that 0 < a < b and p = a2 + b2.)
  • Armed with The Fibonacci Identity and Fermat's Theorem, we are now ready to tackle the r & s issue from our charts. Let's take a look at triples with the hypotenuse 1105. We note that 1105 = 5*13*17. These factors are all congruent to 1 mod 4. Our result from earlier tells us that there are 2(ω(n) – 1) = 2(3-1) = 4 sets of Pythagorean triples with hypotenuse 1105. Let's use Fermat's Theorem to find out what they are:
          • 1105 = 5 * 13 * 17 = [(1² + 2²)(2² + 3²)](1² + 4²). Now, we have a choice as to what we multiply first. Here, we will multiply the 2 terms in brackets first. Note that this will give us 1 sibling triple with hypotenuse 1105. If we were to multiply the 2nd and 3rd terms together first, we would get a different sibling triple. We could also write something like (1² + 2²) as (2² + 1²). This could potentially give us another solution. Thanks to our 2(ω(n) – 1) formula, we know how many sibling triples to look out for.

Looking at our 2 terms in brackets, we see that a=1, b=2, c=2, d=3. Here, we just labeled the numbers in terms of a,b,c,d so that it is easier to see the Fibonacci Identity in action. We are able to combine the 2 terms in brackets using this identity, and we get the following: (1² + 2²)(2² + 3²) = (1*2-2*3)² + (2*2+1*3)² = ((-4)²+7²) = (4² + 7²). Now we are left with
(4² + 7²) (1² + 4²) Using Fibonacci again, we get
=23² + 24²
Notice that z, our hypotenuse, is equal to 1105. Recall from earlier that z = m² + n². Then n = r = 23, and m = r+s = 24. Thus r = 23, s = 1.
Since m = r + s and n = r, we can simply plug m and n into our equations from Thm 6.3 to find our legs x & y.
We see that x = m² - n² = 24² - 23² = 47
and y = 2mn = 2*24*23 = 1104.
Through a quick check, we see that 47² + 1104² = 1105². Hooray!

By changing the order in which we use Fibonacci's Identity, we can produce the other 3 solutions. When we think about it like this, it kind of makes sense that there are 2(ω(n) – 1) many sibling triples. It's just a matter of swapping out the order of multiplication or changing the order of addition. Some changes may not yield a new solution, which explains why there are not more than 2(ω(n) – 1) many sibling triples.

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License