# Prime Power Gaps

In 2000, Baker, Harman and Pintz proved that there is always a prime in the interval $(n-n^{0.525}, n)$. There are also conditional results implying smaller intervals. Nevertheless, I could not find any information about prime power gaps. So, what I'm asking is:

What is the asymptotically largest function $f(n)$ s.t. there is always a prime power in the interval $(f(n), n)$?

For example, Bertrand’s postulate is almost trivial in this case, since there is always a power of $2$ in the interval $(n, 2n]$. On the other hand, the distribution of prime powers with exponent $e>1$ is much smaller than the distribution of primes, so adding them might not change the answer.

-
I expect this is the same as for the primes, between $n-\log^{2+\varepsilon} x$ and $n-\log^2 x$. –  Charles Oct 29 '12 at 21:56
Just looking at powers of integers, usually most integers are near a square. I expect that the 0.525 exponent is not going to change much if you throw in prime powers. Gerhard "Not A Paid Professional Opinion" Paseman, 2012.10.29 –  Gerhard Paseman Oct 29 '12 at 22:00
@Charles, I think you meant $x$ and $n$ to be the same letter? Also, I think you are referring to conjectural results, while it appears OP refers to unconditional results. –  Gerry Myerson Oct 29 '12 at 23:12

The paper shows that for $x \gt x_0$ there are primes in the interval $[x-x^{0.525},x]$ where the value of $x_0$ could be found effectively "with enough effort." The result fails for $x=126$ but I can't immediately rule out that $x_0=127$ suffices. The paper seems to say that for large enough $n$ the number of primes in $[n,n+n^{0.525}]$ eventually exceeds $\frac{9n^{0.525}}{100\log{n}}.$

Call an integer power proper if it is at least a square and respectable if it is at least a cube, To expand on Gerhard's observation: If we looked for intervals which contain either a prime or a proper integer power then we can say that there is always a square in $(n-2\sqrt{n},n)$ so this eventually improves on $x-x^{.525}.$

There is always a respectable power in $(n-3n^{2/3},n)$ but that is pretty near best possible, so I would guess that if we said "a prime or a respectable power" then we would not be able to get any improvement over just "prime". Likewise, there seems no reason to think that "prime or prime power" is essentially better than "prime or prime square" nor that "prime or prime square" is essentially better than "prime."

-
Another "back of the envelope" calculation suggests that for any x large enough, there are at most x^(1/2)logx (and likely fewer) integers less than x which have a prime power less than and nearer to them than any smaller prime, so any bound desired by the poster is likely to be applicable to just having a near prime. Gerhard "Ask Me About System Design" Paseman, 2012.10.31 –  Gerhard Paseman Nov 1 '12 at 1:19
Aaron, thanks. If I get it right, you're saying the (fixed) gaps between squares are similar to the (maximal) gaps between primes, and hence, adding the squares (of primes) will not improve much upon looking just on primes. Indeed, higher powers have even bigger gaps. But, I am not completely convinced that having all powers together still does not improve upon only primes (although I agree with your intuition against this). –  Ami Paz Nov 2 '12 at 16:42
Here is a related conjecture for your consideration. Let I_n be the interval (n^2, (n+1)^2). I conjecture that for every n, if x,y,and z are three respectable integers in I_n, then at least two of them are equal. Further, most I_n have no respectable integers. Powers are too thin to make an asymptotic difference, except perhaps for squares. Gerhard "Ask Me About System Design" Paseman, 2012.11.02 –  Gerhard Paseman Nov 3 '12 at 1:15
Gerhard, I would agree with your second observation-most I_n have no respectable powers (big gaps in average case). But do you have a reason to believe that there are no 3 close respectable powers, or even 3 consecutive respectable powers (small gaps in worst case)? –  Ami Paz Nov 3 '12 at 20:02
Ami, it seems likely that for any $\epsilon \gt 0$, $[x-x^{\epsilon},x]$ contains a prime whne $x$ is large enough. At the moment $\epsilon=0.525$ is perhaps the best value with a proof. Can we get to $\epsilon=0.5$ by including powers? (forget prime). Imagine that there actually are infinitely many prime free intervals $[n-n^{0.5},n].$ Maybe each starts near $m^2-3$ for some $m$, but one would imagine that about half contain a square and half don't. The chance that any particular one contains a cube is under $\frac{1}{n^{1/6}}$ and under $\frac{1}{n^{3/10}}$ for a fifth power. (cont) –  Aaron Meyerowitz Nov 4 '12 at 4:20