Fermat Number — Definition, Formula & Examples
A Fermat number is a positive integer of the form , where is a non-negative integer. The first few Fermat numbers are 3, 5, 17, 257, and 65537.
For each non-negative integer , the -th Fermat number is defined as . A Fermat number that is also prime is called a Fermat prime. As of today, the only known Fermat primes are through .
Key Formula
Where:
- = A non-negative integer (0, 1, 2, 3, ...)
- = The n-th Fermat number
How It Works
To find the -th Fermat number, first compute the exponent , then raise 2 to that power and add 1. Fermat conjectured that every number of this form is prime, but Euler disproved this in 1732 by showing is divisible by 641. No Fermat primes beyond have been found, and it remains an open question whether infinitely many Fermat primes exist.
Worked Example
Problem: Compute the Fermat numbers F_0 through F_4.
F_0: Set n = 0. Compute the exponent 2^0 = 1, then 2^1 + 1.
F_1: Set n = 1. The exponent is 2^1 = 2, so compute 2^2 + 1.
F_2: Set n = 2. The exponent is 2^2 = 4.
F_3: Set n = 3. The exponent is 2^3 = 8.
F_4: Set n = 4. The exponent is 2^4 = 16.
Answer: The first five Fermat numbers are 3, 5, 17, 257, and 65,537. All five are prime.
Why It Matters
Fermat primes are directly connected to classical geometry: Gauss proved that a regular polygon with sides can be constructed using only a compass and straightedge if and only if is a power of 2 times a product of distinct Fermat primes. Fermat numbers also appear in algorithms and primality testing within number theory courses.
Common Mistakes
Mistake: Confusing with . For example, writing instead of .
Correction: The exponent itself is , not . Compute the tower of exponents from the top down: first evaluate , then use that result as the exponent of 2.
