intro to continued fractions

Upload: cahlen-humphreys

Post on 14-Apr-2018

212 views

Category:

Documents


0 download

TRANSCRIPT

  • 7/30/2019 Intro to Continued Fractions

    1/13

    Continued Fractions

    Cahlen Humphreys

    Abstract. Continued fractions are a fundamental part of number theory. We

    will prove that real numbers can be represented through the expansion of sim-

    ple continued fractions. Convergents are a necessary concept in which we will

    moderately investigate to help understand the expansion of these continued

    fractions. Moreover, examples will be provided to further reinforce the stepsneeded to be taken in order to represent an arbitrary real number as an con-

    tinued fraction expansion.

    AMS Subject Classification Number(s): 11A55, 40A15

    Keywords: Continued fractions, simple continued fractions, partial quotients,convergents.

    1. Introduction

    When we look at a number like it can be quite daunting trying to comprehendthe fact that it has no discernible pattern with regard to its decimal expansion. Fur-ther, it is quite tedious and in some ways not very insightful to observe the decimalexpansion by itself. For this reason, among others, continued fractions play andintegral role in the theory of numbers. Suppose for example that one wants to finda good approximation for but is limited to only the rational approximation 22/7.For years it was commonly accepted as being a decent approximation, however withthe theory of continued fractions we can approximate the value of more efficiently.

    Continued fractions have been subject to investigation throughout the seven-teenth and eighteenth centuries, and continue to be investigated today (C.D. Oldspg. 3). The earliest and most popular observance of a continued fraction comesfrom the days of Euclid and his algorithm for finding the greatest common divi-sor of two numbers. One can simply manipulate the algebra in the algorithm and

    easily produce a continued fraction. In this paper we are more intersted in how torepresent real numbers, both rational and irrational, through the expansion of acontinued fraction.

    Convergents are an important concept with regard to continued fractions, es-pecially when we are looking at the approximation of numbers. Lets take the

    2010 Mathematics Subject Classification. Primary 11A55.

    1

  • 7/30/2019 Intro to Continued Fractions

    2/13

    2 CAHLEN HUMPHREYS

    lengendary as a quick example. Observe that 22/7 is only the first convergent ofthe rational approxmation through a continued fraction. That is,

    227

    = 3 + 17

    .

    However if we go further to the second convergent we get,

    333

    106= 3 +

    1

    7 +1

    15

    and one additional step we get that

    355

    113= 3 +

    1

    7 +1

    15 +1

    1

    .

    It is clear that our approximation for gets more and more precise the convergentsa get larger and larger. This is explained more in Section 6 and 7 where we dis-cuss convergents and expansions for irrational numbers through continued fractions.

    So lets begin our investigation with continued fractions. Beginning with no-tation and definitions and ending with the expansion of rational and irrationalnumbers.

    2. Definitions and Notation

    Observe the expression below

    a1 + b1

    a2 +b2

    a3 +b3

    a4 +b4

    . . .

    .

    This expression is known as a continued fraction, and this is its most basic form.The numbers a1, a2, a3, . . . and b1, b2, b3, . . . may be real numbers or complex num-bers. Further, a continued fraction can be infinite or finite.

    We will only be discussing simple continued fractions which have the form

    a1 +

    1

    a2 +1

    a3 +1

    a4 +1

    . . .

    where all the numerators after the first term are 1. The first term a1 can be posi-tive, negative, or zero. The numbers a1, a2, a3, . . . are all positive.

  • 7/30/2019 Intro to Continued Fractions

    3/13

    CONTINUED FRACTIONS 3

    Finite simple continued fractions will be represented as the form

    a1 + 1

    a2 +1

    a3 +1

    a4 +1

    . . . +1

    an1 +1

    an

    where there are only finitely many terms a1, a2, a3, . . . , an. One should note thatcontinued fractions can also take on infinitely many ais, which we will discuss laterin this paper. Unless otherwise indicated, all of our examples and theorems willdeal exclusively with simple continued fractions.

    Another convenient way to write these finite simple continued fractions is ofthe form

    [a1, a2, . . . , an] = a1 +1

    a2 +

    1

    a3 + . . . +

    1

    anwhere after each + we lower the fraction. We will also occasionally restrict ournotation to the simple compact form

    [a1, a2, a3, . . . , an]

    and we call a1, a2, a3, . . . , an simply partial quotients.

    3. Example of Rational Expansion

    3.1. Example. Rational numbers are of the form p/q where p and q are inte-gers, and q = 0. Consider the rational number 67

    13, which can represented through

    a simple finite continued fraction. Observe,

    67

    13= 5 +

    1

    6 +1

    2

    = 5 +1

    6 +

    1

    2

    and we can also represent this expansion simply as [5, 6, 2]. Further observe thatthis can be confirmed through simply using the Euclidean Algorithm.

    67 = 5 13 + 213 = 6 2 + 1

    We now rewrite these equations as

    67

    13= 5 +

    2

    13

    13

    2= 6 +

    1

    2

  • 7/30/2019 Intro to Continued Fractions

    4/13

    4 CAHLEN HUMPHREYS

    Note that we get the continued fraction above by simply substituting the secondequation into the first. Note that,

    6713

    = 5 + 113

    2

    so we can now substitute to get

    67

    13= 5 +

    16 +

    1

    2

    = 5 + 16 +

    1

    2

    which is our continued fraction as desired.

    Observe that we can convert the continued fraction back into rational form.

    5 + 1

    6 +1

    2

    = 5 + 112

    2+

    1

    2

    = 5 + 113

    2

    = 5 + 213

    = 6713

    So in some way it is easier to go from a continued fraction to a rational number,rather than the other way around.

    3.2. Example. Lets take the rational number 125/7 and find the simple con-tinued fraction expansion. Observe that

    125 = 7 17 + 6.Now we divide by 7 to get

    125

    7 = 17 +

    6

    7

    = 17 +1

    7

    6

    .

    We now repeat the process with 7/6, observe,

    7 = 6 1 + 1and dividing by 6 we get

    7

    6= 1 +

    1

    6.

    Now we substitute this into our previous equation and get

    125

    7= 17 +

    1

    1 +1

    6

    .

    Again, we repeat the process with 6/1 and get

    6

    1= 1 6 + 0.

  • 7/30/2019 Intro to Continued Fractions

    5/13

  • 7/30/2019 Intro to Continued Fractions

    6/13

    6 CAHLEN HUMPHREYS

    If r2 = 0, we write (4.3) in the form

    (4.4) qr1

    = a2 + 1r1

    r2

    , 0 < r2 < r1,

    and repeat the division process using r1/r2.

    We observe that the calculations stop when we come to a remainder rn = 0.Is it possible never to arrive at an rn which is zero, so that the division processcontinues indefinitely? This is clearly impossible, for the remainders r1, r2, r3, . . .form a decreasing sequence of non-negative integers q > r1 > r2 > r3 > . . . andunless we come eventually to a remander rn which is equal to zero, we shall be inthe ridiculous position of having discovered an infinite number of distinct positive

    integers less than a finite positive integer q.

    Hence, by successive divisions we obtain a sequence of equations:

    p

    q= a1 +

    r1q

    , 0 < r1 < q,

    q

    r1= a2 +

    r2r1

    , 0 < r2 < r1,

    r1r2

    = a3 +r3r2

    , 0 < r3 < r2,

    . . . . . . . . . . . . . . . . . . . . . . . .

    rn3rn2

    = an1 +rn1rn2

    , 0 < rn1 < rn2,

    rn2rn1

    = an +0

    rn1= an + 0, rn = 0,

    (4.5)

    terminating, after a certain finite number of divisions, with the equation in whichthe remainder rn is equal to zero.

    It is now easy to represent p/q as a finite simple continued fraction. Fromthe first two equations in (4.5) we have

    p

    q= a1 +

    1

    q

    r1

    = a1 +1

    a2 +1

    r1

    r2

  • 7/30/2019 Intro to Continued Fractions

    7/13

    CONTINUED FRACTIONS 7

    Using the third equation in (4.5) we replace r1/r2 by

    a3 +1

    r2

    r3

    ,

    and so on, until we finally obtain the expression

    (4.6)p

    q= a1 +

    1

    a2 +

    1

    a3 + . . . +

    1

    an= [a1, a2, . . . , an]

    The uniqueness of the expansion (4.6) follows from the manner in which theais are calculated. This statement must be accompanied, however, by the remarkthat once the expansion has been obtained we can always modify the last term anso that the number of terms in the expansion is either even or odd, as we choose.To see this, notice that if an is greater than 1 we can write

    1

    an=

    1

    (a 1) + 11

    ,

    so that (4.6) can be replaced by

    (4.7)p

    q= [a1, a2, . . . , an1, an 1, 1].

    On the other hand, if an = 1, then

    1

    an1 +1

    an

    =1

    (an1 + 1),

    so that (4.6) becomes

    (4.8)

    p

    q = [a1, a2, . . . , an

    2, an

    1 + 1].

    5. Example of Irrational Expansion

    Much like our first example, irrational numbers can also be represented as sim-ple continued fractions. In the case of rational numbers, we can represent them withfinitely many partial quotients. In the case of irrational numbers we will observethat the expansion is infinite, hence we will have infinitely many partial quotients.Observe that through each step we obtain and more precise approximation of theirrational number.

    5.1. Example. Appropriately, we will continue our example by expanding one

    of the most popular irrational numbers in history, that being . The largest integer< = 3.14 . . . is a1 = 3. Thus,

    = a1 +1

    x1= 3 +

    1

    x1.

    Now we solve this equation for x1 and get

    x1 =1

    3 7.06251.

  • 7/30/2019 Intro to Continued Fractions

    8/13

    8 CAHLEN HUMPHREYS

    So at the point were at

    = 3 +

    1

    1 3

    .

    Then we continue with the same process as the beginning. The largest integer< x1 = 7.06251 . . . is a2 = 7. Thus,

    = 3 +1

    7 +1

    x2

    .

    As before, we solve for x2 and we get

    = 3 +1

    7 +1

    x2

    3 = 1

    7 +1

    x2

    7 +1

    x2=

    1

    31

    x2=

    22 7 3

    x2 = 3

    22 7 15.9966

    Continuing this process infinitely we get the simple continued fraction expansion of

    = 3 +1

    7 +1

    15 +1

    . . .

    = [3, 7, 15, . . . ]

    5.2. Example. Lets solve another irrational number, take

    3 for example.We first take the lowest integer values of

    3, thus a0 = 1. So we begin with

    3 = 1 +

    1

    x1

    and solving for x1 we get,

    x1 =1

    3 1 .

    So at this point we are at

    3 = 1 +

    1

    13 1

  • 7/30/2019 Intro to Continued Fractions

    9/13

    CONTINUED FRACTIONS 9

    and the lowest integer value of x1 1.3660 . . . , so a1 = 1. We now have,

    x1 = a1 +1

    x2= 1 +

    1

    x2.

    From here we substitute for x1 and get

    13 1 = 1 +

    1

    x2

    which implies that

    x2 =

    3 1

    2 3 2.732 . . . .

    And we repeat by taking the lowest integer value of x2 which is a2 = 2. At thispoint we are at

    3 = 1 +

    1

    1 + 1

    2 +1

    x3

    .

    Now we want to solve for x3

    x2 = 2 +1

    x3

    and after we substitute for x2 we get3 1

    2 3 = 2 +1

    x3

    which simplifies to

    x3 =

    2

    3

    33 5 1.3660 . . . .Observe that x3 is approximately the same value as x1, so we are going to get apattern and can stop here. Hence, we have in the end that

    3 = 1 +

    1

    1 +1

    2 +1

    1 +1

    2 +. . .

    = [1, 1, 2, . . . ]

    where 1 and 2 repeat infinitely.

    6. Convergents

    Before we begin to explain the expansion of irrational numbers it is vital thatwe discuss the concept of convergents of continued fractions. In this section wewill be looking at three different theorems that will be essential in proving thatrational numbers can be represented as finite continued fraction, and more impor-tantly, that irrational numbers can be represented as infinite continued fractions.Convergents are essentally cutting up continued fraction expansions into segments,and then solving them for that segment. We can easily approximate numbers to

  • 7/30/2019 Intro to Continued Fractions

    10/13

    10 CAHLEN HUMPHREYS

    very precise values when utilizing convergents correctly.

    Take the continued fraction = pq

    = [a0, a1, a2, . . . , an], and let

    r1 = [a1, a2, a3, . . . , an] =p

    q. Then we can represent p and q as

    p = a0q + q, q = p(6.1)

    which we require for the next few theorems. If we represent a segment of as

    sk = [a0, a1, a2, . . . , ak]

    where a < n, then we call it the kth-order convergent (or approximant) of thecontinued from . This concept is defined in exactly the same way for finite andinfinite continued fractions. The only difference is that a finite continued fractionhas a finite number of convergents, whereas an infinite continued fraction has aninfinite number of them.

    Take for example an nth-order continued fraction = [a0, a1, a2, . . . , an], thenobviously

    pnqn

    = ;

    such a continued fraction has n + 1 convergents (of orders, 0, 1, 2, . . . , n).

    Theorem 6.1 (Khinchin (1) pg. 4). (the rule for the formation of convergents).For arbitraryk 2,

    pk = akpk1 + pk2,

    qk = akqk1 + qk2.(6.2)

    Proof. In the case of k = 2, the formulas in (6.2) are easily verified directly.Let us suppose that they are true for all k < n. Let us then consider the continued

    fraction[a1, a2, a3, . . . , an]

    and let us denote by pr/q

    r its rth-order convergent. Then by (6.1)

    pn = a0p

    n1 + q

    n1,

    qn = p

    n1.

    And since, by hypothesis,

    pn1 = anp

    n2 + p

    n3,

    qn1 = anq

    n2 + q

    n3

    (here, we have an rather than an1 because the fraction [a1, a2, a3, . . . , an] beginswith a1 and not with a0), it follows that

    pn = a0(anp

    n2 + p

    n3) + (anq

    n2 + qn3)

    = an(a0p

    n2 + q

    n2) + (a0p

    n3 + qn3)

    = anpn1 + pn2,

    qn = anp

    n2 + p

    n3 = anqn1 + qn2,

    which completes the proof.

  • 7/30/2019 Intro to Continued Fractions

    11/13

    CONTINUED FRACTIONS 11

    These recursion formulas in (6.2), which express the numerator and denom-inator of an nth-order convergent in terms of the element an and the numeratorsand denominators of the two preceding convergets, serve as the formal basis of theentire theory of continued fractions.

    Theorem 6.2 (Khinchin (5) pg. 7). For arbitrary k (1 k n),

    [a0, a1, a2, . . . , an] =pk1rk + pk2qk1rk + qk2

    .(6.3)

    (Here, pi, qi, ri refer to the continued fraction on the left side of this equation.)

    Proof. We omit this proof for the sake of brevity.

    To every infinite continued fraction

    [a0, a1, a2, . . . ],(6.4)

    there corresponds an infinite sequence of convergents

    p0q0

    ,p1q1

    , . . . ,pkqk

    , . . . .(6.5)

    Every convergent is some real number. If the sequence (6.5) converges, that is, ifit has a unique limit , it is natural to consider this number as the value of thecontinued fraction (6.4) and to write

    = [a0, a1, a2, . . . ].

    The continued fraction itself is then said to converge. If the sequence does not havea definite limit, we say that the continued fraction diverges.

    Theorem 6.3 (Khinchin (7) pg. 8). If the infinite continued fraction[a0, a1, a2, . . . ]converges, so do all of its remainders; conversely, if at least one of the remaindersof the continued fraction [a0, a1, a2, . . . ] converges, the continued fraction itself con-verges.

    Proof. Let us agree to denote by pk/qk the convergents of a given continuedfraction [a0, a1, a2, . . . ], and by p

    k/q

    k the convergents for any of its remainders, forexample, rn. From Theorem 6.2 we have, we have

    pn+kqn+k

    = [a0, a1, a2, . . . , an+k] =pn1

    pk

    qk

    + pn2

    qn1pk

    qk

    + qn2(k = 0, 1, . . . ).(6.6)

    It follows immediately that if the remainder rn converges, that is, if as k the fraction pk/qk approaches a limit which we shall also denote by rn, then thefraction pn+k/qn+k will converge to a limit equal to

    =pn1rn + pn2qn1rn + qn2

    .(6.7)

    By solving (6.6) for pk/q

    k, we establish the validity of the converse, thus completingthe proof of the theorem.

  • 7/30/2019 Intro to Continued Fractions

    12/13

    12 CAHLEN HUMPHREYS

    7. Expansion of Irrational Numbers

    The procedure for expanding an irrational number is fundamentally the same

    as that used for rational numbers. Therefore, we introduce a new theorem whichvalidates the infinite simple continued fraction expansion of an irrational number.

    Theorem 7.1 (Khinchin (14) pg. 16). To every real number , there corre-sponds a unique continued fraction with value equal to . This fraction is finite if is rational and infinite if is irrational.

    Proof. We denote a0 the largest integer not exceeding . If is not an integer,the relation

    = a1 +1

    r1(7.1)

    allows us to determine the number r1. Here, clearly, r1 > 1, since

    1

    r1=

    a0 < 1.(7.2)

    In general, ifrn is not an integer, we denote by an the largest integer not exceedingrn and define the number rn+1 by the relation

    rn = an +1

    rn+1.(7.3)

    This procedure can be continued as long as rn is not an integer; here, clearly, rn > 1(n 1).

    Equation (7.1) shows that

    = [a0, r1].

    Suppose that, in general,

    = [a0, a1, a2, . . . , an1, rn].(7.4)Then, from (7.3), we have

    = [a0, a1, a2, . . . , an1, an, rn+1];

    thus, (7.4) is valid for all n (assuming, of course, that r1, r2, . . . , rn1 are not inte-gers).

    If the number is rational, all the rn still clearly be rational. It is easy tosee that, in this case, our process will stop after a finite number of steps. If, forexample, rn = a/b, then

    rn an =a ban

    b=

    c

    b,

    where c < b, since rn an < 1. Equation (7.3) then givesrn+1 =

    b

    c

    (provided c is not equal to zero, that is, if rn is not an integer; if rn is an integer,our assertion is already satisfied). Thus, rn+1 has a smaller denominator than doesrn. It follows from this that if we consider r1, r2, . . . , we must eventually come toan integer rn = an. But, in this case, (7.4) asserts that the number is representedby a finite continued fraction, the last element of which is an = rn > 1.

  • 7/30/2019 Intro to Continued Fractions

    13/13

    CONTINUED FRACTIONS 13

    If is irrational, then all the rn are irrational and our process is infinite.Setting

    [a0, a1, a2, . . . , an] =pnqn

    (where the fraction pn/qn is irreducible and qn > 0), we have, by Theorem 6.3 and(7.4),

    =pn1rn + pn2qn1rn + qn2

    (n 2).

    On the other hand, it is obvious that

    pnqn

    =pn1an + pn2qn1an + qn2

    ,

    so that

    pn

    qn =

    (pn1qn2

    qn1pn2)(rn

    an)

    (qn1rn + qn2)(qn1an + qn2)and, consequently, pnqn

    < 1(qn1rn + qn2)(qn1an + qn2)