You are on page 1of 7

Advances in Pure Mathematics, 2011, 1, 16-22

doi:10.4236/apm.2011.12005 Published Online March 2011 (http://www.SciRP.org/journal/apm)

The Pell Equation x 2 Dy 2 = k 2


Amara Chandoul
Institut suprieur dInformatique et de Multimedia de Sfax, Sfax, Tunisia
E-mail: amarachandoul@yahoo.fr
Received January 9, 2011; revised January 29, 2011; accepted February 5, 2011

Abstract

Let D 1 be a positive non-square integer and k 2 be any fixed integer. Extending the work of A. Tek-
can, here we obtain some formulas for the integer solutions of the Pell equation x 2 Dy 2 = k 2 .

Keywords: Pells Equation, Solutions of Pells Equation

1. Introduction For completeness we recall that there are many papers


in which are considered different types of Pell's equation.
The equation x 2 Dy 2 = N , with given integers D and Many authors such as Tekcan [1], Kaplan and Williams
N and unknowns x and y , is called Pells equation. [2], Matthews [3], Mollin, Poorten and Williams [4],
If D is negative, it can have only a finite number of Stevenhagen [5] and the others consider eome specific
solutions. If D is a perfect square, say D = a 2 , the Pell equations and their integer solutions. A. Tekcan in
equation reduces to x ay x ay = N and again [1], considered the equation x 2 Dy 2 = 4 , and he ob-
tained some formulas for its integer solutions. He
there is only a finite number of solutions. The most
mentioned two conjecture which was proved by A. S.
interesting case of the equation arises when D 1 be a
Shabani [6]. In this paper we extend the work of A. Tek-
positive non-square.
can by considering the Pell equation x 2 Dy 2 = k 2
Although J. Pell contributed very little to the analysis
when D 1 be a positive non-square and k 2 , we
of the equation, it bears his name because of a mistake
obtain some formulas for its integer solutions.
by Euler.
Pells equation x 2 Dy 2 = 1 was solved by Lagrange
in terms of simple continued fractions. Lagrange was the 2. The Pell Equation x 2 Dy 2 = k 2
first to prove that x 2 Dy 2 = 1 has infinitly many solu-
tions in integers if D 1 is a fixed positive non-square In this section, we consider the solutions of Pell's
integer. If the lenght of the periode of D is 1, all po- equation x 2 Dy 2 = k 2 when k 2 .
sitive solutions are given by x = P2vk 1 and y = Q2vk 1 Theorem 2.1 Let x1 , y1 be the fundamental solu-
if k is odd, and by x = Pvk 1 and y = Qvk 1 if k is tion of the Pell equation x 2 Dy 2 = k 2 , and let
P n
even, where v = 1, 2, and n denotes the nth con- un x1 Dy1 1
Qn (1)
vn y1 x1 0
vergent of the continued fraction expansion of D Inci-
dentally, x = P 2v 1 k 1 and y = Q 2v 1 k 1 , v = 1, 2, , for n 1 . Then the integer solutions of the Pell equation
are the positive solutions of x 2 Dy 2 = 1 provided x 2 Dy 2 = k 2 are xn , yn , where
that 1 is odd. un vn
There is no solution of x 2 Dy 2 = 1 other than xn , yn = n 1
, n 1 (2)
k k
x
v
xv , yv : v = 1, 2, given by 1 D y1 = xv D yv , Proof. We prove the theorem using the method of
where x1 , y1 is the least positive solution called the mathematical induction. For n = 1 , we have from (1),
fundamental solution, which there are different method u1 , v1 = x1 , y1 which is the fundamental solution of
for finding it. The reader can find many references in the x 2 Dy 2 = k 2 . Now, we assume that the Pell equation
subject in the book [7]. x 2 Dy 2 = k 2 is satisfied for xn 1 , yn 1 , i.e.

Copyright 2011 SciRes. APM


A. CHANDOUL 17

un21 Dvn21 In the other hand, we have


xn21 Dyn21 = = k2 (3)
k 2n 4 vn = y1un 1 x1vn 1 ,
and we show that it holds for xn , yn . so
Indeed, by (1), it is easy to prove that k n 1 yn = y1k k 2 xn 1 x1k n 2 yn 1 ,

un = x1un 1 Dy1vn 1 witch implies


. (4)
y1 xn 1 x1 yn 1
vn = y1un 1 x1vn 1 yn = .
Hence, k
and hence
u 2 Dv 2
x Dy n 2 n 2 n
2
n
2
n xn xn 1
k xn yn 1 yn xn 1
yn yn 1
x1un 1 Dy1vn 1 D y1un 1 x1vn 1
2 2

x1 xn 1 Dy1 yn 1 yx x y
k 2n2 = yn 1 1 n 1 1 n 1 xn 1
k k
x 2 u 2 2 x1un 1 Dy1vn 1 D 2 y12 vn21
1 n 1 x1 xn 1 yn 1 Dy1 yn21 y1 xn21 x1 xn 1 yn 1
k 2n2 =

k
D y12 un21 2 y1un 1 x1vn 1 x12 vn21
y1 ( xn21 Dyn21 )
k 2n2 =
k

=
2
x u
1 2
n 1 Dv 2
n 1 Dy u 2
1
2
n 1 Dvn21 = ky1 .
2n 2
k Theorem 2.3 Let x1 , y1 be the fundamental solu-
u 2
Dvn21 tion of the Pell equation x 2 Dy 2 = k 2 , then xn , yn

= x12 Dy12 n 1

k 2n 2
satisfy the following recurrence relations
2
Applying (3), it is easily seen that xn = k x1 1 xn 1 xn 2 xn 3

un21 Dvn21 = k 2 n 4 k 2 = k 2 n 2 . (7)
y = 2 x 1 y y y
hence we conclude that n k 1 n 1 n2 n 3


xn2 Dyn2 = x12 Dy12 = k 2 . for n 4 .
Proof. The proof will be by induction on n . Using (5),
Therefore xn , yn is also a solution of the Pell equa- we have
tion x 2 Dy 2 = k 2 . Since n is arbitrary, we get all in- x 2 Dy12 x12 x12 k 2 2 2
teger solutions of the Pell equation x 2 Dy 2 = k 2 . x2 1 x1 k
k k k
Corollary 2.2 Let x1 , x2 is the fundamental solu- (8)
2
tion of the Pell equation x 2 Dy 2 = k 2 , then y2 = x1 y1
k
x1 xn 1 Dy1 yn 1 y x x y
xn = , yn = 1 n 1 1 n 1 (5) Using (5) and (8), we get
k k
2 2
and x1 x12 k Dy12 x1
x x Dy1 y2 k k
xn xn 1 x3 1 2
ky1 . (6) k k
xn 1 yn 1
2 2 k2
Proof. By (1), we have un = x1un 1 Dy1vn 1 and
2


x1 x12 Dy12 k x1 2 x1 k
2 2

= k
k k 2
vn = y1un 1 x1vn 1 by (2), we have un = k n 1 xn and
k k
vn = k n 1 yn . We get
2 3k
2
un = x1un 1 Dy1vn 1 , x1 2 x12
k 2 4
then, = = x1 2 x12 3
k n 1 xn = x1k k 2 xn 1 Dy1k n 2 yn 1 k k
2 2 2 2
witch gives y1 x1 k x1 y1
yx x y 4
y3 = 1 2 1 2 = k
k
x1 xn 1 Dy1 yn 1 = y1 2 x12 1
xn = . k k k
k (9)

Copyright 2011 SciRes. APM


18 A. CHANDOUL

Then by (5) and (9), we find x4 and y4 . x1 xn Dy1 yn


xn 1
x x Dy1 y3 k
x4 1 3
k 2
x1 x1 1 ( xn 1 xn 2 ) xn 3
4 4 k
x12 2 x12 3 Dy12 2 x12 1
k k k
k 2
Dy1 x1 1 ( yn 1 yn 2 ) yn 3
4 4 k
x12 2 x12 3 ( x12 k 2 ) 2 x12 1

k k k
k 2 x x Dy1 yn 1 x1 xn 2 Dy1 yn 2
8 8 = x1 1 1 n 1
3 x14 x12 k k k k
k k x x Dy1 yn 3
y1 x3 x1 y3 1 n 3
y4 k
k
2
4 4 = x1 1 xn xn 1 xn 2 .
y1 x1 2 x12 3 x1 y1 2 x12 1 k
k k
k y1 xn x1 yn
yn 1 =
8 4 k
x1 y1 3 x12
k k 2
y1 x1 1 ( xn 1 xn 2 ) xn 3
k
So, we obtained =
k
8 4 8 2 2
x4 k 3 x1 k x1 k x1 x1 1 ( yn 1 yn 2 ) yn 3


k
(10)
y x y 8 x2 4 k
1 1 3 1
4 k k 2 y x x y yx x y
= x1 1 1 n 1 1 n 1 1 n 2 1 n 2
Now, replacing (8) and (9) in (7), one obtains k k k
yx x y
2 1 n 3 1 n 3
x4 x1 1 ( x3 x2 ) x1 k
k
2
2 4 2 = x1 1 yn yn 1 yn 2
x1 1 x1 2 x12 3 x12 k x1 k
k k k
completing the proof.
2 4 2
x1 1 2 x13 3 x1 x12 k x1
k k k
3. The Negative Pell Equation
8 4 8 2
3 x1 x1 k . x 2 Dy 2 = k 2
k k
and
Theorem 3.1 Let x1 , y1 be the fundamental solution
2 of the Pell equation x 2 Dy 2 = k 2 , then the other so-
y4 x1 1 ( y3 y2 ) y1
k lutions are x2 n 1 , y2 n 1 , where
2 4 2 u2 n 1 v2 n 1
x1 1 y1 2 x12 1 x1 y1 y1 x2 n 1 , y2n 1 = , 2n , (11)
k k k k
2n
k
8 4
x1 y1 3 x12 . for n 0 .
k k Proof. We prove the theorem using the method of
which are the same formulas as in (10). Therefore (7) mathematical induction. For n = 0 , we have from (11),
holds for n = 4 . u1 , v1 = x1 , y1 which is the fundamental solution of
Now, we assume that (7) holds for n 4 and we x 2 Dy 2 = k 2 . Now, we assume that the Pell equation
show that it holds for n 1 . x 2 Dy 2 = k 2 is satisfied for n 0 . So, x2 n 1 , y2 n 1 ,
Indeed, by (5) and by hypothesis we have i.e.

Copyright 2011 SciRes. APM


A. CHANDOUL 19

x22n 1 Dy22n 1 =
u22n 1 Dv22n 1
= k 2 (12)
v2 n 1 = 2 x1 y1u2 n 1 x12 Dy12 v2 n 1 . By (11), we have
k 4n u2 n 1 = k 2 n x2 n 1 and v2 n 1 = k 2 n y2 n 1 . We get
and we show that it holds for n 1 .
Indeed, by (1), it is easily to seen that

u2 n 1 = x12 Dy12 u2 n 1 2 Dx1 y1v2 n 1

2n 3
then,
u2 n 3 x1 Dy1 1

k 2 n x2 n 1 = x12 Dy12 k 2 n 2 x2 n 1 2 Dx1 y1k 2 n 2 y2 n 1
v2 n 3 y1 x1 0
2 2 n 1 witch gives
x Dy1 x1 Dy1 1
1
y1

x1 y1

x1

0 x2 n 1 =
x 2
1
Dy12 x2 n 1 2 Dx1 y1 y2 n 1
.
(13) k2
x 2 Dy12 2 Dx1 y1 u2 n 1 1
1
2 x1 y1 x12 Dy12 v2 n 1 0 In the other hand, we have


x12 Dy12 u2 n 1 2 Dx1 y1v2 n 1 v2 n 1 = 2 x1 y1u2 n 1 x12 Dy12 v2 n 1 ,

2x y u
1 1 2 n 1
x12 Dy12 v2 n 1
so

k 2 n y2 n 1 = 2 x1 y1k 2 n 2 x2 n 1 x12 Dy12 k 2 n 2 y2 n 1 ,
Hence, by (*), we have ( x2 n 2 ) D( y2 n 2 ) k 4 4 4

witch implies
Therefore x
2 n 1 1 , y2 n 1 1 = x2 n 3 , y2 n 3 is also a

2 x1 y1 x2 n 1 x12 Dy12 y2 n 1
solution of the Pell equation x 2 Dy 2 = k 2 . Since n y2 n 1 = 2
.
is arbitrary, we get all integer solutions of the Pell equa- k
tion x 2 Dy 2 = k 2 . and hence
Corollary 3.2 Let x1 , x2 is the fundamental solu- x2 n 1 xn 1
tion of the Pell equation x 2 Dy 2 = k 2 , then x2 n 1 y2 n 1 y2 n 1 x2 n 1
y2 n 1 yn 1

x2 n 1 =
( x12 Dy12 ) x2 n 1 2 Dx1 y1 y2 n 1
,

x 2
1
Dy12 x2 n 1 2 Dx1 y1 y2 n 1
y2 n 1
k2
(14) k2
( x12 Dy12 ) y2 n 1
y2 n 1
2x y x
= 1 1 2 n 1
k2

2 x1 y1 x2 n 1 x12 Dy12 y2 n 1 x2 n 1
2
k
and Dy22n 1 x22n 1
= 2 x1 y1
x2 n 1 x2 n 1 k2
= 2 x1 y1 . (15)
y2 n 1 y2 n 1
= 2 x1 y1

k 2
2
Proof. Using (1), we have k

u2 n 1 = x12 Dy12 u2 n 1 2 Dx1 y1v2 n 1 and = 2 x1 y1 .

x
2 2
u 2 Dv 2
2
Dy12 u2 n 1 2 Dx1 y1v2 n 1 D 2 x1 y1u2 n 1 x12 Dy12 v2 n 1
*
1
x 2
2n 3 Dy 2
2n3 2n 3 4n 4 2n 3
k k 4n 4 k 4n 4
x
2
2
1 Dy12 u22n 1 4 Dx1 y1 x12 Dy12 u2 n 1v2 n 1 4 D 2 x12 y12 v22n 1
= 4n 4
k


x 2
1 Dy 2 2
1 v2
2 n 1
4 Dx1 y1 x12 Dy12 u2 n 1v2 n 1 4 Dx12 y12 u22n 1
4n 4
k


u22n 1 Dv22n 1
2 2

u Dv

2 2
= x12 Dy12 4 Dx12 y12 2 n 1 4 n 4 2 n 1 = x12 Dy12
k k 4n4
u2 n 1 Dv2 n 1 1
2 2

1

2
= k 2 = k 4 k 2 4 = k 2
k 4n k4 k

Copyright 2011 SciRes. APM


20 A. CHANDOUL

Theorem 3.3 Let x1 , y1 be the fundamental solu-


tion of the Pell equation x 2 Dy 2 = k 2 , then xn , yn x3 =
x 2
1
Dy12 x1 2 Dx1 y12
=

x1 x12 3Dy12
2 2
satisfy the following recurrence relations k k
(17)
4 2
x1 x 3 x 3k
2 2 2
=x 4
x2 n 1 = k 2 x1 1 x2 n 1 x2 n 3 x2 n 5
1 1
1 2 x1 3
2
=
k2 k
(16)
y 4 2
2 n 1 k 2 1
= x 1 y2 n 1 y2 n 3 y2 n 5
y3

2 x12 y1 x12 Dy12 y1
y1 2 x12 x12 Dy12
=
k2 k2
(18)
for n 3 .

y1 4 x12 k 2 =y 4
1 2 x 1
2
Proof. The proof will be by induction on n . Using = 1
(14), we have k2 k

Using (14), (17) and (18), we get


4 4
x2
1
Dy12 x3 2 Dx1 y1 y3 x
2
1
Dy12 x1 2 x12 3 2 Dx1 y12 2 x12 1
k k = 4 x 4 x4 5x 5 k .
2
x5 = = 1 1 1 (19)
k2 k2 k2 k2 4
4 4

2 x1 y1 x3 x12 Dy12 y3 k

2 x12 y1 2 x12 3 x12 Dy12 y1 2 x12 1
k = 4 y 4 x 4 3x 2 k
2

2 1 2 1 .
y5 = = 1 (20)
k2 k 2
k k 4
Then by (19) and (20), we find x7 and y7 .
4 4 k 2
2 2

x Dy x5 2 Dx1 y1 y5
x1
Dy12 2 x1 2 x14 5 x1 5
2

1 1 k k 4
x7 2
2
k k
4 4 4 k 2

2 Dx1 y1 2 y1 2 x1 3 x12
k k 4 4 16 6 28 4 k2
= x1 x1 x1 14 x1
2
7
k2 k2 k4 k2 4

4 4 k 2
2 x1 y1 2 x1 2 x14 5 x1 5
y7

2 x1 y1 x5 x Dy y52
1
=
2
1 k k 4
2 2
k k
4 4 k

2
x12 Dy12 2 y1 2 x14 3 x12
k k 4 4 16 4 k2
2
= 2 y1 4 x16 5 2 x14 6 x12
k k k k 4
So, we obtained
4 16 6 28 4 k2
x7 = 2 x1 4 x1 2 x1 14 x1 7
2

k k k 4
(21)
4 16 6 4 4 k2
y 7 = 2
y1 4
x1 5 2
x1 6 x1
2

k k k 4
Now, replacing (17), (18), (19) and (20) in (16), one obtains

4 4 4 4 k2 4
x7 2 x12 1 x5 x3 x1 2 x12 1 2 x1 2 x14 5 x1 5 x1 2 x12 3 x1
k k k k 4 k
4 16 6 28 4 k2
x1 x1 x1 14 x1
2
7
k2 k4 k2 4

Copyright 2011 SciRes. APM


A. CHANDOUL 21

and

4 4 4 4 k2 4
y7 = 2 x12 1 y5 y3 y1 = 2 x12 1 2 y1 2 x14 3 x12 y1 2 x12 1 y1
k k k k 4 k
4 16 6 4 4 k2
= y1 x1 5 x1 6 x1
2

k2 k4 k2 4

which are the same formulas as in (21). Therefore (16) Now, we assume that (16) holds for n 3 and we
holds for n = 3 show that it holds for n 1 .

Indeed, by (14) and by hypothesis we have

x2 n 3
x 2
1
Dy12 x2 n 1 2 Dx1 y1 y2 n 1
k2
4 2 4 2
x 2
1 Dy12 k 2 x1 1 x2 n 1 x2 n 3 x2 n 5 2 Dx1 y1 k 2 x1 1 y2 n 1 y2 n 3 y2 n 5

k2 k2
4 x1 Dy1
= 2 x12 1
2 2
x2 n 1 x2 n 3 2 Dx1 y1 y2 n 1 y2 n 3

x
2
1
Dy12 x2 n 5 2 Dx1 y1 y2 n 5
k
2
k k2

= 2 x1 1
2 2

4 2 x1 Dy1 x2 n 1 2 Dx1 y1 y2 n 1 4 2 x1 Dy1 x2 n 3 2 Dx1 y1 y2 n 3
2 x1 1
2 2

k k2 k k2


x 2
1
Dy12 x2 n 5 2 Dx1 y1 y2 n 5

x 2
1
Dy12 x2 n 5 2 Dx1 y1 y2 n 5
2
k k2

y2 n 3 =

2 x1 y1 x2 n 1 x12 Dy12 y2 n 1
2
k
4 2 4 2
2 x1 y1 2 x1 1 x2 n 1 x2 n 3 x2 n 5 k 2 x1 1 x2 n 1 x2 n 3 x2 n 5
2
x12 Dy
k 1

=
k2 k 2

= 2 x1 1
2 2

2 x1 1

4 2 2 x1 y1 x2 n 1 x1 Dy1 y2 n 1 4 2 2 x1 y1 x2 n 3 x1 Dy1 y2 n 3
2 2

k k2 k k2



2 x1 y1 x2 n 5 x12 Dy12 y2 n 5 4
= 2 x12 1 y2 n 1 y2 n 3 y2 n 5 .
k
2
k

completing the proof. x 2 my 2 = 1, 4 and continued fractions, Journal of


Number Theory, Vol. 23, 1986, pp. 169-182.
4. Acknowledgements [3] K. Matthews, The Diophantine Equation
x 2 Dy 2 = N , D > 0 , Expositiones Mathematicae, Vol.
We would like to thank Sad Chandoul and Massuda 18, 2000, pp. 323-331.
Lorayed for helpful discussions and many remarks. doi:10.1016/0022-314X(86)90087-9
[4] R. A. Mollin, A. J. Poorten and H. C. Williams, Halfway
5. References to a Solution of x 2 Dy 2 = 3 , Journal de Theorie des
Nombres Bordeaux, Vol. 6, 1994, pp. 421-457.
[1] A. Tekcan, The Pell Equation x 2 Dy 2 = 4 , Applied [5] P. Stevenhagen, A Density Conjecture for the negative
Mathematical Sciences, Vol. 1, No. 8, 2007, pp. 363-369. Pell Equation, Computational Algebra and Number The-
[2] P. Kaplan and K. S. Williams, Pells Equation ory, Mathematics and its Applications, Vol. 325, 1995,

Copyright 2011 SciRes. APM


22 A. CHANDOUL

187-200. [7] I. Niven, H. S. Zuckerman and H. L. Montgomery, An


[6] A. S. Shabani, The Proof of Two Conjectures Related to Introduction to the Theory of Numbers, 5th Edition,
Wiley, the Republic of Singapore, 1991.
Pell's Equation x 2 Dy 2 = 4 , International Journal of
Computational and Mathematical Sciences, Vol. 2, No. 1,
2008, pp. 24-27.

Copyright 2011 SciRes. APM

You might also like