Fermat Primes

Last Updated : 23 Jul, 2025

Fermat numbers are a special sequence of integers defined by the formula:

Fn = 2^{2^n} + 1

Where n is a non-negative integer. If any Fermat number is prime it is called Fermat Prime. Currently, there are five known Fermat primes. These are:

  • F0 = 2^{2^0} + 1 = 3
  • F1 = 2^{2^1} + 1 = 5
  • F2 = 2^{2^2} + 1 = 17
  • F3 = 2^{2^3} + 1 = 257
  • F4 = 2^{2^4} + 1 = 65537

Beyond F4 all known Fermat numbers Fn for n ≥5 [F5 = 4294967297], have been found to be composite numbers. The search for new Fermat Prime continues, but none has been discovered since F4.

Note: all other Fermat numbers are divisible by some other numbers i.e.,

  • F5​ = 4294967297 (641 × 6700417)
  • F6 = 18446744073709551617 (274177 × 67280421310721)
  • F7 = 340282366920938463463374607431768211457 (59649589127497217 ×5704689200685129054721)

Facts about Fermat Primes

Some facts about Fermat number and primes are:

  • All Fermat prime are odd.
  • There are only five known Fermat primes: 3, 5, 17, 257, and 65537.
  • Fermat numbers are related to the construction of regular polygons. Specifically, a regular polygon with Fn ​sides can be constructed with a compass and straightedge if Fn​ is prime.
  • Any two Fermat numbers Fm​ and Fn​ (where m ≠ n) are coprime, meaning gcd(Fm, Fn) = 1.
  • 2^{(2^n)}+1 is a Fermat prime if and only if the period length of 1/(2^{(2^n)}+1) is equal to 2^{(2^n)}. In other words, Fermat primes are full reptend primes.

Conclusion

In conclusion, Fermat primes are a special type of prime number that follow a unique formula, F_n = 2^{2^n} + 1. Although Fermat once believed that all numbers in this form would be prime, we now know that only the first five are Fermat primes, and the rest are composite.

Read More,

Comment
Article Tags:

Explore