# 2: Prime Numbers

- Page ID
- 8830

Prime numbers, the building blocks of integers, have been studied extensively over the centuries. Being able to present an integer uniquely as product of primes is the main reason behind the whole theory of numbers and behind the interesting results in this theory. Many interesting theorems, applications and conjectures have been formulated based on the properties of prime numbers. In this chapter, we present methods to determine whether a number is prime or composite using an ancient Greek method invented by Eratosthenes. We also show that there are infinitely many prime numbers. We then proceed to show that every integer can be written uniquely as a product of primes. We introduce as well the concept of diophantine equations where integer solutions from given equations are determined using the greatest common divisor. We then mention the Prime Number theorem without giving a proof of course in addition to other conjectures and major results related to prime numbers.

- 2.1: The Sieve of Eratosthenes
- The Sieve of Eratosthenes is an ancient method of finding prime numbers up to a specified integer. This method was invented by the ancient Greek mathematician Eratosthenes. There are several other methods used to determine whether a number is prime or composite.

- 2.2: The Infinitude of Primes
- We now show that there are infinitely many primes. There are several ways to prove this result. An alternative proof to the one presented here is given as an exercise. The proof we will provide was presented by Euclid in his book the Elements.

- 2.3: The Fundamental Theorem of Arithmetic
- The Fundamental Theorem of Arithmetic is one of the most important results in this chapter. It simply says that every positive integer can be written uniquely as a product of primes. The unique factorization is needed to establish much of what comes later. There are systems where unique factorization fails to hold. Many of these examples come from algebraic number theory. We can actually list an easy example where unique factorization fails.

- 2.4: Least Common Multiple
- We can use prime factorization to find the smallest common multiple of two positive integers.

- 2.5: Linear Diophantine Equations
- In this section, we discuss equations in two variables called diophantine equations. These kinds of equations require integer solutions. The goal of this section is to present the set of points that determine the solution to this kind of equations. Geometrically speaking, the diophantine equation represent the equation of a straight line. We need to find the points whose coordinates are integers and through which the straight line passes.

- 2.6: The function [x]. the symbols "O", "o" and "∼"
- We start this section by introducing an important number theoretic function. We proceed in defining some convenient symbols that will be used in connection with the growth and behavior of some functions that will be defined in later chapters.

- 2.7: Theorems and Conjectures involving prime numbers
- We have proved that there are infinitely many primes. We have also proved that there are arbitrary large gaps between primes. The question that arises naturally here is the following: Can we estimate how many primes are there less than a given number? The theorem that answers this question is the prime number theorem.

## Contributors and Attributions

Dr. Wissam Raji, Ph.D., of the American University in Beirut. His work was selected by the Saylor Foundation’s

for public release under a Creative Commons Attribution (**Open Textbook Challenge**) license.**CC BY**