OFFSET
1,3
COMMENTS
This is the difference between the estimate for the number of primes in power of two intervals determined by the li approximation, and the actual number of primes in the power of two interval. The MAGMA program gives the ceiling of the difference between the li estimate at the end points of the interval and the actual number of primes in the interval (A036378).
H. J. J. te Riele (1987) using methods developed by Lehman (1966) showed that between 6.62*10^370 and 6.69*10^370 there are more than 10^180 consecutive integers where pi(x) > li(x). It is worth noting that this falls entirely within the power of two interval starting at 2^1231, and while the condition "li underestimates the number of primes in an interval" is not sufficient to imply that pi(x) > li(x), for example in (2^18, 2^19) li(x) underestimates by 5 but li(x) > pi(x) at every point in the interval, it does seem to be necessary for this to occur, assuming runs of consecutive values where pi(x) > li(x) do not cross a power of two.
LINKS
Brad Clardy, Table of n, a(n) for n = 1..74
R. S. Lehman, On the difference pi(x) - li(x), Acta Arithmetica XI (1966), p. 397-410
H. J. J. te Riele, On the sign of the difference pi(x) - li(x), Math. Comp. 48 (1987), p.323-328
MATHEMATICA
pi = Table[PrimePi[2^n], {n, 1, 30}];
li = Table[LogIntegral[2^n], {n, 1, 30}];
Ceiling[Rest@li - Most@li] - (Rest@pi - Most@pi) (* Peter Luschny, Oct 14 2017 *)
PROG
(Magma)
1;
for i := 2 to 29 do
x := 2^i;
y := 2^(i+1);
delta_li := Ceiling(LogIntegral(y) - LogIntegral(x));
delta_pi := #PrimesInInterval(x, y);
delta_li - delta_pi;
end for;
CROSSREFS
KEYWORD
sign
AUTHOR
Brad Clardy, Mar 28 2013
STATUS
approved