User:Springelec/Pythagorean Triples

'New Pythagorean Triple Formula'

1.0) Introduction.

In 1985, the BBC’s flag ship science programme, Horizon, broadcast a programme about unsolved theories and problems which included Fermat’s Last Theorem of 1637 in which Fermat* stated that no integer solutions existed for the equation:

an = bn + cn,	(Eq 1); if n was an integer whose value was greater than 2.

Intrigued by the simplicity of the equation and the fact that, at the time, no one had found or rediscovered Fermat’s alleged general proof, the author made various attempts to solve Fermat’s Last Theorem. Although no claim is made to have either rediscovered Fermat’s proof nor offer an alternative, analysis of Fermat’s original problem has allowed a novel technique to be formulated which allows the automatic generation of Pythagorean triples from a seed integer. Examples include 52 = 42 + 32 and 132 = 122 + 52.

2.0) History.

It should be noted that this abstract equation is a multi dimensional equation depending upon the value of ‘n’ and refers to a right angled triangle when n = 2, as illustrated below for clarity. In this example sides A, B & C are mathematically related by the equation A2 = B2 + C2, i.e. an = bn + cn when n = 2.

Fig 1

The reader will quickly appreciate that when n = 1, (an = bn + cn ) is reduced to just (a = b + c), an expression which has an infinite number of real number and integer solutions. The reader will remember from school maths lessons that when n = 2, (an = bn + cn ) becomes the famous Pythagorean equation for right angled triangles, (a2 = b2 + c2 ) from which can be calculated the hypotenuse of a right angled triangle providing two lengths or one length and an angle are known.

Famous Pythagorean triples include 52 = 42 + 32 and 132 = 122 + 52, triples which were known to the ancient Sumerians and Babylonians four thousand years ago because they used the formula (p2 – q2), 2pq, (p2 + q2) to calculate perfect triples. The reader can quickly determine this formula works by substituting p = 2, q = 1 or p = 3, q = 2 for example, but it is all the more remarkable that the Babylonians also worked out that 2291, 2700 and 3541 is also a perfect triplet using this method.

It is not known why the Sumerians and Babylonians needed to know these perfect triples, other than for, perhaps, agricultural mapping, but regardless of the exact reason, several perfect integer triples have been known to man for at least four thousand years and knowledge of their existence has always fascinated mankind for practical and aesthetic reasons.

Pierre de Fermat is the first person recorded in history to seek a general solution for the abstract equation an = bn + cn and whilst solutions for n = 1 and n = 2 were known for a long time, it would have seemed odd to Pierre Fermat and other mathematicians throughout history that there appeared to be no known integer solutions for the cubic volume equation, a3 = b3 + c3 or the fourth order space equation, a4 = b4 + c4 or even higher order triples. Pierre Fermat was curious to understand this problem and went on to prove that there were no integer solutions for the two specific equations when n = 3 and n = 4. Whilst the proof for n = 3 is lost, n = 4 is extant and provided an insight into Fermat’s analytical methods. His proof was based upon the assumption that three integer solutions existed to satisfy the equation a4 = b4 + c4. The analysis went on to show that three smaller integers could also exist which also satisfied the equation and so on, down to the smallest set of a, b and c which clearly did not satisfy the equation. Once a minimum set of a, b and c were found that could not satisfy the equation, then none of the previous values for a, b and c could satisfy the equation because all sets of a, b and c were mathematically linked. This mathematical strategy aimed to prove a flaw or logical inconsistency with the original argument and by proving the flaw, bring down the whole argument like a house of cards. In this way, Fermat proved there were no integer solutions for a4 = b4 + c4.

Although lost, there is little doubt Fermat would have used the same argument to also prove there are no integer solutions for when n = 3. One of the reasons why Fermat’s proof for n = 3 is lost is because Fermat didn’t keep very good records of his mathematical research, preferring to scribble notes in the margins of other people’s work which he read for enjoyment. Whilst working on a general solution for the equation (an = bn + cn ) and translating and editing one of the five extant copies of thirteen books of Arithmetica, written by the Greek mathematician, Diophantus, Fermat is said to have written in a margin: “I have found a truly marvellous demonstration which this margin is too narrow to contain”. The demonstration Fermat referred to was a proof that there were no integer solutions for the abstract equation, (an = bn + cn ) for all integer values of n > 2. Unfortunately, Fermat either forgot to record his thoughts on this topic or they were lost after his death. Either way, the World was only left with his tantalising note suggesting that he had solved this problem with a seemingly simple and elegant proof.

Whether Fermat did or did not prove that there are no integer solutions for (an = bn + cn ) for all values of n > 2 remains a mystery due to the loss of much of his work. History granted Fermat the benefit of doubt for this discovery because he had already proven many theorems and solved the problem for the two discrete cases when n = 3 and n = 4. However, the tantalising note Fermat left behind in 1637, frustrated the attempts of very many well known mathematicians to rediscover Fermat’s alleged proof, all without success. French mathematician Legendre proved there were no integer solution for n = 5 in 1823 and in 1840, Lamé and Lebesgue gave proofs for when n = 7. Dirichlet gave a proof for n = 14 and in 1849, Kummer proved that there were no integer solutions for some Bernoullian conditions, 37, 59 and 67 being exceptions. Because Fermat’s last theorem defied solution for nearly 360 years, it acquired an extraordinary celebrity status among mathematicians until Princeton mathematician, Professor Andrew Wiles indirectly, but finally proved the theorem in 1995 as a consequence of proving the Taniyama Shimura conjecture.

3.0) A new analytical approach. Although Andrew Wiles proved Fermat’s Last Theorem, the following analysis is offered as a bi-product of the authors unsuccessful attempts to solve Fermat’s Last Theorem.

Given the right angled triangle below, we know from Pythagoras that the sides A, B and C are related by the equation; (A2 = B2 + C2 ) and through the centuries many perfect Pythagorean triples have been found, (52 = 42 + 32 ) and (132 = 122 + 52 ) are just two of the most recognisable triples.

Table 1 illustrates a sample of eleven integer triples, although there are infinitely many more.

Fig 2

A	B	C 5	4	3 13	12	5 17	15	8 25	24	7 29	21	20 37	35	12 41	40	9 61	60	11 65	63	16 85	84	13 113	112	15

Table 1

Ancient mathematicians looked for patterns and symmetry in numbers to find an underlying truth. Using this philosophical approach, we begin this analysis of Pythagorean triples by assuming there is an underlying relationship between the numbers that make up all Pythagorean triples. Since the hypotenuse of all right angles triangles is always the largest number, we start by converting the Pythagorean equation:

(A2 = B2 + C2) into an equivalent that links the three numbers together, i.e. A2 = (A-p)2 + (A-q)2

For clarity, we also choose to replace A with n, such that the equation becomes:

n2 = (n – p)2 + (n – q)2 ………….(Eqn 2)

Expanding terms, we get: n2 = n2 – 2np + p2 + n2 – 2nq + q2

Collecting terms, we get: n2 = 2n2 – 2n(p + q) + (p2 + q2)

And hence from this analysis we form a new quadratic equation: n2 – 2n(p + q) + (p2 + q2) = 0

Using the standard quadratic formula to solve this equation: (-b ± √(b2 – 4ac))/2a

The solutions are n1, n2 = (p + q) ± √2pq ………….(Eq 3)

The difficulty with solving this solution for p and q is the surd, ± √2pq which restricts the number of possible integer solutions. To find this limit, we need to ensure ± √2pq becomes a perfect square, i.e. the values of p and q always ensure 2pq is a perfect square and therefore always produces an integer square root, e.g. 4 roots to 2, 9 roots to 3, 16 roots to 4 and so on.

Let r = ± √2pq, then r2 = 2pq and making p the subject: p = r2 / 2q

From which it is seen that for all values of q, the denominator, 2q is always even.

This means ‘r’ cannot be an odd number because r2 / 2q will always leave a fractional remainder.

This can be shown as follows:

Let ‘r’ be any generalised odd number, i.e., r = (2u + 1) where ‘u’ is any integer.

Therefore: r2 = (2u + 1)(2u + 1) and hence p = (2u + 1)(2u +1)/ 2q,  i.e. p = (4u2 + 4u + 1)/2q

Any value of ‘u’ will always leave a remainder equal to 1/2q, which is fractional because q is defined to be an integer. Therefore for a perfect square to exist, ‘r’ cannot be an odd number. Since all numbers must be either odd or even, ‘r’ must therefore be an even integer, i.e.

r = 2u	►	p = (2u)2 / 2q	►	p = 4u2 / 2q	►	2pq = 4u2 	►	pq = 2u2

and we have achieved the goal of expressing 2pq in terms of a perfect square, since 4u2 will generate perfect integer roots for all values of ‘u’. Table 2 is a small tabulation of the first ten positive integers to illustrate the effect.

u 4u2	± √2pq = ±√4u2 0	0	0 1	4	2 2	16	4 3	36	6 4	64	8 5	100	10 6	144	12 7	196	14 8	256	16 9	324	18 10	400	20

Table 2

Note that ‘u’ represents any positive, zero or negative seed integer and therefore p and q represent integer factors which can be used to solve the quadratic solution; n1, n2 = (p + q) ± √2pq and because steps have been taken to ensure 2pq is a perfect square, n1 and n2 will therefore always exist as integers.

Factors p and q are actually derived from 2u2 because there is a redundant 2 in the 2pq = 4u2 relationship. Factors p and q are therefore calculated from pq = 2u2

4.0) Application. Because the seed integer ‘u’ is squared, ’u’ can be any positive, zero or a negative integer, but for simplicity let u = 1 to begin.

Let u = 1 2u2 = 2(1)2 = 2. Therefore, non repeating factors of 2u2 are	p = 1 q = 2

Note that once the pq factors repeat, the process of factorising the integer, 2u2 stops because this would produce redundant factors and therefore redundant information. Using the quadratic solution from page 5, the two possible values of n are:

n1, n2 = (p + q) ± √2pq ………..(Eq 3)

i.e. n1, n2 = (1 + 2) ± √2(1)2

n1, n2 = 3 ± 2		i.e.	n1, n2 = 5 or 1

Substituting these integers into Eqn 2, we get:

n12 = (n1 - p)2 + (n1 - q)2 	or	n22 = (n2 - p)2 + (n2 - q)2

52 = (5 – 1)2 + (5 – 2)2		or	12 = (1 – 1)2 + (1 – 2)2

52 = 42 + 32		or	12 = 02 + (-1)2

And we discover that when the seed integer is unity, two Pythagorean triples are created, but only one is of any real interest. The other is known as a trivial solution because it equates a number to itself and contains zero in the solution.

Let u = 2 2u2 = 2(2)2 = 8 and the non repeating factors of 2u2 are:	p = 1	2 q = 8	4

Now we have four factors when u = 2 which will generate four Pythagorean triples.

Substituting these factors into Eqn 3, we get:

n1, n2 = (1 + 8) ± √2(1)8	and		n3, n4 = (2 + 4) ± √2(2)4

n1, n2 = 9 ± 4		and		n3, n4 = 6 ± 4

n1, n2 = 13 or 5 	and		n3, n4 = 10 or 2

Substituting these integers into Eqn 2, we get:

n12 = (n1 – p1)2 + (n1 – q1)2 	&	n22 = (n2 – p1)2 + (n2 – q1)2

& 	n32 = (n3 – p2)2 + (n3 – q2)2 	&	n42 = (n4 – p2)2 + (n4 – q2)2

132 = (13 – 1)2 + (13 – 8)2 	&	52 = (5 - 1)2 + (5 - 8)2

&	102 = (10 – 2)2 + (10 – 4)2 	&	22 = (2 - 2)2 + (2 - 4)2

132 = 122 + 52	 &	52 = 42 + (-3)2 	&	102 = 82 + 62	&	22 = 02 + (-2)2

And we discover that when the seed integer, u = 2, it generates three real and one trivial Pythagorean triples, although strictly speaking only one new triple has been calculated because the (52 = 42 + 32) triple has been repeated twice in the form of (52 = 42 + (-3)2) and (102 = 82 + 62).

Let u = 3 2u2 = 2(3)2 = 18 and the non repeating factors of 2u2 are:	p = 1	  2	3 q = 18	  9	6

Now we have six separate possible solutions when u = 3, i.e. 2 x the non repeating factors of pq.

Substituting these integers into Eqn 3, we get:

n1, n2 = (1 + 18) ± √2(1)18	& n3, n4 = (2 + 9) ± √2(2)9	&	n5, n6 = (3 + 6) ± √2(3)6

n1, n2 = 19 ± 6			&	n3, n4 = 11 ± 6			&	n5, n6 = 9 ± 6

n1, n2 = 25 or 13 		&	n3, n4 = 17 or 5			&	 n5, n6 = 15 or 3

Substituting these integers into Eq 2, we get:

n1, n2 = n2 = (n–p1)2 + (n–q1)2 & n3, n4 = n2 = (n–p2)2 + (n–q2)2 & n5, n6 = n2 = (n–p3)2 + (n–q3)2

252 = (25 – 1)2 + (25 – 18)2 	& 172 = (17 - 2)2 + (17 - 9)2 	&  152 = (15 – 3)2 + (15 – 6)2

252 = 242 + 72 		& 	172 = 152 + 82  		&	152 = 122 + 92

and

132 = (13 – 1)2 + (13 – 18)2 	&	52 = (5 - 2)2 + (5 - 9)2 		 &	32 = (3 – 3)2 + (3 – 6)2

132 = 122 + (-5)2 		&	52 = 32 + (-4)2  		&	32 = 02 + (-3)2

Of these six results, only two are new triples, (252 = 242 + 72 ) and (172 = 152 + 82 ). The 132 = 122 + (-5)2 triple is a version of the 132 = 122 + 52 triple found when u =2. The (152 = 122 + 92 ) triple is just three times the 52 = 42 + 32 triple found when u =1. The 52 = 32 + (-4)2 triple is a variant of the 52 = 42 + 32 triple calculated when u = 1. Finally, the last triple is the trivial solution 32 = 02 + (-3)2 which just equates a number to itself with the addition of zero.

5.0) Pythagorean Patterns of Behaviour. There now follows a list of the Pythagorean triples calculated from seed values of ‘u’ between 1 and 10 to illustrate the patterns that exist in these integers. A Basic programme was written for this task. The two most interesting patterns that emerged quite quickly from this limited study were:

1)	Each triple was made from two odd integers and one even integer. 2)	The area of the triangle and the sum of the triples were related to the seed integer, ‘u’. 3)	The seed integer has the dimension of ‘metres’.

Both these topics are discussed later in this paper, but expressed mathematically, it will be shown that:

Seed integer, u = (2 x Triangle Area / Sum of triples)	►	u = (BC / (A+B+C))

Using this new fact, it has been possible to calculate the seed integer for the impressive Sumerian and Babylonian triple, A = 3541, B = 2700, C = 2291 was 725. Naturally, they would have been completely unaware of the existence of this seed integer, nor the other triples that this number produced. A full catalogue of the ‘725’ triples is reproduced at the end of this section.

In the following tabulation, each seed integer generates a number of Pythagorean triples, some unique, some variants, but always one trivial triple. For the purposes of clarity, each triple is described by these terms.

u = 1

52 = 42 + 32		Unique 12 = 02 + (-1)2		Trivial

There are two solutions, including the trivial solution is; u2 = 02 + (-u)2

u = 2

132 = 122 + 52 		Unique 52 = 42 + (-3)2 		Variant 102 = 82 + 62 		(5u)2 = (4u)2 + (3u)2 ) 22 = 02 + (-2)2 		Trivial

Although there are four solutions, only one is original. The 52 = 42 + (-3)2 triple is a variation of 52 = 42 + 32 & 102 = 82 + 62 is (5u)2 = (4u)2 + (3u)2. The trivial solution is again u2 = 02 + (-u)2

u = 3

252 = 242 + 72 		Unique 172 = 152 + 82		Unique 152 = 122 + 92 		(5u)2 = (4u)2 + (3u)2 132 = 122 + (-5)2 	Variant 52 = (-4)2 + 32 		Variant 32 = 02 + (-3)2 		Trivial

There are six (2u) solutions, but only two are original. 132 = 122 + (-5)2 and 52 = 32 + (-4)2 are variants of 132 = 122 + 52 and 52 = 42 + 32 and 152 = 122 + 92 is just (5u)2 = (4u)2 + (3u)2. Note again the trivial solution is also u2 = 02 + (-u)2

u = 4

412 = 402 + 92		Unique 252 = 242 + (-7)2	Variant 262 = 242 + 102 	2 x (132 = 122 + 52) 102 = 82 + (-6)2 	2 x (52 = 42 + (-3)2) 202 = 162 + 122 	(5u)2 = (4u)2 + (3u)2 42 = 02 + (-4)2 		Trivial

u = 5

612 = 602 + 112	Unique 372 = 352 + 122 	Unique 412 = 402 + (-9)2	Variant 172 = 152 + (-8)2 	Variant 252 = 202 + 152 	(5u)2 = (4u)2 + (3u)2 52 = 02 + (-5)2 		Trivial

u = 6

852 = 842 + 132	Unique 292 = 212 + 202	Unique 612 = 602 + (-11)2	Variant 52 = (-4)2 + (-3)2	Variant 392 = 362 + 152 	3 x (132 = 122 + 52) 152 = 122 + (-9)2 	3 x (52 = 42 + (-3)2) 502 = 482 + 142	2 x (252 = 242 + 72) 262 = 242 + (-10)2 	2 x (132 = 122 + (-5)2) 342 = 302 + 162	2 x (172 = 152 + 82) 102 = (-8)2 + 62	2 x (52 = 42 + 32) 302 = 242 + 182	(5u)2 = (4u)2 + (3u)2 62 = 02 + (-6)2 		Trivial

u = 7

1132 = 1122 + 152	Unique 652 = 632 + 162	Unique 852 = 842 + (-13)2	Variant 372 = 352 + (-12)2	Variant 352 = 282 + 212	(5u)2 = (4u)2 + (3u)2 72 = 02 + (-7)2 		Trivial

u = 8

1452 = 1442 + 172	Unique 1132 = 1122 + (-15)2	Variant 822 = 802 + 182	2 x (402 = 402 + 92) 502 = 482 + (-14)2	2 x (252 = 242 + (-7)2) 522 = 482 + 202	4 x (132 = 122 + 52) 202 = 162 + (-12)2	4 x (52 = 42 + (-3)2) 402 = 322 + 242 	(5u)2 = (4u)2 + (3u)2 82 = 02 + (-8)2 		Trivial

u = 9

1812 = 1802 + 192	Unique 1452 = 1442 + (-17)2	Variant 1012 = 992 + 202	Unique 652 = 632 + (-16)2	Variant 752 = 722 + 212	3 x (252 = 242 + 72) 392 = 362 + (-15)2	3 x (132 = 122 + (-5)2) 512 = 452 + 242	3 x (172 = 152 + 82) 152 = (-12)2 + 92	3 x (52 = 42 + 32) 452 = 362 + 272 	(5u)2 = (4u)2 + (3u)2 92 = 02 + (-9)2 		Trivial

u = 10

2212 = 2202 + 212	Unique 1812 = 1802 + (-19)2	Variant 1222 = 1202 + 222	2 x (612 = 602 + 112) 822 = 802 + (-18)2	2 x (412 = 402 + (-9)2) 742 = 702 + 242	2 x (372 = 352 + 122) 342 = 302 + (-16)2	2 x (172 = 152 + (-8)2) 652 = 602 + 252	5 x (132 = 122 + 52) 252 = 202 + (-15)2	5 x (52 = 42 + (-3)2) 532 = 452 + 282 	Unique 132 = (-12)2 + 52 	Variant 502 = 402 + 302 	(5u)2 = (4u)2 + (3u)2 102 = 02 + (-10)2 	Trivial

The Sumerian & Babylonian Seed Integer: 725 10527012 = 10527002 + 14512	Unique 5270772 = 5270752 + 14522		Unique 423412 = 423402 + 2912		Unique 213172 = 213152 + 2922		Unique 37572 = 31322 + 20752		Unique 36252 = 29002 + 21752		(5u)2 = (4u)2 + (3u)2 35412 = 27002 + 22912		Sumerian & Babylonian 19972 = 19722 + 3152 			Unique 17412 = 17402 + 592			Unique 13012 = 13002 + 512			Unique 11812 = 11312 + 3402			Unique 9012 = 8992 + 602			Unique 7252 = 02 + (-725)2			Trivial 6772 = 6752 + 522 			Unique 612 = 602 + 112			Variant 372 = 352 + 122			Variant 10498012 = 10498002 + (-1449)2	Variant 5241772 = 5241752 + (-144811)2	Variant 417612 = 417602 + (-289)2		Variant 207372 = 207352 + (-288)2		Variant 16252 = 16242 + (-57)2		Variant 14172 = 13922 + (-265)2		Variant 12012 = 12002 + (-49)2		Variant 8572 = (-825)2 + 2322			Variant 7852 = 7832 + (-56)2			Variant 6412 = (-609)2 + (-200)2		Variant 6012 = 5512 + (-240)2			Variant 5772 = 5752 + (-48)2 			Variant 412 = 402 + (-9)2			Variant 172 = 152 + (-8)2			Variant