# Is this true about Fermat Primes?

Let every prime of the form $2^n+1$ be called "Fermat Prime" (I know that the real definition is by using $2^{2^{n}}+1$, but I will use the other one to get things easier). By definition, we have that $p$ will be a Fermat Prime if and only if it is prime and it is not of the form $qn+1$ for any prime $q$ such that $2<q<p$.

Then, by Dirichlet Theorem on arithmetic progressions, we have that, as $N \to \infty$, the number of primes of the form $qn+1$ lower than $N$ will tend to be the same than the one of primes of the form $qn+2$ and of the one of the primes of the form $qn+3$; and like this up to $qn+(q-1)$.

So, to know the number of Fermat Primes as $N \to \infty$, we have that:

1. Only the primes of the form $3n+2$ can be a Fermat Prime. Then, as $N \to \infty$, The number of FM will be lower than $\pi(N)\frac{1}{2}$.

2. Only the primes of the form $5n+2, 5n+3$ and $5n+4$ can be a Fermat Prime. Then, as $N \to \infty$, The number of FM will be lower than $\pi(N)\frac{1}{2}\frac{3}{4}$.

3. ...

If we continue like this, we would get that: $$\lim_{N \to \infty}\pi_{\text{FermatPrimes}}(N)=\lim_{N \to \infty} \pi(N)\prod_{p>2}\frac{p-2}{p-1}=K \lim_{N \to \infty} \frac{\pi(N)}{\log{(N)}}$$

Which clearly diverges.

Is this true?

• In your notation, Euler proved that factors are of the form $2q n+1$ and Lucas that they are of the form $4 q n+1$. These are incompatible with your "$qn+1$ for any prime $q$ such that $2<q<p$." Dec 4, 2016 at 23:42
• @Eric But let $p$ be a Fernat Prime. As $p-1=2^n$, the only factor than $p-1$ can have is 2. From here, you get to the conclusion that if a composite number has a divisor ($q$) greater than 2, that number plus 1 cannot be a Fermat Prime Dec 4, 2016 at 23:47
• @user3141592 : And how does this make either $2q$ or $4q$ prime, as you have stated? Dec 4, 2016 at 23:50
• You actually have made the vacuous statement that the only numbers that can be Fermat primes are Fermat numbers. That is, yes, all Fermat primes are a power of $2$ plus $1$. Of course, all Fermat numbers are a power of $2$ plus one, so you have not said very much. Dec 4, 2016 at 23:53
• Greg, there is nothing wrong with the sieve. A prime is $p$ is a Fermat prime if and only if $2$ is the only prime divisor of $p-1$ if and only if $p\not\equiv1\pmod q$ for any odd prime $q<p$. The explanation, as you implied, probably has something to do with the convergence of the various limiting processes here. For example, it takes time for the Dirichlet densities to average out, and early on there may larger deviations from the average and/or larger deviations from independence. Because those appear as factors here, a handful of factors smaller than the expected $(p-2)/(p-1)$... Dec 5, 2016 at 15:30