0% found this document useful (0 votes)
154 views259 pages

Elements of Number Theory - Pettofrezzo

Uploaded by

jorge roque
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
154 views259 pages

Elements of Number Theory - Pettofrezzo

Uploaded by

jorge roque
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 259

elements of number theory

ELEMENTS

Prentice-Hall, Incorporated
Englewood Cliffs, New Jersey
OF NUMBER THEORY

ANTHONY J. PETTOFREZZO
Professor of Mathematical Sciences
Florida Technological University
Orlando, Florida

DONALD R. BYRKIT
Assistant Professor
Faculty of Mathematics and Statistics
7716 University of West Florida
Pensacola, Florida
ELEMENTS OF NUMBER THEORY
by Anthony J. Petmfrezzo and Danald R. Byrkit

© 1970 by Prentice-Hall, Inc.,


Englewoad Clifiiv, New Jersey
All rights reserved. Nu part of this book
may be reproduced in any form
ar by any means without permission
in writing from the publisher‘

1 2 3 4 5 6 7 8 9 10 Current printing (first digit)


137268300—8
Library 17f Cangreu Cam/cg Card Number 77—81766
Printed in the United States of America

PRENTICE-HALL INTERNATIONAL, ma, London


PRENI‘ICE-HAIL or AUSTRALIA, pry. 1.11)., Sydney
PRENTICE-HALL or CANADA, 1.113., Tmonto
PKENTICE-HALL OF INDIA PRIVATE LTD., New Dehli
PRENTICE-HALL OF JAPAN, INC., Tokyo
PREFACE

The purpose of this book is to present to the reader at an introductory level


selected topics in one of the most interesting and stimulating areas of mathe-
matics. Number theory has few applications to physical situations; it is one
of the prime examples of pure mathematics. And although the reader in
number theory is concerned with a familiar algebraic system—the set of
integers and its properties with respect to the binary operations of addition
and multiplication—the authors know of no subject in the field of mathe-
matics which affords the reader a better opportunity to test his ingenuity in
the development and use of a wide variety of methods of proof.
Since the subject of number theory represents a broad area of mathematics,
a selection of topics had to be made. Those topics considered appropriate to
a first course are treated. Many of the topics of the book are fundamental in
the classical approach to the study of number theory. Others were selected
because of personal interests. For example, more attention is paid to the
study of continued fractions than is usual in most number theory books.

V 140128
vi PREFACE

Three main topics of number theory considered in this book are the di-
visibility properties of integers, the theory of congruences, and continued
fractions. Linear Diophantine equations in one variable and more than one
variable are treated briefly.
Chapter 1 consists of a brief presentation of four preliminary considera—
tions which are pertinent to the remainder of the book. Chapter 2 is funda—
mental to the rest of the book. The properties of prime and composite
numbers, the fundamental theorem of arithmetic, number-theoretic functions,
perfect numbers, and the Euler ¢-function are considered. Chapter 3 presents
the theory and methods of solving linear congruences, the theorems of
Euler, Fermat, and Wilson, the relationship between linear congruences and
linear Diophantine equations, the Chinese remainder theorem, and quad-
ratic congruences. Finite and infinite continued fractions are treated in
Chapter 4. The evaluation of convergents and the use of their properties in
the study of linear Diophantine equations, approximation theory, and the
solution of quadratic equations are stressed. Periodic continued fractions
and square roots of the positive integers as continued fractions complete the
study of Chapter 4. Certain relatively difficult theorems concerning continued
fractions have been omitted or are stated without proof wherever necessary
in order to establish the continuity of the subject.
More than 110 detailed illustrative examples have been included as an aid
to the reader in his mastery of the concepts and methods presented. The
proofs of 73 theorems are presented. There are over 530 exercises, many of
which have several parts, that range from routine numerical problems to
those requiring some degree of ingenuity on the part of the reader. Several
exercises are included which afford the reader an opportunity to investigate
a mathematical problem, make a conjecture, and verify or prove the con-
jecture. Answers to approximately 400 selected exercises are provided in the
back of the book.
The only prerequisite for the reader is a mathematical maturity usually
obtained from a well-defined secondary school mathematics program, and
perhaps one or two introductory college-level mathematics courses. No
previous knowledge of abstract algebra is assumed. Some familiarity with
determinants is assumed for an understanding of §4.5. The book contains
enough material for a one-semester course in number theory at the under-
graduate level. The topics of the book constitute appropriate subject matter
for teacher training programs, summer institute study, and in-service pro-
grams. Elements of the book may be used by advanced students in a secondary
school enrichment program.
We wish to express our appreciation to Mr. James Walsh, for his continued
encouragement and interest during the evaluation and development of the
manuscript, to Mr. Wayne P. Ellis for his editorial comments and suggestions,
PREFACE vii

and to the entire editorial and production staff of Prentice-Hall, Inc., for
their efforts and contributions toward the publication of the book. A special
note of appreciation is due Mr. Donald W. Duman, who constructed the list
of prime numbers less than ten thousand which appears in the back of this
book, using the computing facilities at Southern Connecticut State College.
We also acknowledge our appreciation and gratitude to Mrs. Betty Petto—
frezzo, who gave willingly of her time and ability to type the manuscript.

A. J. P.
D. R. B.
CONTENTS

chapter I

PRELIMINARY
CONSIDERATIONS

1.1 ORDERED INTEGRAL DOMAINS


1.2 MA THEMA TICAL IND UCTION
1.3 NUMBER BASES
1.4 NOTATIONS FOR SUMS AND PRODUCTS

ix
x CONTENTS

chapter 2

DIVISIBILITY
PROPERTIES
OF INTEGERS 23

2.1 PRIME AND COMPOSITE NUMBERS 23


2.2 SOME PROPERTIES OF PRIME NUMBERS 27
2.3 THE GREATEST COMMON DIVISOR 34
2.4 THE GENERALIZED
GREATEST COMMON DIVISOR 4o
2.5 PROPERTIES
OF THE GREATEST COMMON DIVISOR 43
2.6 LINEAR DIOPHANTINE EQUATIONS 46
2.7 THE FUNDAMENTAL THEOREM
0F ARITHMETIC 51
2.8 SUM OF DIVISORS 58
2.9 NUMBER OF DIVISORS 63
2.10 PERFECT NUMBERS 65
2.11 MERSENNE NUMBERS 69
2.12 THE EULER (ii—FUNCTION 72
2.13 PROPERTIES OF THE EULER ¢~FUNCTION 78
2.14 SOLUTION OF THE EQUATION¢(x) : In 81

chapter 3

THE THEORY OF
CONGRUENCES 87

3.1 DEFINITIONS
AND ELEMENTAR Y PROPERTIES 87
CONTENTS xi

3.2 SOME CONGR UENCE THEOREMS 92


3.3 AN APPLICATION
OF THE CONGRUENCE RELATION 99
3.4 REDUCED RESIDUE SYSTEMS MODULO m 103
3.5 THE THEOREMS 0F EULER AND FERMAT 108
3.6 LINEAR CONGRUENCES 113
3.7 LINEAR CONGRUENCES
AND LINEAR DIOPHANTINE EQUATIONS 120
3.8 WILSON‘S THEOREM 124
3.9 LINEAR CONGRUENCES IN TWO VARIABLES I29
3.10 THE CHINESE REMAINDER THEOREM I35
3.1] QUADRATIC CONGRUENCES I43

chapter 4

CONTINUED
FRACTIONS 149

4.1 FINITE CONTINUED FRACTIONS I49


4.2 INFINITE CONTINUED FRACTIONS 156
4.3 CONVERGENTS 162
4.4 EVALUATION OF CONVERGENTS I67
4.5 CONVERGENTS AS DETERMINANTS I72
4.6 SOME PROPERTIES OF CONVERGENTS I77
4.7 CONTINUED FRACTIONS
AND LINEAR DIOPHANTINE EQUATIONS I80
4.8 THEOREMS ON
INFINITE CONTINUED FRACTIONS I82
4.9 APPROXIMATION THEOREMS I87
4.10 USE OF CONTINUED FRACTIONS
IN SOLVING QUADRATIC EQUATIONS 192
4.11 PERIODIC CONTINUED FRACTIONS 196
4.12 CONTINUED FRACTIONS FOR W 202
xiicoum

ANSWERS
TO SELECTED
EXERCISES 207

LIST OF
PRIME NUMBERS
LESS THAN
10,000 238

INDEX 242
chapter I

I.I ORDERED INTEGRAL DOMAINS

In. our study of number theory we shall be primarily concerned with the set
I of integers and the binary operations of addition + and multiplication x
defined on that set. The system (I, +, X , <) of integers has a number of pro-
perties which we present here for reference purposes.

BASIC PROPERTIES OF (I. +. X. <)

In the following statementr, let a, b, c, and d be arbitrary elements of I.'

Properties of Equality
Reflexive: a = a for every a.

l
2 PRELIMINARY CONSIDERATIONS § 1.1

Symmetric: If a : b, then b : a.
Transitive: If a = b and b = c, then a = c.

Properties of Addition and Multiplication


Well-defined: If a = b and c = d, then a + c = b + d and
a X c = b X d.
Closure: a+belanda X be].
Commutative: a+b=b+aando x b=b X a.
Associative: (a + b) + c = a + (b + c) and
(uxb)><c=a><(b><c).
Identity: There exists an element 0 such that a + 0 = 0 + a = a;
there exists an element 1 such that a X 1 = 1 X a = a.
Inverse; For each a there exists an element —a such that
a+(—a)=(—a)+a=0.
Cancellation: If a X c = b X c where c aé 0, then a : b.
Dirtributive: a X (b + c) = (a X b) + (a X c);
(b+c) xa=(b xa)+(c>< a).

Properties of Inequality (a < b ¢> b > a)


Trichotomy: For every pair of elements a and b, exactly one of these
statements is true:
a<b, azb, or b<a.
Addition: Ifa < b, then a + c < b + c.
Multiplication: Ifa < b and c > 0, then a X c < b X c.
Transitive: Ifa < b and b < c, then a < c.

As a result of the basic properties of equality, addition, and multiplica-


tion, a number of theorems can be proved, among which are the following:

Zero Property of Multiplication: a X 0 : 0.


Zero-Product: Ifa X b : 0, then a = 0 or b = 0.

As a result of the basic properties of inequality, addition, and multipli-


cation, a number of theorems can be proved, among which are the following:

Cancellation Property ofAddition for Order: If a + c < b + c, then a < b.


Cancellation Property of Multiplication for Order: If a X L‘ < b X c and
c>0,thena<b.
Furthermore, since a g b ¢ a < b or a = b, these properties can be estab-
lished:
§l.l ORDERED INTEGRAL DOMAINS 3

Ifugb,thena+cgb+c.
Ifagbandc>0,thena><cgb><c.
Ifagbandbgc,thenagc.
Ifa+cgb+c,thenagb.
Ifaxcgbxcandc>0,thenagb.

The system (I, +, X , <) of integers is an example of an abstract alge-


braic system called an ordered integral domain. An integral domain is a system
(D, e, 8)) in which the basic properties of addition and multiplication of
integers are valid for the binary operations 6 and ® , respectively. An ordered
integral domain is an integral domain that contains an order relation at for
which the basic properties of the inequality of integers are valid.
As an example of another integral domain, consider a finite set D, where
D = {0, 1, 2, 3, 4} , with the binary operations ® and (8 defined on the set
by means of Tables 1.1.1 and 1.1.2, respectively. The system (D, 9, ®) can
be shown to be an integral domain by simply verifying that each of the basic
properties is satisfied. For example, note that

(2e4)eszies:4
and

263(463)=2®2=4;

thus,

(2®4)$3:263(4€B3)-
Similarly,

(2®4)®3=3®3:4

Table 1.1.1 Table 1.1.2

® I 0 1 2 3 4 ® ll 0 1 2 3 4

0 0 l 2 3 4 0 0 0 0 0 0
1 l 2 3 4 0 1 0 1 2 3 4
2 2 3 4 0 1 2 0 2 4 1 3
3 3 4 0 1 2 3 0 3 1 4 2
4 4 0 1 2 3 4 0 4 3 2 1
4 PRELIMINARY CONSIDERATIONS § 1.1

and

2®(4®3)=2®2=4;
thus,

(2®4)®3=2®(4®3)-

Many other examples of integral domains exist. The set of rational


numbers with the operations of addition and multiplication defined on that
set is an example of another ordered integral domain.
The system of integers has several additional properties which are not
necessarily properties of every ordered integral domain. We shall state three
such properties here.

Well-Ordering Principle: Every nonempty set ofpositive integers has a small-


est element.

The well-ordering principle guarantees us that any subset of the set of


integers which contains only positive integers has a smallest positive integer.
For example, the set of positive even integers has a smallest element, 2.

Archimedenn Property: If a < b and a > 0, then there exists a positive


integer e such that a X c > b.

The Archimedean property can be illustrated by using a number line.


For example, let a = 2 and b = 11. On a number line we can think of c as
the number of times we would lay ofl” a segment of length 2 to extend beyond
a segment of length 11.

a
4L l l I I l I I I I I I I l I
01234567891011121314
c=6;2><6>11.
Fig.1.1
§ 1.1 ORDERED INTEGRAL DOMAINS 5

Division Property: If a is any integer and b is a' positive integer, then there
exists a unique pair of integers q and r such that

a=qb+r, where 0gr<b.

For example, let a 2 72 and b = 5. Then q = 14 and r = 2; that is,

72=14-5+2, where 0g2<5.

Hereafter, unless otherwise stated, the letters a, b, c, . . . , x, y, z are used


to represent integers.

EXER CISES

1. Consider a finite set D, where D ={0, 1, 2), with the binary operations (-9
and (3 defined on the set by means of the given tables:

(+3
-o®

COCO

HNON
h—lo

Determine whether or not the system (D, (-9, ®) is an integral domain.


2. Consider a finite set D, where D ={0, 1, 2, 3), with the binary operations (-9
and ® defined on the set by means of the given tables:

(-9 ®
rot—out»
H

ooooo
uN—oo

HOUNN

NONON

HNwou

0 0
ot—

1 1
9:c

2 2
3 3

Determine whether or not the system (D, (-9, ®) is an integral domain.


3. Determine whether or not the set of even integers with addition and multipli-
cation defined on that set is an integral domain.
4. Prove that a set of complex numbers a + bi, where a and b are integers, with
addition and multiplication defined on that set is an integral domain.
5. Let a and b be any two integers. Define the binary operations 6 and ® such
thataeb = a + b +1anda ®b :— a + b + ab. Determine whether or not
the system (I, @, ®) is an integral domain.
6 PRELIMINARY CONSIDERATIONS § 1.2

In Exercises 6 through 9 illustrate the division property by finding q and r for each
pair a and b:

6.a=132;b=7. 7.a=—52;b=3.
8.a=132;b=11. 9.a=541;b=16.
10. Use the well-ordering principle to prove that there is no integer between 0 and
1. (Hint: If e is a positive integer such that 0 < c < 1, then 0 < c2 < c < 1.)
11. Use the well-ordering principle to prove the division property.

1.2 MA THEMA TICAL INDUCTION

In this section we shall examine a method of proof called mathematical in-


duction. This method of proof is based upon the principle of mathematical
induction, which we accept as a postulate.

First Principle of Mathematical Induction: If a set S of positive integers is


such that (i) the positive integer 1 is an element of S, and (ii) the positive
integer k + l is an element of S whenever the positive integer k is an ele-
ment of S, then S is the set of all positive integers.

Consider a statement, expression, formula, . P(n). A proof by mathe-


matical induction that P(n) is true for all positive integers 7: involves two
steps. We need to show that
(i) P0) is true;
(ii) if P(k) is true, then P(k + 1) is true, where k is any positive integer.
Then, by the first principle of mathematical induction, P(n) is true for all posi-
tive integers n; that is, the set S of positive integers for which P(n) is true is
the set of all positive integers.

EXAMPLE 1. Prove that the sum of the first n odd integers is 712.
Since the first odd integer is 1, the second odd integer is 3, the
third odd integer is 5, . . ., then the nth odd integer is of the form
2n ~ 1. Thus, we need to show that

1+3+5-l—---+(2n—1)=n2 (1.2.1)

for all positive integers n. Let S be the set of positive integers for
§1.2 MATHEMATICAL INDUCTION 7

which statement (1.2.1) is true. The positive integer 1 is an element


of S since 1 = 11. Now, assume that the positive integer k is an ele-
ment of S. Then

1+3+5+---+(2k—1)7k1- (11-2)
In order to show thatk + 1 is an element of S, it is necessary to show
that

1+3+5+“-+(2k—1)+[2(k+1)*1]:(k-H)‘.
Note that 2(k + 1) 7 1 = 2k + 1. By adding equals to both mem-
bers of equation (1.2.2), we obtain

1+3+s+~~+(2k71)+[2(k+1)—11=k1+2k+1
=(k+1)1.
Hence, k + 1 is an element of S. Therefore, by the first principle of
mathematical induction, S is the set of all positive integers; that is,
statement (1.2.1) is true for all positive integers n.

EXAMPLE 2. Prove that 22" 7 1 is a multiple of 3 for all positive


integers u.
If n = 1, then 22" 7 1 = 3, a multiple of 3. Now, assume that
21" 7 1 is a multiple of 3 for n 2 k; that is, assume

2“— 1 :31;

for some integer p. Then


22(k+1)71:22.22k#1

=4-2’”‘—1

:4-2"—4+471

=4(22"71)+3

:4-3p+3

=3(4p+1).
Hence, 2‘” 7 1 is a multiple of3 for n 7 k + 1 if 22" 7 1 is a multi-
8 PRELIMINARY CONSIDERATIONS § 1.2

ple of 3 for n : k. Therefore, by the first principle of mathematical


induction, 2“" ~— 1 is a multiple of 3 for all positive integers n.

It is important to note that both parts of the first principle of mathe-


matical induction must be satisfied in order for the set S to be the set of all
positive integers. For example, note that the statement

1+2+3+---+n=1 (1-2-3)
is true if n = 1. However, if the statement is assumed to be true for n = k
where k is any positive integer, we can show that it is false for n : k + 1.
Hence, statement (1.2.3) is not true for all positive integers n. Similarly, the
statement

2+4+6+---+2n=n2+n+1 (1.2.4)

can be shown to be true for n = k + 1 if it is true for n : k where k is any


positive integer. However, the statement is not true for n = 1. Hence, state-
ment (1.2.4) is not true for all positive integers n.
An equivalent alternate statement of the principle of mathematical in-
duction may be postulated.

Second Principle of Mathematical Induction: If a set S ofpositive integers is


such that (i) the positive integer 1 is an element of S, and (ii) the positive
integer k + 1 is an element of S whenever the positive integers 1, 2, 3, . . .,
k are elements of S, then S is the set of all positive integers.

It is sometimes more convenient to use the second principle of mathe-


matical induction than the first principle (See Theorem 2.12.4).

EXERCI SES

tical induction:
In Drew-S“ I through 12 prove 9“" ”meme“ by mathema
1‘1+2+3+"'+"="("2—+1)-

H2=W.
2. 11+21+31+HI+

3.1’+2’+3=+~-~+n’:"‘("4_+‘>’.
§ 1.3 NUMBER BASES 9

4.1+2+2‘+---+2""=2"71.
5.1+5+9+‘-‘+(4n—3)=n(2n71).

L L L #7 ’1
6‘1-2+2.3+3-4+ +n(n+1)_n+1‘
7.a+(a+d)+(a+2d)+"‘+[a+(n71)dl=g[2a+(nil)d].

8.a+ar+ar‘+-~-+ar"“=£:%p,providedr¢l.

9. 5’”—1isamultipleof24.
10. 10"“ — 9n 7 10 is a multiple of 81.
11.2">n.
1 1
12.1+;+§+ 1 1
+Fsz—;.
13 Prove that the first and second principles of mathematical induction are equiva-
lent statements.
14 Prove that the second principle of mathematical induction implies the well-
ordering principle.
15 Prove that the well»ordering principle implies the first principle of mathematical
induction.

1.3 NUMBER BASES

Much of number theory is dependent upon the divisibility properties of


integers and the residues, or remainders, that are obtained by division. In
order to study the divisibility properties of integers, an understanding of
number bares is essential.
The decimal system of notation is a positional numeral system because
the order of the digits in any numeral is important. For example,

5763=S-IO3+7-101+6-10+3,

5637:5-103+6-102+3-10+7,

and

3675:3-103+6-102+7-10+5;

thus, 5763, 5637, and 3675 each denote difierent unique numbers although
the same four digits, 3, 5, 6, and 7, are used in representing each of the
10 PRELIMINARY CONSIDERATIONS § 1.3

numbers. In the decimal system of notation, every positive integer can be


expressed as a polynomial in 10 abbreviated as indicated in the example
shown. Since only the ten digits 0, l. 2, 3, 4, 5, 6, 7, 8, and 9 are necessary
to represent each positive integer in decimal notation, the decimal system of
notation has a base of ten.
The Babylonians used a system of notation with a base of sixty. Thus.
5763 in the Babylonian system would mean

5-603 +7-60z +6-60+3.

In general, the numeral 5763 in a system of notation with a base of b, where


b > 7, denotes

S-bJ +7-b2 +6-b +3.

It is possible to define positional numeral systems with any positive integer


b, where b > 1, as a base. Then every positive integer n can be expressed
uniquely as a polynomial in b:

n : tab" + ak_1b“‘1 + - ~- + alb + a0, (1.3.1)

where k is a nonnegative integer and 0 g a, < b for every 1’ except that


ak > 0. The positive integer u would be abbreviated as

”Wail ' ' ' “Ino-

EXAMPLE 1. If a Martian had six fingers on each hand, what would


he probably mean by 782?
With six fingers on each of his hands, the base of a Martian’s
positional numeral system would most likely be six or twelve. The
base could not be six since the digits 7 and 8 appear in the given
numeral. Therefore, assuming that the base is twelve,

782:7-12z+8-12+2.

In order to avoid confusion in discussing different number bases, 21


numeral written without a subscript is assumed to be in base ten; a numeral
written with a subscript is assumed to be in the base denoted by the subscript.
For example,

431m=4-81+3-8+1
§ 1.3 NUMBER BASES 11

=4'64+3-8+1
=256+24+1
=281.
Note that all numerals on the right side of each indicated equation are written
in base ten. Furthermore, “431mm” should be read “four three one, base
eight,” not “four hundred thirty one.”
The operations and rules of addition and multiplication are basically the
same in any positional system of notation. However, different addition and
multiplication tables are needed for the nonnegative integers less than the
base for each number base used. For example, the addition and multiplication
tables for the base seven system are given in Tables 1.3.1 and 1.3.2, respec-
tively.

Table 1.3.1
ADDITION TABLE FOR THE BASE SEVEN SYSTEM

, ll 0 1 2 3 4 5 6

0 0 1 2 3 4 5 6
1 1 2 3 4 5 6 10
2 2 3 4 5 6 10 11
3 3 4 S 6 10 11 12
4 4 5 6 10 ll 12 13
5 5 6 10 11 12 13 14
6 6 10 11 12 13 14 15

Table 1.3.2
MULTIPLICATION TABLE FOR THE BASE SEVEN SYSTEM

0
._.

><||
0
mmhuNp—o
Quantum—o

O
0
m

N
..N

A
N

_
UI

O
0
0
0
12 PRELIMINARY CONSIDERATIONS § 1.3

EXAMPLE 2. Find the product of 532men and 46mm.


Using Tables 1.3.1 and 1.3.2,

532seven

m
Thus,

532seven X 46mm = 35355;”..-

As a check, note that

532m,n=5'71 +3-7+2 =268,

465m“ 2 4-7 + 6 = 34,

35365,,“ =3-74 + 5-73 +3-72 +6-7 +5 =9112,

and

268 X 34 = 9112.

Consider the problem of representing a number given in decimal nota-


tion in another system of notation. For example, suppose we want to repre-
sent 1639 in base seven notation. Note that

1639 = 4531
=4-73+s-71+3-7+1
:(4-72+5-7+3)7+1
=[(4-7+5)7+3]7+1.
Therefore, ifthe number 1639 is divided by 7, the quotient is (4 - 7 + 5) 7 + 3
and the remainder is 1; if the quotient (4 - 7 + 5) 7 + 3 is divided by 7, the
second quotient is 4 - 7 + S and the second remainder is 3; if the quotient
4 - 7 + 5 is divided by 7, the third quotient is 4 and the third remainder is
5; if the quotient 4 is divided by 7, the fourth quotient is 0 and the fourth
remainder is 4. Thus, the remainders for each division process, if considered
in the reverse order of appearance, may be associated with the digits of the
§ 1.3 NUMBER nuns 13

number 1639 expressed in base seven notation. The algorithm (refer to defi-
nition on page 36) presented here may be abbreviated in the following form:

remainder 1
remainder 3
remainder 5
remainder 4.

Then, 1639 = 4531”,“.

EXAMPLE 3. Express 2417 in base five notation.

remainder 2
remainder 3
remainder 1
remainder 4
remainder 3.

Thus, 2417 : 34132,“.

To construct a positional numeral system with a base greater than ten,


it is necessary to invent new symbols for the additional digits required. One
positional numeral system with a base greater than ten that is frequently
considered is the duodecimal system, a system with base twelve. In this system
it is customary to denote ten and eleven by t and e, respectively. Hence, the
digits of the duodecimal system are denoted by 0, l, 2, 3, 4, 5, 6, 7, 8, 9, t,
and e.

EXAMPLE 4. Express 3’97mm in decimal notation.

3127 twelve =3-123+10-122+ll-12+7=6763.

One of the simplest and most useful positional numeral systems is the
binary system, a system with base two. Only the two digits 0 and l are neces-
sary in the binary system. The addition and multiplication tables for the
binary system are given in Tables 1.3.3 and 1.3.4, respectively.
14 PRELIMINARY CONSIDERATIONS §1.3

Table 1.3.3 Table 1.3.4


ADDITION TABLE MULTlPLlCATlON TABLE
FOR THE BINARY SYSTEM FOR THE BINARY SYSTEM
+ 0 1 X 0 1

0 0 1 0 0 0
1 1 10 1 0 I

The mathematical units of large—scale digital computers are designed to


employ the binary system since the digits 0 and 1 can be represented me—
chanically or electrically by a bistable device (that is, a device which is either
“on" or “05”). For example, a simple mechanical or electrical switch may
represent 1 when closed and 0 when opened. By means of simple combina-
tions of these switches, the processes of addition and multiplication in the
binary system can be duplicated.

EXAMPLE 5. Find the product of 1101t and 111“”.


Using Tables 1.3.3 and 1.3.4,
1101two
X 111m
1101““,
1101two
1101M,
1011011m.
Thus,

1101M, X 111““, =1011011m.

As a check, note that

1101",”:1-23 +1-2z +0-2 +1 2 13,

111m=1-22 +1-2+1:7,

1011011m=1-26 +0-25 +1-2‘ 4—1-23 +0-22 +1-2+1

=91,

and

13X7=91.
§ 1.4 NOTATIONS FOR SUMS AND PRODUCTS 15

EXERCISES

Fina’ the sum of each pair of numbers:

1. 72ttwelve and 6e31we1ve.


2. 5162mu. and 634mm.

Find the product of each pair af numbers:

3. 2011111“: and 112mm.


4. 1101001two and 10111011wo.
5. 454m and 43m.
6. 813m: and 76m.

Express each number in decimal notation:

7. 313221our. 8. 5t19e1evcn.

Express each number in (a) base eight notation; (b) binary notation:

9. 132. 10. 285.

In Exercises 11 and 12 write the addition and multiplication tables for the nonnegative
integers less than the base for each system of notation with the given base:

11. 5. 12. 8.

13. Expms 7645eigh: in base five notation.


14. Express t3ecwem in base seven notation.

1.4 NOTATIONS FOR SUMS AND PRODUCTS

In number theory we often need to compute either the sum or the product
of related expressions. It is convenient to define a summation symbol and a
product symbol to indicate “the sum of” terms of a given form and “the pro-
duct of” factors of a given form, respectively. The Greek capital letter
“sigma,” 2, is used as a summation symbol. By definition,
n n71
n
lg”

Zai=Zai—l—a,I and
ah

x=m
' i=m i

where m and n are integers, m < n, and ai represents an expression in i.


The symbol i is called the index of summation; m is the lower limit of the
index, and n is the upper limit of the index.
16 PRELIMINARY CONSIDERATIONS § 1.4

From the definition of the summation symbol it should be clear that an


equivalent alternate definition can be given:
11
_Zai:am +“m-H +“m+z +"' +0,»
1:»!
where m and n are integers and m g 71.

Theorem 1.4.1: 201‘ + bi) = z ai + z bi.


i=1 i=1 i:1

PROOF: The proof is by mathematical induction. If n = 1, then by


definition
1
2(ai+b:) =‘11 +bi
i=1

1 1
=2m+2h
i:1 i=1

Now, assume that

k k k
'25“! + bi) :21“; + Ebr-
I: I: i=1

Then, by definition,

h+1 h
2:101.- + bi) :25“: + bi) + (ak+l + bh+1)

h k

7,21“ +E1bi + “H1 + bk+1

k k
= (‘Zrai + ak—H) + ( 2b! + bk+1)
1: i=1
k+1 k+1
= 2 :1i + Z bi.
i=1 i=1
Therefore,

.2(ai+b9=iai+ibi
l=l i=1 1:1
§le4 NOTATIONS FOR suMs AND PRODUCTS 17

for all positive integers n.

in
Theorem 1.4.2: If r is a canstant, then 2 c : nc.
i=1

PROOF: Let ci = c for all 1'. Then


n ..
20:22:?
i=1 i=1

If n = 1, then by definition

1
Zcizcl=c=lw
i=1

Now, assume that

k
251:,“
i=1

Then, by definition,
Ic+1 k.
ct = 2 C! + ck+1
=1 {:1

=kc+c

= (k + l)c.

Therefore,

that is,

for all positive integers n.

Theorem 1.4.3: Ifc is a constant, then 2 (a‘ + c) = 2 11,. + M.


i=1 i:l
18 PRELIMINARY CONSIDERATIONS § 1.4

The proof of Theorem 1.4.3 follows directly from Theorems 1.4.1 and
1.4.2 and is left to the reader as an exercise (Exercise 15).

n 5
Theorem 1.4.4: If t is a constant, then Z M,- 2 c 2 at.
i= 1 i: 1

Theorem 1.4.4 states that a constant factor which is independent of the


index of summation can be factored out of the summation expression. The
proof of Theorem 1.4.4 is left to the reader as an exercise (Exercise 16).

5
EXAMPLE 1. Evaluate 21'2".
i=1

5
2i2i=1.2‘ +2-22+3-23+4-24+5-25
i=1

=2+8+24+64+160
=258.

EXAMPLEZ. Showthat E; iaibj=iar§br


1:1
‘ ,_
-,1 i=1 i=1

: 2 [bi Z (1,] (by Theorem 1.4.4)

= Z 01.. - 2 hr (by Theorem 1.4.4)


'= 1

n n 2
EXAMPLE 3. Show that 2 af as ( Z (1,.) .
i: 1

Let n = 2. Then
1
20;2_
ea.2 +a§..
i:1
§ 1.4 NOTATIONS FOR sums AND PRODUCTS 19

2 2

(Z ai) : (a1 + "1)2 = “i + 2‘11“: + 0%.


i=1

Since 11% + ag ;é a? + Zulu: + 0% in general,


71 n 2
2a} aé (2a,) .
i=1 i=1

In an analogous fashion, a notation for products may be defined using


the Greek capital letter “pi,” H:

I! Hi] In

na.=(na.)-a. and Ha.=a..


where m and n are integers, m < n, and ai represents an expression in i. An
equivalent alternate definition can be given:

n
ll'laa :am'am+1 'am+2 ' '“nr
x=m

where m and n are integers and m g n. For example, a product such as


3
411b‘zzzb2113173 can be written as .H a‘b‘. Similarly, the expression 11!, that

is,n(n—l)(n—2)-~3-2-1, canbewrittenas Hi.

Theorem 1.4.5: 1'1 all), = H a, ' H [7:-


i=1 (:1 i=1

PROOF: The proof is by mathematical induction. If n = 1, then by


definition

Now, assume that

Then, by definition,
20 PRELIMINARY CONSIDERATIONS §1.4

k+1 k

Illa-1h =( g; laibi) ' ak+1bk+1

n h
=(l-[ai‘1—Ibi) ‘az+1bh+1
(=1 I=I

=[(.Iial)-a~+1]{aim-hm]
k+1 ’H—l

Therefore,

for all positive integers 71.

Theorem 1.4.6: If c is a constant, then H c 2 c”.


i=1

PROOF: Let cl = c for all 1‘. Then

Now, assume that

Then, by definition,
§ 1.4 NOTATIONS FOR sums AND PRODUCTS 21

Therefore,

.2:

H
.‘n
J.‘
that is,

”:1;

H
na
a
for all positive integers n.

n 71
Theorem 1.4.7: Ifc is a constant, then H cai = c” H at.
i=1 i: l

The proof of Theorem 1.4.7 is left to the reader as an exercise (Exer-


cise 17).

4
EXAMPLE 4. Evaluate H (21‘ + 1)‘.
i=1

4 4 2
H (21' + 1)‘ 2 [H (21' + 1)] (by Theorem 1.4.5)
1:1 4:1

: (3 . 5 . 7 . 9)2

: 9452

2 893,025.

EXERCISES

Evaluate each expression:


5 1
1. 2 3‘. 2. E 6.
1=1 (=3
4 3
3. 3:150 + 1)(i + 2). 4. Eli“.

.
s. 131‘ (i’ + 3). 6. _1'1 5.
22 PRELIMINARY CONSIDERATIONS § 1.4

2 J m J
7. 2 22'3’. 8. E 20" + 1).
1‘! i- 1 j: x (=1

Write each expression using the summation symbol:

9. ‘1t + tab: + 413174 + mks.


10. 3-4-5+4-5-6+5-6-7 +~-- +k(k+1)(k+2).
In Exercises 11 through 14 determine whether each statement is true or false:

11.2(i+3)=>:i.
H is. 12.2(2+i)=2+2i.
m is.
. . 2 5 5
13.11a?=(1'la.).
m m 14.2a,=2a..
m .-=.
15. Prove Theorem 1.4.3.
16. Prove Theorem 1.4.4.
17. Prove Theorem 1.4.7.

18. Define E = fié‘xi. Prove that (Eu: 7 _)‘ =23]: — m7.

19. Prove that (13101; + b.) 2 EI‘aI + [I‘bh where m and bx are uonnegative inte-

gets.

20. Prove that li,aibi 5 (£111.) (32‘1”), where a. and b. are nounegative integers.
chapter 2

DIVISIBILITY
PROPERTIES
OF INTEGERS

2.1 PRIME AND COMPOSITE NUMBERS

If a, b, and c are integers such that ab = c, then a and b are called factors,
or divisors, of c, and c is called a multiple of a and of 174 The number 3 is a
factor of 12 since 3 - 4 = 12; the number 12 is a multiple of 3. Similarly, 4
is a factor of 12; the number 12 is a multiple of 4. There are also other factors
of 12. For example, —2 is a factor of 12 since (—2) (76) = 12.
If a number dis a factor, or divisor, of a number 6, it shall be denoted
by d|c. If dis not a factor of c, then we write 114’s.
Now, let us consider the positive integers greater than 1, that is, 2, 3,
4, . . .. Each of these integers can be classified as either a prime number or
a composite number. A positive integer p greater than 1 is called a prime if it
has no positive factors other than 1 and p. A positive integer greater than 1
that is not a prime is called a composite; that is, a composite number is a

23
24 DIVISIBILITY PROPERTIES OF INTEGERS § 2.1

positive integer n that has positive factors other than 1 and n. The number
5 is a prime number since it has no positive factors other than 1 and 5. The
number 10 is a composite number since 2 is a factor of 10 while 2 ye 1 and
2 9e 10. Since the number 1 is not considered to be either a prime number
or a composite number, then each number in the set of positive integers is
either prime, composite, or equal to 1.

Theorem 2.1.1: Every composite number has a prime factor.

PROOF: Let n be a composite number. Then

I: : nlnz,

where nl and n; are positive integers both of which are less than n. If either
n1 or n2 is a prime, the theorem is proved. If n1 is not a prime, then

711 : n3n4,

where n3 and n, are positive integers both of which are less than n1. Again,
if either na or n4 is a prime, the theorem is proved. If n3 is not a prime, the
process is continued by writing

”3 : ”snsv
where ns and 716 are positive integers both of which are less than n3. In gen-
eral, after k steps we write

"2hr : "n+1 ”n+2:


where n" +1 and "n+2 are positive integers both of which are less than
712,71. Since

n>n1>n3>n5>m>nufl>0

for any value k, the process must terminate; that is, since there are only a
finite number of composite integers less than 71, there must exist an n2k_1,
for some value of k, that is a prime. Hence, every composite number has
a prime factor.

The following method can be used to determine whether a positive


integer such as 113 is a prime number or a composite number. The square
root of 113 is between 10 and 11 since 101 =100,112 = 121, and 100 <113
< 121; that is,
§ 2.1 PRIME AND COMPOSITE NUMBERS 25

10 < V113 <11.

If 113 has any positive factors other than 1 and 113, there will exist a factor
less than or equal to the square root of 113. For every factor greater than
the square root of 113, there must exist an associated factor less than the
square root in order for their product to be equal to 113. Therefore, to deter-
mine whether 113 is a prime or a composite, we only need to determine if
positive factors greater than 1 and less than or equal to the square root of
113 exist. The possible such factors are, in this case, 2, 3, 4, . . ., and 10.
Indeed, in View of Theorem 2.1.], we only need to check for factors those
integers less than or equal to the square root of 113 that are prime numbers;
that is, 2, 3, 5, and 7. Since the integers 2, 3, 5, and 7 are not factors of 113,
we conclude that 113 is a prime.
In general, to determine whether a given number p is a prime or a com-
posite, we only need to determine if any prime number less than or equal
to J} is a factor of the number p. If any prime less than or equal to V1? is
a factor of p, then 17 is a composite number. Otherwise, p is a prime number.

EXAMPLE 1. Determine if 313 is a prime.


The square root of 313 is between 17 and 18 since 17‘ 2289,
182 : 324, and 289 < 313 < 324. The prime numbers less than or
equal to m are 2, 3, 5, 7, 11, 13, and 17. None of these numbers
is a factor of 313:

3l3=156-2+l,

313:104-3+l,

313:62-5+3,

313:44-7+5,

313:28-11 +5,

313=24-13+l,

313=18-17+7.

Therefore, 313 is a prime.

Note that while the method illustrated in Example 1 will enable us to


determine whether or not a given positive integer is a prime, no one has yet
26 nivrsrarurv PROPERTIES or INTEGERS §2.l

discovered a formula that will determine the nth prime. That is, no explicit
formula or rule has yet been developed which generates the prime numbers.
Furthermore, it should be noted that the method of Example 1 is impractical
for relatively large numbers.

EXAMPLE 2. Find all primes that are one less than a perfect square.

Let p be a prime, and let x be any positive integer. Ifp 2 {:2 — 1,


then p = (x 7 1) (x + 1). Therefore, (x — 1) = j: 1 or (x + 1)
= i1.Now,(x71)= j;lifandonlyifx=20rx=0;(x+ l)
= 3|: 1 if and only ifx = 0 or x = 72. Since x is a positive integer,
x = 2. Hence, the only prime one less than a perfect square is 3
sincep=x17 l =227l.

There exist many simple ways of classifying primes. The next example
illustrates one of these ways.

EXAMi’LE 3. Every odd prime is of the form 4k + 1 or 4k e 1,


where k is a positive integer.

If an integer is divided by 4, the remainder is 0, 1, 2, or 3. There-


fore, every positive integer is of the form

4k, 4k+1, 4k+2, or 4k+3,

where k is a nonnegative integer. Now, 4k is never a prime. Since


2 | (4k + 2), it follows that 4k + 2 is a prime only when k : 0.
However, 2 is an even prime. Hence, every odd prime is of the form
4k + 1 or 4k + 3, where k is a nonnegative integer. When k = 0,
4k + 1 is not a prime. The set of integers of the form 4k + 3 where
k is a nonnegative integer is equivalent to the set of integers of the
form 4k # 1 where k is a positive integer. Therefore, every odd
prime is of the form 4k + 1 or 4k — 1, where k is a positive integer.

Care should be taken not to interpret the results of Example 3 as imply-


ing that every number of the form 4k + 1 or 4k — l, where k is a positive
integer, is an odd prime. For example, 4k + 1 is not prime when k z 2.
§2.2 some PaoPERTias or PRIME NUMBERS 27

EXERCISES
H

. Show that if all), then albc.


N

. Show that if ulb and blc, then alc.


3. Show that if alb and ale, then a|(xb + yo).
4. Show that if a and b are positive integers such that all) and bla, then a = b.
5. Prove that if n is an integer, then n, n + 2, or n + 4 is divisible by 3.
6. Prove that 6|n(n + 1)(2n + I).
7. Prove that 301(71’ — n).
8. Determine if (a) 169; (b) 197; (c) 239; (d) 473 are primes.
9. Prove that if n : kp and k > J3, where k and p are positive integers, then
p 5 J2.
10. Find all primes that are one less than a perfect cube.
11. Prove that an odd prime number can be expressed as the difi‘erenoe of two
squares in one and only one way.
12. Prove that the product of two odd numbers is an odd number.
13. Prove that the square of an odd number is of the form 8k + 1.
l4. Prove that the sum of the squares of two odd numbers cannot be a perfect
square.
15. Prove that the product of four consecutive integers is always one less than a
perfect square.

2.2 SOME PROPERTIES OF PRIME NUMBERS

The problem of obtaining a complete list of primes less than some number n
can be a rather laborious task for large values of n. Indeed, for extremely
large values of n the task may be almost impossible from a practical stand-
point. Several complete, reliable lists of primes exist for values of n up to
approximately 107. Probably one of the best-known tables of primes is that
of D. N. Lehmer (List of Prime Numbers from I to 10,006,721 , Washington,
D. C.: Carnegie Institution of Washington, 1914).
A technique known as the sieve a! Eratosthenes, named for the Greek
mathematician Eratosthenes (276—194 B.C.), represents a reasonable method
for obtaining a complete list of primes less than or equal to n where n is a
relatively small value. The sieve technique consists of writing a list of positive
integers from 2 to n. Then every second number after 2 is "sieved out" or
crossed out since such numbers contain the factor 2 and, hence, are compos-
28 DlVlSlBlLlTY PROPERTIES OF INTEGERS § 2.2

ite; that is, 4, 6, 8, . . . are composite numbers. Every third number after 3
is crossed out since such numbers are composite; that is, 6, 9, 12, . . . are
composite numbers; every fifth number after 5 is crossed out; every seventh
number after 7 is crossed out; . . .. In the sieve process many composite
numbers may be sieved out, or crossed out, more than once. The process is
terminated when the multiples ofp, other than itself, for all primes p S J};
have been crossed out. The positive integers that remain after this sieve
process are the primes less than or equal to n.
Table 2.2.1 represents the results of the completed sieve process for
n = 150. The primes less than or equal to 150 are circled.

Table 2.2.]
THE SIEVE OF ERATOSTHENES FOR
n:150

© @ I © 1’
® 3’ I 14/ ® 2!
® I! 44’ J6 (D X
36 2? 31/ ® a!
2! )6 If A“ ® 46
® 32 36’ at a 36’
® as 3: w W
I M 96 @ A!
45 :9 5r 9: 63 5r
2: M :4 s: (59 w
or s: 64 65 a?
9x a: 2? ® n
® 74 at w 2/ 26'
as art M @ 11/
36 96 81 m as
M 71 95 94 as x
9! 3f 196 {El M
M W an «m w
m m 142 ® m
M 1A6 m m m w
m 1;! 12s m 125 w
@ 128 m w @ m
m 1M 14v! Us @ w
m w m w m
w us we w
§ 2.2 some PROPERTIES or PRIME NUMBERS 29

Note that except for the primes 2 and 3, every prime number in Table
2.2.1 occurs in either the first or the fifth column. The positive integers
located in these columns are of the form 6k + 1 or 6k — l, where k is a
positive integer. One might conjecture that every prime number, except 2
and 3, is of the form 6k + l or 6k — 1. Such a conjecture can be shown to
be true, and the proof is left to the reader as an exercise (Exercise 6).
An examination of a more extensive sieve of Eratosthenes would suggest
additional properties of prime numbers. For example, the distribution of
primes decreases steadily; that is, the ratio of the number of primes to the
number of positive integers less than or equal to it decreases as n increases.
We shall denote the number of primes less than or equal to n by 7r(n). Table
2.2.2 shows the number of primes and the ratio of the number of primes to
the number of positive integers less than or equal to n for n = 1,000; 2,000;
3,000; ...; 10,000.

Table 2.2.2
A DISTRIBUTION or PRIMES FOR n S 10,000
It 1r(n) 1t(n)/n
1,000 168 0.1680
2,000 303 0.1515
3,000 430 0.1433
4,000 550 0.1375
5,000 669 0.1338
6,000 783 0.1305
7,000 900 0.1286
8,000 1007 0.1259
9,000 1117 0.12.41
10,000 1229 0.1229

One might conjecture that since the distribution of primes steadily de-
creases, the number of primes is finite. However, such a conjecture is false.
Euclid proved that the number of primes is infinite.

Theorem 2.2.1: The number ofprimer is infinite.

PROOF: Assume there exists a largest prime p. Denote the product of


every prime less than or equal to p by n. Then

n+1=(2-3'5-7-----p)+1>p.
30 Drvrsrmmrv PROPERTIES or INTEGERS §2.2

If n + l is a prime number, then p is not the largest prime. If n + l is a


composite number, then it must contain prime factors greater than 17 since
division of n + 1 by primes less than or equal to p results in remainders of
1. Hence, there is no largest prime; that is, the number of primes is infinite.

Although the number of primes is infinite, mathematicians have dis-


covered that 7t(n) behaves somewhat like the expression n/loggr for very
large values of n. Both Legendre (1752718333) and Gauss (1777—1855) inde-
pendently conjectured the relationship between 1r(n) and n/logen, which may
be stated symbolically in the form

lim[1t(n)-(log,n) / n] = 1. (2.2.1)
However, relationship (2.2.1) was first proved independently during the last
decade of the 19th century by the French mathematician Hadamard (1865~
1963) and the Belgian mathematician de la Vallée-Poussin (1866—1962). The
statement of equation (2.2.1) is known as the Prime Number Theorem. Table
2.2.3 indicates the validity of the Prime Number Theorem.

Table 2.2.3
n 1:01) n/log.n 7r(n) - (log.n)/n
1,000 168 145 1.159
10,000 1,229 1,086 1.132
100,000 9,592 8,686 1.104
1,000,000 78,498 72,382 1.084
10,000,000 664,579 620,421 1.071
100,000,000 5,761,455 5,428,681 1.061

The statement of the following example is suggested by Theorem 2.2.1


and an examination of Table 2.2.1.

EXAMPLE 1. There are infinitely many primes of the form 6k * 1,


where k is a positive integer.
Assume there are only a finite number of primes 171, p1, . . ., p"
ofthe form 6k — 1, wherep1 <11, < - - - <1)". Let

N=6(p.p2 "'p.)-1-
Note that N is of the form 6k — 1. If N is a prime number, then p,I
§ 2.2 some PROPERTIES or PRIME NUMBERS 31

is not the largest prime of the form 6k ~ 1. If N is a composite


number, then it must contain prime factors. It can be shown that
' every prime number, except 2 and 3, is of the form 6k + 1 or 6k — 1
(Exercise 6). Now, 2 and 3 do not divide N. Furthermore, N cannot
contain only prime factors of the form 6k + 1 since the product of
any number of such factors is not of the form 6k — 1. For example,

(6k, + 1) (6k2 + 1) : 36k1k1 + 6k1 + 6k, + 1


= 6 (6k2 + k1 + k2) +1
: 6k3 + 1.
Hence, N must contain a prime factor of the form 6k — 1. Since
P1: 171, . . ., and P» are not factors of N, there exists a prime factor of
the form 6k 7 l which is greater than p”. Therefore, there are in-
finitely many primes of the form 6k ~ 1, where k is a positive integer.

Since the distribution of primes steadily decreases, one might correctly


conjecture that arbitrarily long sequences of consecutive composite integers
exist.

EXAMPLE 2. Find a sequence of ten consecutive integers all of


which are composite.

Consider the sequence

11!+2,11!+3,11!+4,...,11!+11. (2.2.2)

The sequence consists of ten consecutive integers. The first integer


is composite since 2 | 11! and 2 | 2; the second integer is composite
since 3 [ 11! and 3 | 3; the third integer is composite since 4 | 11!
and 414; ...; and, finally, the tenth integer is composite since
11 | 11! and 11 | 11. Hence, the ten consecutive integers in the se-
quence are all composite numbers.

Note that the sequence of (2.2.2) is not the only sequence of ten con-
secutive composite integers. An examination of Table 2.2.1 yields several
sequences of ten consecutive composite integers between 113 and 127:
32 DIVISIBILITY rmpcnnns or 1NTEOER5 § 2.2

114,115,116, ...,123;

115,116,117, ...,124;

116,117,118, ..., 125; '

117,118,119, r..,126.

V In general, a sequence of n consecutive integers all of which are compo-


site can always be expressed in the form

(n,+1)!+2.(n+1)5+3,(n+1)!+4. -.-,(n+1)!+(n+1)-

Although arbitrarily long sequences of consecutive composite integers


exist, an examination of Table 2.2.1 suggests that many consecutive primes
differ by 2; that'is, only one composite number exists between them. Two
consecutive o'dd integers, both of which are prime, are called twin primes.
Examples of twin primes include 3 and 5, 5 and 7, 11 and 13, 17 and 19, 29
and 341, 41 and 43, . . .. It is still an open question whether or not there are
infinitely many pairs of twin primes. Among the largest known twin primes
are

l,00(),000,000,061 and 1,000,000,000,063 ;

l,000,000,000,331 and l,000,000,000,333;

1,000,000,009,649 and 1,000,000,009,651;


a

140,737,488,353,507 and 140,737,488,353,509;

I40,737,488,353,699 and 140,737,488,353,701.

Interestingly enough, the question of whether or not there are infinitely many
triplets of consecutive odd integers, all of which are prime, has been answered.
The number of “prime triplets,” such as 3, 5, and 7, is finite (Exercise 7).
A number of interesting problems concerning primes remain unsolved.
Numerous research efforts have been devoted to the solution of a problem
known as Goldbneh’s conjecture. In the 18th century, a mathematician named
§ 2.2 some PROPERTIES OF PRIME Humans 33

Charles Goldbach conjectured that every even integer greater than 4 can be
expressed as the sum of two odd primes. For example,

6:3+a
8=3+i
w=3+7zs+i
n=5+z
M:3+U=7+L
m:3+n=5+u,

Although many mathematicians have attempted to prove or disprove Gold-


bach’s conjecture, no one has yet been successful.

EXERCISES

. List the pairs of twin primes in Table 2.1.1.


aun—

. Show that 1997 and 1999 are twin primes.


. Find a pair of twin primes between 400 and 500.
. Use a sieve of Eratosthenes to determine a list of primes less than n where
(a) n = 200; (b) n = 300.
5. Prove that there are infinitely many primes of the form 4k + 3, where k is a
positive integer.
. Prove that every prime number, except 2 and 3, is of the form 6k + 1 or 6k — l,
9K

where k is a positive integer.


7. Prove that 3, 5, and 7 is the only set of prime triplets.
8. Find a sequence of four consecutive integers all of which are composite.
9. Find a sequence of one hundred consecutive integers all of which are com-
posite.
10. Verify Goldbach’s conjecture for the even integers (a) 32; (b') 100; (c) 456;
(d) 1024.
11. The proof of Theorem 2.2.1 implies that if pl, 17:, i . ., 17k represent the first k
pnmes, then the next prime lies in the closed interval from pk + 1 to (mp;
pk) + 1. Verify this statement using the first two primes.
34 mvrsmurv PROPERTIES or INTEGERS § 2.3

2.3 THE GREA TEST COMMON DIVISOR

In this section we shall discuss the problem of determining the largest


factor common to two integers. We shall also discover some interesting prop-
erties of this factor in later sections of this chapter.
If kla and klb, then k is called a common divisor, or common factor, of a
and b. The largest positive integer g that divides the absolute values of each
of two integers a and b is called the greatest common divisor of a and b. The
greatest common divisor of a and b shall be denoted by (a, b). For example,
the greatest common divisor of 24 and 78 is 6; that is,

(24, 78) : 6.

Note also that

(~24, 78) = (24, —78) = (—24, ~78) = 6.

Ifa = b = 0, then (a, b) does not exist. If a aé 0 and b = 0, then (a, b)


:1a|;ifa :0 and b ;6 0, then (a, b) : |b|.
To show that a positive integer g is the greatest common divisor of two
integers a and b, which are not both zero, it is sufficient to show that
(i) sin and glb;
(ii) if k|a and klb, then klg.
Condition (i) states that the greatest common divisor g of a and b is a com-
mon divisor of a and b; condition (ii) states that every common divisor of
a and b is a divisor of the greatest common divisor g of a_and b. Statements
(i) and (ii) will be accepted as an equivalent form of the definition of the
greatest common divisor g of two integers a and b.
The following theorem not only demonstrates the existence of the great-
est common divisor of two integers which are not both zero, but it states an
interesting and useful property of the greatest common divisor.

Theorem 2.3.1: If a and b are integers which are not both zero, then the
greatest common divisor (a, b) of a and b is the smallest positive integer
that can be expressed as a linear homogeneous function of a and b; that
is, (a, b) is the smallest positive integer such that

(a, b) = M + yb,
§ 2.3 THE GREATEST COMMON Drvrsox 35

where x and y are integerr.

PROOF: Consider the set S of all positive integers of the form xa + yb,
where x and y are integers. The set S is obviously not an empty set since
a2 + b2 > 0. Therefore, there exists a smallest positive integer g in the set
such that '

g : x,a + ylb. (2.3.1)

If either a or b is equal to 0, the proof that g is (a, b) is trivial. Assume


a # 0 and b aé 0. By the division property, there exist integers q and r such
that

a =qg+r, where 0gr<g.

Then

r = a a qg.

Using (2.3.1), it follows that

r a — q(xra +yrb)
(1 — 1m) a + (—01) b;
that is, r is a linear homogeneous function of a and b. However, r is not a
member of S since 0 g r < g and g is the smallest positive integer in S.
Therefore, r : 0 and a = qg; that is, g|a. In a similar manner, it can be shown
that glb. Hence, g is a common divisor of a and 17.
Let k be any other divisor of a and b. Consider ka’ = a and kb’ = b.
Then

2: : X1 (160') + yr 065')
= k(x1a' + yxb')

and k| g. Hence, g is the greatest Common divisor of a and b.

Two points concerning Theorem 2.3.1 should be mentioned. First, while


(a, b) is the smallest positive integer that can be expressed as a linear homo-
geneous function of a and b, the representation is not unique. Note that if

/ mw=m+m
36 DIVISIBILITY PROPERTIES OF INTEGERS §2.3

where x and y are integers, then

(a, b) =(x +bt)a+(y7at)b

for any integer 1. Second, note that if

d = ra + sb,

for some pair of integers r and r, then 11 need not be the greatest common
divisor. For example, if

(a, b) : M + yb,

t(a, b) = on: + tyb,

for any integer t; that is,

d : ra + 5b,

where d : [(11, b), r = tx, and s = 1y.

Theorem 2.3.2- The greatest common divisor of two integers, which are not
both zero, is unique.

PROOF: If g and g' are two positive integers satisfying conditions (i)
and (ii) for two integers a and b, which are not both zero, then glg’ and
g’lg. Hence, g r g’.

While Theorems 2.3.1 and 2.3.2 considered together state that a greatest
common divisor of two integers which are not both zero exists and is unique,
neither theorem gives a procedure for determining a greatest common di-
visor. We shall illustrate a procedure for doing so when both integers are
nonzero. This procedure, an algorithm, depends upon the division property.
An algorithm is a procedure involving repeated applications of a formula,
a rule, or an operation such that the information or result derived at each
step is used in the succeeding step until the desired result is obtained.
Consider two unequal positive integers a and b. Let a > b. Then in
general, by the division property, there exist q {s and r i‘s such that

a =q1b +rl, where 0<rl < b;


§ 2.3 THE Gunner COMMON DIVISOR 37

b = 11hrl + r2, where 0 < r2 < r1;

’1 243'; +r3, where 0<r3 < r2;

rki3 =q,,,,r,,_z + rk_1, where 0 < 5-1 < n4;


’k—z =qkr,‘_1 + r," where 0 < rk < rkhl;

rkil : qk+lrk + 0'


Note that r1, r2, r3, . . . , rk,“ 1,, represents a decreasing sequence of positive
integers. Since there exists only a finite number of positive integers less than
17, the above process must terminate; that is, only a finite number of positive
integers r i exist which satisfy the above equations. This process, called
Euclid’s algorithm, yields (a, b) : rk. To show that (a, b) : r”. we need to
show that ‘
(i) rkla and rk|b;
(ii) every divisor of a and b also divides rt.
From the last equation, rk|rksr By substitution for rkix in the next-to-last
equation,

rib: =qq+1rk + ’k

= (qq+1 + 1) ’1:-
Therefore, rk|rksz. By substitution for r,,_2 and rk,1 in the second-to-last
equation,

’nia =qk71(qq+l + D71; +qk+lrk

: (qk—lqhqk+1 ‘i’ qhil + qua) rk‘

Therefore, r,‘|r_,,3. By continuing along these lines, we can show that since
r,‘|r1 and 7,,e in the second equation, then rklb. Therefore, using the first
equation, rk|a so that condition (i) is satisfied; that is, r,‘ divides a and b. To
show that condition (ii) is satisfied, let d|a and d|b. Then, from the first equa-
tion, dirt; from the second equation, dlrz; from the third equation, dlrs; . . . ,
and finally from the next-to—last equation, d|r,,. Therefore, every divisor of
a and b also divides rk. Hence, (a, b) : rk.
If a or b is a negative integer, we may disregard the negative sign in
using Euclid's algorithm since
38 Dlvrsraru'rv PROPERTIES OF INTEGERS § 2.3

(a, b) : (a, —b) = (7a, b) = (~a, —b).

EXAMPLE 1. Find (10,672, 4140.


Let a = 10,672 and b = 4147. Then, by Euclid’s algorithm,

10,672 : 2 - 4147 + 2378,~ ‘

4147 : 1-2378 +1769, w.

2378 = 1 - 1769 + 609, h,

1769 = 2 - 609 + 551,“;

609 =1-551+58,W(

551:9-58 +29,

and

58 = 2 - 29.

Hence, (10,672, 4147) = 29.

Euclid’s algorithm may be used to determine the integers x and y of


Theorem 2.3.1 which are necessary to write (a, b) as a linear homogeneous
function of a and b. This can be accomplished by expressing the successive
remainders r, in terms of a and b:

’1 =1 +(‘qr)b,

r2 : b + (—112) n = (—112) a + (1 — qi) b,


'3 =r1 +(—qa)r2 =0 +qzq:)a+(qlqzi‘11_q3)b,

Eventually, we can obtain r,‘ as a linear function of a and b.

EXAMPLE 2. Find (10,672, 4147) as a linear homogeneous function


of 10,672 and 4147.
From Example 1,
§ 2.3 THE GREATEST COMMON DIVISOR 39

Yr 2378 = 10,672 + (72) -4147,


V, 1769 = 4147 +(—1)-2378'=(—1)-10;672 + (3)-4147,
V1 609 = 2378 + (‘1)- 1769 =(2) - 10,672 + (—5) -4147,
1/9 551 = 1769 + (—2) - 609 =(—5)-10,672 + (13) .4147,
58 = 609 + (—1) - 551 = (7) . 10,672 +(—18)-4147,
and

29 = 551 + (*9) -5g : (—68) - 10,672 + (175) -4147.


Since (10,672, 4147) = 29, then
(10,672, 4147) : (—68) - 10,672 + (175) -4147.

EXAMPLE 3. Find (252, —180) as a linear homogeneous function


of 252 and —180.
Let a = 252 and b = 180. Then, by Euclid’s algorithm,

252=1-180 +72,

180=2-72+36,

and

72 = 2 ~ 36.

Hence,

(252, #180) = (252, 180) = 36.

Now,

72 = 252 +(—1)-180,

and

36 = 180 + (—2) -72 = (—2) -252 +,(3) - 180.

Since

36 = (—2) -252 + (3) - 180,


40 DIVISIBILITY PROPERTIES or INTEGERS § 2.4

then

36 : (72) - 252 + (-3) 17180);

that is,

(252, ~180) : (#2) - 252 + (‘3) - (—180).

EXERCISES

In Exercises 1 through 8 find the indicated greatest common divisor by Euclid's


algorithm:

1. (172, 64). 2. (117, 169).


3. (323, 221). 4. (884, 1292).
5. (—816, 7209). 6. (—5376, ~3402).
7. (7469, 2387). 8. (11,143, 8749).

In Exercises 9 through 16 find integers x and y such that each statement 1': true:

9. 2 = 78x + 32y. 10. 13 :104x + 91y.


11. 7 = 312: + 19y. 12. 16 = 42;: + 26y.
13. 3 = 288x + 51y. 14. 1 = 52x + 13y.
15. 87 = 145): + 58y. 16. ~2 : 17x + 5y.

17. Prove that if d = xa + yb, then (a, b)[d.


18. Prove that if a : qb + r, then (a, b) = (b. r).
19. Use the results of Exercise 18 to prove that in Euclid’s algorithm (a, b) =
(rk—r, rt).
2 Prove that (ka,vkb) = la, b), where k # o.

2.4 THE GENERALIZED GREATEST COMMON DIVISOR

An extension of the concept of a greatest common divisor of two integers


may be made. The largest positive integer g that divides the absolute
values of each of n integers a1, (12,. . ., and an, which are not all zero, is called
the greatest common divisor of the n 2 2 integers. The greatest common
divisor of a,, £12,. . ., and a,I will be denoted by (a1, 02,. . ., a"). For example,
the greatest common divisor of 30, 21, 12, and 66 is 3; that is,

(30, 21, 12, 66) : 3.


§2.4 THE GENERALIZED GREATEST COMMON DlVlSOR 41

To show that a positive integer g is the greatest common divisor of


n 2 2 integers al, a2, . . ., and an, which are not all zero, it is sufficient to
show that
(i) gla, for i = 1,2, ..., n;
(ii) if d|a, for 1' = 1, 2, . . ., n, then dlg.

Theorem 2.4.1: If (1,, a2, . . ., and oz,I are nonzero integers where n 2 3, then

(01, a2; -- -a an) = ((01! “2! ~ ' ') an—l)’ an)‘


PROOF: Let

g = (a1) “2: -~ -- a») and g, = ((111, “2; -- -: art), an)’

Since gla, for i: 1, 2, .. ., n, then g|(a1, a2, . . ., anil) and glan. Hence,
g|g’. In a similar manner, since g’1(a,, 42,. . ., an_1) and g’lan, then g’la, for
i = 1, 2, . . ., n. Hence, g’|g. Since g and g’ are positive integers, then g = g’
by the results of Exercise 4 of §2.1; that is,

(an 42; -- u an) = «an 42, -- -, flail), an)‘

By use of Euclid’s algorithm and Theorem 2.4.1, we can determine the


greatest common divisor of more than two integers which are not all zero.
Note that

(up “2: -"1 “”10: 0, "-ao) =(a1! ”z, ~~-; an)‘

EXAMPLE 1. Find (570, 810, 495, 125).


By Theorem 2.4.1,

(570, 810, 495, 125) = ((570, 810, 495), 125);

(570, 810, 495) = ((570, 810), 495).

By Euclid’s algorithm,

(570, 810) : 30;

(570, 810, 495) = ((570, 810), 495) : (30, 495) = 15;

(570, 810, 495, 125) = ((570, 810, 495), 125) = (15, 125) = 5;
42 DIVISIEILITY PROPERTIES OF INTEGERS §2.4

that is, the greatest common divisor of 570, 810, 495, and 125 is 5.

Theorem 2.4.2: If a1, up. . i, and a" are integers which are not all zero, then
the greatest common divisor (al, a2, . . ., a") of a1, a2, . . ., and an is the
smallest positive integer that can be expressed as a linear homogeneous
function of a], a2, . . ., and a”; that is, (al, a2, .. ., an) is the smallest
positive integer such that I

(an “2’ - - u an) 2 klal + kzaz + ' " + knan’

where k1, k2, . . ., and k" are integers.

The proof of Theorem 2.4.2 is similar to that of Theorem 2.3.1 and is


left to the reader as an exercise (Exercise 13).

EXAMPLE 2. Find (570, 810, 495, 125) as a linear homogeneous


function of 570, 810, 495, and 125.
Since (570, 810) = 30, then

30 : (10) - 570 + (—7) - 810;

since (30, 495) : 15, then

15 = (716) -30 + (1) -495,


and

15 : (—160) - 570 + (112) - 810 + (1) -495;

since (15, 125) = 5, then

5 =(78)-15 +(1)-125,

and

5 = (1280) - 570 + (—896) - 810 + (~8) - 495 +(1)-125.

That is,

(570, 810, 495, 125) : (1280) - 570 + (~896) - 810

+ (—8) - 495 +(1)-125.


§2.5 PROPERTIES or THE GREATEST COMMON DIV'lSOR 43

EXERCISES

In Exercises 1 through 6 find the indicated greatest common divisor by Euclid’s


algorithm:
1. (624, 504, 90). 2. (285, 675, 405).
3. (209, 299, 102). 4. (69, 598, 253).
5. (116, 248, 148, 152). 6. (1131, 594, 2907, 1517).
In Exercises 7 through I0 find integers x, y, and 2 such that each statement is true:
7.1=11x+19y+32. 8.2=56x+6y+32:.
9.9=6x+3y+15z. 10.4=14x+7y+212.
In Exercises 11 and 12 find integers w, x, y, and 2 such that each statement is true:
11. 15 =120w + 30): + 60y +1652.
12.1:21w+9x+3y+62.

13. Prove Theorem 24.2.

2.5 PROPERTIES OF THE GREATEST COMMON DIVISOR

Two integers a and b, which are not both zero, are called relatively
prime if their greatest common divisor is unity; that is, if (a, b) = 1. For
example, 22 and 15 are relatively prime integers, although neither integer is
a prime. More generally, the n 2 2 integers a1, a2, . . ., and an, which are not
all zero, are called relatively prime if their greatest common divisor is unity;
that is, if (a,, a2, ..., an) 2 1. Furthermore, if (11,, 11,-) : l for each i #j
and i,j : 1, 2, .. ., n, then the n 2 2 integers a1, a2, ..., and a,‘ are called
pairwise relatively prime. For example, the three integers 5, 10, and 13 are
relatively prime since (5, 10, 13) = 1; however, the three integers are not
pairwise relatively prime since (5, 10) aé 1.
The following theorems concerning the properties of the greatest com-
mon divisor of two integers are of interest. ’

Theorem 2.5.1: Two integers a and b, which are not both zero, are relatively
prime if and only if integers x and y exist such that

=s +yb.

PROOF: If (a, b) = 1, then by Theorem 2.3.1 integers x and y exist


such that
44 mvxsmlu'ry PROPERTIES OF INTEGERS § 2.5

1=xa+yb.

If (a, b) = d where d > 1, then by Theorem 2.3.] d is the smallest positive


integer that can be expressed as a linear homogeneous function of a and 17.
Hence,

laéxa+yb

for any integers x and y. Therefore, the theorem is proved.

Theorem 2.5.2: Ifd = (a, b), then (3, g) = 1.

.
PROOF. 2 é _ e_ . é _ .,
If (11’ d) — k where k 9E 1, then dika and d 7 kb , that

is, a = likal and b : dkb’. Since dk|a and dklb, then d 96 (a, 1;). Hence, if
_ eé _
d—(a, b), then (d’ d)— 1.

Theorem 2.5.3: If (a, b) = 1 and (:1, c) = 1, then (a, be) = 1.

PROOF: If (a, b) = 1, then by Theorem 2.3.1 integers x and y exist


such that

1 : xa + yb;

if (a, c) : 1, then integers r and s exist such that

1 2 m + sc.

Then

1:xa +yb(ra+sc)

= (x + ybr) a + (ys) be.

Hence, by Theorem 2.5.1, it follows that (a, be) = 1.

Theorem 2.5.4: If(a, 1),.) : lfar i= 1, 2, .... n, then (a, Mr ~17.) =


1.
§ 2.5 PROPERTIES OF THE GREATEST COMMON DIVISOR 45

PROOF: The proof is by mathematical induction. It is given that


(a, bi) : 1. Now, assume that

(a, b1b2-"bh):1.

Since (a, bk“) 2 1, then by Theorem 2.5.3

(a, blbz-al) =1.

Hence,

(a, b1b2~~bn) :1

for any positive integer n, and the theorem is proved.

Theorem 2.5.5: If (1l and (a, b) = 1, then alc.

PROOF: If (a, b) = 1, then by Theorem 2.3.1 integers x and y exist


such that

1 = xa + yb.

Then

c = xac + ybc.

Since a|bc and alac, then a|(xac + ybc) by Exercise 3 of §2.1; that is, alc.

EXER CISES

Prove:
I. If blc and (a, c) = 1, then (a, b) = 1.
2. If blc, then (a, b) 2 (a + c, b).
3. If (a, c) : 1, then (a, b) = (a, be).
4. If ale, blc, and (a, b) = 1, than ablc.
5. If (h, c) = 1, then (a, be) = (a, b)(a, c).
6. If (a, b) = 1, then (11", b") : lwhere k andn are positive integers.
7. If(a,b)=1,then(a+b,a—b)=lor(a+b,a—b)=2.
8. If (a, be) : 1, then (a, b) = 1 and (a, c) = 1.
46 mvxslmu‘rv PROPERTIES or 114mm § 2.6

2.6 LINEAR DIDPHANTINE EQUATIONS

If a, b, and c are integers and ab 9e 0, any linear equation of the form

ax + by : c,

where the values of x and y are restricted to the set of integers, is called a
linear Diophnntine equation in two variables. In general, any polynomial equa-
tion in several variables x, y, z, . . . with integral coefficients is called a Di-
ophantine equation if the values of the variables are restricted to the set of
integers. The Greek mathematician Diophantus was the first person to study
such equations at length. In this section the use of Euclid’s algorithm for the
solution of linear Diophantine equations in two variables will be discussed.
Consider the linear Diophantine equation

11;: +27y =4.

Let a = 27 and b = ll. Then, by Euclid’s algorithm,

27:2-11 +5,

11 :2-5+l,

and

525-1.

Therefore, 27 and 11 are relatively prime. By Theorem 2.3.1, it is possible


to write 1 as a linear homogeneous function of 27 and 11:

5:27+(—2)-11,

and

1 =11 +(~2)-5 =(5)-11+(—2)-27.

Since 11-(5) + 27 -(~2) = 1, then

11-(20) +27-(—8)=4.

Hence, a particular solution of the linear Diophantine equation 11): + 27y =


4 is given by the equations
§ 2.6 LINEAR DIOPHANTINE EQUATIONS 47

x = 20 and y = 78.

Note that other solutions exist. For example,

x = —34 and y = 14;

x = —7 and y = 3;

x = 47 and y = —19.

A general rolution of the linear Diophantine equation is given by the equations

x=20+27t and y=78711t,

where t is an integer, since

11-(20 + 27t) +27-(~8 7111): 4.

Linear. Diophantine equations that have no solutions exist. For example,


if 2x + 4y = 7, it is evident that no integral solutions exist since 2;: + 4y is
an even integer for all possible values of x and y.
The following theorem states a necessary and sufficient condition for a
linear Diophantine equation in two variables to have a solution.

Theorem 2.6.1: The linear Diophantine equation

ox + by = c

has a solution ifnnd only ifglc where g = (a, b).

PROOF: Let g = (a, b). There exist integers a' and If such that a = ga’
and b = gb'. Thus,

2:“ + gb’y = c,
g (a’x + W) = v-
If a solution of this equation exists, then glc since g is a factor of the left
member of the equation.
Conversely, if glc, then there exists an integer c' such that c : gc’. By
Theorem 2.3.1, there exist integers x’ and y’ such that

ax' + by’ = g.

Then, multiplying both members of this equation by c’,


48 DIVISIBILITY PROPERTIES OF INTEGERS § 2.6

ax’c’ + by’c’ = gc’,

a (x’c’) + b (y’c’) = c,

“(’50) +b(yo) : C,

where x0 and ya are integers. Hence, the linear Diophantine equation ax + by


= c has a particular solution x0 and yo.

Theorem 2.6.2 places conditions on the form of the general solution of


a linear Diophantine equation in two variables.

Theorem 2.6.2: Ifg = (a, b), glc, and x0 and y0 is a particular solution of the
linear Diaphantine equation

ax + by = c, (2.6.1)

then every solution x and y is given by the equations

x = x0 + 2t and y :y0 — 3!, (2.6.2)


. g g
where t is an integer.

PROOF: We first show that the expressions given for x and y by statement
(2.6.2) represent solutions of the linear Diophantine equation. By substitu-
tion,

a(x 0 +ét)+b
g yo ~21
g =ax 0 +bYo

=c
since x0 and y0 is a particular solution of equation (2.6.1). Hence, equation
(2.6.1) is satisfied.
Now, let x and y be any solution of equation (2.6.1). Then

ax+by=c and ax°+byo=c.

By substitution,

ax + by = axo + bye,

ax — axo = byn — by,


§ 2.6 LINEAR DIOPHANTINE EQUATIONS 49

“(x _ x0) = 17(yo 7 y);

a b
— x — x o) = —
g( g ( yo — Y) .

By Theorem 2.5.2, if g = (a, b), then (3, 3) = 1. Hence, by Theorem 2.5.5,

do
b
— x0) and EM
a
ey).
It follows that

x—xozgr and yo~y=§u

that is,

b a
x = x o + —t
g and y 2 yo — g
-t,

where t is an integer.

It should be mentioned that a particular solution of a linear Diophantine


equation may often be obtained by trial and error, as well as by the use of
Euclid’s algorithm. In either case, Theorem 2.6.2 can be used to obtain the
general solution.

EXAMPLE 1. Determine the general solution of the linear Diophan-


tine equation

14x + 22y = 50.


Since 28 + 22 = 50, it follows that x0 : 2 and y0 = l repre-
sents a particular solution of the given Diophantine equation. Now,
g = (14, 22) : 2, a = 14, and b = 22. Hence, by Theorem 2.6.2, the
general solution of the linear Diophantine equation 14x + 22y : 50
is given by the equations

x=2+llt and y=1—7t,

where t is an integer.
50 DIVISIBILITY PROPERTIES or INTEGERS § 2‘6

EXAMPLE 2. Determine a particular solution of the linear Di-


ophautine equation

39): + 26y = 105.

Since (39, 26) = 13 and 13 1105, then by Theorem 2.6.1 the


linear Diophantine equation 39x + 26y = 105 has no solutions.

EXAMPLE 3. Determine the positive integral solutions of the


equation
18): + 5y = 48.

Let a = 18 and b = 5. Then, by Euclid’s algorithm,

18:3-5+3,

5=1-3+2,

3=1-2+1,

2=2-1;

thus, (18, 5) = 1. Using the steps of Euclid’s algorithm, 1 can be


written as a linear homogeneous function of 18 and 5:

3:18+(—3)-5,
2:5 +(—1)-3 =(—1)'18+(4)-s,
1:3+(—_1)-2=(2)-1s +(—7)-s.
Since 18-(2) + 5 -(—7) = 1, then
18-(96) +5-(436) :48.
A general solution of the linear Diophantine equation 18x + 5y =
48 is given by the equations

x :96 +5! and y = ~336 —18t,

where t is an integer. The positive integral solutions can be obtained


by considering the system of inequalities

96 +5t>0
~336—18¢'>0.
§ 2.7 ms FUNDAMENTAL THEOREM or ARITHMETIC 51

Now, 96 + 51> 0 provided t 2 ~19; —336 — 18! > 0 provided


t g —19. Thus, I = —19 and

x =96 +5-(—19) =1 and y = —336— 18-(~19) =6.

Hence, 1 and 6 is the only positive integral solution of the equation


18x + 5y = 48.

EXERCISES

Determine the general solution of each linear Diaphuntine equation:

1. 48): + 7y = 5. 2. 57x — 99y = 77.


3. 112: + 30y = 31. 4. 27): ~ 18y = 54.
5. 13): — 7y = 21. 6. 44): + 66y =11.
7. 21;: —— 12y = 72. 8. 17): + 54y = 8.

In Exercises 9 through 12 determine the positive integral solutions of each linear


Diophtmtine equation:

9. 5x — 11y = 29. 10. 32x + 55y = 771.


ll. 58x ~ 87y = 290. 12. 62x + 11y = 788.

13. An organization purchased some simulated relics for $17 each and sold some
of them for $49 each. If the number originally purchased was between 50 and
100, and the organization made a net profit of $245, how many simulated rel-
ics remain unsold?
14. A man 'received a check for a certain amount of money. The man bought an
item for $0.68 and used the check for the purchase. The cashier mistook the
number of dollars for the number of cents and the number of cents for the
number of dollars. The cashier then returned twice the amount of the check to
the man as change. What was the smallest possible value of the check?

2.7 THE FUNDAMENTAL THEOREM 0F ARITHMETIC

An integer n > 1 is either a prime or can be expressed as a product of


primes. For example,

30 = 2 - 3 - 5,

83 = 83,

143 = 11 - 13,
52 mvrsmiun PROPERTIES or INTEGERS § 2.7

and

350:2-5-5-7.

If it is agreed that a prime may be regarded as being expressed as a "product


of primes,” then the primefactorization of any integer n > 1 is unique except
for the order in which the prime factors appear. This property of positive
integers greater than 1 is called the Fundamental Theorem of Arithmetic and
is proved in this section as Theorem 2.7.4.
The validity of the Fundamental Theorem of Arithmetic may not be
obvious. Indeed, it is possible to define systems of numbers such that the
prime factorization of such numbers is not necessarily unique. Consider a
set S of positive integers of the form 4k + 1, where k is a nonnegative integer;
that is,

S = (l, 5, 9,13, 17, 21, 25, 29, 33, 37, 41, 45, 49, . . .}.

Let any positive integer p e S, Where p > 1, be considered a prime number


if it has no positive factors contained in S other than 1 and p. A positive
integer greater than 1 that is not a prime will be considered a composite
number. The set of primes includes 5, 9, 13, 17, 21, 29, 33, 37, 41, 49, .. .;
the set of composites includes 25, 45, 65, 81, 85, 105, 117, 125, 145, 153, 165,
169, . . .. Note that the prime factorization of a number in S is not unique
since, for example,

441 :9-49221-21

while 9, 21, and 49 are primes in S. If two different prime factorizations can
occur in one system, then it should not be obvious that it cannot occur in the
system of positive integers. This example indicates the need for a proof that
the prime factorization of any positive integer n > 1 is unique.
The following sequence of theorems culminates in a proof of the Funda—
mental Theorem of Arithmetic.

Theorem 2.7.1: p is a prime andp|ab, then pla or plb.

PROOF: pla, then the theorem is proved. Up 4’ a, then (p, a) = 1. By


Theorem 2.5.5, it follows that plb.

Theorem 2.7.2: p is aprime andplala2 - - ‘ a", then p divides at least one


afthefactor: a1, a1, . . ., an.
§ 2.7 THE FUNDAMENTAL THEOREM or ARITHMETIC 53

PROOF: Assume that pin, for i: 1, 2, . . ., n. Then, since p is a


prime, (p, a‘.) 2 1 for i: l, 2, 1..,n. By Theorem 2.5.4, it follows that
(p, ala2 - - ~ 11") : 1. Therefore, p )(alaZ - - - an. Hence, ifp is a prime and
plalaz ' - - an, then p divides at least one of the factors (1,, a2, .. ., a".

Theorem 2.7.3: p, p‘, p2, ..., andp,l areprimes andplplp2 ~ ' ‘17", thenp
equals at least one of thefactors 171, p1, . . ”p”.

The proof of Theorem 2.7.3 follows from Theorem 2.7.2 and is left to
the reader as an exercise (Exercise 15).

Theorem 2.7.4: The prime factorization of any positive integer n >1 is


unique except for the order in which the prime factors appear.

PRooF: The proof consists of two parts. First, it needs to be shown


that any positive integer n > 1 can be expressed as a product of primes. Note
that if a positive integer n > 1 is a prime, then it is already expressed as the
“product of primes.” If n is a composite number, then by Theorem 2.1.1 it
has a prime factor p1; that is,

’1 :Pini

for some positive integer n1 > 1. If n1 is a prime, the prime factorization of


n has been accomplished. If n1 is a composite number, then by Theorem 2.1.1
it has a prime factor p2 ; that is,

"1 = Pznz
and

’1 2 171172")

for some positive integer n2 > 1. If n2 is not a prime, then we can continue
the process applied to n and n1 and thus obtain a third prime factorp3 ; thatis,

’1 : Fipzpz":

for some positive integer 113 > 1. In general, after k steps we have

’1 =P1l73 ' ‘ ‘Pknh


54 DIVISIBILITY PROPERTIES or rNTmEns §2.7

where pl, p2, p3, . . ., pk are primes and n,‘ is some positive integer greater
than 1. Since

n>nl>n1>n3> >nk>l

and there exists only a finite number of positive integers less than n and
greater than 1, the process must terminate; that is, there must exist an nh,
for some value of k, that is a prime. Hence, any positive integer n > 1 can
be expressed as a product of primes.
To prove that the prime factorization of any positive integer n > I is
unique, assume that. two prime factorizations of I: exist. let

n =P1P2P3 ‘ ’ 'Pk

where pl, 112, p3, .. .,pk are primes and

111 SP; Spa S $11.;


let

u = Q1429: ' ‘ ' q,"

where ql, qz, 4:: . . ., q," are primes and

qXqéqgs "'Sq..;

and let k g m. Then

pimp; - ~ 7. = qlqzqs ~ ' ' q... (2.7.1)


Since 171 divides 1:111s - ' - 17,, it divides qxqzq3 - - - qm. By Theorem 2.7.3,
111 = q, for some i where 1 g ig m; that is, 1:1 2 ‘11- In a similar manner,
q1 =p, for some iwhere l g is k; that is, q1 2111. Thus, 171 = 111. Then,
dividing both members of equation (2.7.1) by p1,

P2P3 ' "Pk 292?: ' "q".-

If we continue as before, p2 = q2,p3 = 113, .. ., and p,‘ : qk. Ifk < m,

1 = 4k+1qx+2 ' ' ' qm- (2-7‘2)


Since equation (2.7.2) is not possible if 4,“, 4,“, . . ., q," are primes, then
k 4,: m. Thus, k = m and the prime factorization of any positive integer
n > 1 is unique.
§ 2.7 . THE FUNDAMENTAL THEOREM 0F ARITHMETIC 55

In proving the Fundamental Theorem of Arithmetic we considered the


possibility that the prime factorization of a number could contain equal
primes. It is often convenient to express a positive integer n > 1 whose prime
factors pl, 112, . . ., pk occur a1, a1, . . ., at times, respectively. as

"2 1,1. 1,31 . . '17:“; (2.7.3)


that is,

k
n = Hm”. (2.7.4)
1: 1

When n is expressed as the product of powers of distinct primes, such as in


(2.7.3) or (2.7.4), the representation is called the standard form of n.

EXAMPLE 1. Represent 1176 in standard form.


Since

1176:2-2-2-3-7-7,

then

1176:23-3-72

represents the standard form of 1176.

EXAMPLE 2. Find (936, 588) by using the Fundamental Theorem


of Arithmetic.
Now,

936 =2-2-2-3-3-13

and

588 :2-2-3-7-7.

The prime factor 3 is common to both numbers; the prime factor 2


is common to both numbers twice. Hence, 2 -2 .3 is the greatest
common divisor of 936 and 588; that is,

(936, 588) = 12.


56 DIVISIBILITY PROPERTIES or INTEGERS - § 2.7

If alk and b|k, then k is called a common multiple of a and b. For example,
since 3|12 and 4t 12, then 12 is a common multiple of 3 and 4; since 3|24 and
4|24, then 24 is also a common multiple of 3 and 4. The smallest positive
integer m that is a multiple of each of two nonzero integers a and b is called
the least common multiple of a and b. The least common multiple of two
nonzero integers a and b shall be denoted by [11, b]. Note that if m = [a, b],
then

m : [11, —b] = [—a, b] = [—a, ~b].

To show that a positive integer m is the least common multiple of a and


b, where a and b are nonzero integers, it is suflicient to show that
(i) a|m and blm;
(ii) ifalk and b|k, then mlk.
Condition (i) states that the least conunon multiple m of a and b is a common
multiple of a and [7; condition (ii) states that every common multiple of a
and b is a multiple of the least common multiple of a and b. Statements (i)
and (ii) will be accepted as an equivalent form of the definition of the least
common multiple m of two integers a and bi

EXAMPLE 3. Find [936, 588] by using the Fundamental Theorem of


Arithmetic.
Since

936:2-2-2-3-3-13

and

588:2-2-3-7-7,

then

[936,588]22-2-2-3-3-7-7-13

:45,864.

Notethat

45,864 = 49 - 936,

45,864 : 78 - 588,
§ 2.7 THE FUNDAMENTAL THEOREM or ARITHMETIC 57

and

(49, 78) z 1.

EXERCISES

In Exercises 1 through 6 represent each pair af numbers in standard form, and


find their greatest common divisor and their least common multiple:

1. 45 and 21. 2. 83 and 68.


3. 120 and 110. 4. 86 and 71.
5. 224 and 192. 6. 1287 and 507.

In Exercises 7 through 17 prove each theorem:

7. Every odd prime of the form 3k + 1, where k is a positive integer, is of the


form 6n + 1, where n is a positive integer.
No integers m and n exist such that m1 2 2n‘.
P

Um, kb] = IkI [a. b], where k $ 0.


10. aIb ifasxd only if [a, b] = Ibl.
11. Ifa = gal and b = gbt, whereg = (a, b), then [a, b] = glad lbtl.
12. labl = (a, b) - [a, b].
13. If (a, b) = 1, then [a, b] = [abI.

14. [a, b] 7 k , where k is any common positive multiple of a and b.


(z. '5‘)
15. Theorem 2.7.3.
u
16. If n = 1'1 p7“ represents the standard form of a positive integer n, then n may
i=1
be factored into two relatively prime factors in 2'”I different ways.
1. k
17. Ifa : Tip? and b : l'lpf‘,where at. 20nd fl. 20fori : 1, 2, ..., k, then
«=1 m
[11, b] = fl p'f“(“‘""") where max (at, fit) is the larger of a. and fit for each i
(:1
= l, 2, .. ., k. Furthermore, (a, b) = .,IEI‘p'f‘“(“iv"’ where min (Hi, [3.) is the
smaller of a. and ,9. for each i = l, 2, ..., k.

18. Verify the theorem of Exercise 11 where a = 315 and b = 75.


19. Verify the theorem of Exercise 14 where a = 12, b = 9, and k = 144.

The smallest positive integer m that is a multiple of each of n nonzero integers at,
an, . l . , and a.I is called the least common multiple ofthe n 2 Z integers. It is denoiea'
58 DIVISIBXLITY PROPERTIES or INTEGERS § 2.8

by [a], 11;, ..., an]. In Exercises 20 through 23 prove each theorem:

10. [u., a;, .. ., an] = [[a., a1, .. ., am], an].


21. label = (ab, ac, bc) ' [n, b, c].
22 . label 2 (a, b, c) - [a, b, c].
23 . (a, [17, 0]) = [(a, b), (a, c)].
24. Find [18, 8, 20, 5].
25. Verify the theorem of Exercise 21 where a = 24, b = 60, and c = 14.
26. Verify the theorem of Exercise 23 where a = 120, b = 270, and c = 225.
27. Determine the conditions under which label = (a, b, 0) ~ [0, b, c].

2.8 SUM OF DI VISORS

Functions whose domain of definition is the set of positive integers are


called number-theoretic functions. In this section we shall consider a number-
theoretic function related to the positive divisors of a positive integer. It
should be evident that the sum of the positive divisors of a positive integer
is a number-theoretic function. We shall denote the sum of the positive di-
visors of a positive integer n by a(n).
Consider the positive integer 1008. By the Fundamental Theorem of
Arithmetic,

1008 2 24 -32 -7.

The positive divisors of 1008 can be determined by considering all the pos-
sible combinations of the factors 2, 3, and 7 with nonnegative integral powers
less than or equal to 4, 2, and 1, respectively. That is, the positive divisors of
1008 are the terms of the product

(H4+r+r+ma+3+ma+n
Hence,

zr(1008)=(1+2+22 +23 +2‘)(1 +3 +32)(1 +7)

=25—133—172—1
2—1'371‘fi
=31 -13-8

:3224.
§ 2.8 SUM or DIVISORS 59

The procedure of this example can be generalized to obtain a formula for


the sum of the positive divisors of any positive integer. We shall first prove
a theorem concerning the form of the positive divisors of a positive integer.

k
Theorem 2.8.1: If n : 1'1 11"" represents the standard form of a positive in-
i=1
teger n, then each positive divisor d of n is given by
k
,1 2 H 175i
1': 1

where 0 g [3, g aifor each i.

PROOF :
It
n=l'lp‘l'

I:
: npqi‘m-m
i=1 |

k k
= “Pair” .111??-
[=1 ‘
k k

Hence, H p‘?‘ is a positive divisor of n provided [3,. 2 0 for each i and 1'1 pg‘i’m
i= 1 i: 1

is a positive integer, that is, provided 0 g [71 g at. for each 1'.

k
Theorem 2.8.2: If n = 1'[ p? represents the standard form of a positive in-
i=1
teger n, then
n+1 # 1

fi”——‘Pi
an): 1—1 . (2.8.1)
— 1

PROOF: By Theorem 2.8.1, each positive divisor of n appears once and


only once as a term in the expression

(1 +p1 +pi + +p‘1‘)(1 +172 +p§ + "+p‘-)

(1 +111. +12: + ' " +115“)-


60 DIVISIEILITY PROPERTIES OF INTEGERS § 2.8

Hence,

a(n)=(1 +1:1 +11% +--- +p1')(1 +1»2 +12% + +1132)”.


(1 +p,. +172 + - ~ +1)? (18.2)
:pflil+l_1.p;1+l_l ..... 17:?“ #1

P1 *1 P2 — 1 1h —1
k pT‘i'l ‘1

i=1 171*1

Note that, by definition, (1(1) = 1.

EXAMPLE 1. Find the sum of the positive divisors of 84 by the use


of Theorem 2.8.2. Verify the result by listing the positive divisors and
summing.
Since 84 = 22 -3 -7,

”(84)=T_—1'TT'W
=7.4.3

=224.

The positive divisors of 84 are 1, 2, 3, 4, 6, 7, 12, 14, 21, 28, 42, and
84. The sum of these twelve numbers is 224.

EXAMPLE 2. Find all solutions of the equation a(x) = 60.


The factors of 60 are factors of equation (2.8.2); the factors of
60 are 1, 2, 3, 4, 5,6, 10, 12, 15, 20, 30, and 60. Now,

(1 +p, +p? + ‘ ' ' +171”) aé 1 for any primepi,

95 2 for any prime Pi:

= 3 ifand only ifpi = 2,

= 4 if and only ifp, = 3,


§ 2.8 SUM or DIVISORS 61

94 5 for any primepi,

= 6 if and only ifp, = 5,

9E 10 for any prime 17v

=12 ifand only ifpi : 11,

= 15 if and only ifpl. = 2,

2 20 ifand only ifpi = 19,

= 30 ifand only ifpi = 29,

= 60 ifand only ifp‘ : 59.

Since60:3-20 :4-15 :60,then

a(x) = 60 = (1 +2) (1 + 19)


=(1+3)(1+2+22 +23)
= (1 + 59)
implies x : 2 - 19 or 3 - 23 or 59, respectively; that is, 38, 24, and 59
are solutions of the equation a(x) : 60.

A number-theoretic function flu) is called a multiplicative number-


theoretic function iff(r.\') =f(r) -f(s), where (r, s) = 1.

Theorem 2.8.3: The function a(n) is a multiplicative number-theoretic


function; that is,

a'(r.v) = 11(r) - a(.\'), (2.8.3)

where (r, s) = 1.

PROOF: Letr =pfp51- - 12:“ ands =q€‘q§= ”15'", where pi # 11,. for
i=l,2,...,kandj:1,2,...,m.'1‘hen

rs =1)??? ‘ ' 'pq‘f‘ql‘ ‘ ' ' ‘15:“


and
62 mvrsmru-ry PROPERTIES on INTEGERS § 2.8

a(rS)=(1 +171 +pi+m +p‘i‘)(1 +P2 +p§ +--'+Pi‘


(1+pk+p:+---+pik)(1+q1+qi+w+qf0
(1+qz+q§+“'+q‘§‘)'~'(1+4m+qi+-~-+q£")
—1_"qi‘+‘-1_
i=1 ‘Ii—l

Hence,

:r(rs) = a(r) - 5(5).

EXAMPLE 3. Verify that the function not) is a multiplicative


number-theoretic function for n = 63.
Now, 63 : 32 - 7 and (9, 7) = 1. Thus.
3— 2—
a(63)=33_—11-H=13-8=104,
33—1_
a(9)— 3_1~13,

and

_b_
0(7), 7_1_s.
Hence,

5(63) = a(9) - 0(7).

The sum of the positive divisors d of a positive integer n is often denoted


by Z d; that is,
dln

a(n) = 2 01- (2.8.4)


dln

In general, the notation 2}”(11) shall denote the sum of terms of the form[(11)
dln
in which d varies over the positive divisors of a positive integer n. For
example,

2:13 =13 +23+33 +63 =252.


dl6
§ 2.9 NUMBER or DIVISORS 63

EXERCI SES

I. Find a(n) where n is equal to (a) 144; (b) 360; (c) 1009; (d) 6534.
2. Show that a(n) = 2n where n is equal to (a) 6; (b) 28; (c) 496; (d) 8128.
3. Show that 0(a) = 3n where n is equal to (a) 120; (b) 672.
4. Find all solutions of the equation a():) = 36.
5. Prove that f(n) = n1 is a multiplicative number-theoretic function.
6. Verify that a(n) is a multiplicative number-theoretic function for n = 144.
7. A number-theoretic function f(n) is called a completely multiplicative number-
theoretic function if f(rs) = f(r) -f(s) for any positive integers r and s. Dem-
onstrate that a(n) is not a completely multiplicative number-theoretic function.
r
8. Prove that if n = £11112” represents the standard form of a positive integer n, then

s h(u+ 1), 1
Z dn : 11 Pin—-
do. t= 1 pi 7 1

9. Verify the results of Exercise 8 for n = 12 and h = 2.

2.9 NUMBER 01" DIVISORS

The number of positive divisors of a positive integer is another number-


theoretic function. We shall denote the number of positive divisors of a posi-
tive integer n by v(n).
Consider the problem of determining the number of positive divisors
v(n) of a positive integer n. For example, consider I: = 1350. Since 1350
: 2 -33 - 5’Y then by Theorem 2.8.1 the divisors of 1350 are of the form
2"-3”1-5”, where 03/31 31.031533, andogfisgl
That is, [3, may be chosen in 2 ways, [31 may be chosen in 4 ways, and [33 may
be chosen in 3 ways. Hence, #1, [32, and [33 may be chosen in 2 - 4 - 3 ways;
that is, 24 ways. Therefore there exist 24 positive divisors of 1350. The pro-
cedure of this example can be generalized to obtain a formula for the number
of positive divisors of any positive integer.

1:

Theorem 2.9.1: If n = HP? represents the standard form of a positive


i=1

integer n, then

v(n) = 111011 + 1). (2.9.1)


(:1
64 DIVISIBILITY PROPERTIES or INTEGERS § 2.9

PROOF: Since each positive divisor of n appears once and only once as
a term in the expression

(1 +111 +pi + +P'i‘X1 +1); +17% + +p3‘)--~


(1+1), +112 + +112“).
the number of positive divisors of n is equal to the number of terms in the
expression. Hence,

V(")=(°‘1+1)(az+1)"‘(°lt+1)
k

= H (a. + 1).
I: 1

Note that, by definition, v(1) = 1.

EXAMPLE 1. Find the number of positive divisors of 756 by the


use of Theorem 2.9.1. Verify the result by listing the positive divisors.
Since 756 2 21 - 33 - 7,

V056) = (2 + 1X3 + l)(1 + l)


= 3 .4 .2

= 24.

The twenty-four positive divisors of 756 are 1, 2, 3, 4, 6, 7, 9, 12, 14,


18, 21, 27, 28, 36, 42, 54, 63, 84, 108, 126, 189, 252, 378, and 756.

EXAMPLE 2. Find the smallest positive integer n with ten positive


divisors.
Since 10 :10-1: 5 ~2, then

W!) = (a, +1)(oc2 + 1) = 10-1,


or

v('1) : (a, +1)(uz + 1) = 5 ~2.


Hence, the powers at, and a, of the prime factors of n are either 9
and 0, or 4 and 1. Since 2“ - 3 is less than 2", the smallest positive
integer with ten positive divisors is 2‘ - 3; that is, 48.
L/ .

§ 2.10 PERFECK‘ NUMBERS 65

Theorem 2.9.2: The function v(n) is a multiplicative number-theoretic


function; that is,

v(rs) : v(r) - v(s), (2.9.2)

where (r, s) = 1.

The proof of Theorem 2.9.2 is similar to that of Theorem 2.8.3 and is


left to the reader as an exercise (Exercise 7).

EXERCISES

1. Find v(n) where n is equal to (a) 144; (b) 360; (c) 1009; (d) 6534.
2. Find the smallest positive integer n with six positive divisors.
3. Find the smallest positive integer n with eight positive divisors.
4. Prove that if v(n) = 2, then n is a prime,
5. Prove that the equation v(x) = m, where m is any given positive integer greater
than 1, has an infinite number of solutions.
6. Prove that v(n) is odd if and only if n is a perfect square.
7. Prove Theorem 2.9.2.
8. Verify that v(n) is a multiplicative number-theoretic function for n = 144.
9. Demonstrate that v(n) is not a completely multiplicative number-theoretic
function (See Exercise 7 of §2.8).
10. Prove that the product of the positive divisors of a positive integer n is equal
to nv(n)/2_

1. Verify the results of Exercise 10 for n = 24.


.—

2.10 PERFECT NUMBERS

One of the oldest areas of study in number theory is related to the


problem of determining positive integers that are integral multiples of the
sum of their positive divisors. The Greeks, who believed in various aspects
of number mysticism, were the first to investigate the properties of such
numbers and to name a particular class of them. A positive integer n is called
a perfect number if it is equal to the sum of all its positive divisors other than
itself; that is, o(n) = 2n. For example, the first four perfect numbers are 6,
28, 496, and 8128 since
/
66 DIVISIBILITY PROPERTIES or INTEGERS § 2.10

1+2+3+6=2-6;

1+2+4+7+14+28=2'28;

1+2+4+8+16+31+62+124+248+496:2-496;

1+2+4+8+16+32+64+127+254

+508 +1016 +2032+4064+8128 =2-8128.

The ith perfect number shall be denoted by Pi.


One of the most important theorems concerning perfect numbers is
suggested by the representation of the first four perfect numbers in binary
notation:

Decimal notation Binary notation

P] 6 1 10
P1 28 1 1 100
P3 496 1 1 1 110000
P4 8128 1111111000000

Every number equal to 1 + 2 + 4 + - -- + 2"", which equals 2" —— 1, is


represented in binary notation by n consecutive 1’s. Therefore,

P1 :‘ 2(22 — 1),
P2 : 22(23 — 1),
P3 : 24(25 7 1),
and

P4 = 26(27 — 1).
Note that the factors of the form 2'I — 1 in P1, P2, P3, and P4 are prime
numbers; that is,

217123,
23—1=7,
25—1231,
and
k/
§ 2.10 PERFECT NUMBERS 67

27—1=127.

The pattern suggests the following theorem which was proved by Euclid in
Book IX of the Elements.

Theorem 2.10.1: An even integer is a perfect number if it is of the form


2P’1(2" — l) where 2" — 1 ix aprime.

PROOF: Let n : 2"'(2" — 1) where 2" — l is a prime. Then

v(n)=(1+2+22+~~+2P-1)[1+(2P—1)1
2"-—1 .21:
g2~1

=2r(2p_1)

:2n.

Hence, n is an even perfect number. That is, an even integer is a perfect


number if it is of the form 2"”(21’ — 1) where 2" — 1 is a prime.

EXAMPLE 1. Prove that 33,550,336 is a perfect number.


Now,

33,550,336 = 211(2” — 1)
and

213 7 1 = 8191,

a prime. Since 33,550,336 may be expressed in the form 2"“(21’ — 1)


where 2" — 1 is a prime, then the even integer is a perfect number.

The converse of Theorem 2.10.1 was proved by Euler about 2,000 years
after Euclid.

Theorem 2.10.2: If an even integer is a perfect number, then it is of the form


2"”(2’ - 1) where 2" — 1 is aprime.

PROOF: Let n be an even integer. Then n = 2”1 -r, where r is odd


and p > 1;
\/
68 DIVISIBILITY murmurs OF INTEGERS § 2.10

0'01) = ”(21:71). W)
= (2" - 1) ' “(r)-
If n is a perfect number, then
a(n) = 2"r : (2p # 1) - a(r).

Consider a(r) = r + s, where s represents the sum of all the positive divisors
of r that are less than r. Then

21’r : (2" # 1)(r + s)


:2”r—r+2".r—s,

and
r = 5(21’ — 1).

Now, 5 divides r. However, since 5 is the sum of all the positive divisors of
r that are less than r, it follows that s = 1. Therefore, r = 2" —— 1, and r
must be a prime since o‘(r) = r + 1. Hence, n = 2”“‘(29 — 1) where 2" — 1
is a prime. That is, if an even integer is a perfect number, then it is of the
form 21’“(2F — l) where 2" — 1 is a prime.

EXAMPLE 2. Prove that 416 is not a perfect number.


Now, 416 : 25 - 13 and 25 - 13 aé 2""(2’ — 1) for any value of
p such that 2" — 1 is a prime. Hence, the even integer 416 is not a
perfect number.

A positive integer n is called a mum-perfect number if o-(n) = kn, where


k is an integer and k 2 3.

EXAMPLE 3. Prove that (a) 120; (b) 30,240 are multi-perfect


numbers.
(8) Since 120 = 23 - 3 - 5, then

a(120) = (1 + 2 + 22 + 23)(1 + 3X1 + 5)


=15'4-6

= 360
= 3 - 120;
\/
§ 2.11 MERSENNE NUMBERS 69

hence, 120 is a multi-perfect number.


(b) Since 30,240 = 2s - 33 -5 - 7, then

25~134—1_517172—1
a(30,240) :
2—l3~1 5—17—1

= 63 .40-6-8
= 120,960
: 4-30.240;
hence, 30,240 is a multi—perfect number.

EXERCISES
H

. Two positive integers m and n are called amicable numbers if their sum is equal
to the sum of the positive divisors of each one; that is, if a(m) : m + n : u(n).
Prove that (a) 220 and 284; (b) 17,296 and 18,416 are amicable numbers.
Prove that (a) 672; (b) 523,776 are multi-perfect numbers.
.N

3. Prove that the sum of the reciprocals of the positive divisors of an even per-
fect number is equal to 2; that is, if n is an even perfect number, then
1 7
«21. d _ ‘
4. Verify the results of Exercise 3 for n = 28.
5. Prove that if n is an even perfect number, then
k pqx+l +1

x
E d‘:2n .131 4—,
p.+1
where n = 1:11p?” represents the standard form of n.

6. Verify the results of Exercise 5 for n = 28.


7. Prove that 130,816 is not a perfect number.
8. Find all possible numbers n = 2k -3 -p, where p is an odd prime, such that
u(n) = 3n.

2.11 MERSENNE NUMBERS

Theorems 2.10.2 and 2.10.1 state necessary and sufficient conditions,


respectively, for an even integer to be a perfect number. According to Theo-
rem 2.10.2, a necessary condition for an even integer to be a perfect number
is that it contain a prime factor of the form 2" - 1. The following theorem
70 DIVISIBILITY PROPERTIES or INTEGERS § 2.“

states a necessary, but not sufficient, condition for a number of the form
2" — 1 to be a prime.

Theorem 2.11.1: If a number of the farm 2" — 1 is a prime, then p is a prime.

PROOF: We shall prove the equivalent statement that if p is not a


prime, then 2" — 1 is not a prime. Let p = rs, a composite number (r > 1
and r > 1). Then

21' — 1 = 2" — 1
: (2')= — 1
= (2r _ 1)[(2r)371 + arr—2 + + 1]_

Since r > 1, then 2’ ~ 1 > 1. Hence, 2" 7 1 is a composite number.

Leibniz believed the converse of Theorem 2.11.1 to be true. However,


this is not the case. If the converse were true; that is, if that p is a prime
implied that 2" A 1 were a prime, then there would exist an infinite number
of perfect numbers. Whether there is an infinitude of perfect numbers is still
an open question.
Interest in primes of the form 2" — 1, where p is a prime, was motivated
by the search for perfect numbers of a seventeenth-century mathematician
named Mersenne. A number of the form 2" — l, where p is a prime, is
called a Mersenne number and will be denoted by Mp. The following twenty
Mersenne numbers are known primes and are called Mersenne primes: M2-
M3: M5) M71 M131 M17- M19: Maia M61) M39, M107! M127! M521: M607!
M1279, M2203, M2231, M3217, Mn”, and M44“. Associated with each
Mersenne prime is an even perfect number. For example:

Prime Mersenne prime Even perfect number


p 2' — 1 29"(2' — 1)
2 3 6
3 7 28
5 31 496
7 127 81 28
13 8191 33,550,336
17 131,071 8,589,869,056
§ 2.11 MERSENNE NUMBERS 71

The largest known even perfect number 2“"“(24423 a 1) is a number with


2663 digits.
Theorem 2.11.2 is an interesting theorem concerning even perfect
numbers which the reader may have conjectured by this time.

Theorem 2.11.2: Every even perfect number ends in 6 0r 8.

PROOF: Every even perfect number n is of the form 2"”(2P — 1) where


2" — 1 is a prime. By Theorem 2.11.1, if 2" — 1 is a prime, thenp is a prime.
If p = 2, then n = 6. Consider p > 2. Every prime greater than 2 is of the
form 4m +1 or 4m + 3. p is ofthe form 4m + 1, then

n = 24m(24m+1 _ I)

:16”'(2-16’” — 1) where m2 1.

It can be 'shown that every positive integral power of 16 ends in 6 (Exercise


3). Then 2 - 16"I — 1 ends in 1, and n ends in 6. In a similar manner, ifp is
of the form 4m + 3, then

n = 24m+z(24m+3 _ 1)

= 4- 16'"(8 - 16'” — 1) where m 2 0.


Since 16’" ends in 6, then 4 - 16’" ends in 4; 8 - 16’" 7 1 ends in 7; and n ends
in 8. Hence, every even perfect number ends in 6 or 8.

In our discussion of perfect numbers we have been concerned with even


perfect numbers onlyifor a very good reason. No known odd perfect num-
bers exist. That is not to say that no odd perfect numbers exist. The question
as to whether or not there are odd perfect numbers has not been answered.
However, several partial answers have been given. The following theorems
tell us something about possible odd perfect numbers, if they exist.

Theorem 2.11.3: A prime number cannot be a perfect number.

PROOF: Let p be any prime. Then

0(11) = 1 +1?-
If p is a perfect number, then a(p) : 2p and
72 DIVlSlBlLlTY PROPERTIES or INTEGERS § 2,11

2p=1+p.
=1.

Since p 2 2, then p is not a perfect number; that is, a prime number cannot
be a perfect number.

Theorem 2.11.4: No power of a prime can be a perfect number.

The proof of Theorem 2.11.4 is similar to that of Theorem 2.11.3 and


is left to the reader as an exercise (Exercise 4).

EXERCISES

Find M19.
misc-Np-

. Prove that M“ is a composite number.


. Prove that 16'", where m is any positive integer, ends in 6.
. Prove Theorem 2.11.4.
. Prove that a perfect square cannot be a perfect number.

2.12 THE EULER ¢-FUNCTION

The number of positive integers less than or equal to a positive integer n and
relatively prime to n shall be denoted by ¢(n). For example, (#02) = 4 since
the four positive integers 1, 5, 7, and 11 are less than 12 and relatively prime
to 12. In a similar manner, we can show that

¢(1)=1. ¢(2)=1. ¢(3)=2, ¢(4)=2.


¢(5)=4. ¢(6)=2. ¢(7)=6, ¢(8)=4,
45(9) = 6, ¢(10) = 4, 42(11) = 10, ¢(13) : 12, .

This interesting and extremely important number-theoretic function ¢(n) is


called the Euler ¢-function. The function ¢(n) is sometimes also called the
indicator of n. Less frequently, it is called the totient of n.
§2.12 THE EULER ¢-FUNcn0N 73

Theorem 2.12.1: Ifp is a prime, then

49(1)) =12 — 1. (2.12.1)


PROOF: If p is a prime, each of the p 7 1 positive integers less than p
is relatively prime to 1:. Now, p is not relatively prime to itself. Hence,
4’0?) =11 — 1-

Theorem 2.12.2: Ifp is a prime and on is a positive integer, then

1501") =11“ — 17‘"; (2.12.2)


that is,

15(1)“) 2 p‘(1 7 It) (2.12.3)

P110012 The positive integers less than or equal to p“ which are not
relatively prime to p" are p, 2p, 3p, . . ., and (p"‘)p; that is, there are 17""
such integers. Hence, .

W) : r 7 p.-.
1
=
Pi 1 — ,)— .
As an example of Theorem 2.12.2, note that

41(2): «1(23) : 23 , 22 = 4.
01'

43(23) 2 23(1 — g) = 4.

Theorem 2.12.3: Ifp is a prime, then


MR

' 0
W) :12“. (2.12.4)
PROOF: By Theorem 2.12.2,
74 mvxsmu'nr norm-ms 0F INTEGERS § 2.12

¢(p) = p 7 1,

W) = p2(1 — ,7)I = p0: — 1),


49073) = p’(1 7%) =p2(p — 1).

1 ,_
¢(p“)=r(1—I;)=p 1(,,_ 1).
Therefore,

,§1¢(p‘>=(p— 1)(1 +p+p1+~~ +1711“)


_ (p _ 1) P“_—1
— p _1 _— _ 1.

Hence,

g M) = am If — 1
=l+p‘~l
:17“,

EXAMPLE 1. Verify Theorem 2.12.3 forp = 2 and o: = 3.


Now,

¢(2°) : 1,
«20 = 1.
¢<21)= 4(1—§)= 2.
and
§2.12 THE EULER ¢~1=UNCTION 75

Then

lMu
(50‘) = ¢(2°) +¢(2‘) + 45(22) + ¢(23)

=1+1+2+4
:8
= 23.

Consider the problem of determining ¢(n) where n is equal to 72. Since


72 =23 - 32, the positive integers less than or equal to 72 which are relatively
prime to 72 are relatively prime to both 2 and 3. The positive integers 2, 4,
6, . . . , and 72 are multiples of 2 and hence not relatively prime to 72; that
is, there are 36, or 722, positive integers less than or equal to 72 which are
divisible by 2. The positive integers 3, 6, 9, . . ., and 72 are multiples of 3

and hence not relatively prime to 72; that is, there are 24, or g, positive

integers less than or equal to 72 which are divisible by 3. The positive inte-
gers 6, 12, 18, . . . , and 72 are multiples of 2 - 3 and hence not relatively prime
to 72; that is, there are 12, or £743, positive integers less than or equal to 72
which are included among the 36 positive integers divisible by 2 and among
the 24 positive integers divisible by 3. Hence, the number of positive integers
less than or equal to 72 and relatively prime to 72 is 72 — 36 — 24 + 12;
that is, ¢(72) : 24.
The following theorem for determining ¢(n) for any positive integer n
is suggested by considering the preceding example in generalized form. Let
n = pi'pgl. Then the numbers of positive integers less than or equal to n and
It It n .
— —,
d'“’1'sible b ypi , P2 , and P1172 are 171,112 and 171172
— , respectively. Hence,

n n n
n =n——~—+
(M) P1 P2 P1P:

= l
1a__—l l
n( Pi P2+I71P2)
76 DiVIsmILm! PROPERTIES or lNTEGERS § 2.12

1:
Theorem 2.12.4: If n = 1'1 p? represents the standard form of a positive
i=1

integer n, then
k
W) =[ll (pt—171‘”); (2.12.5)

that is,

k 1 (2.12.6)
¢(n) = r3131 — 1;).

PROOF: We shall prove this theorem by mathematical induction. The


number of positive integers less than or equal to n which are not divisible
by P1 is obviously given by the expression

n —1; that is, n(l — L).


P1 P1

Assume that the number of positive integers less than or equal to n


which are not divisible by pl, 112, . . ., pm, where m < k, is given by the ex-
pression

"Mil—Lille)-
pl F: P.»

The multiples of pm+1 less than or equal to n are pm“, 2pm+1, 3pm“, . . .,
pip"l +1. The positive integers among these which are not multiples of 111,
"1+1

p2, . . ., or P». are the ones in which the coefficients ofpmH, that is, 1, 2, 3,
n . . .
l .,p , are not div1s1hle by Pp p2, . . l , or pm. By the assumption previously
n+1
made, the number of such positive integers is given by the expression

,;;(1 '30 2%.)“(1 2%.)-


Therefore, the number of positive integers less than or equal to n which are
not divisible by p1, p2, . . ., or Pm H is given by the expression

"(I3%.)(1nit-(1ei)7.h(lri)(l-i)m(lsi);
that is,
§ 2.12 THE EULER ¢-i=U‘NC'n0N 77

«haoeii—Ai
P1 P2 pm+1
Hence, by the second principle of mathematical induction,

1
¢nvai
Since 7: = 1'1 17?, we may also write
[=1

(#01) =1:Ip?‘(1 , 17‘)

l
” (mi—1):“).
1

Note that, by definition, ¢(1) : 1.

EXAMPLE 2. Find the number of positive integers less than or


equal to 1350 and relatively prime to 1350 by the use of Theorem
2.12.4.
Since 1350 = 2 ~ 33 - 52, then

¢(1350)= 1350(1 _%>(1 _ 3)(1 _ %)

amoee
= 360.

That is, there are 360 positive integers less than or equal to 1350
and relatively prime to 1350.

It is often more convenient to use equation (2.12.5) than equation


(2.12.6) to compute ¢(n).

EXAMPLE 3. Find ¢(7865).


Since 7865 = 5 ~112 '13, then
78 DIVISIBILITY PROPERTIES or INTEGERS § 2.13

45(7865) = (5 — 1)(112 — 11x13 — 1)


:4-11042
= 5280.

EXERCISES

. Find ¢(n) where n is equal to (a) 30; (b) 360; (c) 2003; (d) 8316.
,—

Verify Theorem 2.12.3 {orp = 3 and a = 4.


P.“

Prove that the number of irreducible positive fractions less than or equal to 1
with denominators equal to n is ¢(n).
Prove that ¢(n‘) = n - ¢(n) for any positive integer n.
weer-999

Verify the results of Exercise 4 for n = 6.


Prove that if n is an even perfect number, then ¢(n) = 2"‘(2"‘ — 1).
Verify the results of Exercise 6 for n = 28.
. Prove that the number of primes is infinite by the use of Theorem 2.12.4.
. Prove that if n > 2, then 9501) is even.

2.13 PROPERTIES OF THE EULER ¢-FUNCTION

Theorem 2.13.1: If n > 1, then the rum of the positive integers less than or
equal to n and relatively prime to n is equal to § - n - ¢(n).

PROOF: Let m1, m2, m3, . . ., mm) be the positive integers less than or
equal to n and relatively prime to n. Then the sum S of these integers is
given by

S=m1+mz+m3+m+mflnr
Note that if (mi, 7:) = 1, then (n 4 mi, 7:) =1 for i = l, 2, 3, . . ., ¢(n).
Therefore, the positive integers less than or equal to n and relatively prime
to n may be written in the form

(n — m1)! (n — "12), (n — m3), . . ., (71 ~ man),


and

S=(n—m1)+(n—m2)+(n—m3)+~--+(n—mM).
§ 2.13 PROPERTIES or THE EULER ¢-FUNCHON 79

Hence,

2S=n+n+n+-~+n=n~¢(n),

S=§-n-¢(n);
that is, the sum of the positive integers less than or equal to n and relatively
prime to n is equal to % - n -¢(n), provided n > 1.

EXAMPLE 1. Verify Theorem 2.13.1 for n : 15.


Since 15 = 3 -5, then

¢(15):1s(1—%)(1—%)= s.
The eight positive integers less than or equal to 15 and relatively
prime to 15 are 1, 2, 4, 7, 8, ll, 13, and 14. Now,

1 1
i-lS-¢(15)—§-15-8—60,
and
1+2+4+7+8+11+13+14=60.

Hence,

%-15-¢(15)=1+2+4+7+s+11+13+14;
that is, the sum of the positive integers less than or equal to 15 and
relatively prime to 15 is equal to % - 15 - ¢(15).

The following theorem which relates the Euler 4J-functions of the posi-
tive divisors of a positive integer to that positive integer is a generalization
of Theorem 2.12.3.

Theorem 2.13.2: If n is a positive integer, then

2 ¢(d) = n. (2.13.1)
dln
80 DIVISlBlLlTY PROPERTIES or INTEGERS § 2.13

PROOF: Let (1,, d2, . . ., aim, be the positive divisors of a, positive integer
n. Let m1, m2, . . ., mm) be positive integers such that

’1 : dlml : 2m2 = ' " = v(n)mv(n)'


Note that the mi’s are also the positive divisors of n. Each positive integer
less than or equal to n has with I: one and only one greatest common divisor
mi. Since the multiples of mi less than or equal to n are

mi, 2m“ 3m“ .. ., dimi,

where dim, : n, then the number of positive integers less than or equal to
n which have with n the greatest common divisor m, is equal to (“‘10- Hence,

(#011) + ¢(dz) + ' ' ' + (Kim) = n;


that is,

Z (Md) = "-
dln

EXAMPLE 2. Verify Theorem 2.13.2 for n = 105.


Since 105 = 3 - 5 - 7, then v(105) : 2 - 2 - 2 = 8. The eight
positive divisors of 105 are 1, 3, 5, 7, 15, 21, 3S, and 105. Moreover,
45(1) = 1; ¢(3) = 2; 45(5) = 4; $0) = 6; $05) = 8; ¢(21)=12;
¢(35) : 24; ¢(105) = 48; and

(ES ¢(d) = 45(1) + (#0) + ¢(5) + $0) + 4505)


+ ¢(21) + M35) + 45005)
:]+2+4+6+8+12+24+48

= 105.

Theorem 2.13.3: The Euler ¢~fimction is a multiplicative number-theoretic


function; that Lt,

45m) = W) -¢(s), (2.13.2)


where (r, s) = 1.

PROOF: Let r =p1‘p31-upgk ands=q{‘q52--~qf;, wherepi a6 qJ. for


1‘: 1,2, ...,kandj=1,2, ...,m.
§2.14 SOLUTION or THE EQUATION ¢(x) = m 81

Then

rs = pi‘p‘é“ - -p:"q‘i‘qé‘ - ' - r15"

11:11.__)(.__)...(.__)(.-_)(._.)...(.__
P1
1
P2
1 1
P11
1
41
1
‘12 q».
1

= ¢(r) ' 45(5)-

Note that Theorem 2.13.3 may be easily generalized:

45011"; ' ' ' m.) = ¢("1)'¢(”2) ' '¢(nr), (2-13-3)


where (n,, n) : l for i #j.

EXERCISES

Verify Theorem 2.13.1 for n equal to (a) 17; (b) 28.


bear-r

Verify Theorem 2.13.2 for n equal to (a) 36; (b) 147.


Verify that ¢(n) is a multiplicative number-theoretic function for n = 144.
. Demonstrate that ¢(r1) is not a completely multiplicative number-theoretic
function (See Exercise 7 of §2.8).
Prove that ¢(rs) = g- ¢(r) -¢(.r)/¢(g) for any positive integers r and r, where
5"

(r, .v) = 3.
Verify the results of Exercise 5 for r 2 12 and s = 21.
>‘9‘

Prove Theorem 2.12.4 by the use of Theorems 2.12.2 and 2.13.3.

2.14 SOLUTION OF THE EQUATION ¢(x)=m

Consider the problem of finding all solutions of the equation ¢(x) : m,


where m is any given positive integer. It can be shown that there are no solu-
tions if m is odd and greater than 1 (See Exercise 9 of §2.12). If m = 1, then
x = 2 or x = 1. In general, there is no known formula for solving the equa-
tion ¢(x) = m, where m is any given positive even integer. However, a
82 DIVlSlBlLlTY PROPERTIES OF INTEGER: § 2.14

method exists by which we may determine all solutions of the equation.


Let x = 1:1 p1“ represent the standard form of any positive integer
satisfying the equation ¢(x) = m. Then, by equation (2.12.5),

¢(x)=i11(p1‘— i”);
that is,
k

40:) = [lips—‘01. — 1) = m.
If we let
.1, =11: — 1 (2.14.1)
for i = 1, 2, 3, ..., k, then we may write
k
{1 11411,. _ m, (2.14.2)
i=1

" 1 di) _
EH? (P1 7 m,
k (11
x — = ,
iuipt
and
m k

i - 1112..
x= H (2.14.3)
d1 i=1

Equations (2.14.1), (2.14.2), and (2.14.3) place three conditions on the di’s
which enable us to determine the values of x satisfying the equation
4106) = m:
(i) each d, + 1 is a prime;
(ii) each a!i is a positive divisor of m;
(111) h is a positive integer which contains no prime factor not in-
1'14:
::1
k
cluded in 1'1 p 1-
i=1
§2.14 SOLUTION on THE EQUATION 950:) = m 83

EXAMPLE 1. Find all solutions of the equation ¢(x) : 24.


The positive divisors of 24 are 1, 2, 3, 4, 6, 8, 12, and 24. How-
ever, the possible d,’s are the integers 1, 2, 4, 6, and 12 since only
these divisors are such that d, + l is a prime. Since every product
of four or five of the d,'s is equal to an integer greater than 24, we
may eliminate those products immediately; that is, in each case,
24 . . .
k 15 not an integer when four or more d,’s are consrdered. The
1'14;
i=1
1:
possible remaining expressions for 1'1 (1, are
i: 1

El, [,5], I,1-2, “,1-s,1.12,2.4,


,2-12,4-6, -,1-2-4, 1-2-6,
1-2-12, 14-6,- ”.,
-"nmd
Those products which are circled may be eliminated since, in each
case, 34 is not an integer; those products which are boxed in

i=1
may be eliminated since, in each case, k contains prime factors
1'1 d:
i=1
1: k
not contained in H (d, + 1), that is, 1'1 1’1- Now, the remaining ex-
i=1 1'21
1:
pressions for H d, lead to solutions:
a-

fidg A fip. A-fip; x


l=l 1‘ 1:) k i=x
Hdi l'Idi
i=1 (:1
1-2 21-3 2-3 23-3‘ 72
1-6 22 2-7 2’-7 56
1-12 2 2-13 21-13 52
2-4 3 3-5 31-5 45
2-12 1 3-13 3-13 39—
4-6 1 5-7 5-7 35~
1-2-4 3 2-3-5 2'32-5 90
1-2-6 2 2-3-7 2’-3-7 84
1-2-12 1 2-3-13 2-3-13 78
1-4-6 1 2-5-7 2-5-7 70
84 DIVISIBILITY PROPERTIES or INTEGERS § 2.14

Hence, the solutions of the equation ¢(x) = 24 are 35, 39, 45, 52,
56, 7o, 72, 78, 84, and 90.

EXAMPLE 2. Find the ten solutions of the equation ¢(x) : 24 by


the use of Theorem 2.13.3.
Consider ¢(x) : ¢(n1)-¢(nz) - ¢(n3) - - - : 24, Where n1, n2, n3,
are relatively prime in pairs. By searching a list of values of
(Mn), we can determine sets of factors 4:01,), 45012), ¢(n3), . . ., where
n1, n2, n3, . . . are relatively prime in pairs, whose products are equal
to 24. The products nlnzn3 - ~ , represent solutions of the equation
¢(x) : 24. Since

45(3) -¢(13) = 2 - 12 and (3, 13) = 1, x : 39;


W) -¢(13) = 2 - 12 and (4, 13) = 1, x 2 52;
¢(5)‘¢(7)=4-6and(5,7)=1, x=35;
¢(5)-¢(9)=4-6and(5,9)=1, x=45;
45(6) «1503) = 2 - 12 and (6, 13) 2 1, x : 7s;
¢(7)‘¢(3)=6'4and(7, a):1, x=56;

¢(7) -¢(10) = 6-4 and (7, 10) = 1, x = 70;


W) -¢(12) = 6-4 and(7, 12) :1, x 2 34;
W) -¢(9) = 4-6 and (s, 9) = 1, x = 72;
45(9) -¢(10) = 6-4 and (9, 10) = 1, x : 90_
Hence, the ten solutions of the equation ¢(x) : 24 are 35, 39, 45, 52,
56, 70, 72, 78, 84, and 90. This result agrees with that of Example 1.
Note that, by this method, it is necessary to know in advance
the number of solutions desired, or to limit the upper bound of the
solutions desired, in order to decide when to terminate the search.

Among the Improved conjectures of number theory is one concerning


the equation ¢(x) = m: the number of solutions of the equation ¢(x) = m
cannot be equal to one; that is, If the equation has a solution, then it
has at
least two solutions.
§2.14 SOLUTION or THE EQUATION ¢(x) = m 85

EXERCISES

In Exercises 1 through 4 find all solutions of the equation ¢(x) = m, where m ix given:

1. 16. 2. 30. 3. 72. 4. 242.

5. Find the six solutions of the equation ¢(x) = 16 by the use of Theorem 2.13.3.
6. Prove that the equation ¢(x) : 211, where p is a prime and 2p + 1 is a composite
number, has no solution.
chapter 3

THE THEORY OF
CONGRUENCES
3.1 DEFINITIONS AND ELEMENTARY PROPERTIES

The solutions of several problems in number theory depend upon the prop-
erties of the remainders obtained when numbers are divided by certain posi-
tive integers. For example, see the solutions to Exercises 6 and 7 of §2.l as
well as the discussion concerning Euclid’s algorithm.
Consider a positive integer m. If a and b are two integers such that
m|(a — b), then a is said to be congruent to b modulo m; this will be denoted by

a a b(mod In). (3.1.1)


If m 4’ (a — b), then a is said to be incongruent to b modulo m and will be
denoted by
a i b(mod m).

87
88 THE THEORY or CONGRUENCES § 3.1

For example, 7 E 2(mod 5), 31 E 72(mod 3), and 16 $ 9(mod 4). The
congruence relation expressed by statement (3.1.1) is equivalent to the ordinary
equation

a — b : km;

that is,

a = b + km,

where k is an integer.

Theorem 3.1.1: Twe integers a and b have {he same remainders when divided
by a positive integer m if and only If a E b(mod m).

PROOF: If a E b(mod m), then there exists an integer k such that

a = b + km.

By the division property, there exist integers q and r such that

b:qm+r, where 0gr<m.

Note that r is the remainder when b is divided by m. Then

a : (qm + r) + km

and

a = (q + k)m + r.
Since (q + k) is an integer, r is also the remainder when a is divided by m.
Now, let

a=q’m+r and b=qm+r,

where 0 g r < m; that is, let a and b have the same remainder when divided
by m. Then

a—b=(q’—q)m
Since q’ — q is an integer, m](a ~ b); that is, a E b(mod m).

Theorem 3.1.2: The congruence relation modulo m, Where m is a positive


§ 3.1 DEFINITIONS AND ELEMENTARY PROPERTIES 89

integer, is an equivalence relation on the re! of integers; that is, the con-
gruence relation modulo In is

(i) reflexive: a E a(mod m) for every integer a;


(ii) symmetric: ifa E b(mod m), then b E a(mod m)for every
pair of integers a and b;
(iii) transitive: if a E b(mod m) and b E C(mod m), then
a Ec(mod m) for all integers a, b, and c.

The proof of Theorem 3.1.2 is left to the reader as an exercise (Exercise


8). However, as an example of (iii), note that

13 E 3(mod 5) and 3 E E12(mod 5)

implies

13 E E12(mod 5).

EXAMPLE 1. Determine which of the following statements are true


and which are false:
(a) 15 E 3(mod 4);
(b) —4(niod 3);
(c) 2 = 2(mod 7);
(d) 17 E 9(mod 2);
(e) 5 E —l(mod 6) and —1 E —7(mod 6) implies
5 E A7(mod 6);
(f) x E 3(mod 5) implies xe (.. ., ,7, 72, 3, 8,13, . . .}.
Statement (21) is true since 4|(15 E 3); statement (b) is false since
3 4’ [7 — (—4)l; Statement (c) is true since 7|(2 E 2); statement (d)
is false since 2|(L7 — 9); statement (e) is true by property (iii) of
Theorem 3.1.2; and statement (f) is true since x E 3(mod 5) is
equivalent to x = 3 + 5k, where k is any integer.

Under the congruence relation modulo m, the set of integers is parti-


tioned into m distinct sets, or equivalence classes; that is, under the congru-
ence relation modulo m, each integer may be considered as belonging to one
of m equivalence classes according to its smallest nonnegative remainder 0,
1, 2, . . . , or m — 1 upon division by m. These equivalence classes are often
called residue classes modulo m. A particular residue class modulo m consists
of the set of integers which are congruent to each other modulo m. For ex-
90 THE THEORY or CONGRUENCES » § 3.1

ample, under the congruence relation modulo 5, the five residue classes con-
sist of the integers of the form 0 + 5k, 1 + 5k, 2 + 5k, 3 + 5k, and 4 + 5k,
respectively, where k is any integer; that is, the five residue classes are

(..., —10,#5,0, 5,10, ...),

(m, —9, —4, 1, 6,11, ..r),

{..., #8, —3,2,7, 12, ...),

{..., *7, —2,3,8, 13, ...),

and

{..., —6, 71,4,9, 14, ...).

Each residue class modulo m may be represented by any one of its mem-
bers, although we shall usually represent each residue class by the smallest
nonnegative integer which belongs to that class. Note that any two members
of different residue classes modulo m are incongruent modulo m. Further-
more, every integer belongs to one and only one residue class modulo m. Any
subset C of the set of integers is called a complete residue system modulo m
if each integer is congruent to one and only one of the members of the subset
C. The set ‘

{0, 1,2, ...,m— 1)

is always a complete residue system modulo m. For example,

{0, 1, 2. 3, 4)

is a complete residue system modulo 5. Another complete residue system


modulo 5 is

(0, 1, 12, —2, 4}

since 12 E 2(mod 5) and —2 E 3 (mod 5). Many other complete residue


systems modulo 5 exist.

EXAMPLE 2. Determine which of the following sets are complete


residue systems modulo 4:
§3.l DEFINITIONS AND ELEMENTARY PROPERTIES 91

(a) (0,1,2,3);
(b) (—2,—1.0,1};
(c) (o, 4, 8, 12);
(d) (~13,4,17,18};
(e) (—5,0,6,22).
The sets in (a), (b), and (d) represent complete residue systems
modulo 4 since each integer is congruent to one and only one of the
members of each set. In other words, no two members of the set in
(a), or in (b), or in (d), are congruent modulo 4 and each set has
exactly four members. The set in (c) is not a complete residue system
modulo 4 since, for example, 3 is not congruent to any of the mem-
bers of the set. Alternately, there exist at least two members of the
set in (c) that are congruent modulo 4. The set in (e) is not a complete
residue system modulo 4 since 22 E 6(mod 4); that is, integers exist
which are congruent to both 22 and 6 modulo 4, or alternately, inte-
gers must exist which are not congruent to any of the members of
the set in (e). For example,

1 ,é. —rS(mod 4),

l $'0(m°d 4),
1 ,é. 6(mod 4),

and

1 ,é. 22(mod 4).

The integers may be interpreted geometrically in terms of a number line


upon which we lay ofl" multiples of a unit length in each direction from the
zero point. In this way a correspondence between some of the points on the
line and the set of integers may be made. For the congruence relation modulo
m we may consider a circle divided into In arcs of equal length. Each of the

{..., —7, —2, 3, s, 13, ...)


{..., —6, —I,4,9, 14, m) (...,:8. 4.2.7.12, ...}

(..., —l0, —5,o,5,10,..l) (NW9, —4,1,6,11...-)


Fig. 3.1
92 THE THEORY or CONGRUENCES § 3.2

end points of the m are segments can be made to correspond to a residue


class modulo m. For example, such a correspondence is shown in Figure 3.1
for the congruence relation modulo 5.

EXERCISES

. Find the smallest positive integer that represents each sum:


...

(a) 5+3+2+1+8(mod7);
(b)2+3—1+7—2(mod4).
2. Determine which of the following statements are true and which are false:
(8) 37 a 19(mod 3); (b) 56 a 11(mod 15);
(c) 10 s 10(mod 9); (d) 42 z —8(mod 10).
3. Show that 11“7 E 1(mod 100).
4. Determine which of the following sets are complete residue systems modulo 6:
(a) (1, 2, 3. 4, 5); (b) (0. 5, 10, 15, 20, 25};
(C) (*4, ~3, 72, 71, 0,1); (d) (17, —4, 6, 7,10, 3}.
5. Determine a complete residue system (17}, p2, P3, 114, ps, pa, p7) modulo 7 where
each 11. is a prime.
Find a complete residue system modulo 7 consisting of nonnegative multiples
9"

of 4.
7. By inspection, find the values of x that satisfy each statement of congruence:
(a) X + 3 E 0(m0d 7); (b) x + 4 E 3(mod 5);
(c) 3): E 1(mod 8); (d) 7): — 10(mod 12);
(e) x“ E 2(mod 7); (f) x‘ E 1(mod 6).
8. Prove Theorem 3.1.2.
Prove that if p is an odd prime, then
2‘

(a) 1 +2+3 +--- +0271) E001000110;


(b)11 + 2‘ + 3‘ + + (p—1)2 a 0(modp)providedp $ 3;
(0)1J +2’ + 33 +"' +(p—l ° E0(modp).
10. Prove that (a + b)” E a" + b’(mod p) where a and b are integers and p is a
prime.
11. Prove that (a + 1)" = a" + 1(mod p) where a is an integer and p is a prime.

3.2 SOME CONGRUENCE THEOREMS

In this section several theorems concerning the congruence relation defined


on the set of integers will he proved. These theorems are important for an
understanding of the remaining sections of this chapter.
§ 3.2 SOME CONGRUENCE THEOREMS 93

Theorem 3.2.1: If a E b(mod m) and c is an integer, then

a+c E b+c(modm).

PROOF: If a E b(mod m), then there exists an integer k such that

a : b + km.

Then

a + c = b + km + c;

that is,

(a+c)=(b+C)+km,
and by the definition of the congruence relation

a+csb+c(modm).

Theorem 3.2.2: If a E b(mod m) and c is an integer, then

ac E bt(mod m).

PROOF: If a E b(mod m), then there exists an integer k such that

a = b + km.

Then

do = (b + km)c;

that is,

ac : be + (kc)m.

Since kc is an integer, then by the definition of the congruence relation

ac E bc(mod m).

As an example of Theorem 3.2.1 and of Theorem 3.2.2, consider the


congruence

12 E 5(mod 7).
94 THE THEORY or CONGRUENCES § 3.2

Ifc in Theorems 3.2.1 and 3.2.2 is equal to 3, then

12+ 3 a 5 + 3(mod 7),

that is,

15 E 8(mod 7);
and
12 - 3 E 5 - 3(mod 7),
that is,

36 E 15(mod 7).

Note that the congruence statements 15 E 8(mod 7) and 36 E 15(mod 7)


are both true since 7|(15 » 8) and 7|(36 — 15), respectively.

Theorem 3.2.3: If a E b(mod m) and c E d(mod m), then


n+2; b+d(modm).

PROOF: If a E b(mod m), then there exists an integer k such that

a = b + km;

if c E d(mod m), then there exists an integer j such that

c = d + jm.

Using the properties of real numbers, it follows that

a+€=b+d+<k+f)m-
Since k + j is an integer, then by the definition of the congruence relation

(1+5; b+d(modm).

Theorem 3.2.4: If a E b(mod m) and c E 11(d m), then

airs b—d(modm).

The proof of Theorem 3.2.4 follows from Theorems 3.2.2 and 3.2.3,
and is left to the reader as an exercise (Exercise 7).
§ 3.2 SOME CONGRUENCE THEOREMS 95

Theorem 3.2.5: If a E b(mod m) and c E d(mod m), then do 5 bd(mod m).

PROOF: If a E b(mod m) and c a d(mod m), then there exist integers


k and j such that

a=b+km
and
C=d+jm,
respectively. Then

do : (b + km)(d + jm)

: bd + (bj + kd + kjm)m.

Since bj + kd + kjm is an integer, then by the definition of the congruence


relation

ac E ba'(mod m).

As an example of Theorem 3.2.3 and of Theorem 3.2.5, consider the


congruences

30 E 8(mod 11)
and
13 E 2(mod 11).

According to Theorem 3.2.3,

30 +13 E 8 + 2(mod 11)

43 E 10(mod 11);

according to Theorem 3.2.5,

30- 13 E 8-2(mod11)

390 E 16(mod 11).

Note that the statements 43 s 10(mod 11) and 390 E 16(mod 11) are both
true since 111(43 — 10) and 111(390 - 16), respectively.
96 THE 11-1150“ or CONGRUENcrs § 3.2

Theorem 3.2.6: If a E b(mod m) and n is a positive integer, then

a" E b”(rnod m).

PROOF: The proof is by mathematical induction. It is given that a E b


(mod m). Now, assume

a" E b"(mod m),

where k is any positive integer. Then, by Theorem 3.2.5,

aka E b"b(mod m);

that is,

ak+1 E b*+‘(mod m).

Hence, by the first principle of mathematical induction,

a" E b”(mod m)

for any positive integer n, and the theorem is proved.

Theorem 3.2.7: If a E b(mod m), c E d(rnod m), and r and s are integers,
then

ar + c: E br + ds(mod m).

The proof of Theorem 3.2.7 follows from Theorems 3.2.2 and 3.2.3, and
is left to the reader as an exercise (Exercise 8).

Theorem 3.2.8: If a E b(mod m) and P(x) is a polynomialfunction of x with


integral coefiicients, then

P(a) E P(b)(mod m).

The proof of Theorem 3.2.8 follows from Theorems 3.2.1, 3.2.2, 3.2.3,
and 3.2.6, and is left to the reader as an exercise (Exercise 9).

EXAMPLE 1. Given 13 E 4(mod 3) and 8 E 2(mod 3), verify Theo-


rem 3.2.7 where r = 5 and s E 7.
§ 3.2 SOME CONORUENCE THEOREMS 97

Leta:13,b:4,c=8,andd=2.Then

ar+cs:13-5+8-7

:12]

and

br+ds=4-5+2-7

=34.

Since 31(121 — 34), then

121 _ 34(mod 3);


[I

that is,

ar + cs E br + ds(mod m).

EXAMPLE 2. Given 7 E 3(mod 4), verify Theorem 3.248 where


P(x) = 2x1 — x + 3.
Leta = 7 and b : 3. Then

1’01) = 2(7): — (7) + 3


: 94

and

P(b) = 2(3)2 — (a) + 3


= 18.

Since 4|(94 — 18), then

94 E 18(mod 4);

that is,

P(a) E P(b)(rnod m).

EXAMPLE 3. Find the remainder when 2” is divided by 15.


The problem is equivalent to finding which of the fifteen residue
98 THE raroxv or CONGRUENCES § 3.2

classes modulo 15 containing 0, 1, 2, 3, . . . , 14, respectively, contains


23°. We first recognize that

2‘ E 1(mod 15).

Then, by Theorem 3.2.6,

(2“)7 E 1(mod 15);

that is,

225 : 1(mod 15).

By Theorem 3.2.2 with c = 22, we have

230 E 4(mod 15).

Hence, according to Theorem 3.1.1, the remainder when 2‘" is di-


vided by 15 is 4.

The theorems considered in this section do not exhaust those which


exist in the theory of congruences. Several additional theorems will be con-
sidered in the remaining sections of this chapter and in the exercises for this
section. However, for reference purposes we cite here an interesting and useful
theorem in the study of congruences with a composite modulus. The proof of
this theorem is left to the reader as an exercise (Exercise 10).

Theorem 3.2.9: Ifa E b(mod ml)for 1' : 1, 2, . . ., k and (m,, m5) = lfar
I
r, .9 =1, 2, ..., k where r ;é s, then a E b(mod1'[m,-).
[=1

EXERCISES

Given 9 E 5(mod 4) and 13 E —3(mod 4), (a) verify Theorem 3.2.3;


5"

(b) verify Theorem 3.2.5.


Given 10 E 4(mod 3), verify Theorem 3.2.6 where n = 5.
5".“

Given 9 E 3(mod 6) and 22 E —2(mod 6), verify Theorem 3.2.7 where r = 4


and s = 3.
Given 11 E 3(mod 8), verify Theorem 3.2.8 where P(x) = 3x‘ + 2x —— 5.
.5

Find the remainder when (a) 3’7 is divided by 26; (b) 2” is divided by 31.
9‘5"

Verify that a E b(mod d) and dlm do not imply a E “mod m).


§ 33 AN APPLICATION or THE CONGRUBNCE RELATION 99

Prove each of the following theorem:

7. Theorem 3.2.4.
8. Theorem 3.2.7.
9. Theorem 3.2.8.
10. Theorem 3.2.9.
11. If a E b(mod m) and dlm, then a E b(mod d).
12. If a E b(mod m), then (a, m) = (b, m).
13. Ifa E b(mod m.) and a E b(mod m;), then a E b(rnod [m., mfl).
14. There are an infinite number of primes p such that p E 3(mod 4).

3.3 AN APPLICATION OF THE CONGRUENCE RELATION

The study of the criteria under which a given integer is divisible by another
integer has fascinated students of mathematics for many years, and continues
to be of interest. For example, it is well knovtm that an integer is divisible by
2 if and only if the integer is even. An integer is an even integer if the units
digit is even. Therefore, the criterion under which a given integer is divisible
by 2 is that the units digit be 0, 2, 4, 6, or 8.
Since any positive integer n can be expressed in the form n 2 10k + r,
where r is a nonnegative integer such that 0 g r < 10, then 71 is divisible by
5 if 10k + r is divisible by 5; that is, ifr = 0 or r : 5. Since r represents the
units digit when n is expressed in decimal notation, the criterion under which
a given integer is divisible by 5 is that the units digit be 0 or 5.
Note that the criteria under which a given positive integer n is divisible
by another integer are the same for the negative integer in.
Special divisibility criteria under which a given integer is divisible by
another integer can be determined by means of the properties of the congru-
ence relation presented in § 3.2. However, many of the divisibility criteria are
too difficult to apply to be considered useful. In this section we shall derive
the criterion under which an integer is divisible by 9 and the criterion under
which an integer is divisible by 11.

Theorem 3.3.1: An integer expressed in decimal notation is divisible by 9 if


and only if the sum of its digits is divisible by 9.

PROOF: Every positive integer n can be expressed in decimal notation


in the form
100 THE THEORY OF CDNGRUENCES § 3.3

n=ao+a,-10+a2-102+a3-103+---+a,,-10",

where each a, is an integer such that 0 g a, < 10 and k is a positive integer.


Since

10 E 1(mod 9),

then by Theorem 3.2.6


102 E 1(mod 9),

101 E 1(mod 9),

10" E 1(mod 9);

and by Theorems 3.1.2 and 3.2.2

410 E a°(mod 9),

a, - 10 a,(mod 9),

a2 - 10z _ a2(rnod 9),

a. - 10’ a armed 9).

a, - 10" E ak(mod 9).

By Theorem 3.2.3

”a‘i’ai+az+a3+"'+”k(m°d9);

where no + a1 + a2 + a3 + ~ ~ - + 11,, represents the sum of the digits of n.


Therefore, by Theorem 3.1.1, both the positive integer n and the sum of its
digits have the same remainder when divided by 9. Hence, an integer ex-
pressed in decimal notation is divisible by 9 if and only if the sum of its digits
is divisible by 9.

EXAMPLE 1. Show that 26,356,734 is divisible by 9.


The sum of the digits of the number 26,356,734 is

2+6+3+5+6+7+3+4;
§ 3.3 AN APPLICATION or THE CONGRUENCE RELATION 101

that is, 36. Since 36 is divisible by 9, then 26,356,734 is divisible by 9.


As a check note that

26,356,734 + 9 = 2,928,526.

The rule expressed by Theorem 3.3.1 and illustrated in Example 1 is


known as “casting out nines.” The phrase is derived from the fact that, in
applying Theorem 3.3.1, any sum equal to a multiple of 9 may be "cast out”
when finding the sum of the digits of the number.

1:
Theorem 3.3.2: Let n = 2 (1i - 10‘ represent a positive integer in decimal nota-
i=0
1:

tian. Then n is divisible by 11 ifand only if: (—1)'al is divisible by 11.


i:0

PROOF: Since 10 E ——1(mod 11), then by Theorem 3.26 we obtain

102 1(mod 11),


Ill

103 —— 1(mod 11),


Ill

10‘ E 1(mcd 11),

10k E (—l)"(m0d 11).

Since
I:
n=2ai-10‘=ao+a1~10+az-101+03-103+~~-+ak-10",
i=0
we form
I
.
2(_1)i”i = “o — 111+ 17; — a3 + ' ' ' + (elf/1k
z : i=0

Now,

n — z = a,(io + 1) + a,(102 e 1)
+ ”3003 + 1) + - ~ + (2,.[10‘k e (—1)”l-
By applications of the theorems of §3.2 and the fact that 10" E (-1)‘
(mod 11), we have
102 THE THEORY or CONGRUENCES § 3.3

a,(10 +1)+ a1(101 # 1) + (13(103 + 1) + ‘ - -

+ ak[10’t — (— l)*] E 0(mod 11).

Therefore,

n — z E 0(mod11);

that is,

n E z(mod 11).

Hence, an integer expressed in decimal notation is divisible by 11 if and only


if the number formed by taking the units digit minus the tens digit plus the
hundreds digit minus the thousands digit plus ' ' - is divisible by 11.

EXAMPLE 2. Verify that 96,542 is not divisible by 11.

Since 71 = Eat-10‘ = 96,542, then no : 2, a1 = 4, :12 = 5,


a3 : 6, a, = 91,:aond

z=a0—a1+az—a3+a4

=2—4+ 5— 6+ 9

= 6.

Now, 11 X 6. Hence, 11 X 96,542.

k
EXAMPLE 3. It can be shown that if n = Z 11,- 10‘ represents 3.
i=0
positive integer in decimal notation, then u is divisible by 7 if and
only if

ao+3a1+2az—as~3a4—2as+a6

+3a7+2aaia9—3a10—2a11+--~

is divisible by 7 (Exercise 3). Verify this special divisibility criterion


for n : 64,575.
h
Sinoe n = 2 11,-10‘ = 64,575, then a0 = 5, a1 = 7, a, = 5,
i:0
03 : 4, a, = 6, and
§ 3.4 REDUCED RESIDUE SYSTEMS MODULO m 103

a0 + 3a, + 2a2 — a3 — 3a, : 5 + 3(7) + 2(5) — (4) 7 3(6)


= 14,
which is divisible by 7. Therefore, 64,575 is divisible by 7. This fact
is confirmed and the criterion for divisibility by 7 is verified by not-
ing that 64,575 + 7 : 9,225.

EXERCISES

1. Use Theorem 3.3.1 to determine whether or not each integer is divisible by 9:


(a) 374,518; (b) 1,520,397.
2. Use Theorem 3.3.2 to determine whether or not each integer is divisible by 11 :
(a) 370,546; (b) 22,481,907.

In Exerciser 3 through 6 let n : [glam-10‘ represent a positive integer in decimal

notation: ‘

3. Derive a criterion under which a positive integer is divisible by 7.


4. Derive a criterion under which a positive integer is divisible by 4.
5. Derive a criterion under which a positive integer is divisible by 6.
6. Derive a criterion under which a positive integer is divisible by 3.

7. Use Theorem 3.2.8 to prove Theorem 3.3.1.


8. Use Theorem 3.2.8 to prove Theorem 3.3.2.

3.4 REDUCED RESIDUE SYSTEMS MODULO m

In §3.l a complete residue system modulo m was defined. Quite often it is


necessary to identify the subset of a complete residue system modulo m that
contains the integers relatively prime to the modulus m. Integers relatively
prime to a modulus play an important role in number theory. For example,
consider the following theorem.

Theorem 3.4.1: If ac E bc(mod m) and (e, m) : 1, then a E b(mod m).

PROOF: If ac E bc(mod m), then by definition m|(ac 4 be); that is,


m|c(a ~ b). Since (6, m) = 1, it follows from Theorem 2.5.5 that m|(a — b).
Hence, a E b(mod m).
104 THE THEORY or CONGRUENCES § 3,4

Any subset R of the set of integers is called a reduced residue system


modulo m if
(i) (r, m) : 1 for each r contained in R;
(ii) R contains 45(m) elements;
(iii) no two elements of R are congruent modulo m.
For example, {1, 5) is a reduced residue system modulo 6 since (i) (1, 6) = 1
and (5, 6) = 1; (ii) the set {1, 5) contains ¢(6) elements, that is, two elements;
and (iii) 5 $ 1(mod 6). Similarly, (0, 1, 2, 3, 4} is a reduced residue system
modulo 5, as well as a complete residue system modulo 5. Note that any
reduced residue system modulo m is a subset of some complete residue system
modulo m. In general, if the modulus is a prime number, then each of its
reduced residue systems is also a complete residue system.

EXAMPLE 1. Determine which of the following sets are reduced


residue systems modulo 10:
(a) (23, 79, 9, 17);
(b) {9, 13, 17, 101, 43);
(c) (1,15,71;
((1) ll: 3» 7, 9);
(e) {13, ~19, *3, 11).
The sets in (a) and (d) represent reduced residue systems modulo
10. Note that for the set in (a)
(23, 10) = (—9, 10) : (9, 10) = (17, 10): 1;
the set contains ¢(10) elements, that is, four elements; and no two
elements of the set are congruent modulo 10. Similarly, for the set‘
in (d) '
(1, 10) : (3, 10) = (7, 10) = (9, 10) = l;
the set contains ¢(10) elements; and no two elements of the set are
congruent modulo 10. The set in (b) is not a reduced residue system
modulo 10 since it does not contain exactly «500) elements. Since
(5, 10) as 1, the set in (c) is not a reduced residue system modulo 10.
The set in (e) is not a reduced residue system modulo 10 since 11 E
—19(mod 10); that is, the set contains two elements which are con-
gruent modulo 10.

The following theorems concerning complete residue systems and re-


duced residue systems are required for the proofs of several important theo-
rems in §3.5, as well as for an understanding of §3.6.
§ 3.4 REDUCED RFSIDUE SYSTEMS MODULO m 105

Theorem 3.4.2: If C is a complete residue system modulo m and (a, m) = 1,


then the set

C’ : (ax + blxe C}

is a complete residue system modulo m.

PROOF: According to the definition of a complete residue system


modulo m, each integer is congruent to one and only one of the members of
the set. Assume that

ax, + b E ax2 + b(mod m)

for two members 1‘1 and x; of C. Then

4x1 5 ax1(mod m).

By Theorem 3.4.1,

x1 2 x2(mod m)

since (a, m) = 1. However, this contradicts our hypothesis that x1 and x2


are members of C since no two members of a complete residue system modulo
m are congruent. Hence,

C’ = {ax + blxe C)

is a complete residue system modulo m.

Theorem 3.4.3: If R is a reduced residue system modulo m and (a, m) = 1,


then the set

R’ = {ax|x E R)

is a reduced residue system modulo m.

PROOF: For each XER, (x, m) : 1 by the definition of a. reduced


residue system modulo m. Since (a, m) = 1, then by Theorem 245.3 we have
(ax, m) : 1. Therefore, condition (i) of the definition of a reduced residue
system modulo m is satisfied for R’. Since R’ contains the same number of
elements as R, condition (ii) of the definition of a reduced residue system
modulo m is satisfied for R’. Finally, no two members of R’ are congruent
modulo m since if
106 THE THEORY OF CONGRUENCES § 3.4

ax, E ax2(mod m)

for two members 2:, and x2 of R, then

x1 E x2(mod m).

This is contrary to the hypothesis that R is a reduced residue system modulo


m. Therefore, condition (iii) of the definition of a reduced residue system
modulo m is satisfied for R’. Hence, the set

R’ = {axlx e R)
is a reduced residue system modulo m.

Note that the set

S = (ax + blxeR},

where R is a reduced residue system modulo m and (a, m) = 1, is not neces-


sarily a reduced residue system modulo m. For example, R = (1, 3, 7, 9) is
a reduced residue system modulo 10; however, the set

S = {3x + 2|xeR),

that is,

S = (5, 11, 23, 29},

is not a reduced residue system modulo 10. The reason is that (5, 10) gé 1.

EXAMPLE 2. Verify Theorem 3.4.2 for the complete residue system


modulo 4

C :(3,4,17,6}

and the linear function ax + b where a : 3 and b = 1.


Now,

C’ : (3x +1[xe C} ={10, 13, 52,19).

Since 10 E 6(mod 4), 13 E 17(mod 4), 52 E 4(mod 4), and 19 E


3(mod 4); that is, since each element of C’ is congruent modulo 4
to a different element of C, it follows that the set
§ 314 REDUCED RESIDUE SYSTEMS MODULO m 107

C’ :(10, 13, 52,19}

is a complete residue system modulo 4.

EXAMPLE 3. Verify Theorem 3.4.3 for the reduced residue system


modulo 8

R = {1, 3, 5, 7}

and the linear function ax where a = 3.


Now,

R’ = [3x]xeR} = (3, 9, 15, 21}.

Since (3, 8): I, (9, 8) = 1, (15, 8) = 1, and (21, 8) = 1, then condi-


tion (i) of the definition of a reduced residue system iS satisfied for
R’. Obviously, condition (ii) is satisfied Since (15(8) = 4. Finally,
condition (iii) of the definition of a reduced residue system is satisfied
since no two members of R' are congruent modulo 8:

9 i 3(mod 8), 15 as 3(mod 8), 21 e 3(mod 8),


15 ¢ 9(mod 8), 21 as 9(mod 8), 21 as 15(mod 8).
Hence, R’ iS a reduced residue system modulo 8.

EXERCISES

1. Determine which of the following sets are reduced residue systems modulo 8:
(a) (11, 33, 55. 77); (b) (7, —7, 5, —5);
(C) (17, 71, 8,11); (d) {3,15, 21, 23}.
2. Determine which of the following sets are reduced residue systems modulo 5:
(a) (0.1.2, 3,4); (b) {1, -2, 3, —4);
(C) {16, 9, —Z, 7); (d) {6, 11.16.21}.
3. Verify Theorem 3.4.2 for the complete residue system modulo 6
C = (7, 74, 9, 4, 17, 0)
and the linear function ax + b where a = 5 and b = 2.
Verify Theorem 3.4.3 for the reduced residue system modulo 12
.3

R = {1, 5,19, 23)


and the linear function ax where a = 7.

In Exercise: 5 through 10 let [x] represent the residue clam modulo m to which the
integer x belongs; Iet addition (9 and multiplication ® be defined on the set ofresidue
108 11-115 THEORY OF CONGRUENCES § 3.5

classes such that [a] (-D [b] = [a + b] and [a] ® [b] = [a X b]. Construct the addi-
tion and multiplication tables for each modulo system. Determine whether or not
each system is an integral domain:

5. Module 2. 6. Module 3.
7. Modulo 4. 8. Module 5.
9. Module 6. 10. Modulo 7.

11. Use the results of Exercises 5 through 10 to make a conjecture about modulo
systems that are integral domains.
12. Show that the modulo 5 system is not an ordered integral domain.

3.5 THE THEOREMS 0F EULER AND FERMAT

Theorem 3.5.1 (Euler’s Theorem): If (a, m) = 1, then

aw") E 1(mod m).

PROOF: Let

R ={r1, r2, r3, 1 . ., am}

he a reduced residue system module In. Consider the set of ¢(m) integers

R' : {urn arz, ars, . . ., MW“)

where (a, m) : 1. This set is also a reduced residue system modulo m by


Theorem 3.4.3. Therefore, each element of R’ is congruent to a different
element of R; that is, arl, arz, ars, .. ., and arflm are congruent to r1, r1,
r3, . i ., and Wm): but not necessarily in the order of appearance. Then

zzr1 E r1(mod m),

: r5(mod m),
nx
I
s:

m. a rs(mod m),

”Mm E dammed m):


where r1, r5, r3, . . i, and 4,0”) are r1, r2, r3, . . ., and W...) in some rearranged
order. By repeated applications of Theorem 3.2.5,
§3.5 THE THEOREMS or EULER AND FERMAT 109

arlarzar3 - ' ‘ Wan.) E rirgrg - - - ré(m)(mod m)

rlrzr3 - - ‘ r¢(m)(mod m),

and

:1" ( ")rlrzrs _. . rflm) =


_ rlrzr3 . . . r,(m)(mod m).

Since (ri, m) = 1 for i = 1, 2, 3, . . ., dz(m), then by Theorem 2.5.4

(’1’1r3“"o(m)s m) = 1-

Hence, by Theorem 3.4.1,

11“”) E 1(mod m).

EXAMLE 1. Verify Euler’s Theorem for a = 7 and m 2 12.


. Note first of all that (7, 12) = 1. Since ¢(12) = 4, then 7‘02) 2
7‘ = 2401. Hence,

7“”) E 1(mod 12)

since 12|(2401 ~ 1).

HAMPLE 2. Use Euler’s Theorem to show that the solution of the


linear congruence

ax E b(mod m),

where (a, m) = 1, is

x E a¢"")‘1b(mod m).

If (a, m) = 1, then according to Euler’s Theorem

aw") E 1(mod m).


By Theorem 3.2.2,

a¢("‘)b E b(mod m).

By the symmetric and transitive properties of the congruence relation


modulo m (Theorem 3.1.2),

ax E a¢("‘)b(mod m),
110 THE THEORY or CONGRUENCES ' § 3.5

whereby

x E a¢""’"b(mod m)

since (a, m) : 1. Hence, we have a solution of the given linear


congruence. In §3.6 we shall show that such a solution is the only
incangruent solution (Theorem 3.6.1). Obviously an infinite number
of congruent solutions exist if at least one solution exists.

As an illustration of the results of this example, consider the linear


congruence

3x E 5(mod 8).

Since (3, 8) = 1, the solution of the linear congruence is

x E 34“”1 - 5(mod 8)
34’1 - 5(mod 8)

a 135(mod 8);

that is,

x E 7(mod 8).

CheCk: 3 - 7 E 5(mod 8) since 8|(3 - 7 — 5).

In the 17th century the great French mathematician Pierre de Fermat


discovered the following theorem while studying the properties of perfect
numbers. It is a special case of Euler‘s Theorem. (Euler proved his theorem
late in the 18th century as a generalization of Fermat’s Theorem.)

Theorem 3.5.2 (Fermat’s Theorem): If p m a prime and (a, p) = 1, then

0"“ E 1(modp).

PROOF: Since (a, p) = l, by Euler’s Theorem

0“!” E 1(mod p).

Up is a prime, then (15(1)) E p — 1 and

a!"1 E 1(mod p).


§ 3.5 THE THEOREMS or EULER AND FERMAT 111

An equivalent form of Fermat’s Theorem is the statement of Theorem


3.5.3.

Theorem 3.5.3: If p is a prime, then a” E a(mod p) for any integer a.

PROOF: Now, eitherpla orp X a. If}: 4’ a, then (a, p) : 1 and we know


from Theorem 3.5.2 that

a?“ E 1(mod p).

Therefore, we have by Theorem 3.2.2

a” E a(mod 11).

If pla, then

a E 0(mod p),

and by Theorem 3.2.6

11" E 0(mod p).

Hence, by the symmetric and transitive properties of the congruence relation


modulo 1) (Theorem 3.1.2),

a” E a(mod 1:).

EXAMPLE 3. Verify Fermat’s Theorem for a : 3 and p = 7.


Note first ofall that (3, 7) : 1. Sincep — 1 : 6, then up" : 36
= 729, and 7|(729 E 1). Hence,

36 E 1(mod 7);

that is,

a?" E 1(modp)

where a = 3 andp = 7.

EXAMPLE 4. Verify that one of the converses of Fermat’s Theorem


is not valid.
A statement of the form "if A and B, then C,” where A, B, and
C are propositions, has two converses. One converse is of the form
112 THE THEORY or CONGRUENCES § 3.5

“if A and C, then B"; a second converse is of the form “if C and B,
then A.” Therefore, one converse of Fermat’s Theorem is “if p is a
prime and a‘“1 E 1(mod p), then (a, p) 2 1." This converse is valid
and its proof is left to the reader as an exercise (Exercise 16). The
second converse of Fermat's Theorem is "if a'”1 E 1(mod p) and
(a, p) = 1, then p is a prime." This converse is not valid since, for
example, 53 E 1(mod 4) and (5, 4) = 1, but 4 is not a prime.

EXAMPLE 5. Prove that n5 and n have the same units digit, where
h is any integer.
Now, n5 and n will have the same units digit if n5 E n(mod 10).
By Theorem 3.5.3,

n5 E n(mod 5)

for any integer n. Furthermore,

n5—n=n(n‘7 l)

= M — 1x»1 + 1)
= n(n — 1X" + 1X"2 + 1)
for any integer 71. Therefore n5 — n is an even number since it con-
tains two consecutive integers, n and n + l, as factors; that is,

n5 E n(mod 2).

Hence, since (2, 5) = 1, it follows from Theorem 3.2.9 that

n5 E n(mod 10)
for any integer n.

EXERCI S E S

1. Verify Euler’s Theorem for a = 3 and m 2 10.

In Exercise: 2 through 7 use Euler’s Theorem :9 find a solution of each linear can-
gmence: 1,
:1 > )7 \\ *
2. 5x 2 7(mod 12). 7 ' I 3. 2x : 3(mod 9).
W
4. 7x a 1(mod 10). Erll * 5. 8x a 4(mod 5).
6. 22: E 1(mod 17). 7. 5x E —3(mod 8).
§ 3.6 LINEAR CONGRUENCES 113

8. Verify Fermat’s Theorem for a = 2 and p = 13.


9. Prove Fermat’s Theorem by using the congruence (a + 1)’ E a” + l(mod p)
where p is a. prime and ((1,1)) 2 1.
10. Prove Fermat’s Theorem by expanding (1 + 1 + - - ~ + 1)” where p is a prime.

Prove that each congruence is valid/or any integer x:

11. x” E x(mod 7). 12. x“ E x(mod 13).

In Exercises 13 and 14 find all the incangruent solutions of each congruence:

13. x5 E 1(mod 11). 14. x' E 1(mod17).

15. Find a polynomial congruence of lower degree that is equivalent to the poly-
nomial congruence
3x“ + 2x” + 7x”— 2):“ E 0(mod 7).
16. Prove that if p is a prime and a"" E 1(mod p), then (a, p) = 1.
l7. Prove that if p is a prime, then
‘1’" + 2'H + 3"" +-~ + (p — 1)"' +1 E 0(modp).

3.6 LINEAR CONGR UENCES

In Example 2 of § 3.5 we employed Fermat's Theorem to obtain the solution


of a linear congruence. A linear congruence modulo m is a statement of the
form ax E b(rnod m), where m X a.
Note that if x1 is an integer that satisfies the linear congruence ax E
b(mod m), then x1 + km where k is any integer also satisfies the linear con-
gruence. Furthermore, x1 + km E x1(mod m); that is, if x1 satisfies a linear
congruence modulo m, then every member of the residue class modulo m to
which x1 belongs satisfies the linear congruence. Integers that satisfy a given
linear congruence modulo m and belong to different residue classes modulo
m are called incongruent solutions; integers that satisfy a given linear congru-
ence modulo m and belong to the same residue class are called congruent
solutions. As a matter of convention, the solution set of a linear congruence is
said to consist of exactly one representative of each of the different residue
classes modulo m whose members satisfy the linear congruence. That is, the
incongruent solutions which belong to any complete residue system modulo
m constitute a solution set. In one sense, it is actually certain residue classes
that are solutions of a given linear congruence modulo 'm.
If the modulus m of a linear congruence is a relatively small positive
integer, the incongruent solutions can always be determined conveniently by
114 THE THEORY or CONGRUENcas 3 § 3.6

trial and error. For example, consider the linear congruence 5x E 2(mod 6).
By actual substitutions, in turn, of 0, 1, 2, 3, 4, and 5 for x, we find that
only 4 satisfies the linear congruence; that is, 5 -4 E 2(mod 6). Hence,
x E 4(mod 6) is the only incongruent solution. Note that every member of the
equivalence class or residue class modulo 6 to which 4 belongs satisfies the
given linear congruence, and these members represent congruent solutions.
Not every linear congruence need have a solution. Furthermore, not
every linear congruence that has a solution need have only one incongruent
solution. For example, by trial and error we can easily show that the linear
congruence 2): E 3(mod 4) has no solutions, while the linear congruence
2x E 6(mod 8) has exactly two incongruent solutions: )5 E 3(mod 8) and
x E 7(mod 8).
In this section we will examine different methods of obtaining the in-
congruent solutions of a linear congruence. We will also determine an answer
to the question of how many incongruent solutions of a given linear congru-
ence exist.

Theorem 3.6.1: If (a, m) = 1, then the linear congruence ax E b(n10d m)


has exactly one incongruent solution.

PROOF: Let C represent any complete residue system modulo m. By


Theorem 3.4.2, the set (axlx e C ) is also a complete residue system modulo
m. Therefore, there exists only one element x0 5 C such that axo is congru-
ent modulo m to a ‘given integer b. Hence, the linear congruence ax E b
(mod m), where (a, m) E 1, has exactly one incongruent solution x E x0
(mod m).

Note that by Euler’s Theorem, if the linear congruence ax E b(mod m)


has a unique solution, the solution is of the form x E a“"""b(rnod m).
The following theorem is a generalization of Theorem 3.4.1; it is ex-
tremely useful in one approach to obtaining the incongruent solutions of a
linear congruence.

Theorem 3.6.2: Ifac E bc(mod m) and (c, m) : g, then a E b(mod m/g).

PROOF: If ac E bc(rnod m), then m1(ac E be); that is, m|c(a E b). If
(c, m) : g, then c = gc' and m : gm’. Now,
§ 3.6 LINEAR CONGRUENCES 115

gm’lgc’(a ~ b),

m’lc’(a — b),

where (c’, m’) = 1. Therefore,

m’|(a — b).

Hence,

a E b(mod m’);

that is,

a E b(mod m/g).

As an illustration of Theorem 3.6.2, note that if

114 E 66(mod 16),

then

19 E 11(mod 8)

since (6, 16) = 2. However, note that

19 ,=s 11(mod16)4

EXAMPLE 1. Solve the linear congruence

36x 2 53(mod 131).

Since (36, 131) = 1, then by Theorem 3.6.1 the given linear


congruence has exactly one incongruent solution. Since 53 E —78
(mod 131), then by the transitive property of the congruence relation

36x E 778(mod 131).

By Theorem 3.6.2,

6x E ——13(mod 131).

Using the symmetric and transitive properties of the congruence


relation and the fact that 7144 .=_ —13(mod 131), we obtain
116 THE Tawny OF CONGRUENCES § 3.6

6;: E 7144(mod 131).

Once again, by Theorem 3.6.2,

x E —24(mod 131),

and
x E 107(mod 131).

EXAMPLE 2. Solve 11x 5 25(mod 60).


Since (11, 60): 1, then by Theorem 3.6.1 the given linear
congruence has exactly one incongruent solution. Now, x must be
a multiple of 5 since

11x = 25 + 60k

for some integer k and (25, 60) = 5. Let x = 5y. Then

11 - 5y 2 25(mod 60).

By Theorem 3.6.2 and the properties of the congruence relation,

11y E 5(mod 12),

~y E 5(mod 12),

E —5(mod 12),

y E 7(mod 12).

Therefore, x = 5y = 35. Hence,

x E 35(mod 60).

The question of how many incongruent solutions exist in general for a


given linear congruence is answered by the next theorem.

Theorem 3.6.3: The linear congruence ax E b(mod m) has exactly g incon-


gruent solutions, where g : (a, m), if and only if glb. If gl’ b, then the
linear congruence has no solutions.

Pnoor: By definition the linear congruence ox E b(mod m) implies


§ 3.6 LINEAR CONGRUENcas 117

ax = b + km, where k is an integer; that is, ax — km = b. Now, any divisor


of a and m must divide b. Hence, if (a, m) = g, no solution exists if g X b.
If glb, then

a 2 ga’, m : gm’, and b = gb’,

where (a’, m’) = 1. By Theorem 3.6.2, since (m, g) = g,

a’x E b’(mod m’). (3.6.1)

Since (a’, m’ : 1, there exists exactly one incongruent solution

x E xo(mod m')

of this linear congruence. Obviously, every solution of linear congruence


(3.6.1) is also a solution of the given linear congruence

ax E b(mod m). (3.6.2)

The congruent solutions of linear congruence (3.6.1) are of the form

x 5 x0 + tm’(mod m’),

where tis an integer. Not all the integers of the form x0 + tm’ are congruent
modulo m. Those integers of the form x0 + tm’ that are incongruent modulo
m constitute incongruent solutions of the given linear congruence (3.6.2). To
determine what values of t yield incongruent solutions of linear congruence
(3.6.2), let
x0 + t1m’ 2 x0 + tzm’(mod m).

Then, by Theorems 3.2.1 and 3.6.2,

tlm’ E tzm’(mod m)

and

r. a rz<modg),
respectively. Therefore, when t ranges over the values of the complete residue
system {0, l, 2, . . ., g — 1} modulo g, the integers of the form x0 + tm’
represent different residue classes modulo m. Hence, since m’ : m/g, the g
incongruent solutions of the given linear congruence ax E b(mod m) are of
the form

x0, x0 + m/g, x0 + 2M/g. . . -, X0 + (g A DWI/g. (3-6-3)


118 THE THEORY or CONGRUENCES § 3.6

where x0 is the incongruent solution of linear congmence (3.6.1) and g :


(a, m).
Since every integer of the form x0 + tm', where t is an integer, is con-
gruent modulo m to one and only one of the integers of statement (3.6.3),
it follows that the integers of (3.6.3) represent the only solutions of the given
linear congruence ax E b(mod m).

EXAMPLE 3. Find the incongruent solutions of the linear congru-


ence
64): E 16(mod 84).

Since (64, 84) = 4 and 4|16, then by Theorem 3.6.3 there are
exactly four incongruent solutions modulo 84. By Theorem 3.6.2,

4x E 1(mod 21)

since (64, 16) = 16, (16, 84) : 4, and 84/4 = 21. By Theorem 3.6.2
and the properties of the congruence relation,

4x 5 720(mod 21),

x E —5(mod 21),

x E 16(mod 21).

Therefore, by the results of Theorem 3.6.3, the four incongruent


solutions in the complete residue system modulo 84 of least nonnega-
tive integers {0, l, 2, . . ., 83) are the integers of the form 16 + 21!,
where t : 0, l, 2, and 3. Hence, the solution set is

{16, 37, 58, 79};

that is, the incongruent solutions are x E 16(mod 84), x E 37


(mod 84), x E 58(mod 84), and x E 79(mod 84).

EXAMPLE 4. Solve 7x 2 9(rnod 21).


Since (7, 21) = 7 and 74/ 9, no solutions of the given linear
congruence exist.

EXAMPLE 5. Find the incongruent solutions of the linear congru-


ence
§ 3.6 LINEAR CONGRUENCES 119

21): a 15(mod 39)


by use of Euclid’s algorithm.
Since (21, 39) = 3 and 3|15, then by Theorem 3.6.3 there are
exactly three ineongruent solutions modulo 39. By means of Euclid’s
algorithm,

39=l-21+18,

21=1-18+3,

18:6-3.

Then

3:2171-18

:21—(39—1-21)

=2-21+(71)~39,

and

15 : 10-21 + (73-39.
Therefore, converting this last statement to a congruence statement,

21-10 E 15(mod 39);

that is,

x E 10(mod 39)

is one solution of the given linear congruence. Since (21, 15) : 3


and 39/(39, 3) = 13, it follows from Theorem 3.6.3 that the incongru—
ent solutions differ by 13. Hence,

x E 23(mod 39)

and

x E 36(mod 39)

represent the other two incongruent solutions of the given linear


congruence.
120 THE THEORY or CONGRUENCi-‘s § 3.7

EXERCISES

Find a set of incongruent solution: of each linear congruence:

1. 14): E 11(mod 5). 2. 6x E 8(mod 20).


3. 12): E 98(mod 20). 4. 3x E 10(mod 14).
5. 8;: E 16(mod 12). 6. 23x E 8(mod 17).
7. 11x E 715(mod 10). 8. 12x E 17(mod 27).
9. 25;: E 13(mod 60). 10. 14x E 36(mod 48).
11. 4x E 3 E 6(mod 7). 12. 3x + 6 E 5(mod 11).
13. 32x E 28(mod 36). 14. 5x E —20(mod 125).
15. 6): E 15(mod 21). 16. 7x 5 14(mod 21).
17. 49): E 23(mod 25). 18. 22:: E 77(mod 121).
19. 15): E 30(mod 60). 20. 51x E 9(mod 54).

3.7 LINEAR CONGRUENCES


AND LINEAR DIOPHANTINE EQUATIONS

The theory of linear congruences can be used to derive the form of the solu-
tions, if they exist, of the linear Diophantine equation

ax + by = 0. (3.7.1)

Determining the solutions of this linear Diophantine equation is equivalent


to determining the solutions of the linear congruence

ax E C(mod b). (3.7.2)

By Theorem 3.6.3, if g = (a, b), then a solution of this linear congruence


exists if gin. Every solution of linear congruence (3.7.2) is of the form

x0 + gt, (3.7.3)
where Jr0 is a particular solution and t is an integer. By a substitution of the
integer expressed in (3.7.3) for x in equation (3.7.1), the form of the values
of y satisfying the linear Diophantine equation can be obtained. Therefore,

—t b=,
a(x0 + g)ec
b
§ 3.7 LINEAR CONGRUENCBZ AND LINEAR DIOPHANTINE EQUATIONS 121

and

c 7 a(x° + E!)
y: b

awnfl,
_ b g

a
=yo‘gty

where yu is such that ax0 + byo : c. Hence, if x0 and yo satisfy the linear
Diophantine equation ax + by = c, then every solution x and y is given by
the equations

b a
x : x0 + E! and y : yo a Et’ (3.7.4)

where g = (a, b) and t is an integer. The results here agree with the results
of § 2.6.

EXAMPLE 1. Use linear congruences to determine a particular solu-


tion of the linear Diophantine equation

48): + 7y = 17.

Since (48, 7) = 1, solutions of the linear Diophantine equation


48x + 7y = 17 exist. To determine a particular solution of the equa-
tion, we first determine a solution of an equivalent linear congruence:

48): E 17(mod 7),

—x E 17(mod 7),

—x E 3(mod 7),

x E 73(mod 7),

x E 4(rnod 7).

Now, substituting 4 for x in the given Diophantine equation, we


obtain
122 THE THEORY OF CONGRUENCES § 3.7

48-(4)+7y= 17,
192 + 7y = 17,

7y : #175,

y = —25.

Hence, 4 and —25 is a particular solution of the linear Diophantine


equation 48.x + 7y 2 17.

EXAMPLE 2. Use linear congruences to determine the general solu-


tion of the linear Diophantine equation
11): 7 30y : 29.

Since (11, —30) = 1, solutions of the linear Diophantine equa-


tion 11): — 30y = 29 exist. Now,

730y E 29(mod 11),

3y E 29(mod ll),

3y E 18(mod 11),

y E 6(mod 11);

substituting 6 for y in the given Diophantine equation,

11): — 30-(6) : 29,

11): — 180 = 29,

11x : 209,

x : 19.

Hence, by (3.7.4), the general solution of the linear Diophantine


equation 11;: — 30y = 29 is given by the equations

x:19—30t and y=6711t,

where t is an integer.

The theory of linear congruences can also be used to derive solutions,


§ 3.7 LINEAR CONGRUENCB AND LINEAR DIOPHANTINE EQUATIONS 123

if they exist, of linear Diophantine equations in more than two variables.


The procedure is illustrated in the next example.

EXAMPLE 3. Use linear congruences to determine the general solu-


tion of the linear Diophantine equation

8x—5y+7z=21.

The linear Diophantine equation 8;: _ 5y + 72 = 21 is equiva-


lent to the linear congruence

8:: ~ 5y 5 21(mod 7),

x 7 5y 5 21(mod 7),

x 7 5y E 0(mod 7),

x E 5y(mod 7).

Thus, if y = m, then x = 5m + 7n, where m and n are integers.


Substituting 5m + 7n and m for x and y, respectively, in the given
Diophantine equation,

8(5m + 7n) — 5(m) + 72 : 21,

40m+56n—5m+7z:21,

7z : 21 — 35m — 56n,

z = 3 — 5m — 871.

Hence, the general solution of the linear Diophantine equation


8x — 5y + 72 : 21 is given by the equations

x=5m+7n, yzm, and 2:375m78n,

where m and n are integers.

It is possible to establish necessary and sufficient conditions for a


linear Diophantine equation in three variables to have a solution. The follow-
ing theorem is analogous to Theorem 2.6.1. Its proof is left as an exercise
(Exercise 15).

Theorem 3.7.1: The linear Diaphantine equation


124 THE THEORY or CONGRUENCES § 3.8

ax+by+cz=d

hat a rolun'an ifand only ifgld where g = (a, b, e).

EXERCISES

In Exercise: I through 12 use linear congruences to determine the general solution of


each linear Diophantine equation:

l.7x+6y=9. 2.11x+27y=4.
3. 75): — l31y = 6. 4. 39:: + 26y = 104.
5. 61:: — 11y = 81. 6. 65x + 77y = 200.
7. 51x + 85y = 1037. 8. 1586): — 806y = 338.
9.7x—11y+9z=37. 10.3x—2y+4z:34.
11. 144;: — 90y + 60z = 78. 12. 20;: + 44y — 322 = 34.

13. A corporation wants to buy a fleet of one hundred automobiles for exactly
$250,000. If automobiles of type A cost $2600 each, type B cost $2100 each,
and type C cost $1800 each, how many of each type should the corporation
purchase?
14. A group of twenty men, women, and children spent $50 at a restaurant. If
each man spent $5, each woman 53, and each child $1, how many men were
in the group?
15. Prove Theorem 3.7.1.

3.8 WILSON’S THEOREM

One of the most celebrated theorems in number theory is due to Wilson, a


pupil of the English algebraist Waring. Waring reported it in 1770; the French
mathematician Lagrange was the first to prove the theorem in that same year.
However, Leibniz apparently made the observation first, a century earlier.

Theorem 3.8.1 (Wilson’s Theorem): Ifp is a prime, then

(p — l)! + 1 E 0(modp). (3.8.1)

PROOF: Let p be any prime. By Fermat’s Theorem, the congruence

xp" 5 1(modp),
that is,
§ 3.8 WILSON'S THEOREM 125

x?" — l E 0(modp),

has 11 7 l incongruent solutions 1, 2, 3, . . ., p — 1. Therefore,

x"“1 71 E(x 7 1)(x — 2)(x 7 3) - - - [x — (p 71)](modp).

Now, any value of x satisfies this congruence. If we let x = 0, then

715(—1)H-1-2-3 ----- (p—l)(modp);


that is,

(4)1441, 71)!+1E 0(modp).


Since )7 is a prime, p is either an odd number or equal to 2. If p is odd, then
(—1)"'1 : l and

(p 71)!+ l a 0(mod p);

ifp : 2, then (41y:-1 : 71,7121(mod 2), and


(p7 1)1+ 1 a 0(modp).
Thus, congruence (3.8.1) is valid for any prime p.

Theorem 3.8.2 is the converse of Wilson’s Theorem.

Theorem 3.8.2: If (n 7 l)! + l E 0(mod n), then n is a prime.

PROOF: Assume that n is a composite number. Then there exists a


divisor d of n such that 1 < a' < 71. Furthermore, since d is a factor of
1 . 2 . 3 ..... (n _ 1),

(n 71)! E 0(mod d)

and
(n — 1)! + 1 gé 0(mod d).

Hence,

(n — l)! + 1 ,=é 0(mod n).

Thus, from this contradiction of the hypothesis of the theorem, it follows


that n is a prime.
126 THE THEORY or CONGRUENCES § 3.8

Collectively, Wilson’s Theorem and its converse represent a necessary


and suflicient condition for an integer to be a prime. However, the test is
impractical for large integral values.

EXAMPLE 1. Verify Wilson's Theorem for p = 7.


Now, (7 — 1)!+1 = 6! + 1 = 720 +1: 721. Since 7|721,
then
(p— 1)! + 1 E 0(modp)

where p = 7.

EXAMPLE 2. Prove that if n is not a prime, then (7: — 1)! + 1 is


not a power of n.
We shall prove the contrapositive of the given statement. Assume
that (n — l)! + 1 : n", where k is a positive integer. Since n* E 0
(mod n), then

(n — 1)! + l E 0(rnod n).

Hence, by the converse of Wilson’s Theorem (Theorem 3.8.2), It is


a prime. Therefore, if n is not aprime, then (71 — 1)! + 1 is not a
power of n.

An interesting and quite different proof of Wilson’s Theorem based upon


the concept of associates can be presented. Let k be any integer such that
1 < k < p — 1, where p is a prime. Then (k, p) = 1 for all such integers k.
By Theorem 3.6.1, the linear congruence

kx E 1(mod p)

has exactly one incongruent solution. If we let j denote the solution, then k
and j are called associates of p. Since 1 < k <p — 1, then (p, k + 1) =
(p, k — 1): 1. By Theorem 2.5.3, (p,k2 — 1) : 1 2:1nd,iz,}’(k2 — 1). Thus,
each k is different from its associate, for if k were equal to j, then

k2 E 1(mod p),

kZ—l «mod p).


£1.ndp|(k2 — 1). Hence, the integers from 2 through 1; — 2 can be paired as
§ 3.8 WILSON’s THEOREM 127

associates k. and jl, k2 and 1'1, . . ., k,, and j” such that

ktj1 E 1(modp), kzjz E 1(modp), . . ., knj,I E 1(modp).

Then

kljlkzjz ' ' ‘16.]. E 1(1110d p),


2-3 ----- (p72)E 1(modp),

(P —1)!EP -1(m°dp).
(P —1)!5 —1(modp),
(p — 1)! + 1 E 0(modp).

EXAMPLE 3. Verify Wilson’s Theorem for p = 13.


‘ The associates ofp, wherep = 13, are 2 and 7, 3 and 9, 4 and
10, 5 and 8, and 6 and 11; that is, 2-7E1(mod13), 3-9 E 1
(mod 13), 4- 10 E 1(mod 13), 5-8 E 1(mod 13), and 6-11 E 1
(mod 13). Therefore,

2.3.4.5-6-7-8-9-10-11 E 1(rnod 13),

12! E 12(mod 13),

12! E —1(mod13),

121+ 1 E 0(mod 13).

Hence,

(p — l)!1L 1 E 0(modp)

wherep = 13.

Gauss generalized Wilson’s Theorem to obtain the following result


which will be presented here Without proof.

Theorem 3.8.3: Let P represent the product of the positive integers less than
some integer n and relatively prime to n. If n equals 4, p", or 2p" where p
is an odd prime and k is a positive integer, then
128 THE THEORY or CONGRUENCES § 3.8

1’ +1 E 0(mod n);

for other values of n,

P — 1 E 0(mod n).

EXAMPLE 4. Verify Theorem 3.8.3 for n : 24.

Since 24:23-3, then ¢(24)=241—% 1—%)=8 and


P:1-5-7-11-13 - 17- 19'23.Notethat24isnotoftheforrnp‘t or
2p", where p is an odd prime and k is a positive integer; obviously,
24 aé 4. Hence, we need to show that P E 1 E 0(mod 24). Now,

1'23 E ——1(mod 24);

5 ' 19 E —1(mod 24);

7 - 17 E 71(mod 24);

11-13 E —1(mod 24).

Therefore,

1'5-7-11-13-17-19-23 E 1(mod24),

P E 1(mod 24),

P E 1 E 0(mod 24).

EXAMPLE 5. Verify Theorem 3.8.3 for n = 18.

Since 18 =2-32, then 41(13): 18(1 —1) 1—1) =6 and


2 3
P =1- 5 - 7 -11-13 - 17. Note that 18 can be expressed in the form
2p“, where p is an odd prime and k is a positive integer. Hence, we
need to show that P + 1 E 0(mod 18). Now,

1.17 _ —1(rnod 18);


5-7 E1(mod 18);

11-13 _ —1(mod 18).


1|

Therefore
§ 3.9 LINEAR CONGRUENCES IN_ "two VARIABLES 129

1'5'7-11-13-17 E —1(mod18),

E 71(mod18),

P + 1 E 0(rnod 18).

EXERCISES

1. Verify Wilson’s Theorem for p = 5‘


2. Use the converse of Wilson’s Theorem to show that 19 is a prime.
3. Use Wilson’s Theorem to show that 8 is not a prime.
4. Use the concept of associates to verify Wilson's Theorem for (a) 1; =17;
(b) p = 31.
5. Determine all the values of p such that (p — 1)! + 1 is a power of p.
6. Verify Theorem 3.8.3 for (a) n = 54; (b) n = 120.
7. Show that 18! + 1 E 0(mod 437).
8. Prove that if p is a prime, then

(1: 7 1)! sp — 1(mod:2;1:n).


Prove that the solution of the linear congnience ax E 1(mod p) is congruent
2‘

to a if and only ifa ‘5 1(mod p) or a E p — 1(mod p).


10. Prove that ifp is a prime of the form 4n + 1 where n is a positive integer, then
[(2:1) 11’ E *1(m0d11).
11. Prove that (p 7 q)! (q 7 1)! E (—1)”(mod p) wherep is an odd prime and q
is a positive integer less than or equal to p.

3.9 LINEAR CONGRUENCES IN TWO VARIABLES

It should be evident that linear congruences in any number of variables exist.


In this section we shall consider linear congruences modulo m in two vari-
ables; that is, linear congruences of the form

ax + by E c(mod m). (3.9.1)

If x, and y1 are integers that satisfy linear congruence (3.9.1), then this solu-
tion is usually represented as an ordered pair of integers (x1, yl). Furthermore,
note that if (x,, yl) is a solution of the linear congruence, then (x1 + km,
y1 + tm) is a solution where k and t are integers. The solutions (x1, y!) and
(x1 + km. y1 + m) are congruent mlutionr. Those solutions for which either
130 11-15 THEORY or CONGRUENCES § 3.9

the x values or the y values belong to different residue classes modulo m,


respectively, are intongruent solutions of linear congruence (3.9.1).

Theorem 3.9.1: The linear congruence ax + by E C(mod m) has solutions if


and only z'fglc where g : (a, b, m).

PROOF: The given linear congruence can be written as

by E e —— ax(mod m). (3.9.2)

By Theorem 3.6.3, linear congruence (3.9.2) has solutions if and only if


(b, "01(6 ~ ax); that is, if and only if
ax E e(mod(b, m)). (3.9.3)

Similarly, by Theorem 3.6.3, linear congruence (3.9.3) has solutions if and


only if (a, (b, m))lc. Since (a, (b, m)) = (a, b, m) by Theorem 2.4.1,

ax + by E c(mod m)

has solutions if and only if glc where g = (a, b, m).

The method of proof of Theorem 3.9.1 can be used to find the solutions
of a linear congruence in two variables as illustrated in Example 1.

EXAMPLE 1. Solve the linear congruence

3x — 7y E 11(mod 13).

Since (3, 7, 13) = 1, then by Theorem 3.9.1 the given linear


congruence has solutions. The linear congruence can be written as

3x E 11 + 7y(mod 13),

3x E 24 — 6y(rnod 13),

x E 8 7 2y(mod 13).

Each incongruent Value of y modulo 13 will yield exactly one in-


congruent value of x modulo 13. Thus, the incongruent solutions are
the ordered pairs of integers (8, 0), (6, 1), (4, 2), (2, 3), (0, 4), (ll, 5),
(9, 6), (7, 7), (5, 8), (3, 9), (1, 10), (12, 11), and (10, 12).
§ 3.9 LINEAR CONGRUENCES IN TWO VARIABLES 131

Significantly, there are exactly thirteen incongruent solutions modulo


13 of the linear congruence of Example 1. Theorem 3.9.2 is analogous to
Theorem 3.6.1.

Theorem 3.9.2: If (a, m): 1 or (b, m) 2 1, than the linear congruence


ax + by E C(mod m) has exactly m incongrucnt solutions.

PROOF: There is no loss of generality in assuming that (a, m) = 1. Now,


the given linear congruence can be written as

ax E c — by(mod m). (3.9.4)

By Theorem 3.6.1, linear congruence (3.9.4) has exactly one ineongruent


solution x for each incongruent value of y. Since there are exactly m incon-
gruent values of y modulo m, there are exactly m incongruent solutions
(x, y) that. satisfy the given linear congruence.

EXAMPLE 2. Find the incongruent solutions of the linear congru-


ence

7x + 8y E 6(rnod 10).

Since (7, 10) : 1, then by Theorem 3.9.2 the given linear congru-
ence has exactly ten incongruent solutions. The linear congruence
can be written as

7x E 6 7 8y(mod 10),

~3x E 6 — 18y(mod 10),

x E —2 + 6y(mod 10),

x E 8 + 6y(rnod 10).

Thus, letting y : 0, 1, 2, . . ., 9, the ten incongruent solutions are


the ordered pairs (8,0), (4, 1), (0, 2), (6, 3), (2,4), (8, 5), (4, 6), (0, 7),
(6, 8), and (2, 9).
Note that (8, 0) and (8, 5) are considered incongruent solutions,
although x = 8 in each case, since 0 and 5 represent different residue
classes for y. Similarly, (4, 1) and (4, 6), (0, 2) and (0, 7), (6, 3) and
(6, 8), and (2, 4) and (2, 9) are pairs of incongruent solutions.
132 THE THEORY or CONGRUENCES § 3.9

In Examples 1 and 2, at least one of the coefficients of x and y was rela—


tively prime to the modulus. Example 3 illustrates how the solution procedure
changes slightly when neither coefficient is relatively prime to the modulus.

EXAMPLE 3. Find the incongruent solutions of the linear congru-


ence
3x + 4y E 7(mod 12).

Since (3, 4, 12) = 1, then by Theorem 3.9.1 the given linear


congruence has solutions. However, since (3, 12) aé 1 and (4, 12) aé
1, we cannot make any statement at this time about the number of
incongruent solutions. Since the given linear congruence can be
written as 3x 5 7 —~ 4y(mod 12) and (3, 12) : 3, values of x that
satisfy the congruence exist for those values of y for which 3[(7 —— 4y).
Thus, we consider

4y E 7(m0d 3),

y E 7(mod 3),

y E 1(mod 3).

Now, 1 is the only incongruent solution modulo 3. However, since


the modulus of the given linear congruence is 12, the congruent solu-
tions 1, 4, 7, and 10 fory E 1(mod 3) are incongruent modulo 12.
Since any two of these numbers difl‘er by a multiple of 3,'and since
4(3) is a multiple of 12, each of these values yields the same solution
for x in the given linear congruence. Thus,

3x 5 3(mod 12),

x E 1(mod 4).

Now, 1 is the only incongruent solution modulo 4. However, the


congruent solutions 1, S, and 9 for x 2 1(mod 4) are incongruent
modulo 12.
Therefore, for each value of y, where y : l, 4, 7, 10, there exists
a corresponding value of x, where x = l,_ 5, 9. Hence, the incongruent
solutions are the ordered pairs (1, 1), (5, 1), (9, 1), (1, 4), (5, 4), (9, 4),
(1, 7), (5, D, (9, 7), (l, 10), (5, 10), and (9, 10).

The procedure followed in Example 3 suggests the method of proof of


§ 3.9 LINEAR CONGRUENCES IN Two VARIABLES 133

the following important theorem which is analogous to Theorem 3.6.3.

Theorem 3.9.3: The linear congruence ax + by E c(mod m) has exactly gm


incangruent .mlutionr, where g = (a, b, m), provided glc.

PROOF: By Theorem 3.9.1, we already know that a necessary and suffi-


cient condition that the linear congruence

ax + by E C(mod m) (3.9.5)

has solutions is that glc, where g 2 (a, b, m). If g|c, then

a : ga’, b = gb', c = gc', and m = gm’,

where (a’, b', m’) = 1. Now, by Theorem 3.6.2, congruence (3.9.5) implies
that

0’): + b’y E c’(mod m’). (3.9.6)

Let (a’, m’) = 3". Then linear congruence (3.9.6) has solutions if and only if

b’y .=_ c’(mod g’) (3.9.7)

has solutions. Since (a’, b’, m’) : l and (a’, m’) = g’, then (b‘, g') = 1 and
congruence (3.9.7) has one incongruent solution yo modulo g’.
The %: congruent solutions ymyo + g’, y0 + 2g’, . . ., andyo +(%_ 1)g'
of linear congruence (3.9.7) are incongruent modulo m'. Each of these
values of y yields g' incongruent values of x in linear congruence (3.9.6);
m’ . . . .
thus, there are g' - —,, that is, m’, incongruent solutions of linear congruence

(3.9.6).
Let (x1, y1) represent one solution of linear congruence (3.9.6). Then
the g congruent values x1, x1 + m', x1 + 2m', ..., and x1 + (g # 1)m’
modulo m’ are incongruent modulo m; the g congruent values yl, yl + m’,
y1 + 2m’, . . ., and y1 + (g ~ l)m’ modulo m’ are incongruent modulo m.
Therefore, for each solution of linear congruence (3.9.6), we can generate
g1 incongruent solutions of linear congruence (3.9.5). Hence, there are g’m’,
that is, gm, incongruent solutions of linear congruence (3.9.5).

EXAMPLE 4. Find the incongruent solutions of the linear congru-


ence
134 THE THEORY OF CONGRUENCES § 3.9

8): + 6y E 10(mod 16).

Since (8, 6, 16) = 2 and 2110, then there are 2 - 16, that is, 32,
incongruent solutions of the given linear congruence. Now, if
8.): + 6y E 10(mod 16), then

4x + 3y E 5(mod 8).

Since (4, 8) E 4, then

3y E 5(mod 4),

By E 9(mod 4),

y E 3(mod 4).

The congruent solutions 3 and 7 of y E 3(mod 4) are incongru-


ent modulo 8. For each of these values of y there exist four corre-
sponding incongruent values of x modulo 8 such that 4x + By E 5
(mod 8). Thus,

4x + 3(3) E 5(mod 8),

4x + 1 E 5(mod 8),

4x E 4(mod 8),

X 1(rnod 2);
"I

x E 1(mod 8), x E 3(mod 8), x E 5(mod 8), and x E 7(rnod 8).


Similarly,

4x + 3(7) E 5(mod 8),

4x + 5 E 5(mod 8),

4x E 0(mod 8),

x E 0(mod 2);

x E 0(mod 8), x E 2(mod 8), x E 4(mod 8), and x E 6(rnod 8).


Therefore, (1, 3), (3. 3), (5, 3), (7. 3), (0, 7), (2. 7): (4, 7), and (5, 7)
are the eight incongruent solutions of the linear congruence 4x + By
E 5(mod 8).
For each incongruent solution (x, y) of the linear congruence
4x + 3y E 5(mod 8) there exist four corresponding incongruent
§ 3.10 THE CHINESE REMAINDER THEOREM 135

solutions (x, y), (x + 8,y), (x,y + 8), and (x + 8,y + 8) of 8x + 6y


E 10(mod 16). Hence, the solutions of the given linear congruence
are

(1, 3), (9, 3), (1, 11), (9, 11),

(3, 3), (11, 3), (3, 11), (11, 11),

(5, 3), (13, 3), (S, 11), (13, 11),

(7, 3), (15, 3), (7, 11), (15, 11),

(0, 7), (8, 7), (0, 15), (8, 15),

(2, 7), (10, 7), (2, 15), (10, 15),

(4, 7), (12, 7), (4, 15), (12, 15),

(6, 7), (14, 7), (6, 15), (I4, 15).

EXERCISES

In Exercises I through 12 find a set of incongruent solutions of each linear can-


gruence:
1. 5x + 7y E 11(mod 9). 2. 4x — 8y E 2(mod 6).
3. 5x + 6y E 8(mod 20). 4. 7x + 9y E 21(mod l4).
5. 16x 7 12y E 45(mod 60). 6. 9x + 15y E 63(mod 12).
7. 3x + y E 7(mod S). 8. 6x — 2y E 122(mod 8).
9. 15x + 12y E 24(mod 30). 10. 21x + 18y :— 10(m0d 54).
11. 6x + 13y E 27(mod 34). 12. 3x + 3y E 9(mod 6).

13. Prove that the linear congruence ax + by + cz E d(mod m) has exactly gm‘
incongruent solutions, where g = (a, b, c, m), provided gld.
14. Find a set of incongruent solutions of the linear congruence 2x + 4y — 3: E 7
(mod 6).

3.10 THE CHINESE REMAINDER THEOREM

In this section we consider two fundamentally difl‘erent systems of linear


congruences. The first system consists of two or more linear congruences in
two or more variables with the same modUIus; the second system consists of
136 THE THEORY OF CONGRUENCES § 3.10

two or more linear congruences in one variable with different moduli. The
method of solving the first type of system of linear congruences is analogous
to the method of solving systems of linear equations in two or more variables,
and is illustrated in Example 1.

EXAMPLE 1. Solve the system of linear congruences

x + y E 8(mod 13)
2x + 3y E 12(mod 13).

The linear congruence x+ y E 8(mod 13) is equivalent to


2x+2y E 16(mod 13) by Theorems 3.2.2 and 3.4.1. Then, by
Theorem 3.2.4,

(2x + 3y) — (2x + 2y) E 12 — 16(mod 13),

y E ~4(mod 13),

y E 9(rnod 13).

Substituting 9 for y in the linear congruence x + y E 8(mod 13), we


obtain x a 12(mod 13). Hence, the ordered pair (12, 9) is the solu-
tion of the given system of linear congruences.

Systems of linear congruences consisting of two or more linear congru-


ences in one variable with different moduli can be solved under certain
conditions. Consider the system of linear congruences

{x a 9(mod 6)
(3.10.1)
x E 11(mod15).

Ifx E 9(mod 6), then x = 9 + 6a where a is an integer; ifx E 11(mod 15),


then x = 11 + 15b where b is an integer. It follows that a solution of the
system of linear congruences (3.10.1) exists provided values of a and b exist
such that
9+6a:11+15b,

6a — 15b = 2. (3.10.2)
Since (6, —15) = 3, then by Theorem 2.3.1 the smallest positive integer that
can be expressed as a linear homogeneous function of 6 and —15 is 3. There-
fore, values of a and b do not exist that satisfy equation (3.10.2); hence, a
§ 3.10 THE CHINESE REMAINDER THEOREM 137

solution of the system of linear congruences (3.10.1) does not exist.


Consider another system of linear congruences

{x a 3(mod 4)
x E 5(mod 7).
(3.10.3)

If x E 3(mod 4), then x = 3 + 4:: where a is an integer. By substitution in


the second linear congruence of (3.10.3),

3 + 4a 5 5(mod 7),

4a 5 2(mod 7),

4a E 16(rnod 7),

a E 4(mod 7).

If a E 4(mod 7), then a = 4 + 7b where b is an integer. Therefore,

x : 3 + 4a

: 3 + 4(4 + 7b)

: 19 + 28b;

that is,

x E 19(mod 28)

is the solution of the system of linear congruences (3.10.3).


The following theorem justifies the results of the preceding examples.

Theorem 3.10.1: A solution of the system of linear congruences

x E a (mod m )
{x E a:(mod mi) (1104)

exists if and only if (m1, m2)l(az — a1). If a solution exists, each solution
is of theform x E x1(mod[m1, m1]), where [m1, m2] is the least common
multiple ofm1 and m2.

PROOF: Ifx E al(mod m1), then X = a1 + km1 where k is an integer.


By substitution in the second linear congruence of (3.10.4),
138 THE THEORY or CONGRUENCES § 3.10

a1 + km‘ E a1(mod m2),

mlk E (a2 — a1)(mod m2). (3.10.5)

By Theorem 3.6.3, this linear congruence has a solution for k if and only if
(m1, m2)|(a2 — a1). Assume that a solution x0 exists. By Theorem 3.6.3, each
incongruent solution of linear congruence (3.10.5) is of the form

In;
x —t
0 + (m1, m2)
where t is an integer. Therefore,

x=al+km1

E
# 411 , + (x9
+ —m2
(m1, m2)t)m1

”hm;
E a1 + xom1 + (m1, m2).

”hm;
Since 111 + xom1 equals some integer x1 and m : [mu ml] by Exer-
cise 12 of §2.7, then

x = x1 + [m,, m2]t;

x E x1(mod [mp m2]).

The following theorem is a special case of the generalization of Theorem


3.10.1. The results of Theorem 3.10.2 were known in a less convenient form
to the Chinese in ancient times.

Theorem 3.10.2 (The Chinese Remainder Theorem): 1/ (mi, mj)=1 for


1 S i < j g n, then the system of linear congruences

x E a,(mod m1)

x E az(mod m2)
(3.10.6)

x E an(mod m”)
§ 3.10 THE CHINESE REMAINDER THEOREM 139

n
has a unique solution modulo m where m : H m,.
i=1

PROOF: LetM, =£furi= 1,2, ..,.nThen(M,,m,) : lfori= 1,


t
2, . . ., n. By Theorem 3.6.3, unique solutions x, exist to the linear congru-
ences Mix E 1(rnod m) for i: l, 2, . . ., n; that is,

Mlx1 a 1(mod m1), sz E 1(mod m2), ..., M,,x,I E 1(mod m").

Furthermore,

Mlxla1 E al(mod m1), szaz E a2(mod m2), ...,

M,,x,,tz,l E a,,(mod m").

Now, each of the linear congruences of (3.10.6) is satisfied if

x = M1x1a1 + szaz2 + - -- + Mnxnu"

since each M] contains the factor m, where i,j = 1, 2, . . . , n and i 95 1'. Thus,
the system of linear congruences (3.10.6) has a solution.
Let x' be another solution of the system of linear congruences (3.10.6).
Then x’ E a,(mod m,) for i: l, 2, ..., 71; thus, x’ a x(mod m,) for i = 1,
2, . . ., n. Since (mi, mi) 2 1 for 1 g i <j g n, then by a repeated applica-
tion of Theorem 3.10.1 x' E x(mod m) where m = H m,. Hence, the solution
i: 1

is unique modulo m.

EXAMPLE 2. Solve the system of linear congruences

x E 8(mod 5)

x E 5(rnod 3)
(3.10.7)
x E 11(mod 7)

x E 2(rnod 4).

Since (5, 3) : (5, 7) 2 (5, 4) = (3, 7) : (3, 4) = (7, 4): 1,


then by Theorem 3.10.2 there exists a unique solution modulo
5 - 3 - 7 - 4, that is, 420, of the system of linear congruences.
If x E 8(mod 5), then x = 8 + 5a where a is an integer. By
substitution in the second linear congruence of (3.10.7),
140 THE THEORY or CONGRUENCES § 3.10

8 + 5a E 5(mod 3),

5a E 0(mod 3),

a E 0(mod 3).

If a E 0(mod 3), then a = 3b where b is an integer and x : 8 + 511


= 8 + 15b. By substitution in the third linear congruence of (3.10.7),

8 +151: E 11(mod 7),

15b E 3(mod 7),

b E 3(mod 7).

Ifb E 3(mod 7), then b = 3 + 7!: where c is an integer and x = 8 +


15b = 8 + 15(3 + 7c) = 53 + 105:. By substitution in the fourth
linear congruence of (3.10.7),

53 + lOSc E 2(mod 4),

1050 _ 751(mod 4),

C — 5 1 (mod 4),

C 1(mod 4).

If c E 1(mod 4), then 0: l +4d where d is an integer and


x = 53 + 1056 : 53 + 105(1 + 4d) = 158 + 420d. Hence,

)6 a 158(mod 420)
is the unique solution of the given system of linear congmences.

The method of solving systems of linear congruences can be used in


solving linear congruences with composite moduli as illustrated in
Example 3.

EXAMPLE 3. Solve the linear congruence

13x E 17(m0d 42).

The linear congruence 13:: E 17(mod 42) is equivalent to the


system of linear congruences
§ 3410 THE CHINESE REMAINDER THEOREM 141

13x E 17(mod 2)

13x 5 17(mod 3)
13x E 17(mod 7);
that is,

x E 1(mod 2)

x E 2(rnod 3)

x E 4(mod 7).
If x E 1(rnod 2), then x = 1 + 2a where a is an integer and

1 + 2a E 2(mod 3),

2a — 1(mod 3),

a E 2(mod 3).

Ifa E 2(mod 3), then a = 2 + 3b where b is an integer, x : 1 + 211


= 5 + 6b, and

5 + 617 E 4(mod 7),

6b E —I(mod 7),

b E 1(mod 7).

Ifb E 1(mod 7), then b : 1 + 7c where c is an integer and x = 5 +


6b = 11 + 42c. Hence,

x a 11(mod 42)
is the solution of the given linear congruence.

EXERCISES

In Exercises 1 through 6 find a set of incongruent solutions uf each system of linear


congruences:
1. {7x — 11y E 10(mod 14) 2. {3x + 5y E 17(mod 18)
6x — By E 6(mod 14). 2x + 7y E 29(mod 18).
3. {5x + 6y E 42(mod 37) 4. {5x + By E 12(mod 21)
4x — By E 51(mod 37). 11x —— 7y E 45(mod 21).
142 THE THEORY or CONGRUENCES § 3.10

5. 7x 7 22y E 34(mod 36) 6. 2x + 3y 7 z E 0(mod 17)


{11): + 14y : 19(mod 36). x 7 5y + 7 = 7(mod17)
3x + y + 62 E 2(mod 17).

7. Consider the system of linear congruences in two variables x and y


{01X + by E e;(mod In);
alx + by E c2(mod In).
Show that the system implies Dx E D,(mod m), Dy E D1(mod In), Where
at [71 c; bl E; 51
, DI: , and D2:
a; 172 e; [72 a: C:

Prove that the system of linear congruences has exactly (D, m) incongruent
solutions provided (D, m)|Dt and (D, m)|D2.

Use the Chinese Remainder Theorem and solve each system of linear congruences:

8. {x E 5(mod 12) 9. {x E 8(mod 26)


x E 7(mod 19). x E 11(mod 33).
10. x E 7(mod 9) 11. x E a(mod 3)
k E 10(mod 4) t (mod 5)
E 1(m0d 7). E e(mod 8).
12. x E 28(mod 29) 13. 5;: E 11(mod 17)
L 30(mod 31) {3x 19(mod 32)
: 10(mod 11). 11): = 6(mod 37).

In Exercises 14 and 15 use the Chinese Reminder Theorem and solve each linear
congruence:
14. 7): E 1(rnod 180). 15. 8): E 7(mod 165).

16. Prove that a solution of the system of linear congruences


x E at(mod m;)
x a;(mod ma)

x E a..(mod m»)
exists if and only if (Mi, m,)l(a. 7 a) for each pair i, j where 1 S i <j S n.
If a solution exists, each solution is of the form x E xl(mod [m., M2, . . ., mnD.

In Exercises 17 and 18 salve each system of linear congruences:

17. f: E 8(mod 9) 18. x E 4(mod 6)

= 5(mod 7).
x E 1(mod 7).
19. Find the smallest positive integer that has the remainders 2, 3, and 2 when
divided by 3, 5, and 7, respectively (Sun-Tsu, 1st century A.D.).
20. Find the smallest positive integer that has the remainders 5, 4, 3, and 2 when
divided by 6, 5, 4, and 3, respectively (Brahmag'upta, 7th century A.D.).
§ 3.11 QUADRATIC CONGRUENCES 143

21. A sack contains a number of marbles such that l marble remains if the marbles
are removed from the sack 2, 3, 4, 5, or 6 at a time. However, no marbles
remain if the marbles are removed from the sack 7 at a time. Find the least
number of marbles that are contained in the sack.
22. A small boy, playing with a pile of blocks, notes that he has 5 blocks too few
to make a solid whose rectangular base contains 16 blocks. However, he has I
block too many if he makes a solid whose rectangular base contains 25 blocks.
If the boy makes a solid whose rectangular base has 21 blocks, all the blocks
are used. Determine the least number of blocks that the boy is playing with.

3.11 QUADRATIC CONGRUENCES

A congruence of the form

axz + bx + c E 0(mod m)

where a i 0(mod m) is called a quadratic congruence. In this section we shall


restrict our attention to quadratic congruences with prime moduli.
Up = 2, the quadratic congruence

axz + bx + c E 0(mod p),

where (a, p) = I, can be shown to be equivalent to one of the following four


congruences :

x1 E 0(mod 2); x1 + l E 0(mod 2);

x1 + x E 0(mod 2); x1 + x + 1 _ 0(mod 2).

The solution of each of these quadratic congruences can be easily determined


by inspection and presents no difficulty. Therefore, we shall concern our-
selves with the solutions of quadratic congruences with odd prime moduli.
If p is an odd prime and (a, p) = 1, then (441’, p) = 1 and the general
quadratic congruence with a prime modulus

axz + bx + c E 0(modp) (3.11.1)

is equivalent to
441562 + 4abx + 4ac E 0(mod 17);

that is,
(2ax + b 1 E b2 # 4ac(mod p).
144 THE THEORY OF CONGRUENCES § 3.11

Let2ax+b= Xandb2 74ac=d. Then

X2 E d(rnod 1)). (3.11.2)

If the special quadratic congruence (3.11.2) has no solution, then the general
quadratic congruence (3.1 1.1) has no solution. If the special quadratic congru-
ence (3.112) has a solution x0, then by substitution

2ax + b E xo(modp). (3.11.3)

This linear congruence has a solution since (2a, p) = 1; hence, a solution of


the general quadratic congruence (3.11.1) exists. Therefore, the general quad-
ratic congruence with an odd prime modulus (3.11.1) has a solution if and
only if the special quadratic congruence (3.11.2) has a solution. For this
reason we can reduce the discussion of solutions of quadratic congruences
with odd prime moduli to a discussion of solutions of quadratic congruences
of the form X1 E d(modp).
Furthermore, note that if b2 —— 4a: E 0(mod p), then quadratic congru-
ence (3.11.2) has exactly one incongruent solution modulo p, the associated
linear congruence (3.11.3) has one incongruent solution, and hence the
general quadratic congruence (3.11.1) has one incongruent solution. In
general, for each incongruent solution modulo p of (3.11.2), there exists an
incongruent solution of the general quadratic congruence (3.11.1); that is,
there is a one-to-one correspondence between the solutions of (3.11.2) and
(3.1 1.1).
We shall accept without proof the fact that a polynomial congruence of
degree n in one variable with a prime modulus has at most It incongruent solu-
tions. If quadratic congruence (3.11.2) has one solution x0, then the second
solution is p —- xo since

(P - ’60)2 E xfifinod II)-


For example, since 6 satisfies the quadratic congruence x2 a 2(mod 17), then
17 ~ 6, that is, 11, is the other solution. It should be noted that a quadratic
congruence of the form of (3.11.2) need not have a solution. For example,
no solution of the congruence x2 E 3(mod 7) exists.

EXAMPLE 1. Solve the quadratic congruence

3x2 — 4x + 7 E 0(mod 13).

The quadratic congruence 3):2 ~ 4x + 7 E 0(mod 13) can be


expressed in the following equivalent forms:
§ 3.11 QUADRA'nc CONGRUENCES 145

9):2 -— 12x + 21 E 0(mod 13),

(9x2 — 12): + 4) + 17 E 0(mod 13),

(3x 7 2)2 + 17 E 0(mod 13),

(3x — 2)2 E 9(mod 13).

Now, let 3x E 2 : X. The quadratic congruence

X 2 E 9(mod 13)

can be solved by inspection. Since one solution is 3, then the other


solution is 10; that is,

X E 3(mod 13) or X E 10(mod 13).

Thus,

3): E 2 E 3(mod 13),

3x E 5(mod 13),

3x E 18(mod 13),

x E 6(mod 13),

or

3x — 2 E 10(mod 13),

3x E 12(mod 13),

x E 4(mod 13).

Consider the special quadratic congruence

x2 E —1(mod 11), (3.11.4)

where p is a prime. Theorem 3.11.1 which states a necessary and sufficient


condition for the existence of a solution of (3.11.4) is an interesting conse-
quence of Wilson’s Theorem.

Theorem 3.11.1: If p is a prime, then the quadratic congruence x2 E —1


146 THE THEORY OF CONGRUENCES § 3.11

(mod 17) has a solution ifand only ifp = 2 or p : 4t + 1 where I is a


positive integer.

PROOF: Letp be a prime. Up = 2, then 122 —1(mod 2); that is, 1


is a solution of the quadratic congruence x1 E —l(mod p) ifp = 2. Ifp aé 2,
then 12 is odd. By Wilson’s Theorem,

(p — 1)!E 71(modp),

(P—1)(P—2)(P—3)"‘(P*k)"‘
(pT-i-l)(PT—1)...k_..3.2.1 E —1(modp),

[1(p—1)]'[2(p—2)]'[3(17—3)]"'[k(p—k)]"‘

l<"+‘)<"+l)lz
Since k(p — k) E —k2(mod p), the above congruence can be expressed
in the form
z;1)2
. . (_kz) , . _ [_(p ] a —1<mod p),
(*1)(—4)(—9)-

...k2._ _(_p2__1)2]
(*l)p2;1|:1.4.9 —1(m°dp),
2
(—1)p+1|:1.2.3...k... P__l:| = —1(mod p).
2
u
If p = 41+ 1, where I is a positive integer, then (—1) 2 = 1. Therefore,
_ z
“Ll—1H a #1(mod p); (3.11.5)

that is, (p g )l is a solution of the quadratic congruence x2 E #1(mod p)


if p = 4! + 1, where t is a positive integer.
Conversely, if p sé 2 and p # 4! + 1 where t is a positive integer, then
u
(—1) 1 = —1. Assume that an integer a exists such that

a1 E —1(modp).

Then (a2, p) : (a, p) : 1 and, by Fermat’s Theorem,


§ 3.11 QUADRATIC CONGRUENCES 147

a”—1 1(m0d p).


2(p—l)
a 1 —l(modp),

(a1)? a 1(mod p).


(—1)? a 1(mod p),
—l E 1(mod p).

However, the last congruence is not valid unless p = 2, which contradicts


the given hypothesis. Hence, the assumption that an integer (1 exists such
that a2 E —1(mod p) is false.
Thus, if p is a prime, then the quadratic congruence x2 E —l(rnod p)
has a solution if and only if p = 2 or p 2 41+ 1 Where t is a positive
integer.

EXAMPLE 2. Find a solution, if one exists, of the quadratic congru-


ence x2 a —1(mod 29).
Since 29 can be expressed in the form 4! + l where t is a
positive integer, then by Theorem 3.11.1 a solution of the quadratic
congruence x2 E 71(mod 29) exists. By statement (3.11.5), (D)!
2
represents a solution; that is, 14! is a solution. Although the solution
is not expressed in a convenient form, at least it is known that a
solution exists.

The following theorem is due to Euler and states a necessary and suffi-
cient condition for the existence of solutions of the quadratic congruence
x2 E a(mod p) where p is an odd prime. The proof of Theorem 3.11.2 is left
to the reader as an exercise (Exercise 16).

Theorem 3.11.2 (Euler’s Criterion): If p is an odd prime and a gé 0(rnodp),


then the quadratic congruence x2 E a(mod 17) has a rolution if and only
P_—1
if a 2 E 1(modp).

EXAMPLE 3. Determine whether or not each quadratic congruence


has a solution:
148 THE THEORY OF CONGRUENCB § 3.11

(a) x2 E 4(mod 13); (b) x2 E 2(mod 11).

(a) The quadratic congruence x1 E 4(mod 13) is of the form


1341
x2 E a(mod p), where p is an odd prime. Now, 4 2 : 46 = 4096
Id
and 131(4096 — 1); that is, a 1 E 1(mod p). Hence, the quadratic
congruence x1 E 4(mod 13) has a solution.
(b) The quadratic congruence x2 E 2(mod 11) is of the form
1 1 E l
x2 a a(mod11), where p is an odd prime. Now, 2 1 = 25 = 32
and 11 I (32 — 1). Hence, the quadratic congruence x2 E 2(mod 11)
has no solutions.

EXERCISES

Salve each quadratic congmence with a prime madulus:

1. x‘ E —1(mod 13). 2. x2 E —1(mod 7).


3. x1 E 2(mod 19). 4. x2 E 2(mod 31).
5. x“ — 2x — 2 E 0(mod 11). 6. 42:2 + x + 4 E 0(mod 5).
7. 3x‘ — 5x — 9 _ 0(mod 13). 8. 7x2 — x + 11 E 0(mod 17).

In Exercises 9 through I4 salve each quadratic congruence with a composite modulus:

9. x1 E 6(mod 15). 10. x' E 1(mod 8).


11. x1 E 71(mod 65). 12. x1 — 6x E 3 E 0(mod 10).
13. 6):2 + 7x + ll E 0(mod 12). 14. 3x2 + 9x —— 8 E 0(mod 28).

15. Prove that if p is an odd prime and a E 0(mod p), then


aLil E 1(mod p) or a? E 71(mod p).
16. Prove Theorem 3.11.2.
q

l . Prove that if p is a prime and dig; — 1), then there are exactly :1 incongruent
solutions of the congruence x‘ E 1(mod p).
18. Determine the values of a for which the quadratic congruence x‘ E a(mod 7)
has a solution. Find the solutions in each case.
chapter 4

4.1 FINITE CONTINUED FRACTIONS

An expression such as

— (4.1.1)
3 + 4

1
1 +5

IS an example of a continuedfraction. The continued fraction (4 1 1) can be


evaluated by calculating and simplifying the following expressions in the
order considered:
l 3
1+§*?
4+ 7 =4+L=2§
1+12 22 3
149
150 CONTINUED FRACTIONS § 4.!

3+ 5 7 _
—3+ L_2§
26 —26,
4+ 1 T
1+2

2+ 3 1 5 _
—2+ E1 _fl.
93,
+ 4+ 7 1 26
1+2

thatis,

212 1
9—3:2+ 3+ 5 7
4+ 1
1+2

A continued fraction is an expression of the form

[7
(11+ 1 b2 (4.1.2)
111+ a3+'~

+ bn—z
—1
all—1 ‘1‘ b"
an
In general, the ai’s and bi's of (4.1.2) may be real or complex numbers. How-
ever, if each bi is equal to 1 and each a; is an integer such that ai > 0 for
i > 1, then the continued fraction is called a simple continued fraction. Note
that in a simple continued fraction a1 may be a positive or negative integer
or zero. In this chapter we shall be primarily concerned with simple continued
fractions:

a1+
1
—1. (4.1.3)
“2+?
3
a1...
+
§ 4.1 FINITE CONTINUED FRACTIONS 151

The ai’s of a simple continued fraction (4.1.3) are called the terms of the
continued fraction. If the number of terms of a simple continued fraction is
finite, as indicated in (4.1.3), then the continued fraction is a finite simple
continued fraction. If the number of terms of a simple continued fraction is
infinite, then the continued fraction is an infinite simple continued fraction.
Every rational number and every irrational number can be expressed as
a simple continued fraction. The process for expressing a rational number as
a simple continued fraction is illustrated in the following examples. The
problem of expressing an irrational number as a simple continued fraction
will be discussed in §4.2.

95
EXAMPLE 1. Express 4—3 as a simple continued fraction.

95 9 1 1
4—3 2+43~2+ 12 —2+ 4+2
9 9

=2+ 1]:2+ 11
4+— 4+
2 1+2
7 7

=2+ 11 =2+ 11
4+ 1 4+ 1
1+— 1+
2 3+12
2

The representation of % as a simple continued fraction is not


unique. A trivial exception exists since the last term 2 can be ex-
pressed as l + %. Hence,
152 CONTINUED FRACTIONS § 4.1

The first of the two representations of % as a simple continued frac-


tion is usually preferred since fewer terms are involved.

It is sometimes convenient to write a simple continued fraction such as


the one in Example 1 in the abbreviated form [2, 4, 1, 3, 2]; that is,

1
[2.4,1,3.2]=2+—+.
4 + —1

In general,

[a,.a.,a., ...,a,1= a. + 1
(12+ [13+

5|.—
+

EXAMPLE 2. Evaluate the simple continued fraction [3, 4, 7, 4, 8].

[3,4,7,4,8]=3++=3++
”7—1
+
4+—
1 ”—1
7+
13.
8 s
=3+ 11 =3+ 11
4
+7.333 4+2
33
_ 1 1
‘3+ +£ +939
239 239
_ §_3206
‘3+989‘989'

EXAMPLE 3. Express ~ 136 as a simple continued fraction.


§4.1 FINITE CONTINUED FRACTIONS 153

=~2+ L =72+

N
H

one
+
|

I
‘Ol
2 4+l2
2
Hence,

16
—3 g [72, 4, 2].

The integer 72 was selected for al in order that the remaining


terms would be positive integers.

58
EXAMPLE 4. Express 4—9 as a simple continued fraction.

587 l_ ;_ l
‘9“1+49_1+ 9 ‘1+ 5+5
9 9

:14. 1 1 =1+ 11
5+—— 5+
4 4
Hence,

E58 a [1. 5, 2, 41.

Note that the divisor at each step of the process for expressing % as a,
simple continued fraction becomes the dividend in the next step. Therefore,
the process for expressing 2—3 as a simple continued fraction may be sum-
marized as follows:
H
IS,
00
.5
\0

A
0
\0

.4a
N
\D
h—IIW

OI-hqb
154 CONTINUED FRACTIONS § 4.1

Note that in Examples 1, 3, and 4 each rational number was expressed


as a finite simple continued fraction; in Example 2 the finite simple continued
fraction represented a rational number.

Theorem 4.1.1: Every rational number can be expressed as a finite simple


continuedfraction.

PROOF: Let; be any rational number and let q > 0. Then, by the di-
vision property, there exist integers ai and ri such that

p
—=a r1
—=a 1 p
q 1+q 1 +—,
l where a 1 <—q and 0<r 1 < 41 ;
r1

r l
1=a2 —2=uz+—, where uz<l and 0<rz<r1;
r1 r1 r1 r1
’2

r1 r3 1 r1
—=a3+—:a3+—, where a3<— and 0<r3<r2;
’2 ’2 fl ’2
’3

_
rn-J : 7 + fair z 7 +_
1
r”_ n 1 ’n—z n 1 ,"71 !

rnil

rn—S
where (1",, <: and 0 < r,,_1 < rn_z,.
,_

rn V 2 = an.

rail

Note that r1, r2, r3,. . ., r,,_1 is a decreasing sequence of positive integers.
Since there exists only a finite number of positive integers less than q, the
above process must terminate as indicated; that is, only a finite number of
positive integers ri which satisfy the above equations exist. By substitution,
using the steps of the above process,
§ 4.1 rla CONTINUED FRACTIONS 155

= [01, a2, (13, .. ., an].

Hence, since only a finite number of terms are used, the rational number?

is represented by a finite simple continued fraction.

The representation of a rational number as a finite simple continued


fraction is not unique. Because of the manner in which the ai’s are chosen in
Theorem 4.1.1, each ai is unique. However, if oz,l > 1, then

a.:(n.—1)+1=(a.~1)+%
and

2—,: [up a1, a3, ..., n] z [(11, a2, a3, ..., a,l —1,1];

ifiz,I =1, then

afl‘l +11%: ~71 +%=an~l +1

and

"s: [an “2’ ”a: .,.a an] = [(11, “2» as, -- u an—i +1]-

Thus, every rational number can be expressed as a finite simple continued


fraction in exactly two ways. Furthermore, one representation has an odd
number of terms and the other representation has an even number of terms.

Theorem 4.1.2: Every finite simple continued fraction represents a rational


number.

The proof of Theorem 4.1.2 is left as an exercise (Exercise 20).


156 CONTINUED FRACTIONS §4.2

EXERCISES

Express each rational number a: a finite simple continued fraction:

1. %. 2. %.
3. %. 4. 75%.
s. g. 6. 2%.
7. %. s. %.

Evaluate each finite simple continued fraction:

1
9.4+ 1 . 10. 3 + 1
3+z 8+ _1_
1
n+7

In Exercises 1 I through 18 determine the rational number represented by each finite


simple cantinuedfraction:

11. [5, 8, 2]. 12. [2, 4, 6].


13. [0, 2, 4, 6]. I4. [73, 8,11, 7].
15. [4, 7, 3, 5, 2]. 16. [1, 4, l, 4,1].
17. [1, 2, 3, 4, 5]. 18. [5, 4, 3, 2, l].

19. Express the rational number ¥79 as a finite simple continued fraction with
(a) an odd number of terms; (b) an even number of terms.
20. Prove Theorem 4.1.2.

4.2 INFINITE CONTINUED FRACTIONS

The process for expressing an irrational number as a simple continued frac-


tion is basically the same as the process shown in §4.1 for rational numbers.
Let x be any irrational number. The irrational number x can be ex-
pressed in the form
1
x=a‘+x_’
l

where a1 is the greatest integer less than x and


§4.2 INFINITE CONTINUED FRACTIONS 157

0<i<L
x,

If x1 were a rational number, then (by Theorem 4.1.1) it could be expressed


as a finite simple continued fraction; then x could be expressed as a finite
simple continued fraction, and (by Theorem 4.1.2) x would have to be a
rational number. This is contrary to the hypothesis. Therefore, x, is an ir-
rational number. Furthermore, x, > 1 since 0 < xi < 1. Hence, x, can be
1
expressed in the form

1
m—%+fi

where a; is the greatest integer less than x1 and

0<i<L
262

Furthermore, a, is a positive integer and x2 is an irrational number. The


process may be continued indefinitely. For each x, there exists a correspond-
ing ai+1 which is the greatest integer less than x, such that

x. __ a_ + _ 1
+1 ,
i ‘ xH-l
where a...r1 is a positive integer and x,+1 is an irrational number. Therefore,

x = [0,, a2, a3, . . .].

Since a, is the greatest integer less than x and each a, +1 for i > 0 is the
greatest positive integer less than xi, the representation of the irrational
number x as an infinite simple continued fraction is unique. The argument
presented here is a proof of the following theorem.

Theorem 4.2.1: Every irrational number can be expressed as a unique infinite


simple continuedfraction.

The converse of Theorem 4.2.1 follows as a direct consequence of Theo-


rem 4.1.1 and the fact that every real number is either a rational number or
an irrational number.
158 CONTINUED FRACTIONS § 4.2

Theorem 4.2.2: Every infinite simple continued fraction represents an irra-


tional number.

PROOF: Consider any infinite simple continued fraction. Let x be the


number represented by the continued fraction. By Theorem 4.1.1, x cannot
be a rational number. Hence, x is an irrational number.

It should be carefully noted that no interpretation has yet been placed


on the use of the word “represent” with respect to infinite simple continued
fractions. For example, every finite simple continued fraction can be “evalu-
ated” by performing a finite number of rational operations, and in this sense
“represents” a rational number. How does one “evaluate” an infinite simple
continued fraction? This question will be answered in general in § 4.8.

EXAWLE 1. Express fl as a simple continued fraction.


Since 2 < ‘/§ < 3, then 2 is the greatest integer less than fl.
Thus,

~/§=2+(~/§—2)=2++=2+fi
$72 4
=2+ 1 :2+—1_
:78—2 1
1+T 1+T

8*2

=2++=2+—1I—

”m ”m
At this point note that the expression (\/§ 7 2) appears once again.
The expansion of (V? 7 2) as a continued fraction is once again

1
1
”m
Hence,

«i=9, 1,4, 1,4, 1,4, ...],


where the integers 1 and 4 repeat indefinitely. It is convenient to
write
§4.2 INFINITE CONTINUED FRACTIONS 159

«E = [2,171,
where the bar over the integers 1 and 4 indicates that they are re-
peated over and over.

The continued fraction representation of J§ is an example of an infinite


simple continued fraction that is periodic. The sequence of terms 1, 4 is the
period; the length of the period is two since the number of terms that repeat
is two. Periodic continued fractions and their properties are considered in
some detail in § 4.11.

EXAMPLE 2. Express J3 as a simple continued fraction.


Since 1 < J? < 2, then 1 is the greatest integer less than J5.
Thus,

_
fiil‘ififi
n n
1)*1+ ;_
1 1
~1+TT
3—1 2

=l+ 1 =1+ 1
+——‘“; 1+ 5 3~l

1 _ 1
=l+ 1 ’1+ 1

Hence,

fi=[1.1.2,1,2.1.2. m],
where the integers 1 and 2 repeat indefinitely; that is,

x/3 = [1, 37].

The infinite simple continued fraction that represents J3 is another


example of a periodic continued fraction, the length of whose period is two.
In the next example an interesting technique for expressing the irrational
number J? as an infinite simple continued fraction is illustrated.
160 CONTINUED FRACTIONS § 4.2

EXAMPLE 3. Express fl as a simple continued fraction.


Let x:fi. Then x2:2, x2—1=1, and (x-1)(x+l)
= 1. Therefore,

2+ 1

2+1+):

Thus, continuing in this manner, x may be expressed as the infinite


simple continued fraction [1, 2, 2, 2, . . .]; that is,

fl = [1, 5].

EXAMPLE 4. Determine the irrational number represented by the


infinite simple continued fraction [4, 1, 8].
Let x = [4, 1,—8]. Then

x:4+
1+
8+
§4.2 INFINITE CONTINUED FRACTIONS 161

and
_ 1
x4— 1
1+—————T——¥
“—1
1+ 8+"'

The infinite simple continued fraction contained within the pa-


rentheses is simply the representation of x ~ 4. Thus,

x—4= 1
1
1+s+o—o
I
1
1+x+4

A 1
_ x+5
X+ 4

,x+4.
_ +y
R

(XT4)(X+5)=X+4,
x1+x—20=x+4,

x2=24,

pm.
Hence, the infinite simple continued fraction [4, 1,—8] represents the
irrational number fl.
Note that although x1 : 24, x # # m since the first term
of the continued fraction is a positive integer.

No simple method exists for determining the continued fraction ex-


pressions for irrational numbers other than quadratic irrationals. A quadratic
irrational is an irrational number that is a solution of a quadratic equation
nu:2 + bx + c = 0 where a, b, and c are integers. More sophisticated methods
do exist by which continued fraction expressions for other irrational numbers
can be obtained. For example,
162 CONTINUED FRACTIONS § 4.3

{/22 [1, 3,1, 5.1.1,4,1, ml;


e=[2,l,2,1,1,4,1,l,6,l,1,8, ...];

7: = [3, 7,15,1, 292,1, ...].

It should be noted that these infinite simple continued fractions are not
periodic. In §4.ll we shall prove that every periodic continued fraction
represents a quadratic irrational, and every quadratic irrational can be repre-
sented by a periodic continued fraction.

EXERCISES

Express each irrational number a: an infinite simple continued fraction:

1. «3. 2. «H.
3. Jfi. 4. —~/7.
5. v5. 6. m.
7. m. s. 21 + m.

In Exercise: 9 through 16 determine the irrational number represented by each


infinite simple continued fraction:

9. [6, W]. 10. [3, 1,—1.


11. [0,1,7]. 12. [72, ,_4].
13. [5, 2, 3]. 14. [3, 2, s].
15. [3.51. 16. [E].
17. Let x be a real number geater than 1 represented by [an a2, a3, . . .1. Ex-
press Jl—r as a simple continued fraction.

4.3 CON VERGENTS

One of the reasons continued fractions are important is that they can be used
to obtain numerical approximations to irrational numbers.
The finite simple continued fractions

cl = [01] = an
1
£2 = [(11, “2] 2 “1 + (T:
2
§ 4.3 CONVERGENTS 163

1
c3 =[a1, “2! “3] = “i + 1 ,
«2+1:—3

1
ck = [an a2, a3, . . ., ah] = al +
a2 + ._1__
a3+---

l
at;
are called the convergents of the simple continued fraction [av a2, a3, . . .].
(The simple continued fraction [(11, a2, a3, . . .] may be a finite or an infinite
continued fraction.) In this section we shall examine some of the properties
of convergents of simple continued fractions by means of examples. In (54.8
and § 4.9 we shall prove a number of these properties of convergents, includ-
ing the properties of convergents as approximations to rational and irrational
numbers.

EXAMPLE 1. Determine the convergents of the finite simple con-


tinued fraction [1, 3, 4, 2, 3].

q:m=L
c,=[1,3]=1+§—3.
1_é

c3=[1,3,4]=1+ 11%}.
z
38
c‘=[1,3,4,2]=1+%=§,
3+ 1
4+5

c,=[1,3,4,2,3]=1+———l—l—=%.
”—1—
4+ 1
2+—
164 CONTINUED FRACTIONS § 4.3

Note that in Example 1, since the simple continued fraction [1, 3, 4, 2, 3]


is a finite continued fraction consisting of five terms, the fifth convergent as
is equal to the value of the continued fraction. In general, the last convergent
of a finite simple continued fraction always equals the rational number repre-
sented by the continued fraction.
Furthermore, note that each convergent of the finite simple continued
fraction in Example 1 is a better approximation to the rational number %
than the preceding convergent; that is,
131 31
m71=m=0.3100,
131 4 _m~o.0233,
im‘E 7

131 — '13
ifio 17 _ _1300
3 ~ 0.0023,

131 — 5i
ifio 38 c 2—900
1 N 0.0003,

fl_fl ,
100 100 — '
EXAMPLE 2. Determine the first five convergents of the infinite
simple continued fraction [2, 2,—4].

91:91:21

€2=[2.2]=2+%=g=2.5,
c;=[2,2.4]=2+ 11=%~2.444,
2+Z

c4=[2,2,4.21=2++1:§%=2.45,
2+—T
4+5

c,=[2.2,4,2,41=2+ 11 =2;_§z2.449.
2+ 1
4+ 1
2+—
§ 4.3 CONVERGENTS 165

Since 281—98 z 2.449 and J3 z 2449, one might conjecture that the in-
finite simple continued fraction [2, 2,—4] of Example 2 represents the irrational
number J3. Indeed, this fact may be verified by expressing J3 as an infinite
simple continued fraction by the method of § 4.2.
Again, note in Example 2 that the second convergent (‘2 is a better ap-
proximation to J3 than the first convergent q; the third convergent cJ is
a better approximation to J3 than the second convergent c,; the fourth
convergent :4 is a better approximation to J3 than the third convergent
as; the fifth convergent as is a better approximation to J3 than the fourth
convergent 64. The convergents cl, 62. c3, 6‘, and es of the continued fraction
that represents J3 form a sequence of rational numbers that are improved
approximations to J3.
, Consider the graph of the first five convergents of the infinite simple
continued fraction representation of J3 as shown in Figire 4.1.

C2 C
2.5 4

C3 C5

2_
CI

l 1 l l l ,-
l 2 3 4 5
Fig. 4.1

The add-numbered convergent: c1, c3, and c, are less than J3; the even-
numbered canvergents c2 and g, are greater than J3 Furthermore,
c,<c3<cs<J3<c4<cz.
Similar results were obtained in Example 1. In general, it can be shown
(Theorems 4.8.1 and 4.8.2) that

(i) the odd-numbered convergents of a simple continued fraction form


an increasing sequence, that is,
166 CON'I'INUED FRACTIONS

c, <: c, <: c, <: r-- ;

® the even-numbered convergents of a simple continued fraction form


a decreasing sequence, that is,

Q>Q>%>W;
(iii) every odd-numbered convergent of an infinite simple continued
fraction that represents an irrational number x is less than x, and
every even-numbered convergent is greater than 3:, that is,

Q<Q<Q<m<x<m<g<g<%

The statement of part (iii) may be amended to cover the case of a finite simple
continued fraction that represents a rational number x by noting that there
will exist some odd-numbered or even—numbered convergent oi, the last con-
vergent, such that c] = x.

EXAMPLE 3. Find a decimal approximation to n by computing the


fourth convergent of [3, 7, 15, 1, 292, 1, i . .].
The fourth convergent of the infinite simple continued fraction
that represents 7: is [3, 7, 15, 1]; that is,

24 2 [3, 7, 15, 1].

Since [3, 7, 15, 1] : [3, 7, 161.

c4 : [3, 7. 161

,3_55
#113

z 3.14159.

Hence,

1|: z 3.14159.
§4.4 EVALUATION OF CONVERGENTS 167

EXER CISES
Determine the convergents of each finite simple continuedfraction:

L1+ 1 12+ 1 1.
4+ 1
1+; 2+;

Determine the eonvergents of each finite simple continued fraction:

3. [8, l, 7, 2]. 4. [1, 3, 5, I, 2].


5. [—3, 4, 2, 4, 3]. 6. [0, 1, 3, 9, 2, 6].

Determine the first five convergents of each infinite simple continued fraction:

mmffi amLLLfl
Compute the first five convergent: of the simple continued fraction that represents
each number. Write a statement of inequality using the first five convergent: and the
number:

mfia mvfi

4.4 EVALUATION OF CONVERGENTS

Although each successive convergent of a simple continued fraction repre-


sents a better approximation to the value of the continued fraction, it is not
eflicient to compute each convergent from its definition. Recursive relations
do exist that enable us to compute each convergent of a simple continued
fraction from the preceding convergents and the terms of the continued frac-
tion. The following analysis motivates the statement of these relations which
is proved as Theorem 4.4.1.
Consider each convergent 0, expressed as the quotient of two integers
p" and an; that is, let c,l 2%. Now, by definition,

el = a1, whereby p1 = a1 and q1 = 1;

c2 = a1 + “—12, whereby p2 = azal + 1 and q2 = a2;


168 CONTINUED FRACTIONS § 4.4

1
£3=a1+
l
a 2 + ._
a3

_ 1134241 + 01 + l1:
(13:12 + 1

_ 43(11201 + 1) + at
>— "a“: + 1

=—L—“3 2+1“ whereb3'


a3q2+ql’ P3 =ap
3 2 +p l

and q: = “3’12 +41;

1
‘4 = “1 + ‘—1
(/12 + 1
a
3 + a4_
= aaaaazfll 4’ that + at“: + 11403 + 1
114113111 + a2 + a4

04(6302a1 + a1 + as! + ((12111 + 1)


a‘(a3a2 + 1) + ”2

= mm + P:
whereby p4 : aw; + p;
“4‘13 + qz’

and 114 : “443 + 112-

The expressions for p3, qa, p4, and q4 suggest that

1).. : NIH +pn_z for n : 3, 4, 5. 6,


1],, =anqn71 +4”,z for n: 3; 4; 5: 61

Them-em 4.4.1: If c" : %, where c,I is the nth convergent of the simple can-
u
firmed fraction [an (1;, a3, . . .], then

171 : (11, 172 = “2‘11 +1,

‘11 = 1: ‘12 = “z,


§4'4 EVALUATION or CONVERGENTS 169

and

P“ = “"17",, +15“; for n 2 3,

(In : "KIM + qr; for n 2 3.


\
PROOF: The expressions for p1, q“ p2, and q2 can be obtained from
the definition of a convergent.
The recursive relations for p,l and q", where n 2 3, are proved by mathe-
matical induction. We have already shown that the relations are true for
n = 3. Assume that the recursive relations are true for all integers from 3
through k. Then

I:
ck 2 [111. “2’ ”a, ..., ah] =:—,

where P); .= “kph—l + Phi: and 4h 2 alqkel + qkil' Now,

1
Eng-H =[a15 “2’ “3: - - 'x at, ah+l] :[“1: “2a ”1a -- -s “a + — ~

Therefore,

1
“I: + " Phi +Pk—2
ak+l
EH1 = (—‘———— l
“k + ‘ qk—l + qx—z
ak+1

= ak+1(akpk—1 + Pk—1)+ pkri


ak+1(aqAl + quiz) + qk—l

= ak-Hpk + Phi.
uk+lqls + qkil
Thus,

pk+l = ak+1pk +Pg—i and 4H1 = ak+1qk + qk—l‘

Hence,

pn : anpn—l +pn71 for ” 2 3:

qn = anqn—l + qnil for n 2 3-


170 CONTINUED FRACTIONS § 4.4

EXAMPLE 1. Find the convergents of the finite simple continued


fraction [1, 3, 5, 1, 2, 4] by the use of Theorem 4.4.1.
Sinceal = 1,112 = 3, a3 : 5, ‘14 :1, as = 2, anda6 = 4, then

p1=a1=1,

q1:1,

P1
0 7——1;
1 (I1

Pz=azfl1+1:3'1+1=4s

q2=a2=3,

c 2 = 172' 4
2 =_;
3

P3=a3P1+P1:5'4+1=21,

4324342+q1=5'3+1=16a

_&_
£
c'3‘ 3—16'

P4=a4P3+P2=1'21+4:25,

q4=a4qa+qz=l-16+3=19,

aza=g
‘14 19
P5:‘15P4 +P322'25‘1‘21271,

qs=asq4+43:2'19+16=54,

Q=E=Q
q, 54

ps=aap5+p4=4-71+25:309,
q6=asqs+44=4'54+19=235,
c _ 176 309
5 ¥q6 _ 235'

It is often convenient to arrange the calculations in table form:


§4.4 EVALUATION OF CONVERGENTS 171

u
._.

u-

as
4x
at 1 3 5 1 2 4
p.- 1 4 21 25 71 309
q, 1 3 16 19 54 235
c, 1 i3 2_1
16
a
19
7_1 w
54 235

The evaluation of the convergents can also be accomplished by using


the formal definitions p0 = l, q0 = 0, [7,1 = 0, and 11,1 = 1. Then

Pn = “um-1 +1!“ for n 2 1, (4.4.1)


‘1. = Juan—1 + 11",; for n 2 1. (4.4.2)

EXAlvn’LE 2. Evaluate the finite simple continued fraction

[3,1, 2, 1,1, 2, 2].

at 3 1 1 1 2 2
p, 0 1 3 4 11 15 26 67 160
qt 1 0 l 1 4 7 18 43

The value of the finite simple continued fraction [3, 1, 2, 1, l, 2, 2]


is the value of the seventh convergent c7, that is, %‘

EXERCISES

Find the convergent: of each finite simple continued fraction by the use of Theorem
4.4.1:
1. [2, 4, 6, 8]. 2. [4, 1, 7, 1, 4].
3. [1, 3, 6, 2,1]. 4. [6,1,],1, 2].

Evaluate each finite simple continuedfraction:

5. [4, 3, 7, l]. 6. [1, 5, 7, 3].


7. [0, 2, 6, 5, l]. 8. [1, 4, ll, 2].
In Exercises 9 and 10 determine the first five convergents of the simple continued
fraction that represent: each number:

9. m. 10. M.
172 CONTINUED FRACTIONS § 4.5

11. Prove that PL = [am a..-” ..., a1, (1,] and q" : [am and, ..., as, m],
"—1 'I "—1
provided at > 0.
12. Verify the results of Exercise ll for n = 5 using the finite simple continued
fraction [3, 2, l, l, 5].
13. Let x be a real number greater than 1. Prove that the nth convergent of
1
E is equal to the reciprocal of the (n 7 1)th convergent of x.

14. Prove that ifS—', 2—1, If, . . . , g5 are the convergents of the finite simple continued
1 2 a A
fraction [1, 2, 3, . . ., n], then 1).. : (n — 1);)“; + (n — 1)pn-1 + (n 7 2)p.._3
+--- +3P1+2PI+(pl +1)-
15. Verify the results of Exercise 14 by computing In for [1, 2, 3, 4, 5].

4.5 CONVERGENTS AS DETERMINANTS

An entirely different method of computing convergents involves the use of


determinants. The use of determinants enables us to compute each convergent
of a simple continued fraction directly from the terms of the continued frac-
tion. Thus, it is unnecessary to know the values of the preceding convergents.
As an example of the procedure, consider the problem of computing the
fourth convergent c‘ of the infinite simple continued fraction [an a2, a3, . . .].
As a consequence of Theorem 4.4.1, each of the first four convergents cn
can be expressed as the quotient of two integers pH and q,I where

171 : up q; = 1;
p2 = am + 1. q; = £124.;
p3=aapz+ptfn q3=a3qz+q1;
P4 : “4173 + 1’2, ‘1‘ = “443 + 42-
The set of equations involving the unknowns pl. 112, p3, and 174 represents a
system of four linear equations. Rearranging the terms of these equations,
we have
_P1 = ~a1

”2171 7172 = —1

P1 + “3P2 *Pa =0

[’2 +449: —P4 = 0-

By the use of Cramer’s rule for the solution of a system of linear equations,
§ 4.5 CONVERGENTS AS DETERMINANTS 173

ha!
—1
o
o
I" ‘1 o o 0
a2 —1 o o
1 (z3 —1 0
0 1 a, —1
Since all the elements above the diagonal elements in the determinant which
is the denominator are zero, the value of the determinant is equal to (—1)‘,
that is, 1. Thus,

—1 0 0 —al 111 —1 0 0

0 1 a4 0 0 0 1 a4

by the properties of determinants.


In a similar manner, the set of equations involving the unknowns q,, q,,
q}, and q‘ represents a system of four linear equations. Rearranging the
terms of these equations, we have
_q1 = _1

aq —42 = 0
41 ‘1' ”3‘1: :33 = 0

42 + “443 — 44 = 0-

Once again, by the use of Cramer’s rule,


174 CONTINUED FRACTIONS § 4.5

—l 0 0 —1

Evaluating this determinant by minors using the elements of the fourth


column,

uz —l 0

44:1 ”a ‘1

Then, by definition,

(4.5.1)
1 a3 —1
0 1 a4

Although the determinants representing 174 and 44 are of different orders,


note the similarity in the arrangement of elements. Furthermore, note that
the values of the determinants representing P4 and q4 depend directly upon
the terms of the infinite simple continued fraction [an (1,, a3, . . .].

EXAMPLE 1. By the use of determinants, evaluate the finite simple


continued fraction [1, 5, 2, 4].

The value of the finite simple continued fraction [1, 5, 2, 4] is


represented by the fourth convergent c4. Since (11 = 1, a2 = 5,
a3 = 2, and a4 = 4, then by equation (4.5.1) and the properties
of determinants
§ 4.5 CONVERGENTS AS DETERMINANTS 175

—l 0 0

5 A1 0
114:
1 2 —l

0 l 4

2 —1+0 2 —l=49+9:58;

—l 0

q‘:1 2 _ 1—49,
_ . gin—49.
Jae-18
0 1 4

These results agree with the results of Example 4 of §4.1.

The following theorem defining convergents as determinants is suggested


by considering the preceding analysis in generalized form. The proof of the
theorem is left as an exercise (Exercise 10).

Theorem 4.5.1: If? is the nth convergent En of the simple continuedfraction


5
[ab «1, 43, ...], then

11.. = H “u H and q" = || 51] H


where H acij II and || [3"] 1| are determinants of order n and n — 1, respec-
tively, and

—1 ifi+1=j

fli ifl=j
a:i l
’ 1 ifi—1=J'
0 for all other values of i andj;
176 CONTINUED FRACTIONS § 4.5

—1 ifi+1=j

ai+1 17":j
fiij‘
1 ifi— l =j

0 for all other values of i and1'.

EXAMPLE 2. Determine the fifth convergent of the infinite simple


continued fraction [2, 2,—4] by the use of determinants.
Since :11 : 2, a2 : 2, 113 : 4, a4 : 2, and a5 : 4, then by
Theorem 4.5.1 and the properties of determinants
2 —1 o o o
1 2 —1 o o
p5:0 1 4 —1 o
0 0 1 271

2—1 0 0
§4.6 SOME PROPERTIES OF CONVERGENTS 177

=2-40+9=89;

,_s_89'
cs—qs—

EXERCISES
In Exercises 1 through 8 evaluate each finite simple continued fraction by the use of
determinants:
1. [2, 3, 5]. 2. [1,3,11].
3. [—5, 3, 2]. 4. [0,5,6].
5. [1, 2, 3, 4]. 6. [4, 3, 2, 1].
7. [4, 3, 9, 6]. s. [1, 9, 81, 9].
9. Determine the fifth convergent of the infinite simple continued fraction
[6, 3, 12] by the use of determinants.
10. Prove Theorem 4.5.1.

4.6 SOME PROPERTIES OF CONVERGENTS

The following theorems concerning the properties of convergents are ex-


tremely interesting and useful. These theorems are prerequisite to an under-
standing of the use of convergents as numerical approximations to irrational
numbers which is discussed in §4.8 and §4.9.

Theorem 4.6.1: If c,I =24, where c,x is the nth convergent of a simple can-
u
tinuedfraction, then

M.-. — 11.4. = (—1)"; (4.6.1)


that is,

(—1 ..
— ”“1 = MH' 462
( ' )
c"
PROOF: The proof is by mathematical induction. Let n = 1. Then,
using the definitions of P0 and 110,

17140—1’0q1 =a1-0—l-1 = —1 =(—1)l.


178 CONTINUED FRACTIONS § 4.6

Since this case is rather trivial and uses the arbitrary definitions of Pa and
qo, we shall also verify that relation (4.6.1) is valid for n 2 2:

17q —plqz = (“2”: + 1) '1 7 '11 '42 = 1 = (—1)”-


Assume that relation (4.6.1) is valid for n = k. Then

PHI‘Ik _at+1 =(ak+1pk + ph—l)qk — pk(ak+lqk + (Ii—1)

= “Hawk + qk — mam —pq_x


= 4pm,! — pk- a.)
= —(—1)*
: (_1)k+1.

Hence,

man—1 — 11,714, = (—1)”


for n 2 1. Furthermore,

gnarl—l _Pn—iqn= (— 1)"


MM (MM (Mn—f
fl¥Pn71=(‘12"
q. qH MH’
= (—1)"
cu ‘ ”n71
MH'

EXAMPLE 1. Verify Theorem 4.6.1 for the finite simple continued


fraction [2, 3, 11, 2].

at 2 3 11 2
pr 0 1 2 7 79 165
iii 1 0 1 3 34 71

plqo—poqi =2-0—1-1:0—1= —1 =(*1)1;


P271 _P1q2=7‘1—2'3=7—6= l =(~1)2;

paqzfluqa =79-3—7-34=237—23S= —1 :(—1)3;


p443 -113t14 = 165-34 — 79-71 = 5610 — 5609 =1=(—1)4.
§ 4.6 SOME PROPERTIES OF CONVERGENTS 179

Theorem 4.6.2: Each convergent of a simple continuedfraction is a rational


number expressed in its lowest terms; that it, if 25 is the nth convergent
u
of a simple continuedfraction, then (11,, q“) = 1.

PROOF: By the use of Theorem 4.6.1, 1 can be expressed as a linear


homogeneous function of pH and q". Since (17», q_) is the smallest positive
integer that can be expressed as a linear homogeneous function ofp" and q",
it follows that (3,, q”) : 1.

Theorem 4.6.3: If e,I = %, where c,I is the nth convergent of the simple con-
tinuedfraction [an (1;, 43, . . .1, then

MM —72._2q. = (—1)""a.; (4.6.3)


that is;
(—1)"'1an
— c e = —. 4.6.4
c" n z (ML-72 ( )

PROOF: Sinoep" : any“, +pn_1 and q,I = ,,q,,_1 + q,l_2 for n 2 1,


then

11.4.4 —p._;q. = (tam—1 + 11.._z)q._; — 11.44a + a..-»


= unpn—lqn#1 +Pn—2‘In—2 _ npn»2qn~l _pn#2qn—2

= .(p.._1q._z —p.-2q._1)
= (—1)"“a,,.

Furthermore,

41.11..-. (1.41..-. MH’


Pu #En—Z =(—1!""an
q. 4..-; MM ’
n71
c” _ 6..-: = m,
_

qnqnil

EXAMPLE 2. Verify Theorem 4.6.3 for the finite simple continued


fraction [3, 4, 2, 1, 3].
180 CONTINUED FRACTIONS §4,7

l fl —1 0 1 2 3 4 5

a. 3 4 2 1 3
111 0 1 3 13 29 42 155
q. 1 0 1 4 9 13 48

p.q_. —p_.q. = 3-17 0-1 : 3 : (71)° .3 = (—1)°a.;


Mo —poqz =13-0 — 1-4 = 4 =(~1)‘-4 = (—1)‘az;
m. —p.q3 = 29-1 — 3-9 =2= (—1)1-2 = (4)2123;
114112 —p244 : 42-4 — 13-13 = —1=(—1)3'1=(—1)3a4;
p5q3 ~p3q5 2 155-9 — 29-48 = 3 = (—1)4-3 = (—1)“a5.

EXERCISES

Verify Theorem 4.6.1 for each finite simple continuedfraction:

1. [3, 6, 1, 2]. 2. [3, 1, 3, 1, 3].

In Exercixex 3 and 4 verify Theorem 4.6.3 for each finite simple cantinued fiactian:

3. [5, 2, 4, 8]. 4. [1, 3, 5, 1, 2, 4].

5. Express the results of Theorem 4.6.1 in determinant form.

4.7 CONTINUED FRACTIONS


AND LINEAR DIOPHANTINE EQ UA TIONS

The theory of continued fractions can be used to derive the form of the solu-
tions of the linear Diophantine equation

ax + by = 6, (4.7.1)

where (a, b) = 1.
The last convergent c,l of the finite simple continued fraction that repre-
sents ‘3' is equal to 5; that is, flfi=i
" b Ir (a, b) = 1, thenp, = a and q. = b-
By Theorem 4.6.1,

MP1 — Pr 1%. = (—1)"-


§ 4.7 CONTINUED mc‘norzs AND LINFAR DIOPHANTlNE EQUATIONS 181

Therefore,

1111.21 2 p.711? = (—1)”-


Multiplying both members of this equation by (—1)"c, we obtain

a[(—1)"€q,_1] + b[(~1)"“BP..21]= 0-
Hence, a particular solution x0 and y0 of the linear Diophantine equation
(4.7.1) is given by the equations

xo = (21)“541—1 and yo = (-1)“+1€11,.71~ (4-7-2)


Recall from §2.6 that if x0 and y0 satisfy the linear Diophantine equation
ax + by 2 c, where (a, b) 2 1, then every solution x and y is given by the
equations

x 2 x0 + bt and y 2 yo — at, (4.7.3)

where t is an integer.

EXAMPLE 1. Use continued fractions to determine a particular


solution of the linear Diophantine equation

88x + 25y = 2.

Since (88, 25) 2 1, solutions of the linear Diophantine equation


exist. The finite simple continued fraction that represents - g is
[3, 1, 1, 12]; the convergents of [3, 1, 1, 12] are c1 2 3, 22 2 4,

c3 2%, and c4 2 3—2. "l'hus,p4 2 88, ‘14 2 25, p3 = 7, and 113 2 2.


By Theorem 4.6.1,

11443 #1344 = (—1)“.


88g, — 25p3 2 1,

3843 + 25(—P;) = 1,
88043) + 25(-2p3) = 2,
88(4) + 25(—14) 2 2.

Hence, 4 and, —14 is a particular solution of the linear Diophantine


equation 88x + 25y 2 2.
182 CONTINUED FRACTIONS § 4.8

EXAMPLE 2. Use continued fractions to determine the general solu-


tion of the linear Diophantine equation

22x + 13y = 5.

Since (22, 13) 2 1, solutions of the linear Diophantine equation


exist. The finite simple continued fraction [1, 1, 2, 4] represents %;

the convergents of [1, l, 2, 4] are cl = 1, 02 = 2, c3 = g, and

54 z %. Thus, n : 4, pk1 = 5, and q",1 = 3. By statement (4.7.2),

a particular solution x0 and yo of the linear Diophantine equation


22x + 13y = 5 is given by the equations

xo:(—1)4-s-3:15 and yo=(—1)5-5-5:—25.


By statement (4.7.3), the general solution of the linear Diophantine
equation 22): + 13y = 5 is given by the equations

x: 15+ 13! and y= —25 —22t,

where t is an integer.

EXERCISES

Use continued fractions to determine the general solution of each linear Diophantine
equation:

1. 14x + 22y : 50. 2. 18x + 5y 7 7.


3. 11x 7 30y : 29. 4. 23x + 54y = 1.
5. 37): 7 11y : 23. 6. 87): + 37y = 807.
7. 69): + 54y : 387. 8. 1586x — 806y = 338.

4.8 THEOREMS 0N
INFINITE CONTINUED FRACTIONS

In §4.3 some properties of the convergents of simple continued fractions in


general, and of infinite simple continued fractions in particular, were stated
without proof. In this section two important theorems on infinite simple
continued fractions will be presented. Theorem 4.8.1 is also valid for finite
simple continued fractions.
§4.8 THEOREMS ON INFINITE CONTINUED FRACTIONS 183

Theorem 4.8.1: The odd-numbered convergents of a simple continuedfraction


form an increasing sequence; the even-numbered convergenls farm a de-
creasing sequence; every ndd-numbered convergent is less than every even-
numbered canvergent.

v n71
PROOF: If n 2 3 and n is an odd integer, then(qfl > 0 since
n ”—2
(— 1)"1 2 1, an > 0. q» > 0, and qP2 > 0. Therefore, by Theorem 4.6.3,

on — 6",; > 0;

that is, each odd-numbered convergent is greater than the preceding odd-
numbered convergent. Hence, the odd-numbered convergents of a simple
continued fraction form an increasing sequence:

c1<ca<cs<---.
. * "A1
If n 2 3 and n is an even integer, then %M < 0 since (—1)"—1
n 71—2

= —1, a,I > 0, q,I > 0, and 11,-42 > 0. Therefore, by Theorem 4.6.3,

”n # ”n72 < 0;
that is, each even-numbered convergent is less than the preceding even-num-
bered convergent. Hence, the even-numbered convergents of a simple con-
tinued fraction form a decreasing sequence:

cz>c4>66>"'.
By Theorem 4.6.1,

c —cg =fl for n22.


" n l qnqngl

Let k be any positive integer, then for n 2 2k


1
C 2k — C 2k 1 ~= —.
qqZk—l

Since qz,‘ > 0 and qZk—l > 0, then ——1— > O and
qqZk—l

22* > ”21:4 for k 2 1. (4.8.1)

Now, consider any two arbitrary positive integers r and s. Either r > s,
r = s, or r < s:
184 CONTINUED rum-10m § 4.8

(i) If r > s, then

C2’71 > 621—1

since the odd-numbered convergents of a simple continued fraction


form an increasing sequence;

52, > Cir—1

by (4.8.1); thus,

:2, > ‘21—1-

(ii) If r = s, then

CZ! > czvi

by (4.8.1).
(iii) If r < s, then

c2r > ‘2:

since the even~numbered eonvergents of a simple continued frac-


tion form a decreasing sequence;

‘2: > 92:71

by (4.8.1); thus,

”2r > 52:71-

Hence, for any two arbitrary positive integers r and s, we have shown that
Cl, > 52:71; that is, every odd—numbered convergent is less than every even-
numbered convergent:

c1<c3<cs<'--<cs<c4<cz.

EXAMPLE 1. Verify Theorem 4.8.1 for the finite simple continued


fraction [4, 1, 1, 2, 1, 3].
The calculations for the convergents of the finite simple contin-
ued fraction [4, l, 1, 2, 1, 3] appear in the table:
§ 4.8 THFDREMS ON INFINITE CONTINUED FRACTIONS 185

i I —1 o 1 2 3 4 5 6
a. 4 1 1 2 1 3
p. o 1 4 s 9 23 32 119
q. 1 o 1 1 2 5 7 26
6‘ 4 5
22 n5 27 fl
26

As decimal expressions, c1 = 4, £2 = 5, c3 = 4.5, C, = 4,6,


c5 z 4.571, and c6 m 4.577. Hence,

c1<ca<cs<efi<c¢<ez
since
4 < 4.5 < 4.571 < 4.577 < 4.6 < 5.

Theorem 4.8.2 enables us to interpret the meaning of the equation


x = [an (1;, a], . . .] where x is an irrational number; that is, the theorem
gives an interpretation of the statement that every infinite simple continued
fraction “represents” an irrational number.

Theorem 4.8.2: Let x be an irrational number represented by the infinite


31
simple continuedfraction [01, a2, a3, . . .]. Ifc" = q , where c" is the nth
n
convergent of the continued fraction, then

x = lim e",
n—wu
x > c,I if n is an odd integer,

x < c.. I' n is an even integer.

PROOF: By Theorem 4.8.1, the odd-numbered convergents c,, 03, c5,


. ., ”2P1: . . . form an increasing sequence of rational numbers which is
bounded by any even-numbered convergent. Thus, lim 9“,, exists and is
”a...
greater than every odd-numbered convergent:

cl < c, < cs < - - ~ < lim c,,,,1. (4.8.2)


Mm
In a similar manner, by Theorem 4.8.1, the even-numbered convergents c2,
eves, .. . C2... - . . form a decreasing sequence of rational numbers which is
186 CONTINUED FRACTIONS § 4.3

bounded by any odd-numbered convergent. Thus, h'm 02,, exists and is less
,._..,.
than every even-numbered convergent:
lim c“ < ' .. < 66 < 64 < 52- (4.8.3)

Furthermore, by Theorem 4.6.1,


(#1)2n
Cln _ czn—i = q 72 '
Zn n—l
Now, since q, = aiqi, 1 + qiiz, then qi increases without bound as iincreases
without bound. Therefore,
. . (—1)”
km: 7c_ =11m—=0,
hm( 2“ 2" 1) n-wn aa-l

Jim 01,, — h'm c2”,1 : 0,


n—wfi n-Nx
Jim 62,, = lim c2n_1.
won 71—40:
Hence, the sequence of even-numbered convergents and the sequence of odd-
numbered eonvergeuts have the same limit. This statement implies that
lim c,l : h'm 22,, : h'm ch,“ (4.8.4)
n—voe n—vee h...
It remains to be shown that lim 6,, = 2:. Let
Wm

X : [111, “2: ‘13: ---’ an, xfl+ll where xn+1 : [awn “n+2! ”n+3: - - -]

Then
x _&=xn+1pn +p»~1 _E_n
qn xn+1qn + qnir q»
(_1)n+1

7 qn(xfl+lqn + qr 1)y

.
11m p. .
—— — = lim —- = 0 (—1)~+1
Mai q.) H. q..(xn+lq. + qH) ’
lim x 4 limlfi = 0,
M. m ..
lim x = limli,
H... H. n
x : lim c”. (4.8.5)
n—m
§ 4.9 APPROXIMATION THEOREMS 187

Combining statements (4.8.2) through (4.8.5), it follows that

c1<c3<c5<~--<x<-~~<c5<c4<c2. (4.8.6)

EXERCISES

Verifiv Theorem 4.8.1 for each finite simple continuedfraction:

1- [4, 1. 4, 6, 5, 1]. 2. [1, 2, 3, 3, 2, 1].


Compute the decimal values of the first six convergents of each infinite simple con-
tinued fraction. Estimate the irrational number represented by each continued frac-
lion:

3. [3, 3]. 4. [4, 73].


s. [2, 1,7]. 6. [5, 1, 10],

4.9 APPROXIMA TION THEOREMS

The fact that each successive convergent of a simple continued fraction is a


better approximation to the number represented by that continued fraction
will be proved in this section. This property of convergents is not implied by
either Theorem 4.8.1 or Theorem 4.8.2, although our experience with simple
continued fractions indicates that such is the case. For example, consider
J3 : [1, 1,—2]. Neither Theorem 4.8.1 nor Theorem 4.8.2 makes any state-
ment as to whether or not c2 is a better approximation to J5 than c1;
whether or not c3 is a better approximation to «E than c2, . . . .

Theorem 4.9.1: Let x = [a1, a2, a3, . . .]. 1ftn =%, where en is the nth can-
,,
vergent of the simple continued fraction, then

I x _ & < ‘ x _ Pn_-1 ;


qr: [In—1

that is, each convergent of an infinite simple continued fraction is nearer


the value of the continuedfraction than the preceding convergent.

PROOF: Let x = [£11, a,, a3, ..., “m xnfl] where xn+1 = [an+1, “n+2!
an“, ...]. Then
188 CONTINUED FRACTIONS § 43

X : Xn+1Pn + Pnir
xn+1qn ‘1’ qua,

x(xn+lqn + qn-l) = xn+1pn + pn—l!

xn+ 1(a — Pa) = —xq.., 1 ‘1‘ Pa— 1

: 7 _ x — Pn—i .
q“ 1( qnvl)
Dividing both members of this equation by xn+1qm

x _&: _ (1.171 ‘x _pn—l)’


qn xn+ lqn $.71

[x _&=

q»»1
xn+ 14.1
. IX—p—fl"
471—1

Since x"+1 > 1 and q” 2 q,_l for n 2 2, then

41.41
<1, and
xn+1qn

x 7L" <[x—p—"il‘.
n 4,141

It should be mentioned that the results of Theorem 4.9.1 are valid for
finite simple continued fractions as well as for infinite simple continued frac-
tions.

EXAMPLE 1. Verify Theorem 4.9.1 for the first six convergents of


the infinite simple continued fraction that represents J3. For J3
use 1.7321 as an approximation.
From Example 2 of §4.2, fl : [1, m]. The calculations for
the first six convergents appear in the table:

i I #1 0 1 2 3 4 S 6

a. 1 1 2 1 2 1
p1 o 1 1 2 s 7 19 26
111 1 0 1 1 3 4 11 15
5 7 19 26
E
01 l 2 3 Z 1—1-
§ 4.9 APPROXIMATION THEOREMS 189

As decimal expressions, c1 = 1, c2 : 2, 03 z 1.6667, e‘ : 1.75,


c5 z 1.7272, and cs z 1.7333. Therefore, using J3 z 1.7321,

NE — c1] z 0.7321; [fl — c.| z 0.0179;

N3 ~ e11 z 0.2679; 1J3 — e5| m 0.0049;

|¢§ — 031 z 0.0654; N3 — c6| z 0.0012.


Hence,

|fi_céi<|\/§‘csi<|‘/§_c4i
<ifi—cai<|\/§_czi<l\/§—Cri
since

0.0012 < 0.0049 < 0.0179 < 0.0654 < 0.2679 < 0.7321.

By Theorem 4.9.1, we know that the eonvergents of an infinite simple


continued fraction represent a sequence of improved rational number ap-
proximations to an irrational number. The error involved in using the nth
convergent as an approximation to the irrational number is discussed in
Theorem 4.9.2.

Theorem 4.9.2: If e,x = 1%, where c, is the nth convergent of the simple con-
..
tinuedfmctian whose value is x, then

x — Q < i2.
11.. qn

PROOF: By Theorem 4.6.1,


(‘1)n+1
c — c = —.
"+‘ " qmqn
Thus,

[6 — cl = 1
"+1 " qn+lqn‘

By Theorem 4.8.2, x lies between 0,, and t“+1; by Theorem 4.9.1, x is nearer
c,,H than en. Therefore,
190 CONTINUED FRACTIONS § 4.9

1
< |x — c,| < (4-9-1)
2qn+1qn 'In+ Iqu-

Statement (4.9.1) is a stronger statement concerning the upper and lower


limits of the error involved in using 2,, as an approximation to x than we
1
need to prove. Since q,“ 2 (1,, then (Infill,I 2 q,’., 1 S —2, and
qn+lqn qn

x — & < i2.


q» q,

Since the qi’s form an increasing sequence, there exists an integer N such
that q—l—z < e for any small positive number E. Furthermore, for all n 2 N,
N

i, < 5. Thus, if an irrational number is expressed as an infinite simple con-


7:
tinned fraction, it is possible to obtain rational number approximations to
any desired degree of accuracy. Theorem 4.9.2 enables us to determine which
convergents to calculate in order to obtain the desired degree of accuracy.

EXAMPLE 2. Find an approximation, which is correct to the nearest


ten—thousandth of a unit, to x where x = [4, 2, 1, 3, 1, 2, 8].

Now, qiz < 0.00005 if q: > 20,000; that is, q,I > 141. Therefore,

any convergent % for which q“ > 141 will represent an approxima-


n
tion, which is correct to the nearest ten-thousandth of a unit, to x.
The calculations for the convergents of [4, 2, 1, 3, 1, 2, 8] appear in
the table:

I I —1 0 1 2 3 4 5 6 7
at 4 2 1 3 1 2 8
p: 0 l 4 9 13 48 61 170 1421
qt 1 0 1 2 3 11 14 39 326

Since q., > 141, the seventh convergent will give the required ap-
proximation. Hence,
§ 4.9 APPROXIMATION THEOREMS 191

1421
x N T23- ~ 4.3589.

It can be shown that \/1_ = [4, 2, 1, 3, 1, 2, 8] and m z


4.358899. Thus, the approximation 4.3589 is correct to the nearest
ten-thousandth of a unit.

EXERCI SE S

1. Verify Theorem 4.9.1 for the convergents of the finite simple continued fraction
that represents %.

2. Verify Theorem 4.9.1 for the first six convergents of the infinite simple continued
fraction that represents s/Zi. For ~/2_4 use 4.89898.

Find an approximation correct to the nearest ten-thousandth of a unit to the irra-


tional number represented by each infinite simple continued fraction. Estimate the
irrational namber represented by each continued fraction:
3. [1, f]. 4. [3, 1, 2, 1, 6].

In Exercises 5 through 10find an approximation correct to the nearest ten-thousandth


of a unit to each irrational number:

s. vfi. 6. JE.
7. vfi. 8. m9:
9.5+Jfi. 10.6+Jfi.

11. Find an approximation correct to the nearest hundred-thousandth of a unit to


e where
e=[2,1,2.1.1.4,1.1,6,1,l,8, ...].
12. Find an approximation correct to the nearest hundred-thousandth of a unit to
nwhere
it = [3, 7,15,1,292,1, ...].
13. Use statement (4.9.1) to find the bounds of the error involved in using g as an
approximation to 7:.
14. Use statement (4.9.1) to find the bounds of the error involved in using the fourth
convergent as an approximation to J7.

15. Prove that if I x 7 [fl < 2%, then 2—“ is the nth convergent of the simple con-
t. ,. n
tinued fraction whose value is x.

16. Prove that if l2 — xl < Icn — xi where p is an integer, q is a positive integer,


‘I
and n >1,thenq > q...
192 CONTINUED FRACTIONS § 4.10

4.10 USE OF CONTINUED FRACTIONS


IN SOL VING QUADRA TIC EQ UA TIONS

Continued fractions can be used to approximate the real roots, if they exist,
of a quadratic equation.
Consider those quadratic equations which are of the form

xzibx—1=O,

where b > 0. Then

x2=bx+l,

1
x=b+;

=b+ 11
b _
X

=b+ 11
b+ 1
b+;

Thus, continuing in this manner, x can be expressed as the infinite simple


continued fraction [11, b, b, . . .]. Hence, [5] is the positive real root of the
quadratic equation x2 7 bx 7 l : 0, where b > 0. The convergents of [5]
represent a sequence of improved approximations to the positive real root of
the quadratic equation. The other real root can be obtained by using the
property that the sum of the two roots is equal to b.

EXAMPLE 1. Find approximations to the roots of the quadratic


equation x2 — 5x — 1 = 0 by the use of continued fractions. Com-
pute each root correct to the nearest tenth of a unit.
Since xz — 5x ~ 1 2 0 is a quadratic equation of the form
x2 — bx — 1 = 0, where b > 0, the infinite simple continued fraction
[5] is the positive real root. Since it is only required that the roots
§4.10 USE OF CONTINUED FRACTIONS IN SOLVING QUADRATIC EQUATIONS 193

of the given quadratic equation be correct to the nearest tenth of a


unit, the process of evaluating the convergents of [5] may be termi—
nated when the values of two successive convergents agree to the
nearest tenth of a unit. Now,

01:5.

c,:5+§:2?6=52,

c,_5+ 1 1=%~52
1
5+3
Hence, 5.2 is an acceptable approximation to one of the roots of the
quadratic equation x2 — 5x 7 1 = 0. Since the sum of the roots is
5, an approximation to the second real root is 70.2.

EXAMPLE 2. Find an approximation to the positive real root of the


quadratic equation x2 7 2x 7 1 : 0 by the use of continued frac-
tions. Compute the root correct to the nearest thousandth of a unit.
The infinite simple continued fraction [2] is the positive real
root of the quadratic equation x2 7 2x 7 1 7 0. Now, ql—z < 0.0005

if q > 44. Therefore, any convergent1: for which q,I > 44 represents
an approximation, which 1s correct to the nearest thousandth of a
unit to the positive real root of the given quadratic equation. The
calculations for the convergents of [2] appear in the table:

1 ll 71 0 1 2 3 4 5 6

a. 2 2 2 2 2 2
pr 0 1 2 5 12 29 70 169
q1 1 0 1 2 5 12 29 70

Since q6 > 44, the sixth convergent 17—7609 represents the required ap-
proximation. Hence,
169
X:W z 2.414;
194 CONTINUED FRACTIONS § 4.10

that is, an approximation, which is correct to the nearest thousandth


of a unit, to the positive real root of the given quadratic equation
x2 72x— 1 =0 is 2.414.
Note that the exact value of the positive real root of the given
quadratic equation can be obtained by using the quadratic formula
and is equal to l + fl Furthermore, I + J? m 2.414, which is
correct to the nearest thousandth of a unit.

The general procedure illustrated in this section can be used to determine


approximations to the real roots, if they exist, of any quadratic equation.
However, it may be necessary to evaluate many more convergents than we
have evaluated in considering quadratic equations which are of the form
x2 — bx — 1 = 0.

EXAMPLE 3. Find approximations to the roots of the quadratic


equation x1 — 6x + 2 = 0 by the use of continued fractions. Com-
pute each root correct to the nearest hundredth of a unit.
Since x1 — 6x + 2 : 0, then

x226x—2,

x=5_Z
X

=6— 2
5_ 2
6* 2
6— ..

By using elementary algebra, x can be expressed in a more convenient


form:

x=6+ 1
(—3)+ 1
6 +*
(—3) + - - -
Although x is not equal to an infinite simple continued fraction, it is
represented by an infinite continued fraction. The first four con-
vergents of the continued fraction are
§4.10 use or: com-mum FRACTIONS [N sorv QUADRATIC EQUATIONS 195

51:6»

cz=6+fi=L37z 5.67,

c3=6+ 1 1:1—z565,
(~3)+3

c4=6++1=%z 5.65.
(—3)+'——1—
+(73)
Hence, one root of the quadratic equation x2 — 6x + 2 = 0 is 5.65,
which is correct to the nearest hundredth of a unit. Since the sum of
the roots is 6, the second root is equal to 0.35, which is correct to the
nearest hundredth of a unit.

EXAMPLE 4. Determine the quadratic equation if the infinite simple


continued fraction [ff] represents one of its roots.
Let x =[3,_2]. Then

_7x+3
_2x+l’
2x2+x=7x+3,

2x1—6x—3:0.

Hence, [3,—2] is one of the roots of the equation 7.7:2 — 6x — 3 = 0.


By the use of the quadratic formula, the positive root of the
quadratic equation 2.):2 — 6x # 3 = 0 can be shown to be equal to
3 +2 15. Thus, 3%5 = [fl].

EXERCISES

Find approximation: to the mat: of each quadratic equation by the use of continued
fractiam'. Compute each root correct to the nearest hundredth of a unit:

l.x’-3x—1=0. 2.x‘76xA1=0.
196 CONTINUED FRACTIONS § 4.11

3.x’~4x—1=0. 4.x‘77x—1:0.
S.x‘—10x~1=0. 6.x’+5x—1:0.
7.X1+il=0. 8.x1#2X—2:0.
9.x’—4x+2=0. 10.x‘+5x+2:0.

In Exercises 11 through 14 determine the quadratic equation one of whose roots is


represented by each infinite simple continuedfraction:

11. [T2]. 12. [571].


13. [2, Z]. 14. [7,171].
15. Prove that if x‘ e an — b = 0 where ob ¢ 0 and a2 + 4b is not a perfect
square, then the continued fraction [a, g] is a real root of the quadratic equa-
tion.
16. Prove that if ax1 + bx + c : 0 where obc at 0 and b‘ — 4ac is not a perfect
square, then the continued fractionl—g, is a real root of the quadratic equa-
tion.

Use the results of Exercise 16 to find approximations to the roots of each quadratic
equation. Compute each root correct to the nearest tenth ofa unit:

17.3x1—6x—4=0. 18.2x‘+3x71:0.

4.11 PERIODIC CONTINUED FRACTIONS

An important and interesting subset of the set of infinite simple continued


fractions is the set of periodic continued fractions. A periodic continued
fraction is a continued fraction of the form

[(11, a2, an, —b1, b2, 1);] (4.11.1)


where n is a nonnegative integer and m is a positive integer. The period of
continued fraction (4.11.1) is the sequence of repeating terms b1, b2, . . .,
bm; the length of the period is m, the number of terms that repeat. If n = 0,
the periodic continued fraction (4.11.1) is of the form

[171, b2, b,,.], (4.11.2)


and is called a purely periodic continued fraction.
Recall that a quadratic irrational is an irrational number that is a solu-
tion of a quadratic equation ax2 + bx + c : 0 where a, b, and c are integers.
§4.11 PERIODIC CONTINUED FRACI'IONS 197

It follows that every quadratic irrational is a real number which has the form
r + 3 fl where r and s are rational numbers, .r aé 0, and k is a positive
integer which is not a perfect square. The periodic continued fractions differ
from other continued fractions in that they represent quadratic irrationals.
For example,

1+m_ _,:
3 —[1.2.11
«75 =[4,1,3,1,s];
_1+‘/§_ _
T7[0,1].

The continued fraction representation of 1 +3 10 is an example of a purely


periodic continued fraction.

Theorem 4.11.1: Every periodic continued fraction represents a quadratic


irrational.

PROOF: Consider any periodic continued fraction

[an a2, . . ., a", W]

Let

x = [(11, a2, . . ., an, y] (4.11.3)

Where

y : [W].
Since

y = [[71, b2, bm, m],


then

y =11?“ 172. --~, 17..., .vl- (4-11-4)


The value of the continued fraction in (4.11.4) is equal to the (m + 1)th
convergent. Let;—1 denote the ith convergent of the continued fraction in
1

(4.11.4). Then
198 CONTINUED FRACTIONS § 4.11

= ypm "‘1‘ Fruit


yam + 11,—1’
and

M” + (qua; - pay—pr; = 0-
The roots of this quadratic equation with integral coefficients are irrational
numbers since y satisfies the equation and y is represented by an infinite
simple continued fraction. Therefore, y is a quadratic irrational. Let
y = r + 5 «fl? where r and s are rational numbers, 5 aé 0, and k is a posi-
tive integer which is not a perfect square. The value of the continued fraction
in (4.11.3) is equal to the (n + 1)th convergent. Let 5—} denote the ith conver-
gent of the continued fraction in (4.11.3). Then

x= yp;, + l
, .
yqn+qn—1
Substituting r + sfl for y, we obtain

= (r + s55»); + p1.”
(r + s km; + 41.2-1
g A + Bill?
T C + DJI?

where A, B, C, and D are rational numbers. Then

= (A + NEXC — Dfi)
(c + 0mm ~ M?)
_(AC + klm)2 + (BC— Ami:
22—kD

_AC kBD +BC— AD,—


Cz—kD1+C2—s k

= r’ + s’x/I?
where r’ and i’ are rational numbers. Furthermore, s’ 96 0 since x is repre-
sented by an infinite simple continued fraction. Therefore, x is a quadratic
irrational and every periodic continued fraction represents a quadratic
irrational.
§ 4.11 nrkronic common) FRACTIONS 199

EXAMPLE 1. Use the method employed in the proof of Theorem


4.11.1 to determine the quadratic irrational represented by the in-
finite simple continued fraction [1, 2, 3,—1].
Let x = [1, 2, y] where y = [3,—1]. Then y = [3, 1, y]. The first
two convergents of [3, 1, y] are 0‘ = 3 and c2 = 4; thus,

_M
y_y+1’

y2—3y—3=0,

“l._
3

h
Y—§+

The first two convergents of [1, 2, y] are 61 = 1 and c2 = %; thus,

* (11 + 3 21)(8 7 2J2_1)


_ (8 + 2‘/2_1)(s — 22721)

_ 19 — £21.
’ 10 ’

that is,

[1,2.3,_1]=19 ‘10 2‘.

EXAMPLE 2. Determine the quadratic irrational represented by the


infinite simple continued fraction [3, 5].
Let x = [3, y] where y = [3]. Then y = [5, y]. Since p1 = 5,
q1 =1,p,J =1, and 40 = 0 for [5, y], then
200 CONTINUE) FRACTIONS § 4.11

=5y_+1_
y y
yZ—Sygl=0,

“is
Y—E-i-

Sincepl =3,q1 =1,p0 : l,andq0 =0for [3,y], then

5 29
x_3(§+T +1
T Li»
2 2

_17+3¢2_9
‘ 5-1—2729
_ (17 + 3mm; — 29)
’ (5 + 2729' )(5 — 329)
_
7 1 +23529,,

that is,

[3, 3] = #5.

The converse of Theorem 4.11.1 is known as Lagrange’s Theorem and


is stated as Theorem 4.11.2. The proof of Lagrange‘s Theorem is omitted
since it involves substantial difficulty for a first reading in number theory.
The two theorems considered together show that quadratic irrationals are the
only real numbers Whose continued fraction representations are periodic.

Theorem 4.11.2 (Lagrange’s Theorem): Every quadratic irrational can be


exprersed as a periodic continued fraction.

The process of expressing any quadratic irrational as a periodic con-


tinued fraction is basically the same as that illustrated in §4.2.
§ 4.11 PERIODIC CONTINUED FRACTIONS 201

EXAMPLE 3. Express 5 +3 10 as a periodic continued fraction.

Since 2 < 5 +3 10 < 3, then 2 is the greatest integer less than

M Thus
3 ' ’
s+m_ m—L _ 1
3 _2+ 3 ‘2+ ’2+ m+1
¢'10—1 3
=2+ 1 =2+
1
1+\/10—2 1+ ;
27'10—2
=2++=2+
1+ 1 1+ 1 1
§7_10+2 2+27—10-2
2 2
=2+ 1‘
1+ 1
2+ 2‘
l7—1o+2
=2+ 11
”—1-
2+ 3210+2
3
=2+ 1 1
1+ 1
1+(103 1)
2+7,—

At this point note that the expression (3%) appears once

again. The expansion of ($) as a continued fraction is once


again
202 CONTINUED FRACEIONS § 4.12

Hence,

5% = [2, ‘1‘, 2, 1].

EXERCISES

Determine the quadratic irrational represented by each infinite simple continued


fraction:

1. [4, 1, 3, 4]. 2. [LT].


3. [0, m]. 4. [m].
s. [1, 1.7]. a [1, 1, i].
7. [7:]. s. [H].
Express each quadratic irrational as aperiodic continued fraction:

9. 1 + «i. 10. #5
1 + J2—1‘ 12. @13— 2 .
11. —2—.

4.12 CONTINUED FRACTIONS FOR x/F

In the examples of previous sections, we have shown that

f8=.[2,fi1; m=[4,fi ,
J5=[1,1.—2]; x/5=[2.2,_4];
x/i=[1.§]; m=[4.m1
Every continued fraction representation of a square root which is not a per-
feet square is a periodic continued fraction by Theorem 4.11.2. By an exami-
nation of the continued fraction representations of the square roots listed
above, we might conjecture that the period begins after the first term. In
§4.12 CONTINUED FRACTIONS FOR Jk 203

order to prove this property, we need to consider a preliminary theorem


concerning purely periodic continued fractions.

Theorem 4.12.1: Let x = r + sJk and E = r — s k, where r + sJk is


a quadratic irrational. If x > 1 and #1 < )_c < 0, then the continued
fraction that represents x is a purely periodic continuedfraction.

The proof of Theorem 4.12.1 will be omitted. As examples of Theorem


4.12.1, note that

2+\/§>l, —1<2—‘/§<0, and 2+\/§=[Z];

1+3 10>1, —l<1;3@<0. and [+3l°=[1.2,ll;

fl>r
2
—1<1_2—‘/5<0, and #:[1,2};

3+7 23>1, e1<fl<o and 3+7 23:[—1,s,13].

Theorem 4.12.2: If k is a positive integer which is not a perfect square, then


the continuedfraction that represents x/k is a periodic continued fraction
whose period begins after the first term; in particular,

J} = [an a2, a3, a... 2a1-


PROOF: Let fl = [an (1;, a3, . . .]. Since 111 is the greatest integer less
than Jk, then (11 + x/k > 1 and —1 < a1 ~ dk < 0. Then, by Theorem
4.12.1, a1 + J]? is a purely periodic continued fraction. Therefore,

(11+ We = rm
«2: —a. Hm}
= 1a! + [mum]
=mmfl

A table of periodic continued fractions for W, where k is a positive


integer which is not a perfect square and 2 S k g 50, follows.
204 CONTINUED FRACTIONS § 4.12

Continued Fractions for J]?


[1, E]
[1, 1,—21
[2}]
[2. 271
[2, 1, 1, 1, 4]
[2,171]
[3,61
[3, 5]
[3,2731
[3,1,1,1,1, 6]
[3, 1, 2, 1, 6]
[3.13]
[4,51
[4, U1
[4, 2,1, 3,1, 2, 8]
[4, fl]

[5, 3, 2, 3, 10]
[5, 2, 1, 1, 2,10]
[5. 2,—101
[5, 1, 1, 3, 5, 3, 1,1, 10]
[5,1,1,1,10]
[5, 1, 2, 1, 10]
[5, 1, 4, 1,10]
[5, W1
[5,171
6—
§4.12 CONTINUED FRACTIONS FOR J]? 205

An examination of the table suggests several additional properties of the


periodic continued fractions that represent square roots of k. For example,
the period of each continued fraction, not including 2a“ is a symmetric ex-
pression. Thus, it appears that every continued fraction for W is of the form

[£11, 112, as, at, - - -. a4, (13, a2, 2111]-


This statement can be shown to be true. The proof is left for another reading
in number theory.
An examination of the continued fractions for V? where k = 2, 5, 10,
17, 26, 37, and 50 suggests the following theorem.

Theorem 4.12.3: Ifp is a positive integer, then the periodic cantinuedfractian


that represents \/p2 + 1 is [p, E].

PROOF: Let p be any positive integer. Then

x/pz—H=p+(\/pz—+1-p):p+—l—
1
x/pz+1~p
# 1 7 1
_p+\/p2+l+pfip+2p+(«/p2+1~p)'
At this point note that the expression (4 p1 + 1 — p)‘ appears once again.
The expansion of (V132 + l — p) as a continued fraction is once again

1
2p + (Up1 +1—p)'
Hence,

V171 + 1 = [11, 27]-

An examination of the continued fractions for J? where k : 3, 8, 15,


24, 3S, and 48 suggests the following theorem.

Theorem 4.12.4: If p is a positive integer greater than 1, then the periodic


continuedfraction that represents ‘lpz — l is [p 7 1, l, 2(p — 1)].

The proof of Theorem 4.12.4 is left as an exercise (Exercise 5).


206 CONTINUED FRACTIONS § 4.12

EXERCISES

In Exercises 1 through 4 verify Theorem 4.12.] for each quadratic irrational:

1.3+Jfi. 2.2+~/7.

11:22 4, w,
5. Prove Theorem 4.12.4.
6. Prove that if p is a positive integer, then the periodic continued fraction that
”Drew“S V1? + 2 is [pm 2p]-
7. Prove that ifp is a positive integer: then the periodic continued fraction that
represents Vp‘ + 2p is [1-, 1, 2p].
. Let p be a positive integer greater than 2. Make a conjecture about the pe-
riodic continued fraction that represents ~/s. Verify your conjecture, if
possible, for (a) p = 8; (b) p : 9.
Examine the continued fractions for #2 where k = 6, 12, 20, 30, and 42.
t‘

Make a conjecture about the irrational number represented by (a) [7, m];
(b) [8, T16]. Verify your conjecture, if possible, in each case.
ANSWERS
TO SELECTED
EXERCISES

CHAPTER 1.

§ 1.1

1. An integral domain. 2. Not an integral domain.


3. Not an integral domain. 5. An integral domain.
6.q=18,r=6. 7.q= —18,r=2.
8.q=12,r=0. 9. q=33,r=13.

§l.3

1. 1221d. 2. 6126mm.
3. 1010002mm. 4. 10011000100101mo.
5. 34130.1x. 6. 68420nine.
7. 890. 8. 7885.

207
208 ANSWERS 1‘0 SELECA'ED EXERCISES

9. (3) 204cm“; (b) 100001oom.


10. (a) 435dght; (b) 100011101mo.
11. Addition Table for the Base Five System

+ 0 l 2 3 4
0 0 l 2 3 4
1 1 2 3 4 10
2 2 3 4 10 11
3 3 4 10 ll 12
4 4 10 11 12 13

Multiplication Table for t he Base Five System

X 0 1 2 3 4
0 O 0 0 0 0
1 0 1 2 3 4
2 0 2 4 ll 13
3 0 3 ll 14 22
4 0 4 13 22 3]

12. Addition Table for the Base Eight System

0 1 2 3 4 5 6 7
0 0 1 2 3 4 5 6 7
1 1 2 3 4 5 6 7 10
2 2 3 4 5 6 7 10 11
3 3 4 5 6 7 10 ll 12
4 4 5 6 7 10 11 12 13
5 5 6 7 10 ll 12 13 14
6 6 7 10 11 12 13 14 15
7 7 10 ll 12 13 14 15 16

Multiplication Table for the Base Eight System

X 0 1 2 3 4 5 6 7
0 0 0 0 0 0 0 0 0
1 0 l 2 3 4 5 6 7
2 0 2 4 6 10 12 14 16
3 0 3 6 11 14 17 22 25
4 0 4 10 14 20 24 30 34
5 0 5 12 17 24 31 36 43
6 0 6 14 22 30 36 44 52
7 0 7 16 25 34 43 52 61

13. 112010five. 14. 4223seven.


CHAPTER 2 209

§ 1.4
1. 363. 2. 30.
3. 210. 4. 746.
s. 336. 6. 125.
7. 168. ' s. 1265.
.
9. .§.”""“- 10. $316+ 1)(i+ 2).
11. True. 12. False. 13. True. 14. False.

CHAPTER 2.

§21
6. Since ti and n + 1 represent two consecutive integers, either n or n + 1 contains
the factor 2. Now, if an integer is divided by 3, the remainder is 0,1, or 2. There.-
fore, n is of the form 3k, 3k +1, or 3k + 2.1fn : 3k, then 3ln. Ifn : 3k +1,
then 2n+1=6k+3 and 3|(2n+1).Ifn=3k+2,thenn+1=3k+3
and SK): + 1). Hence, 6111(21 + 1)(2n + l).
The expression n’ 7 n is equal to n(n — 1)(n + 1)(nz + 1). Since n and n + 1
Ir-

represent two consecutive integers, either 71 or n + 1 contains the factor 2. Since


I: — 1, n, and n + 1 represent three consecutive integers, then u 7 1, n, or
n +1 contains the factor 3. Now, if an integer is divided by 5, the remainder is
0, 1, 2, 3, or 4. Therefore, :1 is of the form 5k, 5k + 1, 5k + 2, 5k + 3, or
5k+4. Ifn=5k, then 5|(n’7n). If n=5k+1, then 7171:5k and
5|(n’ 7 n). Ifn : 5k + 2, then It: +1: 5(5k2 + 2k + 1) and 51(r1s 7 It). If
n=5k+3,thenn‘+1=5(5k‘+3k+2)and5](n57n). Ifn=5k+4,
then u + 1 = 5(k + 1) and 5|(n’ — 71). Hence, 301(11’ — n).

(a) 169 is not a prime since 169 = 13 - 13; (b) 197 is a prime; (c) 239 is a prime;
((1) 473 is not a prime since 473 = 11 - 43.
10. Let p be a prime and x be any integer. If p = x’ 7 1, then
p=(x— 1)(x‘+x+ 1).
Note that the only possible factors ofp are $1 and $11. If x 7 1 = 1 and
x2+x+1=p, then x=2 andp:7. If x—1=—1 and x1+x+1
= 7p, then x = 0 andp = —1. However, 71 is not a prime. 1c1 + x +1
=1 andx71:p, then x=0 andp=—1, or x:71 andp=—2.
However, neither 71 nor 72 is a prime. If x2 + x +1 = —1 and x — 1
= —p, then x is not an integer and 1) cannot be a prime. Hence, 7 is the only
prime that is one less than a perfect cube.
210 ANSWERS TO SELECTED EXERCISES

§ 2.2

1. There are eleven pairs of twin primes in Table 2.1.1: 3 and 5, 5 and 7, 11 and
13, 17 and 19, 29 and 31, 41 and 43, 59 and 61, 71 and 73, 101 and 103, 107
and 109, 137 and 139.
3. The primes between 400 and 500 are 401, 409, 419, 421, 431, 433, 439, 443,
449, 457, 461, 463, 467, 479, 487, 491, and 499. Hence, the pairs of twin primes
between 400 and 500 are 419 and 421, 431 and 433, and 461 and 463.
4. (a) The primes less than 200 are 2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43,
47, 53, 59, 61, 67, 71, 73, 79, S3, 89, 97, 101, 103, 107, 109, 113, 127, 131, 137,
139, 149, 151, 157, 163, 167, 173, 179, 181, 191, 193, 197, and 199; (b) the
primes less than 300 also include 211, 223, 227, 229, 233, 239, 241, 251, 257,
263, 269, 271, 277, 281, 283, and 293.
8. 5! + 2, 5! + 3, 5! +4, and 5! + 5; that is, 122,123,124, and 125.
9. 1011+ 2,101! + 3,101! +4,..., and 101! + 101.
10. (a) 32:3+29= 13 +19;
(b) 100=3+97=11 +89=17+83:29+71 =41 +59:47+53;
(c) 456=7+449=13+443=17+439=23+433 =37 +419
=47+409=59+397:67+389=73+383:83+373
:89+367=97+359=103+353=107+349=109+347
= 139 + 317 = 149 + 307 : 163 + 293 : 173 + 283 =179 + 277
= 193 + 263 =199 + 257 = 223 + 233 = 227 + 229;
(d) 1024 = 3 +1021 : 5 +1019 =11 +1013 = 41 +983
=47+977:53 +971 =71 +953 =83 +941 = 113 +911
= 137 + 887 = 167 + 857 : 197 + 827 = 227 + 797 = 251+ 773
=263 +761: 281+ 743 : 347 + 677 : 383 + 641: 431+ 593
= 461 + 563 = 467 + 557 = 503 + 521.
11. Letp, = 2 and p1 = 3. Thenp; +1 : 4 and (171172) + 1 = 7. The next prime
p3, that is, 5, lies in the closed interval from 4 to 7.

§ 2.3

1. 4. 2. 13. 3. 17. 4. 68.


5. 3. 6. 42. 7. 77. 8. 1.
9. x = 7, y : ——17; other sets of values exist.
10. x = 1, y = +1; other sets of values exist.
11. x : 56, y = +91; other sets of values exist.
12. x = 40, y = +64; other sets of values exist.
13. x = +3, y = 17; other sets of values exist.
14. No integral values of x and y exist.
CHAPTER 2 211

15. x = 3, y = —6; other sets of values exist.


16. x = 4, y = —14; other sets of values exist.

§ 2.4

l. 6. 2. 15. 3. 1.
4. 23. 5. 4. 6. 1.
7. x = 28, y = —16, z = —1; other sets of values exist.
8. x = 17, y = ~153, z = —1; other sets of values exist.
9. x = 18, y = ~18, z = —3; other sets ofvalues exist.
10. No integral values of x, y, and z exist.
11. w = ~15, x = 45, y = 5, z = 1; other sets ofvalues exist.
12. No integral values of w, x, y, and z exist.

§ 2.6

1. x z 75 + 7! and y = 35 — 48:, where t is an integer.


2. No integral values of x and y exist.
3. x =11 + 30! andy = —3 — 11!, where tis an integer.
4. x = 2 + 21 and y = 3:, where t is an integer.
5. x = 7t and y : 73 + 13:, where t is an integer.
6. No integral values of x and y exist.
7. x = 4t and y = —6 + 71, where t is an integer.
8. x =10 + 54! and y = 73 — 171, where t is an integer.
9. x = 8 + 11! and y = 1 + St, where t is a nonnegative integer.
10. No positive integral values of x and y exist.
11. x = 8 + 3! and y 2 2 + 2t, where t is a nonnegative integer.
12. x=1andy=66;x=128ndy=4.
13. S9. _ 14. $10.21.

§ 2.7

l. (45, 21) = 3; [45, 21] = 315.


2. (83, 68) = 1; [83, 68] = 5644.
3. (120,110): 10; [120, 110] = 1320.
4. (86, 71) = 1; [86, 71] = 6106.
5. (224, 192) = 32; [224, 192] = 1344.
6. (1287, 507) = 39; [1287, 507] = 16,731.
212 ANSWERS T0 SELECTED EXERCISES

18. (11,17) = (315, 75) = 15; 315 =15 -21 and 75 =15 -5. Thus,g :15, a1 = 21,
and b1 = 5. [a, b] = [315, 75] = 1575. Hence, since 1575 : 15 -21 -5,
[as b1=gla1|lb1|
where a = 315 and b = 75.

19. 1a. b1=112, 9] =36; (Ek b):(12,


k
9 )=(12, 16): 4. Therefore, Si. nce
144 144

144
36 — T,

(a. b1 :

wherea=12,b:9,andk=l44.
360.
.533

|abc[ = |24 ' 60 '14l : 20,160;


(ab. ac, be) = (24-60, 24-14, 60-14): 24;
[11, b, c] = [24, 60, 14] = 840.
Hence, since 20,160 : 24 - 840,
label = (ab, no, he) - [11, b, c]
where a = 24, b = 60, and 0 =14.
2 (a, [12, c1) = (120, [270, 2251) = (120, 1350) : 30;
9‘

[(a, b), (a, c ] = [(120, 270), (120, 225)] = [30, 15] : 30; hence,

(a, [[7, CD : [(4. b): (a. 6)]


where a = 120, b = 270, and c : 225.
27. label = (a, b, c) - [11, b, 6] provided (ab, ac, be) = 1; that is, provided
(a. b) : (a. v) = (b. r) = 1.
§ 2.8

(a) 403; (b) 1170; (c) 1010; (d) 15,960.


.NI"

(a) 0(6) :(1 +2)(1 +3) = 12 =2-6;


(b) v(28) : (1 +2 + 2‘)(1 + 7) = 56 2 2-28;
(0) 11(496) = (1 + 2 + 2‘ + 2’ + 2‘)(1 + 31) = 992 = 2-496;
(11) ”(8128) = (1 + 2 + 2’ + 23 + 2‘ + 2’ + 2‘)(1 +127)
:127-128 : 16,256 : 2-8128.
(1:) a(120) : (1 +2 + 22 + 23x1 +3)(1 + 5)=15-4-6 = 360 = 3-120;
S“

(b) 0(672) = (1 + 2 + 22 + 2’ + 2‘ 3- 2’)(1 + 3)(1 + 7)


: 63-4-8 =2016 = 3-672:
22.
9.“

Now, 144 = 2‘ - 31 and (16, 9) = 1. Then


CHAPTER 2 213

25—13371
”(144)—2—1 -3_1 =31-13=403,

a(l6)7 25—1
2_1=31,
and
33—1
”(9)’fi:13‘
Hence,
0(144) = a(16) - 41(9).
7. Now,60=2’-3-5 =6-10. Then
0(60) = (1 + 2 + 250 + 3)(1 + 5) = 168;
and
a(6) ' "(10) = [(1 + 2)(1 + 3)] [(1 + 2)(l + 5)] = 216.
Hence, 0(60) at 0(6) - u(10). Other examples exist.
9. The positivedivisors of 12 are 1, 2, 3, 4, 6, and 12; the squares of the six posi-
tive divisors of 12 are 1, 4, 9, 16, 36, and 144. Then
2 d’=1+4+9+16+36+144=210.
an:
Since 12 = 2‘ - 3,
fip2(m+1)_ 1 222(2+1)71'32(1+1)_1

i=1 pi—l 22—1 32—1


= 21 - 10 = 210.
Hence,
Zdl : fip?(l1+1)_l
d1; (:1 pf _ 1
fornlandh=L

§2.9

1. (a) 15; (b) 24; (c) 2; (d) 24.


2. 12.
3. 24.
8. Now,144 = 2‘ - 3‘ and (16, 9) = 1. Then
v(144) = S - 3,
v(16) : 5,
and
v(9) = 3.
Hence,
v(144) : v(16)-v(9).
214 ANSWERS TO SELECTED EXERCISES

9. v(4) = 3; v(2) - v(2) = 2 ~ 2 = 4; v(4) :4: v(2) - v(2). Other examples exist.
11. Since 24 = 23 - 3, v(24) = (3 + 1)(1 + 1) : 8. The eight positive divisors of
24 are 1, 2, 3, 4, 6, 8, 12, and 24. Then
H d=1'2-3-4-6-8-12-24 = 331,776
am
and
v(24)

24 2 = 24‘ = 331,776.
Hence,
v(n)
H d=n 2
m
for n = 24.

§ 2.10

1. (a) Since 220 = 2’-5 '11 and 284 : 21-71, then

(7(220) = (1 + 2 + 2’)(l + 5)(l + 11)


= 7 - 6 - 12
= 504
: 220 + 284; ,
a(284) = (1 + 2 + 2‘)(1 + 71)
= 7 - 72
= 504
= 220 + 284.
Hence, 220 and 284 are amicable numbers.
(b) Since 17,296 = 2‘ -23 -47 and18,416 : 2‘ - 1151, then
v(17,296) = (1 + 2 + 21 + 23 + 2‘)(1 + 23)(1 + 47)
= 31 - 24 - 48
: 35,712
: 17,296 + 18,416;
a(18,416)=(1+ 2 + 22 + 23 + 2‘)(1 +1151)
: 31 - 1152
= 35,712
= 17,296 + 18,416.
Hence, 17,296 and 18,416 are amicable numbers.
2. (3) Since 672 = 2s - 3 - 7, then
CHAPTER 2 215

v(672)=(1+ 2 + 2‘ +-»-+25)(1+ 3)(1+ 7)


= 63 0 4 - 8
= 2016
= 3 - 672.
Hence, 672 is a multi-perfect number.
(b) Since 523,776 2 2’ - 3 -11 - 31, then
tr(523,776) = (l + 2 + 22 + ' " + 29)(1 + 3)(1 +11)(1 + 31)
=1023.4.12.32
= 1,571,328
= 3 . 523,776.
Henoe, $23,776 is a multi-perfect number.
4. Since 28 = 22 - 7, then the positive {divisors of 28 are 1, 2, 4, 7, 14, and 28.
Hence,

=28+14+7+4+2+1
——
28
= 2;
that is, the sum of the reciprocals of the positive divisors of the even perfect
number 28 is equal to 2.
6. Since 71 = 28 = 2‘ - 7, then the positive divisors of n are 1, 2, 4, 7, 14, and 28.
Note thatpl = 2,p; = 7, a1 = 2, and a; = 1. Hence,

§d1=1‘+2‘+4‘+7‘+l4‘+28’

:1+4+16+49+196+784
21050;
Up,
k “+1
+1:2'28.23 +1_7 2 +1
1-1P1+1 2+17+1
50
_2.23.3..s_

=1050;
fii+l
2— kp'
— +11‘or n=28.
e-d 72,3131 [n+1 .
7. Now, 130,816 = 2“(2’ —— 1). However, 2’ — 1 is not a prime since 29 — 1
= 7 - 73. Hence, the even integer 130,816 is not a perfect number.
8. 120 and 672.
216 ANSWERS T0 SELECTED EXERCISES

§ 2.11

1. M19 : 524,287.
2. M“ = 2“ 7 1 = 2047 = 23 . 89. Hence, M“ is a composite number.

§2.12
1. (a) 8; (b) 96; (c) 2002; (d) 2160.
2. Now,
“3") = 1,
¢(3‘) = 2»
¢(3*) = 9(1 7 i) = 6,
¢(3°) : 27(1 — a = 18,
and

¢(3‘) = 81(1 — a : 54.


Then

$095135 = W“) + W) + 456‘) + ¢(3’) + «M


:1+2+6+18+54
= 81
= 3‘.
5. Since 6’ = 36 = 21 - 3‘, then

45(6‘) : 36(17%)(17%): 35-%-33' : 12.


Sinoe6=2-3, then
_ _l _l, .1},
“6’60 2><1 3>_623‘2
and
6-¢(6)=6-2=12.
Hence,

9%“) = 6 ' 115(6)-


Since 28 = 22 - 7, then
."

$15(28)=281—l 1—1 :12.


2 7
Since 28 is an even perfect number, then 28 is of the form 29' ‘(2" ~ 1) where
p = 3; therefore,
CHAPTER 2 217

21"‘(2N — 1) = 21(22 — 1) = 4-3 =12.


Hence,
¢(28) = 21(2) 7 1).
§ 2.13

l. (11) Since 17 is a prime, then ¢(17) = 16. The sixteen positive integers less
than or equal to 17 and relatively prime to 17 are 1, 2, 3, . . ., and 16. Now,
1 l
2-17-¢(17) =3-17-16 = 136

and
1+2+3+"'+16=136.
Hence,

§-17-¢(17)=1+2+a +--~ +16.


(b) Since 28 = 2’ - 7, then

mm=noaao—%=m
The twelve positive integers less than or equal to 28 and relatively prime to
28 are 1, 3, 5, 9, 11, 13, 15, 17, 19, 23, 25, and 27. Now,
1 1
2-28-¢(28) = 5-28-12 _ 168
and
1+3+5+9+11+13+15+17+19+23+25+27=168.
Hence,

%-28-¢(28)= 1 +3 +5 +9+ 11
+13+15+ 17+ 19+23 +25+27.

2. (9.) Since 36 = 21-3‘, then v(36) = 3 -3 = 9. The nine positive divisors of


36 are 1, 2, 3, 4, 6, 9, 12, 18, and 36. Moreover, 93(1) = 1, 95(2) = 1,
1‘6) = 2, 95(4) = 2, 19(6) = 2. 15(9) = 6, #502) = 4. “13) = 5, “35) = 12.
and
“2361101) = 43(1) + M) + 166) + 46(4)
+ 95(6) + 95(9) + 9502) + ¢(18) + ¢(36)
=l+1+2+2+2+6+4+6+12
= 36.
(h) Since 147 = 3 - 7’, then v(l47) = 2 - 3 = 6. The six positive divisors of
147 are 1, 3, 7, 21, 49, and 147. Moreover, ¢(1) = 1, 175(3) = 2, 125(7) = 6,
¢(21) = 12, 95(49) 2 42, ¢(147) = 84, and
218 ANSWERS TO SELECIED EXERCISES

.33.,“ = ¢<1> + 11(3) + 125(7) + ¢(21> + «49) + «147)


=1+2+6+12+42+84
= 147.
3. Now, 144 = 2‘ - 3* and (16, 9) = 1. Then
¢(144) = 144(1 7 i)1 (1 7 3)1 = 4s,

¢(16)=16(1—%)= s,
and

56(9): 9(1 —%) = .


Hence,
45044) = 4505) '¢(9)~
4. Now,60 =22-3-s =s-1o. Then

and
«memo—90axle)”:
1 l 1 1
¢‘6"¢‘1°)=[6(1—5)("3)][1°(1—i)(11)]
= 2-4 = 8.
Hence, ¢(60) at ¢(6) - 9500). Other examples exist.
Since r=12=2‘-3 and s=21= 3-7, then rs :252=Z‘-3’-7 and
9‘

g = (r, x) = (12. 21) = 3. Therefore,

=2521 —§><1 —%><1 —1) =


no —; <1 1)
m=2n<1—%><1—%>:n.
75(3) = 2.
and -

g-viérésms) = 3-42- 12 = 72 = fl”)-

§2.14
l. 17, 32, 34, 40, 48, and 60.
2. 31 and 62.
CHAPTER 3 219

3. 73, 91, 9S,111,117,135,146,148,152,182,190, 216, 222, 228, 234, 252, and 270.
4. No solution exists.
5. Since
¢(l)-¢(l7)=1-16 and (1,17)= 1, x=17;
¢(1)-¢(32)=1-16 and (1,32): 1, x:32;
¢(2)-¢(17) =1-16 and(2, 17) 2 1, x: 34;
¢(5)-¢(8)=4-4and(5,8)=1, x:40;
¢(3)-¢(16)=2-8and(3, 15)=1, x=48;
¢(5) - ¢(12) = 4 -4 and(5, 12) =1, x = 60.
Hence, the six solutions of the equation ¢(x) = 16 are 17, 32, 34, 40, 48, and 60.

CHAPTER 3.

§3.1

1. (a) 5; (b) 1.
2. (a) True; (b) true; (c) true; (d) false.
3. 11‘°—1=(11’)’—1=(11571)(11=+1)
= (11 — 1)(11‘ +11’ +112 +11 +l)(ll +1)
x(11‘ — 11’ +111 4 11 + 1).
Since 10|(11 7 1), 51(11‘ +113 + 11‘ +11 +1), and 2|(11 + I), then
10-5-2|(11—1)(ll‘ +11J +111 +11 + l)(ll + 1)
X(11‘ —— 11’ +112 #11 +1);
that is, 100|(11‘° — 1). Hence, 11” E 1(mod 100).
4. (a) Not a complete residue system;
(b) a complete residue system;
(c) a complete residue system;
(d) a complete residue system.
5. (2, 3, 5, 7, 11, 13, 29); others exist.
6. {0, 4, 8, 12, 16, 20, 24).
7. (a) ..., —10, —3, 4, 11, 18, 25, ...;
(b) —6, —1,4,9,14,19,...;
(c) ~13, —s, 3, 11, 19, 27,
(d). —14, —2, 10,22, 34.46,
(e) . —11, —4, 3, 10, 17, 24,
. .—10, —3,4, 11, 18, 25, .
(r) —11, —s,1,7, 13, 19,
220 ANSWERS T0 SELECTED EXERCISES

§3.2

1. (a) 9 + 13 E 5 + (73)(mod 4), that is, 22 E 2(mod 4) since 4|(22 # 2);


(b) 9 - 13 E 5 - (—3)(mod4), that is, 117 E r15(mod4) since4l[117 —— (715)].
2. 10‘ E 45(mod 3) since 3|(10’ — 4’), that is,
31(10 7 4)(1()4 +103 '4 +101 '41 +10-4J + 4‘).

3. Leta=9,b:3,c=22,andd: 72.1fr=4ands=3,then
ar+cs=9-4+22-3
= 102
and
br+ds:3-4+(—2)-3
= 6.
Since 61(102 7 6), then
102 z 6(mod 6);
that is,
ar + a: E br + dx(mod m)
given a E b(mod m) and c E d(mod m).
P

Leta=11andb=3.IfP(x)=3x‘+2x—5,then
P01) = 3(11)2 + 2(11) — 5
= 380
and
P(b) = 3(3)2 + 2(3) — 5
= 28.
Since 8|(380 7 28), then
380 E 28(rnod 8);
that is,
P(a) E P(b)(mod m)
given a E b(mod m).

. (a) 1; (b) 8.
aux

. Leta = 3,17 : 1, d = 2, and m = 4. Then a E b(mod :1) since 2K3 — 1), and
dlm since 2|4; however, a i b(mod m) since 4*(3 — 1).

§3.3

1. (a) 94674518 since 91(3 + 7 + 4 + 5 + 1 + 8), that is, 9428;


(b) 911,520,397 since 910 + 5 + 2 + 0 + 3 + 9 + 7), that is, 9|27.

2. (a) 111370546 since 11I(6 — 4 + 5 — 0 + 7 ~ 3), that is, 11l11;


(b) 11*22,481,907 since 11,?(7 —— D + 9 — 1 + 8 — 4 + 2 — 2), that is, 11119.
CHAPTER 3 221

§ 3.4

1. (a) A reduced residue system;


(b) a reduced residue system;
(c) not a reduced residue system;
(d) not a reduced residue system.

2. (a) Not a reduced residue system;


(b) not a reduced residue system;
(c) a reduced residue system;
((1) not a reduced residue system.

3. C’ = (5x + 2|): 5 C) = (37, 718, 47, 22, 87, 2).


Since 37 E 7(mod 6), ——18 E 0(mod 6), 47 E 17(mod 6), 22 E 4(mod 6),
87 E 9(mod 6), and 2 E —4(mod 6); that is, since each element of C’ is con-
gruent modulo 6 to one and only one of the elements of C, it follows that
the set
' C’ = (37, #18, 47, 22, 87, 2)
is a complete residue system modulo 6.

4. R’ = (axls} = (7, 35,133, 161).


Since (7, 12) = 1, (35, 12) = 1, (133, 12) :1, and (161, 12) = 1, then
condition (i) of the definition of a. reduced residue system is satisfied for R’.
I 1
Condition (ii) is satisfied since 95(12) : 12(1 *2) (1 — 5) = 4. Finally,

condition (iii) of the definition of a reduced residue system is satisfied since


no two members of R' are congruent modulo 8:
35 EE 7(mod 12), 133 35 7(mod 12), 161 i 7(mod 12),
133 z 35(mod 12), 161 a 35(mod 12), 161 i 133(mod 12).
Hence, R’ is a reduced residue system modulo 12.

ea ® 101 111
[01 101 111 101 101 101
111 111 101 111 101 111
An integral domain.

6. 6)" 101 m 121 ® 101 111 121


101 101 111 121 101 101 101 101
111 111 121 101 111 101 [11 121
[2} [21 [0] I1] [2] [0] [2] [1]
An integral domain.
222 ANSWERS T0 SELECTED EXERCISES

7' (9 l [0] [1] [2] [3] ® a [0] [l] [2] [3]


l0] l0] l1] [2] [3] [0] [0] [0] [0] [0]
[1] [1] [2] [3] [0] l1] [0] [ll [2] [3]
[2] l2] [3] [0] [1] [2] [0] [2] [0] [2]
[3] [3] [0] [1] [2] [31 [0] [3] l2] [1]
Not an integral domain.

3 ® [0] [1] [2] [3] [4] ® [0} [ll [2] [3] [4]
[0] [0] [l] [2] [3] [4] l0] [0] [0] [0] [0] [0]
[1] l1] [2] [3] [4] [0] [1] [0] [1] [2] [3] [4]
[2] [2] [3] [4] [0] [1] [2] [0] [2] [4] [l] [3]
[3] [3] [4] l0] [1] [2] [3] [0] [31 [1] [4] [2]
[4] [4] [0] [1] [2] [3] [41 [01 [4] l3] [2] [1}
An integral domain.

9 ® I! [0] l1] [2] [3] [4] [5] ® [0] [ll [2] [3] [41 [5]
[0] [0] [1] [2] [3] [4] [5] [0] [0] [0] [0] [01 [0] [0]
[ll [1] l2] [3] [4] [fl [0] [l] [0] [1] l2] [3] [4] [5]
[Z] [2] [3] [4] [fl [0] [1] [2] l0] [2] l4] [0] [2] [4]
[3] l3] [4] [5] 10] [1] [2] [3] [0] [3] [0] [3] [0} [3]
l4] [4] [5] l0] [1] [2] [3] [4] [0] l4] [2] [0] [4] [2]
[5] [5] l0] [1] [2] [3] [4] [5] [0] [5] [4] El [2] [1]
Not an integal domain.

10' E II [0] [1] [2] [3] [4] [5] [6] ® l [0] [l] [2] [31 [4] l5] l6]
[0] [0] [11 [2] [3] [4] [5] [6] [0] [0] [0] [0] [0] [0] [0] [0]
[1] [1] [Z] [3] [4] l5] [6] [0] [1] [0] [1] l2] [3] [4] l5] [6]
[2] [2] l3] [4] [5] [6] l0] [1] [2] [0] [2] [4] [6] [1] [3] [5]
[3} [3] [4] [5] [6] [0] [l] [2] [3] [0} [3] [61 [2] [5] [1] [4]
[4] [4] [5] [6] [01 ll] [2] [3] [4] [0] [4] [11 [5] [21 [6] [3]
[5] [5] [5] l0] [1] [2] [3] [4] [51 [0! [fl [3] [1] [6] [4] [2]
[5] [5] [0] [ll [2] [3] [4] [51 [6] [0] [61 [5] [4] [3] [2] [1]
An integral domain

11. Module systems with prime moduli are integral domains.

§ 3.5

1. Note first of all that (3, 10) = 1. Since ¢(10) = 4, then 3‘ = 81. Hence,
34m) 2 1(mod 10)
since 101(81 — 1).

2. Since (5, 12) = 1, then


CHAPTER 3 223

x E 54"”)‘1 - 7(mod 12)


E 875(mod 12);
that is,
x E 11(mod 12).

Since (2, 9) = 1, then


x E 2¢(9)*1 - 3(mod 9)
E 96 (mod 9);
that is,
x E 6(mod 9).
P

Since (7, 10) = 1, then


x E 7¢(10)-1 -1(mod10)

E 343 (mod 10);


that is,_
x E 3(mod 10).

Since (8, 5) = 1, then


x E 8¢(5)—1 ~4(mod 5)
E 2048(mod 5);
that is,
x E 3(mod 5).

Since (2, 17) = 1, then


x E 2¢U7F1 -1(mod17)
a 32,768(mod 17);
that is,
x E 9(mod 17).

Since (5, 8) = 1, then


x E S‘M‘3)‘l - (—3)(mod 8)
E —37S(mod 8);
that is,
x E 1(mod 8).

Note first of all that (2, 13) = 1. Sincep —— 1 =12, then up" = 2” = 4096,
and 131(4096 — 1). Hence,
2” E 1(mod 13);
that is,
a"‘ E 1(modp)
wherea=2andp=13.
224 ANSWERS T0 sELECTED EXERCISES

13. 1, 3, 4, 5, and 9.
14. 1, 2, 4, s, 9, 13, 15, and 16.
15. 3x5 _+ 2x — 2 E 0(mod 7).

§ 3.6

l. (4). 2. (8,18).
3. No solutions exist. 4. (8).
5. (2, 5, 8, 11). 6. (7).
7. (5). 8. No solutions exist.
9. No solutions exist. 10. (6, 30).
11. (4). 12. (7).
13. (2, ll, 20, 29). 14. (21, 46, 71, 96, 121}.
15. (6, 13, 20). 16. (2, 5, 8, 11, 14, 17, 20).
17. (2).
18. (9, 20, 31, 42, 53, 64, 7s, 86, 97, 108, 119).
19. (2, 6, 1o, 14, 18, 22, 26, 30, 34, 38, 42, 46, so, 54, 58).
20. (15, 33, 51).
§ 3.7
1. x : 3 + 61 andy = —2 — 71, where 1 is an integer.
2. x = 20 + 271 and y = 78 7111, where t is an integer.
3. x = 42 + 1311 andy = 24 + 751, where 1 is an integer.
4. x : 21 and y z 4 — 31, where 1 is an integer.
5. x = 8 + 111 and y = 37 + 611, where t is an integer.
6. x = 9 + 771 and y = —5 — 651, where 1 is an integer.
7. x = 2 + Stand y =11 r 31, where 1 is an integer.
8. x =18 + 311 and y = 35 + 611, where t is an integer. ,
9. x=4—m+9n,y=m,andz= 1 +2m—7n,wheremandnareintegers.
10. x = 2 + 2m + 4n, y = m, and z = 7 —— m — 3n, where m and» are integers.
11. x=2+5m,y=1+2n,andz= 72—12m+3n,wheremandnarein-
’tegers.

12. No solutions exist.


13. The corporation can buy the following number of automobiles of type A,
type B, and type C, respectively: 80, 20, and 0; 83, 12, and 5; or 86, 4, and 10.
14. The group could have contained the following number of men, women, and
children, respectively: 1, 13, and 6; 2, 11, and 7; 3, 9, and 8; 4, 7, and 9; 5, 5,
and 10; 6, 3, and 11; or 7.1, and 12.
CHAPTER 3 225

§ 3.8

1. (5E1)!+1:4!+1=24+1=25.Since5|25,then
(p E 1)! +1 E0(modp)
wherep = 5.
2. 1- 18 E 71(mod 19); 4-14 E —1(mod 19); 10-17 E —1(mnd 19);
2- 71(mod 19); 5-15 E —1(mod19); 11-12 E —1(mod19);
3 -6 E —1(mod 19); 7-8 E —1(mod 19); 13 - 16 E —1(mod19).
Hence,
18-17-16- -3-2-1 E (—1)’(mod 19),
18! E —1(mod19),
18! + 1 E 0(mod 19).
Since (19 — 1)! + 1 E 0(mod 19), then, by the converse of Wilson’s Theorem,
19 is a prime.
3. (8 — 1)1.+1 = 7! +1 = 5040 +1: 5041. Since 8,1’5041, then
(p El)! +1 E 0(modp)
where p = 8. Hence, by the cnntrapositive form of the statement of Theorem
3.8.1 (Wilson‘s Theorem), it follows that 8 is not a prime.
4. (a) The associates of p, where p = 17, are 2 and 9, 3 and 6, 4 and 13, 5 and
7, 8 and 15, 10 and 12, and 11 and 14; that is, 2-9 E1(mod17), 3-6
E 1(mod17), 4- 13 E 1(mod 17), 5 -7 E1(mod17), 8- 15 E 1(mod 17),
10- 12 E 1(mod 17), and 11 - 14 z 1(mod 17). Therefore,
2-3-4-5-6-7-8-9-10-11-12-13-14-15 E1(mod17),
16! E 16(mod17),
16! — 1(mod17),
161+1= 0(mod17).
Hence,
(p E 1)! + 1 E 0(modp)
where p = 17.
(b) The associates of p, where p = 31, are 2 and 16, 3 and 21, 4 and 8, 5 and
25, 6 and 26, 7 and 9, 10 and 28, 11 and 17, 12 and 13, 14 and 20, 15 and
29,18 and 19, 22 and 24, and 23 and 27; that is, 2 - 16 E 1(mod 31), 3 -21
E 1(mod 31), 4 - 8 E 1(mod 31), 5 - 25 E 1(mod 31), 6- 26 E 1(mod 31),
7-9 E 1(mcd 31), 10-28 E 1(mod31), 11-17 E 1(mod31), 12- 13E 1
(mod 31), 14-20E1(mod 31), 15 -29 E 1(mod 31), 18- 19 E 1(mod 31),
22 -24 E 1(mod 31), and 23 -27 E 1(mod 31). Therefore,
2-3-4-5- -26-27-28-29 E 1(mod 31),
30! E 30(mcd 31),
226 ANSWERS To SELECTED EXERCISES

30! E —1(mod 31),


30! + 1 E 0(mod 31).
Hence,
([1 E 1)! + 1 E0(modp)
wherep : 31.
5. 2, 3, and 5.
s. (3) Since 54 : 2 - 33, then ¢(s4) = 54(1 — %)(1 7% )=ls andP:1-5-7-
11-13-17-19-23-25-29-31'35-37-41-43-47-49-53. Note that 54
can be expressed in the form 2pk wherep is an odd prime and k is a positive
integer. Hence, we need to show that P + 1 E 0(mod 54). Now,
1-53 E —1(mod 54);11-49 E —1(mod 54); 25 -41 E —1(mod 54);
5 -43 E w1(mod 54); 13-29 E —1(mod 54); 31-47 E —1(mod 54);
7 -23 E E1(mod 54); 17-19 E 71(mod 54); 35 -37 E 71(mod 54).
Therefore,
1-5-7-11-13-17-19-23-25-29-31-3s-37-41-43-47-49-53
—1(mod 54),
P: E1(mod s4),
P+ 1 E0(mod 54).

(b) Since 120 = 23-3-5, then ¢(120) = 120(1 — a (1 E a (1 E a = 32


andP:1-7-11-13-17-19-23-29-31-37-41-43-47-49-53-59-61
-67-71 -73-77-79-83-89-91 -97-101 -103-107-109-113-119. Note
that 120 is not of the form p" or 2p“ where p is an odd prime and k is a
positive integer; obviously, 120 E 4. Hence, we need to show that P — 1
E 0(mod 120). Now,
1- 119 E —1(mod 120); 37- 107 E 71(mod 120);
7- 17 E —1(mud 120); 41-79 E 71(mod 120);
11 - 109 __ flu-nod 120); 71(mod 120);
13-83 E 71(mod 120); _ —-1(mcd 120);
19 - 101 E 71(mod 120); E E1(mod 120);
23 -73 E E1(mod 120); E 71(mod 120);
II

29 -91 E —1(rnod 120); 67 - 77 E 71(mod 120);


31- 89 E —1(mod 120); 103 - 113 E 71(mod 120).
Therefore,
P s 1(mod 120),
P — 1 a 0(mod 120).
CHAPTER 3 227

7. By Wilson‘s Theorem, 18! + 1 E 0(rnod 19). If 18! + 1 E 0(mod 23), then


18! + 1 E 0(mod 19-23); that is, 18! + 1 E 0(mod 437). To prove that
23|(18!+ 1), we write
18! + 1 =(23 E 5x23 —6)(23 —7)~~-(23 —22) + 1.
Every term of the expanded right-hand expression obviously contains 23 as a
factorexceptthetermZZ-Zl -20--- - '7-6-5 + 1. Now, 18! +1 E 0(mod23)
if22-21'20- -7-6-5 +1 =0(mod23),Notethat
23 E0(rnod23),
4! E 1(mod 23),
22! 522-21-20- -7-6-5,
22! +1 522-21-20- -7-6-5+ 1.
By Wilson's Theorem, 22! + 1 E 0(1nod 23). Hence,
22-21-20- -7'6-5+1E0(mod23).
Therefore, 18! + l E 0(mod 437).

§ 3.9

((4. 0), (8, 1), (3. 2). (7, 3). (2. 4), (6. 5). (1. 6), (5, 7), (0, 8)}-
5".“1"

((2. 0), (5. 0), (1, 1), (4, 1), (0, 2). (3. 2), (2, 3). (5. 3). (1. 4). (4, 4). (0, 5), (3. 5))-
((2, 3), (6, 3). (10. 3). (14, 3), (18. 3). (0. 3). (4. 8), (3, 8), (12, 8), (16, 3), (2. 13).
(6,13), (10,13), (14,13), (18,13), (0,18), (4,18), (8,18), (12,18), (16.18)).
A

. ((1 0). (3 0). (5 0), (7 0) (9 0) (ll 0), (13 0). (0 7). (2 7), (4 7), (6 7).
(8 7).(10 7).(12 7)}-
No solutions exist.
«5'-

- ((0. 1), (0. 5). (0. 9). (1. 2). (1. 6), (1, 10). (2, 3). (2. 7), (2, 11), (3. 0). (3. 4),
(3, 8), (4, 1), (4, 5), (4, 9), (5, 2), (s, 6), (5, 10), (6, 3), (6, 7), (6, 11), (7, o), (7, 4),
(7, s), (8, 1), (8, 5), (8,9), (9, 2), (9, 6), (9, 10), (10, 3), (1o, 7), (10, 11), (11, 0),
(11, 4), (11, 8)).
((4, 0). (2. 1). (0. 2), (3. 3). (l. 4)).
9“.“

{(3, 0), (7. 0). (2, 1), (6, 1). (1. 2), (5, 2), (0, 3), (4. 3), (3, 4). (7, 4), (2. 5), (6, 5).
(1, 6). (5, 6), (0, 7). (4. 7)).
P

((0, 2), (10, 2), (20, 2), (2, 2), (12, 2), (22, 2), (4,2), (14, 2), (24, 2), (6, 2), (16, 2),
(26, 2), (s, 2), (18, 2), (28, 2), (o, 7), (10, 7), (20, 7), (2, 7), (12, 7), (22, 7), (4, 7),
(14, 7), (24, 7), (6, 7), (16, 7), (26, 7), (8, 7), (18, 7), (28, 7), (0, 12), (10, 12),
(20, 12), (2, 12), (12, 12), (22, 12), (4, 12), (14, 12), (24, 12), (6, 12), (16, 12),
(26, 12), (s, 12), (18, 12), (28, 12), (0, 17), (10, 17), (20, 17), (2, 17), (12, 17),
(22, 17), (4, 17), (14, 17), (24, 17), (6, 17), (16, 17), (26, 17), (8, 17), (18, 17),
(28, 17), (o, 22), (10, 22), (20, 22), (2, 22), (12, 22), (22, 22), (4, 22), (14, 22),
(24, 22), (6, 22), (16, 22), (26, 22), (8, 22), (18, 22), (28, 22), (0, 27), (10, 27),
228 ANSWERS T0 SELECTED EXERCISE

(20. 27). (2. 27). (12. 27). (22. 27). (4. 27), (14. 27). (24. 27). (6. 27). (16. 27).
(26, 27), (s, 27), (18, 27), (28, 27)).
10. No solutions exist.
11. ((8, 1), (25, 1), (15, 3), (32, 3), (5, 5), (22, 5), (12, 7), (29, 7), (2, 9), (19, 9),
(9, 11), (26, ll), (16, 13), (33, 13), (6, 15), (23, 15), (13, 17), (30, 17), (3, 19),
(20, 19), (10, 21), (27, 21), (0, 23), (17, 23), (7, 25), (24, 25), (14, 27), (31, 27),
(4, 29), (21, 29), (11, 31), (28, 31), (1, 33), (18, 33)).
12. ((1, 0), (3, O), (5, 0), (0, I), (2, l), (4, 1), (1, 2), (3, 2), (5, 2), (0, 3), (2, 3), (4, 3),
(1, 4), (3, 4), (5, 4), (0, 5), (2, 5), (4, 5)).
14. ((2, 0, 1), (5, 0, 1), (2, 0, 3), (5, 0, 3), (2, 0, 5), (5, 0, 5), (1, 2, 1), (4, 2, 1), (1, 2, 3),
(4, 2, 3), (1, 2, 5), (4, 2, 5), (0, 4, I), (3, 4, 1), (0, 4, 3), (3, 4, 3), (0, 4, 5), (3, 4, 5),
(0,1,1),(3,1,1),(0,l, 3), (3, 1, 3), (0, 1, 5), (3, 1, 5), (2, 3, 1), (5, 3, 1), (2, 3, 3),
(5, 3, 3,), (2, 3, 5), (5, 3, 5), (1, 5,1),(4, 5, 1), (l, 5, 3), (4, 5, 3), (1, 5, 5), (4, 5, 5)).

§ 3.10

1- ((12. 8)}. 2. ((14, 13)).


3. ((26,10)). 4. {(6, 3),(20,10),(13,17)).
5. No solutions exist. 6. ((3, 4, 1)}.
8. x E 197(mod 228). 9. x E 242(mod 858).
10. x E 106(mod 252). 11. x E 4011 — 24b — 155(mod 120).
12. x E —1(mod 9889). 13. x E 12,113(mod 20,128).
14. x E 103(mod 180). 15. x E 104(mod 165).
17. x E 26(mod 63). 18. x E 148(mod 210).
19. 23. 20. 59.
21 301 22. 651

§ 3.11

l. x E 5(mod 13) or x E 8(mod 13).


2. No solutions exist.
3. No solutions exist.
4. x E 8(mod 31) or x E 23(mod 31).
5. x E 6(mod 11) or x E 7(mod11).
6. No solutions exist.
7. x E 8(mod 13) or x E 11(mod13).
8. x E 1(mod 17) or x E 4(mod17).
9. x E 6(mod 15) or x E 9(mod 15).
c

. x E 1(mod 8), x E 3(mod 8), x E 5(mod 8), or x E 7(mod 8).


.u
CHAPTER 4 229

11. x E 8(mod 65), x E 18(mod 65), x E 47(mud 65), or x E 57(mod 65).


12. No solutions exist.
13. x E 1(1'nod 12).
14. x E 5(mod 28), x E 12(mod 28), x E 13(mod 28), or x E 20030011 28).
18. Ifa = 0, then x E 0(mod 7); if a = 1, then x E 1(mod 7) or x E 6(mod 7);
if a = 2, then x E 3(mod 7) or x E 4(mod 7); if a = 4, then x E 2(mod 7)
or x E 5 (mod 7).

CHAPTER 4.

§ 4.1

. [2.1.1.2. 2]. pg1,1n.


yummy-

9°99!“

-RLLLifl [—2. 1. 1. 2,1, 2].


.mLLLA MLZLLA
. L—7,10rl.1,1.2L ELLLLLH
gg 1971
1? 631‘
g] §§
11. 12.
1T 2y
13.
2; 14.
_1s15
56 531'
1059 35
15.
256‘
16.
E
17. ZZ§ 18. m
15T 43'
19. (a) [6, Z. 8]; (b) [6, 2, 7, 1]-

§ 4.2

.[2,fi. [3, 3.71.


pan-pan

[4, E]- H, 2, 1.1—1.1].


. M,1,5717571,81 U,E77T7fin
.MJJJJJJJJJJA [25,if3fl
Via Jfi.
11. 73—1. w? , 4.
13. fig 43 + ¢E§
' 14 '
230 ANSWERS T0 SELECFED EXERCISES

_ 16. 3 JFT
JE
15.2+~/2.
17.[0,a;,az,a:,...].

§4.3

3 5
1.01:1,01:2,C1=E,64:§.

2.01=2,£; §,c:*29—0,m=:—g.

3.61:8,Cz=9,03778—1,04=%.

21c *E c =7—1—
4 *1
"" ""3’ c ’ 16’ ‘ 19’ 5 54'
5.c;=—3 Czw—%,Cs=—2?5,64=714101,05:

6. 01—0,0171,CJ_4,C4 ,2 ,2
37,65 _2
78.06 y
505.

7.c1=1,c:=2,c3=§,c4=%,c5=%.

8.c,=2,c2=3,C3=%,04=§,05=%.

9 c *5 c :28 :flc _5201 5 _52,525_


‘ " ’ 1 10' 3 101’ "1020’ “10,301’
515 52,525 5201 _
5<fi<10,301<JE<1020<10'
10. £1=3,Cz=4,93=277,94=%,65—251—53;

2721331
3<7<5_5<‘/1—5<3<4'

§4.4

1.21:2,cz:Z,c; ::,c.=%.

2 c.:4,c;=5,63 %,c: %,c,—%14~5

3 c l :16
u 2 =4
31 6 3 go
1976 —5—-4
:41, c 5 =2
60-

4.5176,B)77C3712—3,C:7?,657%
CHAPTER 4 231

5.12158. "%'
1%, $%-
9.01=5,c;=6,Es=%:c4=%!cs=%‘

10.c;=8,c:=9,c;=%sc‘=
%’c’:%’

2
12.
2
7 10 11 95
2 3 s 28
E=51L;=[5,1,1,2,3]=[a,,a.,a,,az,m];

£=§=[5,1,1,2]:[a,,a4.aa.azl-
q: 5
15.

ps:4p4+4p3+3pz+2PI+Pl+1
=4.43+4-10+3-3+2-1+1+1
=225.
§4.5

1, 2 71 0 —1
0 1 5

,&,fl
c,#ql_16.I-Ience,[2.3,5] =fl
16'
2. 1-1 0 3 —l

o 1 11
_&:‘£
53_q’ 34. Hence, [1. 3, 11:fl
1 34'
3. —51 -13
pa: _ ° :_33;q1=l13 —1
2|=73
o 1 2
c; =P_’ = _£‘ Hence, [—5. 3. 2] = ig‘
113 7 7
232 ANSWERS T0 SELECTED EXERCISES

1
_1
173’ s 7176;417l: _;|=31;
o 1
C3 :12=£
q: 31.Henca, [0, 5, 6] :2
31.

171 o o 2 —1
114 71 7' ’1 °=4a;q.=1 3 —1 =30;
o 1 3—1 0 1
o o 1 4
=a=fl
q‘ 301 Hence, [1, 2, 3, 4] =£
30.

4—1 0 o 3 71
_01 31 712 _1:43,q4=(1)
o 1—1 =10,
o o 1 1
:&=£
‘1‘ 10. Hence, [4, 3, 2, 1] :£
10.

= 0:1 _2 3 1 9 _1 7739;11471 9 717171;o


0 o 1 6 0 1 6
CA 7a=fl
7‘" _E
171‘ Hence, [4, 3, 9, 6] 7 171'
7 o
7 0i :7? o
1 s1 71:7309;q.=19 _1 0
81 7176579;
0 o 1 9 0 1 9
715:7309
7 q‘ -—6579' Hence, [1,
77309
9, 81, 9] 7 —6579'

6—1 0 o o
1 3 71 o o :3: 3
115 =0 1 12 71 o=ssss;q,= o 1 —1 =14os-’
o o 1 371 0 0 12
o o o 1 12
:E=8886
q, 1405'

1 —l 0 l 2 3 4

a1 3 6 1 2
p1 o 1 3 19 22 63
111 1 o 1 6 7 20
CHAPTER 4 233

plqo7puq1=3-0—1-1:071= 71 =(71)‘;
pzq1—plq1:19-l —3-6=19718=1=(71)‘;
17311; 711243 :22-6719-7=1327133= =(71)’;
p4q37p3q.=63-7722-20=4417440=1=(—1)‘.

1
4
1
plqa7pnq1z3-07l-l=0—l—
pq—pxq;=4'1—3-1=4737
paqz—pzq; = 15-1 74-4: 15 716: 71 :(71)’;
p.11;7pgq4=19-4—15-5=76—75=1=(—l)‘;
11q 7p4q5=72-5—19-19:3607361 = —1 =(—1)’.
1' 71 0 1 2 3 4

17141., —p_,q1 =5-1—0-1= 5 =(71)“-S :(71)°a,;


pzqa7paqz:11-071-2= 2=(—1)" =(—1)‘az;
paq. 7p1q: =49-1— 5-9 = = (—1)’-4 = (—1)’a,;
pup —p2q4 =403-2 — 11 -74 = 78 = (71)’-8 : (70311..
2
a1 1 3 5 1 2 4
p. 0 1 1 4 21 25 71 309
111 1 0 1 3 16 19 54 235

12:11” 711—a =1-1- 0'1 =1 (71)"'1=(—1)°an;


qo 7pnq2 = 4-0 71-3 : 73 — (—1)‘ '3 = (71)‘a2;
psq, 711q = 21-171-16 = 5 =(—1)‘-5 = (—1)’a,;
m; 7M4 =2s-3 7 4-19 = 712(71)’-1.=(—1)‘a.;
11q —p3q5 = 71 - 16 7 21 '54 = 2 = (71)“2 = (71)‘a5;
115114 7p“); : 309-19 7 25.235 = 74 = (71)"4 = (—1)’a5.
5. gin—1
= (71)".
qn—l

§ 4.7
1. x=2+11randy =1 —7t,wheretisaninteger.
2. x = 4 + 51 andy 2 713 7181, where t is an integer.
234 ANSWERS T0 SELECTED EXERCISES

3. x = 19 + 301 and y = 6 + 111, where t is an integer.


4. x = —7 + 54t and y = 3 — 231, where t is an integer.
5. x = 3 +11tandy = 8 + 37t, where tis an integer.
6. x 2 8 + 37! and y = 3 e 87!, where t is an integer.
7. x = —3 + 181 and y =11 — 23r, where t is an integer.
8. x =18 + 311 andy = 35 + 61!, where {is an integer.

§4.8

1.

a; 4 l 4 6 5 1
p1 0 1 4 5 24 149 769 918
q; l 0 l 1 5 31 160 191
24 149 769 918
c: 4 5 — — — —
5 31 16019]
As decimal expressions, 61 = 4, c; = 5, c; = 4.8, c. 2 4.80645, :5 = 4.80625,
and O: : 4.80628. Hence,
ci<03<cs<cs<64<62
since
4 < 4.8 < 4.80625 < 4.80628 < 4.80645 < 5.
2.
a. 1 2 3 3 2 1
1:1 0 1 1 3 10 33 76 109
q. 1 o 1 2 7 23 53 76
c 1 2 H E E E
‘ 2 7 23 53 76
As decimal expressions, :1 = 1, c; = 1.5, c: : 1.4286, :1 2 1.4348,
c; 2 1.4340, and Cs 2 1.4342. Hence,
c.<c:<c;<c;<c.<01
since
1 < 1.4286 < 1.4340 < 1.4342 < 1.4348 < 1.5.
3. c. = 3, c. : 3.1666667, c. : 3.1621622, c. : 3.1622807, c. : 3.1622776,
and c. : 3.1622777; [3, 6'] = «m
4. c. = 4, c. = 4.125, c, : 4.12307692, c. :: 4.12310606, c. : 4.12310562, and
a. : 4.12310563; [4,13] = m.
5. c. = 2, c. = 3, :3 =28, a. : 2.8333, c. : 2.8276, and c. :: 2.8286;
[2, 1, 4]: 7E.
6. :1 = 5, c. = 6, c, : 5.90909, 6. : 5.91667, 25 :: 5.91603, and c. : 5.91608;
[5,171] = m.
CHAPTER 4 235

§ 4.9

1. Since 3—1 : [4, 5, 1, 2], the convergents of the finite simple continued fraction

that represents % are 61—


7 4, a; = Z—l, c; — 265’ and c. — —. Therefore,

%—:. = Z; 4 =1—37: 0.1765;


_n ,=%_\ .125|=82_5:o.0235;
—~
::|= ———'=fi2-:0.;0098

Hence,
——.. =0——|,0
%—c. <|%—c; <l:;-Cz <l——cl

since
0 < 0.0098 < 0.0235 < 0.1765.

2. m 2 [4, 1,—8]. The calculations for the first six convergents appear in the
table:

As decimal expressions, c. : 4, c; = 5, c; 2 4.88889, c. = 4.9, c; 2 4.89888,


and Ca : 4.89899. Therefore, using m 2: 4.89898,
lm — c.| : 0.89898; N74 — «I :3 0.00102;
NE — cal : 0.10102; NEE — Cal : 0.00010;
1m — m : 0.01009; M21 — Cal : 0.00001.
Hence,

lx/fi—cal <l‘/2_4#cs|<|\/2_4—64|
<|\/2_4—Cal <|‘/2—4—Czl<l‘/2—4—Cli
since
0.00001 < 0.00010 < 0.00102 < 0.01009 < 0.10102 < 0.89898.
236 ANSWERS T0 SELECTED EmISEs

3. 1.4142; [1, 2'] = Ji. 4. 3.7417;[3,1,2, 1, 6] = J14.


5. 5.1962. 6. 9.9499.
7. 8.4853. 8. 10.9087.
9. 8.3166. 10. 12.0828.
11. 2.71828. 12. 3.14159.
1 22 1 1 s 1
ls‘fifi |"—71<m 14‘84<lfi 3|<42‘
§4.10
1. 3.30, —0.30. 2. 6.16, 4.16.
3. 4.24, —o.24 4. 7.14, —o.14.
5. 10.10, —o.10. 6. 75.19, 0.19.
7. —2.41, 0.41. s. 2.73, —o.73.
9. 3.41, 0.59. 10. 74.56, 70.44.
11.2x’—2x—l=0. 12.x’—5x—5=0.
13. 95—5 0. 14. x1—50=0.
17. 2.5, —0.5. 18. —1.8, 0.3.
§4.11
55 + 4‘5.
1. —13 2. 4—7
+ «37

—4 + vfi
3. —3—. 4. 4 +3 ¢fi .

5. «3. 6. 2 + a.
2
7a+‘/11’+4 sab+¢nxbi+4ab
. ——2 . . —2b .
9. [2]. 10. [1, 1, 16, 2].
11. [2,173]. 12. [0, 3, 1, 2, 1714.

84.12
1.3+J16>1,—1<3—¢ifi<0,and3+¢1_:[a.
2.2+fi>1,—1<2—x/7<0,and2+fi=[4—],1.1,1.
3.1—fl>1,—1<¥<0,and1_+2£:1.4],

4-fl>1:—1<§_3—m<°:andfl=m-
CHAPTER 4 237

8- 41—75.:- = [p — l, W], where p is a positive integer greater


than 2.
(a) J6— : [7, m];
(b) «7‘ = [8, m1.
9- (a) [7,2._1]= 6—;
(b) [8, m = x/fi.
LIST OF
PRIME NUMBERS
LESS THAN
10,000

67 157 257 367 467 599 709


HQMWN

71 163 263 373 479 601 719


73 167 269 379 487 607 727
79 173 271 383 491 613 733
83 179 277 389 499 617 739
13 89 181 281 397 503 619 743
17 97 191 283 401 509 631 751
19 101 193 293 409 521 641 757
23 103 197 307 419 523 643 761
107 199 311 421 541 647 769
31 109 211 313 431 547 653 773
37 113 223 317 433 557 659 787
41 127 227 331 439 563 661 797
43 131 229 337- 443 569 673 809
47 137 233 347 449 571 677 811
53 139 239 349 457 577 683 821
59 149 241 353 461 587 691 823
6] 151 251 359 463 593 701 827
LIST OF PRIME NUMBERS LESS THAN 10,000 239

829 1193 1567 1973 2351 2741 3187 3583


839 1201 1571 1979 2357 2749 3191 3593
853 1213 1579 1987 2371 2753 3203 3607
857 1217 1583 1993 2377 2767 3209 3613
859 1223 1597 1997 2381 2777 3217 3617
863 1229 1601 1999 2383 2789 3221 3623
877 1231 1607 2003 2389 2791 3229 3631
881 1237 1609 2011 2393 2797 3251 3637
883 1249 1613 2017 2399 2801 3253 3643
887 1259 1619 2027 2411 2803 3257 3659
907 1277 1621 2029 2417 2819 3259 3671
911 1279 1627 2039 2423 2833 3271 3673
919 1283 1637 2053 2437 2837 3299 3677
929 1289 1657 2063 2441 2843 3301 3691
937 1291 1663 2069 2447 2851 3307 3697
941 1297 1667 2081 2459 2857 3313 3701
947 1301 1669 2083 2467 2861 3319 3709
953 1303 1693 2087 2473 2879 3323 3719
967 1307 1697 2089 2477 2887 3329 3727
971 ‘ 1319 1699 2099 2503 2897 3331 3733
977 1321 1709 2111 2521 2903 3343 3739
983 1327 1721 2113 2531 2909 3347 3761
991 1361 1723 2129 2539 2917 3359 3767
997 1367 1733 2131 2543 2927 3361 3769
1009 1373 1741 2137 2549 2939 3371 3779
1013 1381 1747 2141 2551 2953 3373 3793
1019 1399 1753 2143 2557 2957 3389 3797
1021 1409 1759 2153 2579 2963 3391 3803
1031 1423 1777 2161 2591 2969 3407 3821
1033 1427 1783 2179 2593 2971 3413 3823
1039 1429 1787 2203 2609 2999 3433 3833
1049 1433 1789 2207 2617 3001 3449 3847
1051 1439 1801 2213 2621 3011 3457 385]
1061 1447 1811 2221 2633 3019 3461 3853
1063 1451 1823 2237 2647 3023 3463 3863
1069 1453 1831 2239 2657 3037 3467 3877
1087 1459 1847 2243 2659 3041 3469 3881
1091 1471 1861 2251 2663 3049 3491 3889
1093 1481 1867 2267 2671 3061 3499 3907
1097 1483 1871 2269 2677 3067 3511 3911
1103 1487 1873 2273 2683 3079 3517 3917
1109 1489 1877 2281 2687 3083 3527 3919
1117 1493 1879 2287 2689 3089 3529 3923
1123 1499 1889 2293 2693 3109 3533 3929
1129 1511 1901 2297 2699 3119 3539 3931
1151 1523 1907 2309 2707 3121 3541 3943
1153 1531 1913 2311 2711 3137 3547 3947
1163 1543 1931 2333 2713 3163 3557 3967
1171 1549 1393 2339 2719 3167 3559 3989
1181 1553 1949 2341 2729 3169 3571 4001
1187 1559 1951 2347 2731 3181 3581 4003
240 LIST OF PRIME NUMBERS LESS THAN 10,000

4007 4447 4903 5333 5749 6211 6661 7103


4013 4451 4909 5347 5779 6217 6673 7109
4019 4457 4919 5351 5783 6221 6679 7121
4021 4463 4931 5381 5791 6229 6689 7127
4027 4481 4933 5387 5801 6247 6691 7129
4049 4483 4937 5393 5807 6257 6701 7151
4051 4493 4943 5399 5813 6263 6703 7159
4057 4507 4951 5407 5821 6269 6709 7177
4073 4513 4957 5413 5827 6271 6719 7187
4079 4517 4967 ‘5417 5839 6277 6733 7193
4091 4519 4969 5419 5834 6287 6737 7207
4093 4523 4973 5431 5849 6299 6761 7211
4099 4547 4987 5437 5851 6301 6763 7213
4111 4549 4993 5441 5857 6311 6779 7219
4127 4561 4999 5443 5861 6317 6781 7229
4129 4567 5003 5449 5867 6323 6791 7237
4133 4583 5009 5471 5869 6329 6793 7243
4139 4591 5011 5477 5879 6337 6803 7247
4153 4597 5021 54791 5881 6343 6823 7253
4157 4603 5023 5483 5897 6353 6827 7283
4159 4621 5039 5501 5903 6359 6829 7297
4177 4637 5051 5503 5923 6361 6833 7307
4201 4639 5059 5507 5927 6367 6841 7309
4211 4643 5077 5519 5939 6373 6857 7321
4217 4649 5081 5521 5953 6379 6863 7331
4219 4651 5087 5527 5981 6389 6869 7333
4229 4657 5099 5531 5987 6397 6871 7349
4231 4663 5101 5557 6007 6421 6883 7351
4241 4673 5107 5563 6011 6427 6899 7369
4243 4679 5113 5569 6029 6449 6907 7393
4253 4691 5119 5573 6037 6451 6911 7411
4259 4703 5147 5581 6043 6469 6917 7417
4261 4721 5153 5591 6047 6473 6947 7433
4271 4723 5167 5623 6053 6481 6949 7451
4273 4729 5171 5639 6067 6491 6959 7457
4283 4733 5179 5641 6073 6521 6961 7459
4289 4751 5189 5647 6079 6529 6967 7477
4297 4759 5197 5651 6089 6547 6971 7481
4327 4783 5209 5653 6091 6551 6977 7487
4337 4787 5227 5657 6101 6553 6983 7489
4339 4789 5231 5659 6113 6563 6991 7499
4349 4793 5233 5669 6121 6569 6997 7507
4357 4799 5237 5683 6131 6571 7001 7517
4363 4801 5261 5689 6133 6577 7013 7523
4373 4813 5273 5693 6143 6581 7019 7529
4391 4817 5279 5701 6151 6599 7027 7537
4397 4831 5281 5711 6163 6607 7039 7154
4409 4861 5297 5717 6173 6619 7043 7547
4421 4871 5303 5737 6197 6637 7057 7549
4423 4877 5309 5741 6199 6653 7069 7559
4441 4889 5323 5743 6203 6659 7079 7561
LIST OF PRIME NUMBERS LESS THAN 10,000 241

7573 7879 8221 8543 8837 9 1 61 9461 9781


7577 7883 8231 8563 8839 91 73 9463 9787
7583 7901 8233 8573 8849 918l 9467 9791
7589 7907 8237 8581 8861 9187 9473 9803
7591 7919 8243 8597 8863 91 99 9479 9811
7603 7927 8263 8599 8867 9203 9491 9817
7607 7933 8269 8609 8887 9209 9497 9829
7621 7937 8273 8623 8893 9221 951 1 9833
7639 7949 8287 8627 8923 9227 9521 9839
7643 7951 8291 8629 8929 9239 9533 9851
7649 7963 8293 8641 8933 9241 9539 9857
7669 7993 8297 8647 8941 9257 9547 9859
7673 8009 831 1 8663 8951 9277 9551 9871
7681 801 1 8317 8669 8963 9281 9587 9883
7687 8017 8329 8677 8969 9283 9601 9887
7691 8039 8353 8681 8971 9293 9613 9901
7699 8053 8363 8689 8999 9311 9619 9907
7703 8059 8369 8693 9001 93 19 9623 9923
7717 8069 8377 8699 9007 9323 9629 9929
7723 . 8081 8387 8707 901 1 9337 9631 9931
7727 8087 8389 8713 9013 9341 9643 9941
7741 8089 8419 8719 9029 9343 9649 9949
7753 8093 8423 8731 9041 9349 9661 9967
7757 8101 8429 8737 9043 9371 9677 9973
7759 8111 8431 8741 9049 9377 9679
7789 8117 8443 8747 9059 9391 9689
7793 8123 8447 8753 9067 9397 9697
7817 8147 8461 8761 9091 9403 9719
7823 8161 8467 8779 9103 9413 9721
7829 8167 8501 8783 9109 9419 9733
7841 8171 8513 8803 9127 9421 9739
7853 8179 8521 8807 9133 9431 9743
7867 8191 8527 8819 9 1 37 9433 9749
7873 8209 8537 8821 91 5 1 9437 9767
7877 8219 8539 883 1 91 57 9439 9769
INDEX

Addition, properties of, 2 Cancellation property:


Addition property of inequality, 2 for addition and multiplication, 2
Algorithm, 13, 36 of multiplication for order, 2
Amicable numbers, 69 Chinese remainder theorem, 138—139
Approximation theorems, 187—190 Closure property, 2
Archimedean property, 4 Common divisor, 34
Associates, 126 Common factor, 34
Associative property, 2 Common multiple, 56
Commutative property, 2
Base, 10 Completely multiplicative number-
Binary operations, 1, 3 theoretic function, 63
Binary system, 13 Complete residue system, 90
Brahmagupta, 142 Composite, 23

242
INDEX 243

Congruence relation, 88 Fermat, Pierre de, 110


Congruent modulo m, 87 Fermat’s theorem, 110
Congruent solutions, 113, 129 Finite simple continued fraction, 151
Continued fraction, 150 First principle of mathematical
finite simple, 151 induction, 6
infinite simple, 151 Fundamental theorem of arithmetic,
periodic, 159, 196 52, 53-54
purely periodic, 196
simple, 150 Gauss, Karl Friedrich, 30, 127
terms of, 151 General solution, 47
Convergents, 163 Goldbach, Charles, 33
even-numbered, 165 Goldhach’s conjecture, 32—33
odd—numbered, 165 Greatest common divisor, 34, 40

Diophantine equation(s) , 46 Hadamard, Jr, 30


linear in, more than two variables,
122—124 Identity property, 2
linear in two variables, 46, 120— Incongruent, 87 ,
122, 180—181 Incongruent solution(s), 110, 113,
general solution of, 47 129—1 30
particular solution of, 46 Index of summation, 15
Diophantus, 46 Indicator of n, 72
Distributive property, 2 Inequality, properties of, 2
Divisibility criteria, 99—103 Infinite simple continued fraction, 151
Division property, 5 Integral domain, 3
Divisors, 23 Inverse property, 2
Duodecimal system, 13
Lagrange, J. L., 124
Equality, properties of, 1—2 Lagrange’s theorem, 200
Equivalence classes, 89 Least common multiple, 56, 57—58
Equivalence relation, 88—89 Legendre, A. M., 30
Eratosthenes, 27 Lehmer, D. N., 27
Euclid, 29, 67 Leibniz, G. W., 70, 124
Euclid’s algorithm, 36—37 Length of the period of a continued
Euclid’s Elements, 67 fraction, 159, 196
Euler, L., 67, 110 Linear congruence(s), 109, 113
Euler’s criterion, 147 solution set of, 113
Euler's ¢-function, 72 systems of, 135—136
Euler’s theorem, 108—109 Linear congruences in two variables,
Even-numbered convergents, 165 129
Linear Diophantine equations in more
Factors, 23 than two variables, 122—124
244 INDEX

Linear Diophantine equations in two Purely periodic continued fraction,


variables, 46, 120—122, 180- 196
181
general solution of, 47 Quadratic congruence, 143
particular solution of, 46 Quadratic irrationals, 161

Reduced residue system, 104


Mathematical induction, 6
Reflexive property, 1, 89
first principle of, 6
Relatively prime, 43
second principle of, 8
Residue classes, 89
Mersenne, M., 70
Memenne number, 70
Second principle of mathematical
Mersenne primes, 70
induction, 8
Modulus, 98
Sieve of Eratosthenes, 27a28
Multi-perfect numbers, 68
Simple continued fraction, 150
Multiple, 23
Multiplication, properties of, 2 Solution set of a linear congruence,
Multiplication property of inequality,
1 13
2 Standard form, 55
Multiplicative number»theoretic Sum of divisors, 58
function, 61 Summation symbol, 15
Sun-Tsu, 142
Symmetric property, 2, 89
Number bases, 9
Systems of linear congruences,
Number of divisors, 63
135—136
Number-theoretic functions, 58
completely multiplicative, 63
Terms of a continued fraction, 151
multiplicative, 61
Totient of n, 72
Transitive property, 2, 89
Odd-numbered convergents, 165 Trichotomy property, 2
Ordered integral domain, 3 ' Twin primes, 32

Pairwise relatively prime, 43 Vallée—Poussin, C. J. de la, 30


Particular solution, 46
Perfect number, 65 Waring, E., 124
Period of a continued fraction, 159, Well-defined property, 2
196 Well-ordering principle, 4
Periodic continued fraction, 159, 196 Wilson, J., 124
Polynomial congruence, 144 Wilson‘s theorem, 124—125
Prime, 23 converse of, 125
Prime factorization, 52.
Prime number theorem, 30 Zero-product property, 2
Product symbol, 15, 19 Zero property of multiplication, 2
QA241 .P48

Pettofrezzo, Anthony J.
Elements of number theory

DATE I ISSUED m 140128

You might also like