1 Fundamentals
1 Fundamentals
Tell me and I will forget. Show me and I will remember. Involve me and I will understand. — CONFUCIUS
he outstanding German mathematician Karl Friedrich Gauss (1777–1855) once said, “Mathematics is the queen of the sciences and arithmetic the queen T of mathematics.” “Arithmetic,” in the sense Gauss uses it, is number theory, which, along with geometry, is one of the two oldest branches of mathematics. Num- ber theory, as a fundamental body of knowledge, has played a pivotal role in the development of mathematics. And as we will see in the chapters ahead, the study of number theory is elegant, beautiful, and delightful. A remarkable feature of number theory is that many of its results are within the reach of amateurs. These results can be studied, understood, and appreciated with- out much mathematical sophistication. Number theory provides a fertile ground for both professionals and amateurs. We can also find throughout number theory many fascinating conjectures whose proofs have eluded some of the most brilliant mathe- maticians. We find a great number of unsolved problems as well as many intriguing results. Another interesting characteristic of number theory is that although many of its results can be stated in simple and elegant terms, their proofs are sometimes long and complicated. Generally speaking, we can define “number theory” as the study of the properties of numbers, where by “numbers” we mean integers and, more specifically, positive integers. Studying number theory is a rewarding experience for several reasons. First, it has historic significance. Second, integers, more specifically, positive integers, are
1 2 CHAPTER 1 Fundamentals
Pythagoras (ca. 572–ca. 500 B.C.), a Greek philoso- pher and mathematician, was born on the Aegean is- land of Samos. After extensive travel and studies, he returned home around 529 B.C. only to find that Samos was under tyranny, so he migrated to the Greek port of Crontona, now in southern Italy. There he founded the famous Pythagorean school among the aristo- crats of the city. Besides being an academy for phi- losophy, mathematics, and natural science, the school became the center of a closely knit brotherhood shar- The Island of Samos ing arcane rites and observances. The brotherhood A Greek Stamp ascribed all its discoveries to the master. Honoring A philosopher, Pythagoras taught that number was the essence of everything, and Pythagoras he associated numbers with mystical powers. He also believed in the transmigration of the soul, an idea he might have borrowed from the Hindus. Suspicions arose about the brotherhood, leading to the murder of most of its members. The school was destroyed in a political uprising. It is not known whether Pythagoras escaped death or was killed.
the building blocks of the real number system, so they merit special recognition. Third, the subject yields great beauty and offers both fun and excitement. Finally, the many unsolved problems that have been daunting mathematicians for centuries provide unlimited opportunities to expand the frontiers of mathematical knowledge. Goldbach’s conjecture (Section 2.5) and the existence of odd perfect numbers (Sec- tion 8.3) are two cases in point. Modern high-speed computers have become a pow- erful tool in proving or disproving such conjectures. Although number theory was originally studied for its own sake, today it has intriguing applications to such diverse fields as computer science and cryptography (the art of creating and breaking codes). The foundations for number theory as a discipline were laid out by the Greek mathematician Pythagoras and his disciples (known as the Pythagoreans). The Pythagorean brotherhood believed that “everything is number” and that the central explanation of the universe lies in number. They also believed some numbers have mystical powers. The Pythagoreans have been credited with the invention of am- icable numbers, perfect numbers, figurate numbers, and Pythagorean triples. They classified integers into odd and even integers, and into primes and composites. Another Greek mathematician, Euclid (ca. 330–275 B.C.), also made significant contributions to number theory. We will find many of his results in the chapters to follow. We begin our study of number theory with a few fundamental properties of in- tegers. 1.1 Fundamental Properties 3
Little is known about Euclid’s life. He was on the faculty at the University of Alexan- dria and founded the Alexandrian School of Mathematics. When the Egyptian ruler King Ptolemy I asked Euclid, the father of geometry, if there were an easier way to learn geometry than by studying The Elements, he replied, “There is no royal road to geometry.”
1.1 Fundamental Properties
The German mathematician Hermann Minkowski (1864–1909) once remarked, “In- tegral numbers are the fountainhead of all mathematics.” We will come to appreciate how important his statement is. In fact, number theory is concerned solely with inte- gers. The set of integers is denoted by the letter Z:†
Z ={...,−3, −2, −1, 0, 1, 2, 3,...}
Whenever it is convenient, we write “x ∈ S” to mean “x belongs√ to the set S”; “x ∈/ S” means “x does not belong to S.” For example, 3 ∈ Z, but 3 ∈/ Z. We can represent integers geometrically on the number line, as in Figure 1.1.
Figure 1.1
The integers 1, 2, 3,...are positive integers. They are also called natural num- bers or counting numbers; they lie to the right of the origin on the number line. We denote the set of positive integers by Z+ or N:
+ Z = N ={1, 2, 3,...}
† The letter Z comes from the German word Zahlen for numbers. 4 CHAPTER 1 Fundamentals
Leopold Kronecker (1823–1891) was born in 1823 into a well-to-do family in Liegnitz, Prussia (now Poland). After being tutored privately at home during his early years and then attending a preparatory school, he went on to the local gymnasium, where he excelled in Greek, Latin, Hebrew, mathematics, and philosophy. There he was fortu- nate to have the brilliant German mathematician Ernst Eduard Kummer (1810–1893) as his teacher. Recognizing Kronecker’s mathematical talents, Kummer encouraged him to pursue independent scientific work. Kummer later became his professor at the universities of Breslau and Berlin. In 1841, Kronecker entered the University of Berlin and also spent time at the University of Breslau. He attended lectures by Dirichlet, Jacobi, Steiner, and Kummer. Four years later he received his Ph.D. in mathematics. Kronecker’s academic life was interrupted for the next 10 years when he ran his uncle’s business. Nonethe- less, he managed to correspond regularly with Kummer. After becoming a member of the Berlin Academy of Sciences in 1861, Kronecker began his academic career at the University of Berlin, where he taught unpaid until 1883; he became a salaried professor when Kummer retired. In 1891, his wife died in a fatal mountain climbing accident, and Kronecker, devastated by the loss, suc- cumbed to bronchitis and died four months later. Kronecker was a great lover of the arts, literature, and music, and also made profound contributions to num- ber theory, the theory of equations, elliptic functions, algebra, and the theory of determinants. The vertical bar notation for determinants is his creation.
The German mathematician Leopold Kronecker wrote, “God created the natural numbers and all else is the work of man.” The set of positive integers, together with 0, forms the set of whole numbers W:
W ={0, 1, 2, 3,...}
Negative integers, namely, ...,−3, −2, −1, lie to the left of the origin. Notice that 0 is neither positive nor negative. We can employ positive integers to compare integers, as the following definition shows.
The Order Relation Let a and b be any two integers. Then a is less than b, denoted by a < b, if there exists a positive integer x such that a + x = b, that is, if b − a is a positive integer. When a < b, we also say that b is greater than a, and we write b > a.†
† The symbols < and > were introduced in 1631 by the English mathematician Thomas Harriet (1560–1621). 1.1 Fundamental Properties 5
If a is not less than b, we write a ≮ b; similarly, a ≯ b indicates a is not greater than b. It follows from this definition that an integer a is positive if and only if a > 0. Given any two integers a and b, there are three possibilities: either a < b, a = b, or a > b. This is the law of trichotomy. Geometrically, this means if a and b are any two points on the number line, then either point a lies to the left of point b,thetwo points are the same, or point a lies to the right of point b. We can combine the less than and equality relations to define the less than or equal to relation. If a < b or a = b, we write a ≤ b.† Similarly, a ≥ b means either a > b or a = b. Notice that a < b if and only if a ≥ b. We will find the next result useful in Section 3.4. Its proof is fairly simple and is an application of the law of trichotomy.
THEOREM ‡ 1.1 Let min{x, y} denote the minimum of the integers x and y, and max{x, y} their maxi- mum. Then min{x, y}+max{x, y}=x + y.§
PROOF (by cases) case 1 Let x ≤ y. Then min{x, y}=x and max{x, y}=y,somin{x, y}+max{x, y}= x + y. case 2 Let x > y. Then min{x, y}=y and max{x, y}=x,somin{x, y}+max{x, y}= y + x = x + y.
The law of trichotomy helps us to define the absolute value of an integer.
Absolute Value The absolute value of a real number x, denoted by |x|, is defined by x if x ≥ 0 |x|= −x otherwise
For example, |5|=5, |−3|=−(−3) = 3, |π|=π, and |0|=0. Geometrically, the absolute value of a number indicates its distance from the origin on the number line. Although we are interested only in properties of integers, we often need to deal with rational and real numbers also. Floor and ceiling functions are two such number-theoretic functions. They have nice applications to discrete mathematics and computer science.
† The symbols ≤ and ≥ were introduced in 1734 by the French mathematician P. Bouguer. ‡ A theorem is a (major) result that can be proven from axioms or previously known results. § Theorem 1.1 is true even if x and y are real numbers. 6 CHAPTER 1 Fundamentals
Floor and Ceiling Functions The floor of a real number x, denoted by x, is the greatest integer ≤ x.Theceiling of x, denoted by x , is the least integer ≥ x.† The floor of x rounds down x, whereas the ceiling of x rounds up. Accordingly, if x ∈/ Z, the floor of x is the nearest integer to the left of x on the number line, and the ceiling of x is the nearest integer to the right of x, as Figure 1.2 shows. The floor function f (x) =x and the ceiling function g(x) = x are also known as the greatest integer function and the least integer function, respectively.
Figure 1.2
= = − =− − =− = For example, π 3, log10 3 0, 3.5 4, 2.7 3, π 4, = − =− − =− log10 3 1, 3.5 3, and 2.7 2. The floor function comes in handy when real numbers are to be truncated or rounded off to a desired number of decimal places. For example, the real number π = 3.1415926535 ... truncated to three decimal places is given by 1000π/1000 = 3141/1000 = 3.141; on the other hand, π rounded to three decimal places is 1000π + 0.5/1000 = 3.142. There is yet another simple application of the floor function. Suppose we divide the unit interval [0, 1) into 50 subintervals of equal length 0.02 and then seek to determine the subinterval that contains the number 0.4567. Since 0.4567/0.02+ 1 = 23, it lies in the 23rd subinterval. More generally, let 0 ≤ x < 1. Then x lies in the subinterval x/0.02+1 =50x+1. The following example presents an application of the ceiling function to every- day life.
EXAMPLE 1.1 (The post-office function) In 2006, the postage rate in the United States for a first- class letter of weight x, not more than one ounce, was 39¢; the rate for each additional ounce or a fraction thereof up to 11 ounces was an additional 24¢. Thus, the postage p(x) for a first-class letter can be defined as p(x) = 0.39 + 0.24 x − 1 , 0 < x ≤ 11. For instance, the postage for a letter weighing 7.8 ounces is p(7.8) = 0.39 + 0.24 7.8 − 1 =$2.07.
† These two notations and the names, floor and ceiling, were introduced by Kenneth E. Iverson in the early 1960s. Both notations are variations of the original greatest integer notation [x]. 1.1 Fundamental Properties 7
Some properties of the floor and ceiling functions are listed in the next theorem. We shall prove one of them; the others can be proved as routine exercises.
THEOREM 1.2 Let x be any real number and n any integer. Then = = n n − 1 1. n n n 5. = if n is odd. 2. x =x+1 (x ∈/ Z) 2 2 + = + n n + 1 3. x n x n 6. = if n is odd. 4. x + n = x +n 2 2
PROOF Every real number x can be written as x = k + x , where k =x and 0 ≤ x < 1. See Figure 1.3. Then
Figure 1.3
x + n = k + n + x = (k + n) + x
x + n=k + n, since 0 ≤ x < 1 =x+n
EXERCISES1.1
1. The English mathematician Augustus DeMorgan, 8. An n-digit positive integer N is a Kaprekar number who lived in the 19th century, once remarked that he if the sum of the number formed by the last n digits was x years old in the year x2. When was he born? in N2, and the number formed by the first n (or n − 1) Evaluate each, where x is a real number. digits in N2 equals N. For example, 297 is a Kaprekar x 2. f (x) = (x = 0) number since 2972 = 88209 and 88 + 209 = 297. |x| 3. g(x) =x+−x There are five Kaprekar numbers < 100. Find them. 4. h(x) = x + −x 9. Find the flaw in the following “proof”: = Determine whether: Let a and b be real numbers such that a b.Then = 2 5. −−x=x ab b a2 − ab = a2 − b2 6. − −x = x − = + − 7. There are four integers between 100 and 1000 that are Factoring, a(a b) (a b)(a b). Canceling − = + = each equal to the sum of the cubes of its digits. Three a b from both sides, a a b.Sincea b, = of them are 153, 371, and 407. Find the fourth num- this yields a 2a. Canceling a from both sides, = ber. (Source unknown.) we get 1 2. 8 CHAPTER 1 Fundamentals
D. R. Kaprekar (1905–1986) was born in Dahanu, India, near Bombay. After losing his mother at the age of eight, he built a close relationship with his astrologer-father, who passed on his knowledge to his son. He at- tended Ferguson College in Pune, and then graduated from the University of Bombay in 1929. He was awarded the Wrangler R. P. Paranjpe prize in 1927 in recognition of his mathematical contributions. A prolific writer in recreational number theory, he worked as a schoolteacher in Devlali, India, from 1930 until his retirement in 1962. Kaprekar is best known for his 1946 discovery of the Kaprekar constant 6174. It took him about three
years to discover the number: Take a four-digit number a, not all digits being the same; let a denote the number
obtained by rearranging its digits in nondecreasing order and a denote the number obtained by rearranging its
digits in nonincreasing order. Repeat these steps with b = a − a and its successors. Within a maximum of eight steps, this process will terminate in 6174. It is the only integer with this property.