Showing posts with label pythagorean triplet. Show all posts
Showing posts with label pythagorean triplet. Show all posts

Thursday, November 10, 2011

2011/088) Find a right angled triangle with integer sides whose all three sides are fibonacci numbers.


No solution

Proof:
Let the legs be x and y
X and y cannot be same then hypotenuse shall be x qrt(2) and it is not integer.
Now let x < y and so hypotenuse >= (x+y)
as next Fibonacci number = (x+y) if x and y are consecutive Fibonacci numbers
and > (x+y) if they are not consecutive
So x^2+y^2 >= (x+y)^2 which is not possible unless x = 0
Hence no solution

Friday, March 4, 2011

2011/021) Pythagorean triplet with Gaussian Integer

Here we discuss the Pyhagorean triplet using Gaussian integers

As I have discussed in the previous blog entry about Gaussian integers that Gaussian integers are complex number of the form α = u + vi, where u and v are ordinary integers d i is the square root of minus one.

A primitive Pythagorean triple is one in which a and b are coprimes

That is integers (a,b,c) form a primitive Pythagorean triple where a^2+b^2= c^2 and

a and b are coprime

as a and b are co primes both cannot be even and only one can be odd. Both cannot be odd as

a mod 2 = 1 and b mod 2 = 1 shall give a^2 + b^2 mod 4 = 2 which is not a perfect square.

Now c^2 = (a^2+ b^2) = (a+ib)(a-ib)

Now both factors a + ib and a-ib cannot share any common factor that is they most be coprime to each other

So both of them must be perfect squares
Let
(a+ib) = (u+iv)^2 (and so (a-ib) = (u-iv)^2)

squaring RHS we get

a = u^2-v^2
b= 2uv

and c = (u+iv)(u-iv) = (u^2+v^2)

so we get

(u^2-v^2, 2uv, u^2+v^2) as Pythagorean triplet

Sunday, February 6, 2011

2011/012) To construct an AP of integers so that 3 successive elements are perfect squares.

It is proved that we cannot have an AP whose 4 successive terms are in perfect squares
But does there exist an AP whose 3 consecutive terms are perfect squares

Solution:

Let the 3 consecutive term be a^2,b^2,c^2

As they are in AP we have
b^2-a^2 = c^2-b^2
or a^2+c^2 = 2b^2

this has a solution and we know that

if x^2 + y^2 = z^2

then (x+y)^2 + (x-y)^2 = 2(x^2+y^2) = 2z^2

so if (x,y,z) is a Pythagorean triplet the (x-y)^2 , z^2, (x+y)^2 are perfect squares and are in AP.

Or a= x-y
b = z^2
v= x+ y
for example
(3,4,5) is Pythagorean triplet so (4-3)^2, 5^2,(4+3)^2 or 1,25,49
(5,12,13) Pythagorean triplet so (12-5)^2, 13^2,(12+5)^2 or 49,169,289

Parametric form of Pythagorean triplet is
(m^2-n^2), (2mn), m^2 + n^2

So Parametric form of the required AP is

(m^2-n^2-2mn)^2,(m^2+n^2)^2,(m^2-n^2+2mn)^2

Sunday, September 20, 2009

2009/020) Pythagorean triplets.- Algebraic way

There is an algebraic way getting Pythagorean triplets

we know

x^2+y^2 = z^2 become a Pythagorean triplet if we have x y and z all to be integers.

If we can find x,y and z all to be rational then multiplying them by LCM of the denominator we are through.

To sort it we start with

n^2+(2n+1) = (n+1)^2 ..1

we know that n^2 and (n+1)^2 are squares and if we chose 2n+1 to be a square then we are through by proper transformation.

We cannot choose n to be an integer as we shall loose some values in the process so we shall put n = p/q but that is la

However we must have to chose 2n+1 to be a whole square say m^2 to get a Pythagorean triplet

So 2n = m^2 – 1

To avoid denominator in 1 we multiply (1) by 4 to get

4n^2 + 4(2n+1) = (2n+2)^2

Or (m^2-1)^2 + 4m^2 = (m^2+1)^2

so
2m, (m^2-1) and (m^2+1) satisfy the condition.(a^2+b^2 = c^2)

But m is not necessarily an integer and by choosing m = p/q and multiplying by q^2 we get

2pq, (q^2-p^2) and (q^2+p^2) satisfy the equation and if p and q are relatively prime then we get triplet with no common factor and hence it is a primitive triple..

Multiply this by any other integer and we shall get another triple(not primitive)

Saturday, September 19, 2009

2009/019) Pythagorean triplets.- trigonometric way

There is a trigonometric way of getting Pythagorean triplets.

we know x^2+y^2 = z^2

is homogeneous expression and dividing it by z^2 we get

(x/z)^2 + (y/z)^2 = 1 or a^2+b^2 =1

This is an identity when we put a = sin t and b = cos t

In case we chose a and b both rational we are through. But how to we guaranty that, that is how to choose both sin t and cos t to be rational. There is a way out.

That is by using double angle formula( writing sin t and cos t in terms of tan t/2)

We know sin t = 2 sin t/2 cos t/2
= 2 tan t/2 cos ^2 t/2
= 2 (tan t/2)/(1+ tan ^2 (t/2))

And cos t = (2 cos^2(t/2) – 1) = 2/(1+ tan ^2 t/2) – 1 = (1- tan ^2 t/2)/(1+ tan ^2 t/2)

So instead of chosing 2 expressions that is sin t and cos t we can chose tan t/2 as rational and so sin t and cos t both come out to be rational

Let tan t/2 = m and we get

(2m/(1+m^2)), (1-m^2)/(1+m^2) and 1 satisfy the condition and so

2m, (1-m^2) and (1+m^2) satisfy the condition.(a^2+b^2 = c^2)

But m is not necessarily an integer and by choosing m = p/q and multiplying by q^2 we get

2pq, (q^2-p^2) and (q^2+p^2) satisfy the equation and if p and q are relatively prime then we get triplet with no common factor and hence it is a primitive triple..

Multiply this by any other integer and we shall get another triple(not primitive)

Saturday, July 11, 2009

2009/005) parametric form for Pythagorean triplet (Gemoetric way)

To generate canonical form of Pythagorean triplet(geometric way)

Introduction

First it makes sense to define what is Pythagorean Triplet.

A Pythagorean triple is a triple of positive integers a, b, and c such that a right angled triangle exists with legs a , b and hypotenuse c. By the definition of Pythagorean Theorem , this is equivalent to finding positive integers a,b and c satisfying

a2+b2 = c2 ….1

The smallest and best-known Pythagorean triple is a =3, b =4, c = 5

It is not unusual to look for primitive Pythagorean triples.

The (1) is equivalent to finding real solution of

(a/c)2+(b/c)2 = 1
or x2+y2= 1 … 2

In case we get rational solutions in x and y the set (x,y,1) satisfy the condition. We can convert them to integer by proper multiplication that is LCM of denominator.
So we need to find rational x and y to satisfy the equation 2
We can put y as a function of x as following
Y = 2(1-x2)
We can choose x to be a rational number <1 all="" be="" br="" but="" cases.="" cases="" does="" for="" general="" generate="" get="" in="" may="" not="" of="" one="" rational.="" rational="" shall="" some="" the="" this="" to="" x="" y="">Now the problem is can we generate x and y to be rational or integer roots for a b c.

There are a couple of methods to find the rational x y.

the equation x^2+y^2 = 1 is a circle at centre (0,0) and radius 1

If we can find one point in the circle which is a rational point and draw a straight line y= mx +c through that point with m and c to be rational then it shall intersect the circle at another point which has got rational point. By choosing different m we can get more and more rational points.

We know one of the point in the circles is
x = 0 and y = -1 (people have used x = -1 and y =0 but this gives me simpler approach. The choice is arbitrary and no specific choice)
putting in y = mx + c we get y = mx-1 ….3
now put it in the equation 2 to get
x2 + (mx-1)2 = 1
or x2+m2x2-2mx=0
or x(1+m2) -2m = 0
x = 2m/(1+m2) ..4
put x = 2m/(1+m2) in 3 to get
y = 2m2/(1+m2) – 1 or (m2-1)/(m2+1)
so (2m/(1+m2), (m2-1)/(m2+1),1) satisfies x^2+y^2 = 1.
multiplying by m2+1 we get

(2m,.(m2-1),(m2+1)) satisfies x^2+y^2 = z^2 but they are not integers

By choosing different m we get different values basically in parametric form.
Now putting m =u/v which is ratio of integers and multiplying by v2
We get

x = 2uv
y = u2- v2
and z = u2 + v2

so (2uv, (u^2-v2) and (u^2+v^2)) form a triplet