1 Number Theory and Graph Theory Chapter 5 Additional Topics By A. Satyanarayana Reddy Department of Mathematics Shiv Nadar University Uttar Pradesh, India E-mail: satya8118@gmail.com
2 Module-2: Pythagorean Triples Objectives Introduction to Pythagorean and primitive Pythagorean triples. Finding all integer solutions of x 2 + y 2 = z 2. We start with quite a well known remarks related with the Pythagorean theorem. The Pythagorean theorem is one of the most important result in elementary mathematics. It states that the sum of the squares of the lengths of the legs of a right triangle equals the square of the length of its hypotenuse. Let a and b denote the lengths of the legs of a right triangle and c the length of its hypotenuse. Then, mathematically, the Pythagorean theorem states that x = a,y = b and z = c is a solution of the Diophantine equation x 2 + y 2 = z 2. The converse of the Pythagorean theorem is also true. That is, if the sum of the squares of the lengths of two sides of a triangle equals the square of the length of its third side then, the triangle is a right triangle with the third side as the hypotenuse. Right triangles whose sides have integral lengths are called Pythagorean triangles. The positive integral triplet (x,y,z) satisfying x 2 + y 2 = z 2 is called a Pythagorean triple. If (x,y,z) is a Pythagorean triple then, so is (kx,ky,kz) for every k Z. Since (3,4,5) is one such Pythagorean triple, one has infinitely many Pythagorean triples. The following statements can be easily verified. corresponding to every odd positive integer n, (n, (n2 1) 2, (n2 +1) 2 ) is a Pythagorean triple.
3 For every positive integer n one can associate a Pythagorean triple (2n,n 2 1,n 2 + 1) Recall the sequence 1, 1, 2, 3, 5, 8,..., is called a Fibonacci sequence. They satisfy the recurrence relation f n = f n 1 + f n 2, for n 2, f 0 = f 1 = 1. Four consecutive Fibonacci numbers f n, f n+1, f n+2, f n+3 yields a Pythagorean triple (x,y,z), where x = f n F n+3,y = 2 f n+1 f n+2 and z = fn+1 2 + f n+2 2. A Pythagorean triple (x,y,z) is said to be primitive if gcd(x,y,z) = 1. Properties of Primitive Pythagorean triples Lemma 1. Every Pythagorean triple is a multiple of a primitive Pythagorean triple. Proof. Let (x,y,z) be an arbitrary Pythagorean triple with gcd(x,y,z) = d. Then, x = dx 1,y = dy 1 and z = dz 1, for some x 1,y 1,z 1 Z with gcd(x 1,y 1,z 1 ) = 1. Further, it can be easily verified that x1 2 + y2 1 = z2 1 and hence (x 1,y 1,z 1 ) is a primitive Pythagorean triple. In light of the above result, we will concentrate only on finding primitive Pythagorean triples. Lemma 2. Let (x, y, z) be a primitive Pythagorean triple. Then, gcd(x, y) = gcd(y, z) = gcd(z, x) = 1. Proof. Let (x,y,z) be a primitive Pythagorean triple with gcd(x,y) = d > 1. Let p be a prime dividing d. Then, p x and p y and hence p 2 divides x 2 + y 2 = z 2. Thus, p divides z. Consequently, p divides gcd(x,y,z) and therefore, (x,y,z) is not a primitive Pythagorean triple, a contradiction to our assumption. Thus, gcd(x, y) = 1. Similarly, one can check that gcd(y, z) = 1 = gcd(z, x). As a direct application of Lemma 2, we obtain the following result which states that if (x,y,z) is a primitive Pythagorean triple then, x and y must have opposite parity. Lemma 3. Let (x,y,z) be a primitive Pythagorean triple. Then, x and y have different parity.
4 Remark 4. We use the above lemma to assume, without loss of generality, that in the primitive Pythagorean triple (x,y,z), the number x is an even positive integer and hence y and z are odd positive integers. Lemma 5. Let m,n N with gcd(m,n) = 1. If mn = t 2 for some t Z then, both m and n are also squares. Proof. Let m = p a 1 1 pa 2 2 pa r r and n = q b 1 1 qb 2 2 qb s s be the factorization of m and n into distinct primes. As gcd(m,n) = 1, none of the p i s equals q j s. Thus, mn = p a 1 1 pa r r q b 1 1 qb s s is the factorization of mn into distinct primes. Since mn is a square, each of a i s and b j s are even positive integers and hence the required result follows. Theorem 6. Let (x,y,z) be a primitive Pythagorean triple. Then, there exist m,n N such that gcd(m,n) = 1, m and n have different parities and x = 2mn,y = m 2 n 2 and z = m 2 + n 2 Proof. By Remark 4, x is an even positive integer, whereas both y and z are odd positive integers. Hence, there exists u,v N such that z + y = 2u and z y = 2v. Therefore, x 2 = z 2 y 2 = (z + y)(z y) = (2u)(2v) = 4uv and hence (x/2) 2 = uv. We now claim that gcd(u,v) = 1. Let if possible, gcd(u,v) = d 2. Then, d divides u + v = z and u v = y, a contradiction to gcd(y,z) = 1. Since uv is a square and gcd(u,v) = 1, by Lemma 5, both u and v are squares. Thus, u = m 2 and v = n 2, for some m,n N with m > n as u > v. Hence, we see that x 2 = 4uv = 4m 2 n 2 and hence x = 2mn,y = u v = m 2 n 2 and z = u + v = m 2 + n 2. As gcd(x,y,z) = 1, we see that gcd(m,n) = 1. Further, note that if m and n have the same parity then, y = m 2 n 2 0 (mod 4) and z = m 2 + n 2 0 or 2 (mod 4). Hence, 2 divides gcd(y,z) = 1, a contradiction. Hence, m and n have different parities. Thus, every primitive Pythagorean triple must satisfy the given conditions.
5 Theorem 7. Let m,n N such that gcd(m,n) = 1,m > n and m and n have different parities. Then, (2mn,m 2 n 2,m 2 + n 2 ) is a primitive Pythagorean triple. Proof. As (2mn) 2 +(m 2 n 2 ) 2 = (m 2 +n 2 ) 2, the triple (2mn,m 2 n 2,m 2 +n 2 ) is indeed a Pythagorean triple. We now need to show that it is also primitive. That is, we need to show that gcd(2mn,m 2 n 2,m 2 + n 2 ) = 1. Let p be a prime factor of gcd(2mn,m 2 n 2,m 2 + n 2 ). As m and n have different parities, the numbers m 2 ± n 2 are odd. Hence, p divides m 2 = 2 1 ( (m 2 n 2 ) + (m 2 + n 2 ) ) and hence n 2. Thus, p divides both m and n, contradicting gcd(m,n) = 1. Therefore, the given triple is indeed a primitive Pythagorean triple. Alternate way of jointly looking at Theorems 6 and 7. Let a,b,c N such that a 2 + b 2 = c 2 and gcd(a,b,c) = 1. Then, ( a c )2 + ( b c )2 = 1 and hence, the rational numbers a c and b c satisfy the equation of the circle x2 + y 2 = 1. Note that the circle x 2 + y 2 = 1 has the center (0,0), radius 1 and passes through the points (±1,0),(0,±1). Let P = (x,y) be any point on the circle such that x and y are rational numbers with 0 < x,y < 1. Then, the slope of the line passing through the points P and Q = ( 1,0) equals t = y 1+x, a rational number. As y2 = 1 x 2 = (1 x)(1 + x), we have t 2 = y2 see that x = 1 t2 2t and y = 1 +t2 1 +t 2. Note that if t = tanθ for some θ,0 θ < 2π then, x = cos2θ and y = sin2θ. = 1 x (1+x) 2 1+x. Thus, we If t is any rational number, then the pair (x,y) = ( 1 t2 1+t 2, 2t 1+t 2 ) gives a rational solution to the equation x 2 + y 2 = 1. Conversely, for every rational solution to x 2 + y 2 = 1 obtained in this way, we can form a unique rational number t. Thus, we have classified all the rational solutions (x,y) of x 2 + y 2 = 1 in terms of a single parameter t and from these we can obtain all rational solutions (a,b,c) of the equation a 2 + b 2 = c 2 in the form (cx,cy,c), where c is rational.
6 Assume b is even. As t is a rational number, t = u v, for some u,v N with gcd(u,v) = 1. Then, (cx,cy,c) = ( (u2 v 2 )c u 2 + v 2, (2uv)c u 2,c). Thus, we see that if gcd(a,b,c) = 1 we must have + v2 c = u 2 + v 2 as gcd(u,v) = 1 already implies that gcd(uv,u 2 + v 2 ) = 1. Thus, a = u 2 v 2,b = 2uv and c = u 2 + v 2. Theorem 8. The number of primitive Pythagorean triples is countably infinite. Proof. By Theorem 7, we know that for each choice of positive integers m,n satisfying gcd(m,n) = 1, m > n and m and n having different parities, we get a unique primitive Pythagorean triple (2mn,m 2 n 2,m 2 + n 2 ). Therefore, for n = 2, we see that m can be any odd prime number. As the number of odd primes is countably infinite, the required result follows. Problem 9. 1. There is no Pythagorean triple (a,b,c) with a = b as 2 is not an integer. 2. Show that the triples (3k,4k,5k), where k N, are the only Pythagorean triples whose terms are in arithmetic progression. Proof. Let (x d, x, x + d) be a Pythagorean triple. Then, we have x 2 + 2xd + d 2 = (x + d) 2 = (x d) 2 + x 2 = 2x 2 2xd + d 2. Also, x 0 and hence x = 4d. Consequently, (x d,x,x + d) = (3d,4d,5d), as desired. 3. The Pythagorean triple (3,4,5) is the only triple with three consecutive integers. Proof. Let (n,n + 1,n + 2) be a Pythagorean triple. Then, we see that n 2 + 4n + 4 = (n + 2) 2 = 2n 2 + 2n + 1 and hence, (n 3)(n + 1) = 0. As n + 1 0, we have n = 3 giving us the Pythagorean triple (3,4,5).
7 4. Let (a 1,b 1,c 1 ) and (a 2,b 2,c 2 ) be two primitive Pythagorean triples. Then, (a 1 a 2 b 1 b 2,a 1 b 2 + a 2 b 1,c 1 c 2 ), (a 1 a 2 + b 1 b 2,a 1 b 2 a 2 b 1,c 1 c 2 ) are also primitive Pythagorean triples. Proof. Note that c 2 j = a2 j + b2 j = (a j + ib j )(a j ib j ), for j = 1,2. Thus, (a 1 ± ib 1 )(a 2 + ib 2 ) gives us the required triples. It can also be independently verified that c 2 1c 2 2 = (a 2 1+b 2 1)(a 2 2 +b 2 2) = (a 1 a 2 b 1 b 2 ) 2 +(a 1 b 2 +b 1 a 2 ) 2 = (a 1 a 2 +b 1 b 2 ) 2 +(a 1 b 2 a 2 b 1 ) 2 and the given triples are primitive. 5. For a given positive integer n, show that there are at least n Pythagorean triples having the same first number. Proof. For 0 k n 1, let y k = 2 k (2 2n 2k 1) and z k = 2 k (2 2n 2k +1). Then, (2 n+1,y k,z k ) is a collection of n Pythagorean triples. 6. Let n 3 be a positive integer. Then, find a Pythagorean triple (not necessary primitive) which has n as one of its member. Proof. Note that ( n, 1 2 (n2 1), 1 2 (n2 + 1) ) ( ) is a Pythagorean triple, if n is odd and n, n2 n2 4 1, 4 1 is a Pythagorean triple, if n is even. [The triple (2m+1,2m 2 +2m,2m 2 +2m+1) corresponds to n = 2m + 1.] 7. Prove that there exists infinitely many Pythagorean triples of the form (x,x + 1,y). Proof. Let m,n be positive integers with gcd(m,n) = 1 and m > n such that m and n have different parities. Then, we know that (x,y,z) = (2mn,m 2 n 2,m 2 + n 2 ) is a primitive Pythagorean triple. Then, we need to find m,n such that m 2 n 2 2mn = 1. Or equivalently, (m n) 2 2n 2 = 1. Therefore, (x,y) = (m n,n) is a solution of the equation x 2 2y 2 = 1.
8 Clearly, (x,y) = (3,2) is a solution of x 2 2y 2 = 1 which gives rise to m = 5 and n = 2 and hence to the Pythagorean triple (2mn,m 2 n 2,m 2 + n 2 ) = (20,21,29). Now, note that if (x n,y n ) is a solution of x 2 2y 2 = 1 then, (x n+1,y n+1 ) = (3x n + 4y n,2x n + 3y n ) is also a solution of x 2 2y 2 = 1. Hence, the triple (2(x n + y n )y n,x n (x n + 2y n ),xn 2 + 2x n y n + 2y 2 n) is a Pythagorean triple of the required form. 8. Show that there exists infinitely many Pythagorean triples (a,b,c) such that b and c are consecutive triangular numbers. Similarly, there are infinitely many Pythagorean triples (a,b,c) such that a and b are consecutive triangular numbers. Proof. Note that from the previous problem, ( n, 1 2 (n2 1), 1 2 (n2 + 1) ) is a Pythagorean triple of the form (y,x,x + 1), whenever n is odd. As y 2 + x 2 = (x + 1) 2, we also note that (p 3 (2x+1)) 2 (p 3 (2x)) 2 = 1 4 [(2x+1)2 (2x+2) 2 4x 2 (2x+1) 2 ] = (2x+1) 2 [(x+1) 2 x 2 ] = (2x+1) 2 y 2. Thus, ((2x + 1)y, p 3 (2x), p 3 (2x + 1)) is a Pythagorean triple, whenever (y,x,x + 1) is a Pythagorean triple. Similarly, use the Pythagorean triples (2(x n + y n )y n,x n (x n + 2y n ),x 2 n + 2x n y n + 2y 2 n) of the previous problem get the result of the second part. 9. The radius of the inscribed circle of a Pythagorean triangle is always an integer. Proof. Let m,n be positive integers with gcd(m,n) = 1 and m > n such that m and n have different parities. Then, we know that (x,y,z) = (2kmn,k(m 2 n 2 ),k(m 2 +n 2 )) is a Pythagorean triple for all k N. Now, by computing the areas of the triangles appearing in the figure below, we have 1 2 xy = 2 1rx + 1 2 ry + 1 2rz, or equivalently, r = xy x+y+z. In particular, r = 2k 2 mn (m 2 n 2 ) k(2mn + m 2 n 2 + m 2 + n 2 ) = kn(m2 n 2 ) = kn(m n) = 1 [x + y z] N. (1) m + n 2
9 x r r y r z 10. Find all Pythagorean triangles whose area is equal to their perimeter. Proof. Let (x,y,z) be the sides of the required Pythagorean triangle. Then, 1 2xy = x + y + z. As z 2 = x 2 + y 2, we get 4x + 4y xy = 8. Clearly, this equation is symmetric in x and y and y cannot take the value 4. So, the above equation reduces to x = 4+ y 4 8 with y 4. As x,y N, we get (x, y) {(5, 12),(6, 8),(8, 6),(12, 5)}. Thus, the corresponding distinct Pythagorean triangles are (12,5,13) and (8,6,10). 11. Let n N. Then, prove that there exists a Pythagorean triangle with n as the radius of it s inscribed circle. Proof. Let r be the radius of the inscribed circle of the Pythagorean triangle with sides a,b and hypotenuse c. Then, using (1), we have r = 1 2 (a + b c). Then, the triple (a,b,c) = (2n + 1,2n 2 + 2n,2n 2 + 2n + 1) gives a Pythagorean triangle with n as the radius of it s inscribed circle.