# What is the probability there is no prime between $n$ and $n+\ln(n)$?

Consequences of the Prime Number Theorem tell us the probability of $$n$$ being prime is $$1/\ln(n)$$. This also means that the number of expected primes between $$n$$ and $$n+\ln(n)$$ is close to $$1$$, but not always. What is the probability there is no prime between $$n$$ and $$n+\ln(n)$$?

• The $\prod_{k=n}^{n+\ln n}(1-\frac{1}{\ln k})$ for large $n$ gives roughly $\approx 0.3$, actual checking for large $n$ ranges gives similar values. – Sil Apr 27 at 16:15

The naive probabilistic model is that each integer $$k$$ between $$n$$ and $$n+\log n$$ independently has a probability $$1/\log k \sim 1/\log n$$ of being prime. According to this model, the probability that none of these integers are prime (as alluded to in Sil's comment) is $$\prod_{n But this model actually gives something more: for any nonnegative integer $$m$$, the probability that there are exactly $$m$$ primes between $$n$$ and $$n+\log n$$ is $$e^{-1}/m!$$. In other words, intervals of this length should give rise to a Poisson distribution. (And this can be generalized to the primes between $$n$$ and $$n+C\log n$$ for any constant $$C>0$$.)
In 1976, Gallagher proved that this is indeed the case if you assume a suitably strong version of the Hardy–Littlewood prime $$k$$-tuples conjecture. This paper of Goldston and Ledoan describes the result more precisely on its first page and gives the exact reference.