# Does the prime number theorem tell us that the next prime number is guaranteed to be relatively nearby?

Let $$\ p_n\$$ be the $$\ n$$-th prime number.

Does the prime number theorem ,

$$\Large{\lim_{x\to\infty}\frac{\pi(x)}{\left[ \frac{x}{\log(x)}\right]} = 1},$$

imply that:

$$\displaystyle\lim_{n\to\infty}\ \frac{p_n}{p_{n+1}} = 1\ ?$$

Edit: I totally get where the vote-to-closes come from and I kind of agree with them. Yeah this is not the question I intended to ask actually. I think I've done an X-Y communication thingy. I'll leave the question and accept the answer though. But I have learned something about prime numbers along the way in reading the answers...

• – lhf
May 21 at 23:31

Indeed, yes! It can be shown elementarily that the statement of the PNT that you gave is equivalent to $$\frac{p_n}{n\ln{n}} \rightarrow 1$$. Since $$\frac{n+1}{n} \rightarrow 1$$, $$\frac{\ln(n+1)}{\ln{n}}\rightarrow 1$$, it follows that $$\frac{p_{n+1}}{p_n} \rightarrow 1$$.

Edit: here’s the elementary proof. $$\frac{\pi(p_n)\ln{p_n}}{p_n} \rightarrow 1$$, thus $$p_n+o(p_n)=(n\ln{p_n})$$ (so $$n=o(p_n)$$). Write $$q_n=\frac{p_n}{n}$$. Then $$p_n+o(p_n)=(n\ln{n})+n\ln{q_n}$$. Now, $$\frac{q_n}{\ln{p_n}} \rightarrow 1$$, and $$p_n \rightarrow \infty$$, so that $$\ln{q_n}=\ln{\ln{p_n}}+o(1)$$. Thus $$n\ln{q_n}=o(p_n)$$, so that $$p_n+o(p_n)=n\ln{n}$$, QED.

• Is that right? $p_n$ converges to $\ n\ln(n)\$ very slowly then... According to google, The 1 millionth prime number is $\ 15,485,863\$ whereas $\ 1,000,000\ln(1,000,000)\ = 13,815,510$. That's not much closer (relatively speaking) than the $1000$-th prime number, $\ 7,919\$ is to $1000\ln(1000)= 6908.\$ So that's very slow convergence. But I guess it's not illegal for convergence to be very slow... May 21 at 23:39
• Also, what is this elementary proof that the statement of the PNT that I gave is equivalent to $\frac{p_n}{n\ln{n}} \rightarrow 1$ ? [I believe you- but I still want to see the proof please]. The rest of what you say is easy to follow. May 21 at 23:47
• It’s bad form to say that “$p_n$ converges to $n\log n,$” for $$p_n\sim n\log n.$$ If $x_n=n\log n$ then $$\frac{x_n}{\log x_n} =\dfrac{n}{1+\frac{\log\log n}{\log n}}$$ @AdamRubinson May 22 at 0:23
• When $n=1000000,$ $\frac{\log\log n}{\log n}\approx 0.19.$ But clearly the fraction converges to $0.$ @AdamRubinson May 22 at 0:28
• Well we have to be more precise by what we mean by "nearby" too. The asymptotics of $n$ primes by the first roughly $n \log n$ integers, does guarantee that for most $n$, the difference between the $n$-th prime and the $n+1$-th prime is $O(\log n)$. It however does not guarantee against the difference between the $n$th prime and the $n+1$-th prime being say $\sqrt{n}$ for an infinite number of $n$.
– Mike
May 22 at 17:10

You can also use results from the prime gap problem. Here, as $$\lim_{n\to\infty} \frac{g_n}{p_n} = 0$$ and $$g_n = p_{n+1} - p_n$$, you can conclude that $$\lim_{n\to\infty}\frac{p_{n+1}}{p_n} = 1$$.