Ancient Greek Number Theory
Greek Number Theory
Ancient Greek mathematics was primarily associated with geometry, but Greek mathematicians also made major contributions to number theory. Number theory is the systematic study of arithmetic involving natural numbers, especially their patterns, divisors, and relationships.
The study of numbers often had a mystical or religious dimension in the ancient world. Certain numbers were regarded as lucky, unlucky, or symbolically significant. However, Greek number theory also developed rigorous mathematical ideas, including the study of square numbers, triangular numbers, primes, perfect numbers, factorization, and greatest common divisors.
Square Numbers
A square number is a number that can be represented as the product of a natural number with itself. In modern notation, the square of n is
For example,
A square number can be represented geometrically as a square array of dots or smaller squares. A 5×5 array contains 25 units.
Square Numbers as Successive Odd Numbers
The Greeks observed that a square can be built by adding successive layers around smaller squares. Each new layer has an odd number of units. These L-shaped layers were called gnomons.
Starting with a single unit:
The first layer contains 1 unit.
The next L-shaped layer contains 3 units.
The next contains 5 units.
The next contains 7 units.
The next contains 9 units.
Thus,
This pattern generalizes to every square number:
For example,
The sum of the first n odd natural numbers is always the square number n2.
The geometric interpretation explains why the identity works: each successive odd number forms an L-shaped layer that enlarges the previous square by one row and one column.
Triangular Numbers
A triangular number is a number that can be represented by arranging dots in a triangular pattern.
The first triangular numbers are:
They are formed by summing the first consecutive natural numbers:
Examples include:
T1=1
T2=1+2=3
T3=1+2+3=6
T4=1+2+3+4=10
The fourth triangular number, 10, can be arranged as four rows containing 1, 2, 3, and 4 dots.
Deriving the Triangular Number Formula
The formula for the nth triangular number is
One way to understand this formula is to duplicate the triangular arrangement and fit the two copies together. The two triangles form a rectangle:
One side has length n.
The other side has length n+1.
Therefore, the area of the rectangle is
Since this rectangle consists of two identical triangular arrangements,
Dividing by 2 gives
Example: The Sum from 1 to 100
The sum
is the hundredth triangular number:
Therefore,
This method avoids adding the numbers individually. A well-known story attributes this type of rapid calculation to the young Carl Friedrich Gauss, who supposedly recognized the pattern and computed the sum quickly.
A triangular number is the sum of the first n natural numbers, and its value is 2n(n+1).
Prime Numbers
A prime number is a natural number greater than 1 whose only positive divisors are 1 and the number itself.
Examples of prime numbers include
The number 19 is prime because its only positive factorization is
By contrast, 18 is not prime because it has several divisors:
Its positive divisors are
A number greater than 1 that is not prime is called composite. The number 1 is neither prime nor composite.
Distribution of Primes
The sequence of primes appears partly regular and partly irregular:
Small numbers contain many primes.
Primes become less frequent as numbers get larger.
There is no simple repeating pattern that lists all primes.
Nevertheless, primes never stop occurring.
For example, the numbers 33 and 35 are composite, not prime, because
and
Euclid’s Theorem on the Infinitude of Primes
One of the great achievements of ancient Greek mathematics was the proof that there are infinitely many primes. Euclid stated this idea in Book 9, Proposition 20 of The Elements as:
“Prime numbers are more than any assigned multitude of prime numbers.”
In modern language, this means that there are infinitely many prime numbers. The ancient Greeks generally avoided speaking about infinite sets. Instead, they described the sequence of primes as never stopping: no matter how far the list continues, another prime can always be found.
Proof That There Are Infinitely Many Primes
Assume, for contradiction, that there are only finitely many primes. Suppose the complete list is
Construct a new number
This number is one greater than the product of every prime on the supposed complete list.
For any prime Pk in the list,
leaves a remainder of 1 when divided by Pk. Therefore, none of the listed primes divides N.
There are two possibilities:
N is prime.
Then N is a prime not included in the supposed complete list.N is composite.
Every composite number has a prime factor. Since none of the listed primes divides N, at least one of its prime factors must be a new prime not in the list.
In either case, a prime exists outside the supposedly complete list. This contradiction proves that the list of primes cannot end.
For any finite collection of primes, the number formed by multiplying them all together and adding 1 leads to a new prime, either directly or through its prime factors.
The number N itself does not always have to be prime. The proof only requires that it have a prime factor not included in the original list.
The Fundamental Theorem of Arithmetic
The Fundamental Theorem of Arithmetic states that every natural number greater than 1 can be expressed as a product of prime numbers in essentially one unique way.
“Essentially unique” means that the order of the factors does not matter. For example,
and
represent the same prime factorization.
Example: Factoring 612
To factor 612 into primes:
Divide by 2:
612=2×306.Divide 306 by 2:
306=2×153.Divide 153 by 3:
153=3×51.Divide 51 by 3:
51=3×17.Both 2, 3, and 17 are prime, so the factorization is complete:
612=22×32×17.
Equivalently,
The divisibility test for 3 used in this process is that a number is divisible by 3 when the sum of its digits is divisible by 3. For 153,
and 9 is divisible by 3, so 153 is divisible by 3.
The uniqueness of prime factorization means that any valid method of factoring 612 must eventually produce the same prime factors:
possibly in a different order.
Prime factorization is central to many results in number theory because it reveals the basic multiplicative structure of every natural number.
Perfect Numbers
A perfect number is a natural number equal to the sum of all its positive divisors other than itself.
The divisors being added are sometimes called the proper divisors.
Examples of Divisors
The positive divisors of 12 are
1, 2, 3, 4, 6, 12.The positive divisors of 7 are
1, 7.The positive divisors of 6 are
1, 2, 3, 6.The positive divisors of 28 are
1, 2, 4, 7, 14, 28.
Examples of Perfect and Non-Perfect Numbers
The number 6 is perfect because its proper divisors sum to 6:
The number 28 is perfect because
The number 12 is not perfect because
The number 7 is not perfect because its only proper divisor is 1:
The ancient Greeks considered perfect numbers especially significant because of the balance between the number and the sum of its proper divisors.
Euclid’s Construction of Even Perfect Numbers
Euclid’s Proposition 36 in Book 9 gives a method for constructing perfect numbers.
Begin with powers of 2:
Continue until the sum of the terms is prime. Then multiply that prime sum by the final power of 2. The result is perfect.
First Example
The sum
is prime. Multiplying the sum by the last term, 2, gives
Thus, 6 is perfect.
Second Example
The sum
is prime. Multiplying by the final term, 4, gives
Thus, 28 is perfect.
A Sum That Does Not Work
The sum
is not prime, so this sequence does not produce a perfect number through Euclid’s construction.
The next sum is
which is prime. Multiplying by 16 gives
another perfect number.
Geometric-Series Form
The powers of 2 form a geometric progression. The sum
is
Therefore, Euclid’s construction can be written as follows:
If 2n−1 is prime, then 2n−1(2n−1) is a perfect number.
The resulting perfect number has the form
This construction explains the first examples:
For n=2:
21(22−1)=2×3=6.For n=3:
22(23−1)=4×7=28.For n=5:
24(25−1)=16×31=496.
Mersenne Primes
Primes of the form
are called Mersenne primes.
Not every number of this form is prime. For example,
and 15 is composite because
When 2n−1 is prime, it can be used in Euclid’s construction of a perfect number.
Mersenne primes are particularly important in the search for large primes because their special form makes them easier to test computationally than arbitrary large numbers. However, testing and discovering very large primes still requires substantial computational effort.
Large Prime Searches
Finding very large primes is difficult. Euclid’s proof gives a theoretical way to show that new primes must exist, but directly multiplying a huge collection of known primes and adding 1 is not practical for discovering new primes. The resulting number may be enormous and difficult to factor.
A historically reported record prime had the form
a Mersenne prime containing approximately twelve million decimal digits. Such discoveries require computers to perform extensive calculations and primality tests.
Modern Importance of Prime Numbers
For many centuries, number theory was often viewed as a recreational or abstract branch of mathematics. In modern times, prime numbers have become essential to cryptography, the mathematics of securing digital information.
Prime Factorization and Security
It is easy for a computer to multiply two large prime numbers together. If the primes are
then calculating
is relatively efficient.
However, if someone is given only the large composite number N, recovering P1 and P2 may be extremely difficult when the primes are sufficiently large. This difference between easy multiplication and difficult factorization is used in encryption systems.
The basic security idea is:
The product of large primes can be made public.
The original prime factors can be kept secret.
Anyone can use the public number in an encryption process.
Only someone who knows the hidden factors can efficiently decrypt or authenticate the information.
This asymmetry creates information that one party knows while others cannot practically determine it, even with substantial computing resources. Prime-based encryption helps protect bank details, private messages, and other sensitive data transmitted over the internet.
The difficulty of factoring large composite numbers is a major foundation of several modern encryption methods.
The Greatest Common Divisor
The greatest common divisor, or GCD, of two natural numbers is the largest positive integer that divides both numbers.
For example, consider 612 and 93.
Their prime factorizations are
and
The only prime factor they share is 3, so
Prime factorization can be used to find a GCD, but factoring large numbers may be difficult. Euclid developed a more efficient method that finds the GCD without requiring complete prime factorizations.
Euclidean Algorithm
The Euclidean algorithm is a systematic sequence of division steps used to calculate the greatest common divisor of two numbers.
It relies on the key fact that if
then
The common divisors of a and b are exactly the common divisors of b and the remainder r.
Why the Reduction Works
Suppose a number d divides both a and b. Since
subtracting bq from a gives
Because d divides both a and b, it also divides a−bq, and therefore divides r.
Conversely, if d divides both b and r, then it divides
Thus, the common divisors of (a,b) and (b,r) are the same, so their greatest common divisors are equal.
Example: Finding gcd(612,93)
Start by dividing the larger number by the smaller number:
Therefore,
Continue dividing:
so
Next,
so
Then,
so
Next,
so
Then,
so
Finally,
The last nonzero remainder is 3, so
General Procedure
To find the GCD of two positive integers:
Divide the larger number by the smaller number.
Record the remainder.
Replace the larger number with the smaller number and the smaller number with the remainder.
Repeat the process.
Stop when the remainder is 0.
The last nonzero remainder is the GCD.
The algorithm must eventually stop because the positive remainders continually decrease. Once a remainder of 0 is reached, the preceding nonzero remainder divides the number before it exactly and is the greatest common divisor.
The Euclidean algorithm finds the GCD efficiently by repeatedly replacing a pair of numbers with a smaller pair having the same common divisors.
The method is historically important as one of the earliest known examples of an algorithm: a finite, logical, and systematic sequence of steps that reliably solves a problem.

Ask anything
We've read this whole study set, so questions about it get the best answers.