This page contains the following material from A Friendly Introduction to Number Theory.
This book was originally written to serve as a text for Math 42, a course created by Jeff Hoffstein at Brown University in the early 1990's. Math 42 was designed to attract non-science majors, those with little interest in pursuing the standard calculus sequence, and to convince them to study some college mathematics. The intent was to create a course similar to one on, say, ``The Music of Mozart'' or ``Elizabethan Drama,'' wherein one introduces an audience to the overall themes and methodology of an entire discipline through the detailed study of a particular facet of the subject. Math 42 has been extremely successful, attracting both its intended audience and also scientifically oriented undergraduates interested in a change of pace from their large-lecture, cookbook-style courses.
The prerequisites for reading this book are few. Some facility with high school algebra is required, and those who know how to program a computer will have fun generating reams of data and implementing assorted algorithms, but in truth the reader needs nothing more than a simple calculator. Concepts from calculus are mentioned in passing, but are never used in an essential way. However, and the reader is hereby forewarned, it is not possible to truly appreciate Number Theory without an eager and questioning mind, a mind that is not afraid to experiment, to make mistakes and profit from them, to accept some frustrations and persevere to the ultimate triumph. Readers who are able to cultivate these qualities will find themselves richly rewarded, both in their study of Number Theory and their appreciation of all that life has to offer.
Mathematics, rightly viewed, possesses not only truth, but supreme beauty - a beauty cold and austere, like that of sculpture, without appeal to any part of our weaker nature, without the gorgeous trappings of paintings or music, yet sublimely pure, and capable of a stern perfection such as only the greatest art can show. (Bertrand Russell, 1902)The Theory of Numbers is that area of mathematics whose aim is to uncover the many deep and subtle relationships between different sorts of numbers. To take a simple example, many people through the ages have been intrigued by the square numbers 1, 4, 9, 16, 25,... If we perform the experiment of adding together pairs of square numbers, we will find that occasionally we get another square. The most famous example of this phenomenon is
32+42=52,but there are many others, such as
52+122=132, 202+212=292, and 282+452=532.Triples like (3,4,5), (5,12,13), (20,21,29), and (28,45,53) have been given the name Pythagorean triples. Based on this experiment, anyone with a lively curiosity is bound to pose various questions, such as "Are there infinitely many Pythagorean triples?" and "If so, can we find a formula which describes all of them?" These are the sorts of questions dealt with by number theory.
As another example, consider the problem of finding the remainder when the huge number 32478543743921429837645 is divided by 54817263. Here's one way to solve this problem Take the number 32478543, multiply it by itself 743921429837645 times, use long division to divide by 54817263, and take the remainder. In principle, this method will work, but in practice it would take far longer than a lifetime, even on the world's fastest computers. Number theory provides a means for solving this problem, too. "Wait a minute," I hear you say, "Pythagorean triples have a certain elegance which is pleasing to the eye, but where is the beauty in long division and remainders?" The answer is not in the remainders themselves, but in the use to which such remainders can be put. In a striking turn of events, mathematicians have shown how the solution of this elementary remainder problem (and its inverse) leads to the creation of simple codes which are so secure that even the National Security Agency is unable to break them. So much for G.H. Hardy's singularly unprophetic remark in 1940 that "no one has yet discovered any warlike purpose to be served by the theory of numbers or relativity, and it seems very unlikely that anyone will do so for many years."
The land of Number Theory is populated by a variety of exotic flora
and fauna. There are square numbers and prime numbers and odd numbers
and perfect numbers. There are Fermat equations and Pell
equations, Pythagorean triples and elliptic curves, unbreakable
codes and much much more. You will meet all of these, and many others,
as we journey through the Theory of Numbers.
The tone of this book is light and informal, which is not to say
that all of the material is easy. However, anyone with a
solid grounding in high school algebra and an eager and questioning
mind will do fine. (The latter requirement is far more important than
the former.) Scattered throughout the book are exercises of varying
degrees of difficulty, ranging from simple calculations
illustrating the material to open-ended questions designed to
stretch your intellect. Rather than including long lists of
problems, I have tried to include just the right number so that you
will be able to work on all of them. For extra practice, there are some
additional problems included in a section at the end of the book. Keep
in mind that the real goals are discovery and understanding. Some
problems have no right or wrong answer. A good question invites you to
say as much as possible about a certain phenomenon. That's how
mathematicians (and scientists) carry out their investigations.
Most of the non-numerical exercises in this book are designed to foster discussion and experimentation. They do not necessarily have "correct" or "complete" answers. Many students will find this extremely disconcerting at first, so it must be repeatedly stressed. You can make them feel more at ease by prefacing such questions with the phrase ``Tell me as much as you can about...'' Tell your students that accumulating data and solving special cases are not merely acceptable, but encouraged. On the other hand, tell them that there is no such thing as a complete solution, since the solution of a good problem will always raise additional questions. So if they can fully answer the specific question given in the text, their next task is to look for generalizations and for limitations on the validity of their solution.
Number theory is not easy, so there's no point in trying to convince
the students that it is. Instead, this book shows the reader
that he or she is capable of mastering a difficult subject and
experiencing the intense satisfaction of intellectual discovery.
The instructor's reward is to bask in the glow of their endeavors.
However, just as with any good rule, certain exceptions will be
admitted. First, one of the best ways to understand a subject is to
explain it to someone else; so if you know a little bit of how to
write computer programs, you will find it
extremely enlightening to explain to a computer how to perform the
algorithms described in this book. In other words, don't rely on a
canned computer package, do the programming yourself. Good candidates
for such treatment are the Euclidean algorithm (Chapters 5-6),
RSA encoding and decoding (Chapters 16-18), quadratic
reciprocity (Chapter 24), writing numbers as sums of two squares
(Chapters 25-26), and adding rational points on elliptic curves
(Chapter 32). The second exception to the "no computer rule" is
generation of data. Discovery in number theory is usually based on
experimentation, which may involve examining reams of data to try
to distinguish underlying patterns. Computers are well-suited to
generating such data, and also sometimes to assist in searching
for patterns, and I have no objection to their being used for these
purposes. The moral is that computers are useful as a tool for
experimentation, and that one can learn by teaching a computer how to
perform number theoretic calculations, but prepackaged programs
merely provide a crutch which will prevent you from learning to walk
on your own.