Continued fractions offer a means of concrete representation for arbitrary real numbers. The continued fraction expansion of a real number is an alternative to the representation of such a number as a (possibly infinite) decimal.
The reasons for including this topic in the course on Classical Algebra are:
Every real number is represented by a point on the real line and, as such, falls between two integers. For example, if is an integer and falls between and , and there is one and only one such integer for any given real . In the case where itself is an integer, one has . The integer is sometimes called the floor of , and one often introduces a notation for the floor of such as
Examples:
For any real with the number falls in the unit interval consisting of all real numbers for which .
Thus, for given real there is a unique decomposition where is an integer and is in the unit interval. Moreover, if and only if is an integer. This decomposition is sometimes called the mod one decomposition of a real number. It is the first step in the process of expanding as a continued fraction.
The process of finding the continued fraction expansion of a real number is a recursive process that procedes one step at a time. Given one begins with the mod one decomposition where is an integer and .
If , which happens if and only if is an integer, the recursive process terminates with this first step. The idea is to obtain a sequence of integers that give a precise determination of .
If , then the reciprocal of satisfies since is in and, therefore, . In this case the second step in the recursive determination of the continued fraction expansion of is to apply the mod one decomposition to . One writes where is an integer and . Combining the equations that represent the first two steps, one may write
Either , in which case the process ends with the expansion or . In the latter case one does to what had just been done to above under the assumption . One writes where is an integer and . Then combining the equations that represent the first three steps, one may write
After steps, if the process has gone that far, one has integers and real numbers that are members of the unit interval with all positive. One may write Alternatively, one may write If , the process ends after steps. Otherwise, the process continues at least one more step with
In this way one associates with any real number a sequence, which could be either finite or infinite, of integers. This sequence is called the continued fraction expansion of .
Let In this case one finds that where Further reflection shows that the continued fraction structure for is self-similar: This simplifies to and leads to the quadratic equation with discriminant . Since , one of the two roots of the quadratic equation cannot be , and, therefore, Finally,
The idea of the calculation above leads to the conclusion that any continued fraction that eventually repeats is the solution of a quadratic equation with positive discriminant and integer coefficients. The converse of this statement is also true, but a proof requires further consideration.
The process of finding the continued fraction expansion of a rational number is essentially identical to the process of applying the Euclidean algorithm to the pair of integers given by its numerator and denominator.
Let , be a representation of a rational number as a quotient of integers and . The mod one decomposition shows that , where is the remainder for division of by . The case where is the case where is an integer. Otherwise , and the mod one decomposition of gives This shows that , where is the remainder for division of by . Thus, the successive quotients in Euclid's algorithm are the integers occurring in the continued fraction. Euclid's algorithm terminates after a finite number of steps with the appearance of a zero remainder. Hence, the continued fraction expansion of every rational number is finite.
Proof. It has just been shown that if is rational, then the continued fraction expansion of is finite because its calculation is given by application of the Euclidean algorithm to the numerator and denominator of . The converse statement is the statement that every finite continued fraction represents a rational number. That statement will be demonstrated in the following section.
For arbitrary real numbers with each for the symbol is defined recursively by: In order for this definition to make sense one needs to know that the denominator in the right-hand side of (1) is non-zero. The condition for guarantees, in fact, that , as one may prove using induction.
It is an easy consequence of mathematical induction that the symbol is a rational number if each is rational. In particular, each finite continued fraction is a rational number. (Note that the symbol is to be called a continued fraction, according to the convention of the first section, only when each is an integer.)
Observe that the recursive nature of the symbol suggests that the symbol should be computed in a particular case working from right to left. Consider again, for example, the computation above showing that . Working from right to left one has:
There is, however, another approach to computing . Let, in fact, be any (finite or infinite) sequence of real numbers. One uses the double recursion to define the sequence . The double recursion, differently initialized, defines the sequence . Note that , , and , , , .
One now forms the matrix Thus, for example, It is easy to see that the matrices satisfy the double recursion as a consequence of the double recursion formulas for the and . Hence, a simple argument by mathematical induction shows that This is summarized by:
Proof. The number is the determinant of the matrix . From the formula (6) the matrix is the product of matrix factors, each of which has determinant . Since the determinant of the product of matrices is the product of the determinants of the factors, it is clear that .
Proof. First recall (i) that the product of a matrix and a (column) vector is defined by the relation (ii) that the transpose of a matrix is the matrix whose rows are the columns of the given matrix, and (iii) that the transpose operation reverses matrix multiplication. One tranposes both sides of the relation (7) to obtain: To this relation one applies the principle that the first column of any matrix is the product of that matrix with the column in order to obtain the column identity (8).
Proof. What is slightly strange about this important result is that while the and the are defined by the front end recursions, albeit double recursions, (2) and (3), the symbol is defined by the back end recursion (1). The proof begins with the comment that the right-hand side of (10) does not make sense unless one can be sure that the denominator . One can show easily by induction on that for under the hypothesis for .
The proof proceeds by induction on . If , the assertion of the theorem is simply the statement , and, as noted above, and . Assume now that . By induction we may assume the correctness of the statement (10) for symbols of length , and, therefore, for the symbol . That case of the statement says that must be equal to , where by corollary 2 with Now by (1) But by corollary 2 again Hence,
Recall that is called a continued fraction only when each is an integer and for . The sequence may be finite or infinite. The symbol formed with the first terms of the sequence, is called the convergent of the continued fraction. Associated with a given sequence are two sequences and that are given, according to the double recursions (2), (3) of the previous section with .
Proof. By Corollary 1 of the previous section . Hence, any positive divisor of both and must divide the left-hand side of this relation, and, therefore, must also divide .
Proof. According to the theorem (formula 10) at the end of the last section the convergent is given by Hence, (The last step is by Corollary 1 above.)
Proof. This is easily proved by induction from the recursive definition (3) of the sequence.
Proof. As one plots the convergents on the line of real numbers, one moves alternately right and left. The formula (11) for the difference between successive convergents elucidates not only the fact of alternate right and left movement but also the fact that each successive movement is smaller than the one preceding. Therefore, one has Since any strictly increasing sequence of positive integers must have infinite limit, the seqence has infinite limit, and so the sequence of reciprocals must converge to zero. Hence, the sequences of odd- and even-indexed convergents must have the same limit, which is the limit of the sequence of all convergents.
Proof. For each the continued fraction expansion of is characterized by the identity where is a real number with . The sequences of 's and 's for the symbol agree with those for the symbol except for the terms. One has by (10) where by (3) Hence, Therefore, the displacement from to is by (11) which is in the same direction but of smaller magnitude than the displacement from to . Therefore, must be larger than every odd-indexed convergent and smaller than every even-indexed convergent. But since all convergents have the same limit, that limit must be .
It has already been observed that the process of finding the continued fraction expansion of a rational number (), involves the same series of long divisions that are used in the application of the Euclidean algorithm to the pair of integers and . Recall that at each stage in the Euclidean algorithm the divisor for the current stage is the remainder from the previous stage and the dividend for the current stage is the divisor from the previous stage, or, equivalently, the dividend for the current stage is the remainder from the second previous stage. The Euclidean algorithm may thus be viewed as a double recursion that is used to construct the sequence of remainders. One starts the double recursion with At the stage one performs long division of by to obtain the integer quotient and the integer remainder that satisfies . Thus, The Euclidean algorithm admits an additional stage if . Since there can be at most stages.
One may use the sequence of successive quotients () to form sequences and , as in the previous section, according to the double recursions: It has already been observed that for and
Bezout's Identity says not only that the greatest common divisor of and is an integer linear combination of them but that the coefficents in that integer linear combination may be taken, up to a sign, as and .
Proof. One uses induction on . For the statement is . Since by (14, 15) and , this statement is simply the case in (13). Assume , and that the formula (16) has been established for indices smaller than . By (13) one has In this equation one may use (16) to expand the terms and to obtain:
Proof. One knows that is the last non-zero remainder in the Euclidean algorithm. This formula for is the case in (16).
Proof. The last remainder . The case in (16) shows that . Since, by the first proposition of the preceding section, and have no common factor, this corollary is evident.
If , , , are real numbers with and is the matrix with entries , , , and , then , for real, will denote the expression One calls the action of on .
is a perfectly good function of except for the case where the denominator vanishes. If it were also true that for the same , then one would have , in contradiction of the assumption . Thus, when , the value of increases beyond all bounds as approaches , and it is convenient to say that where is regarded as large and signless. If further it is agreed to define which is the limiting value of as increases without bound, then one may regard the expression as being defined always for all real and for . The set consisting of all real numbers and also the object (not a number) is called the projective line. The projective line is therefore the union of the (ordinary) affine line with a single point .
Proof. Let . Then The statement of the proposition now becomes This may be seen to follow by multiplying both sides in formula (9), after replacing with , by the column
The matrix in the preceding proposition is an integer matrix with determinant . The notation denotes the set of all such matrices. (The indicates the size of the matrices, and the indicates that the entries in such matrices are numbers in the set of integers.) It is easy to check that the product of two members of is a member of and that the matrix inverse of a member of is a member of . Thus, forms what is called a group. The formula (19) defines what is called the action of on the projective line.
One says that two points and of the projective line are rationally equivalent if there is a matrix in for which . Since (i) is a group, (ii) , and (iii) if and only , it is easy to see that every point of the projective line belongs to one and only one rational equivalence class and that two points rationally equivalent to a third must be rationally equivalent to each other.
In one of the first examples of a continued fraction expansion, it was shown that . This is an example of a periodic continued fraction. After a finite number of terms the sequence of integers repeats cyclically. If a cyclic pattern is present from the very first term, then the continued fraction is called purely periodic. Evidently, is an example of a purely periodic continued fraction.
Note that a periodic continued fraction cannot represent a rational number since the continued fraction expansion of a rational number is finite.
Proof. For clarity: it is being asserted that every periodic continued fraction represent a number of the form where , , , and are all integers with , , and not a perfect square.
Numbers of this form with fixed but varying integers , , and may be added, subtracted, multiplied, and divided without leaving the class of such numbers. (The statement here about division becomes clear if one remembers always to rationalize denominators.) Consequently, for in the number will be a number of this form or if and only if is in the same class.
Since a periodic continued fraction is rationally equivalent to a purely periodic continued fraction, the question of whether any periodic continued fraction is a quadratic irrationality reduces to the question of whether a purely periodic continued fraction is such. Let be a purely periodic continued fraction. By the proposition of the preceding section, where is notationally identical to the in (20). Ignoring the computation (9) of in terms of convergents, let Then or, otherwise said, is a solution of the quadratic equation
This converse will not be proved here.