Ramanujan J (2018) 45:227–251
https://doi.org/10.1007/s11139-016-9839-4




Explicit estimates of some functions over primes

Pierre Dusart1,2




Received: 18 March 2016 / Accepted: 10 August 2016 / Published online: 27 October 2016
© Springer Science+Business Media New York 2016



Abstract New results have been found about the Riemann hypothesis. In particular,
we noticed an extension of zero-free region and a more accurate location of zeros in the
critical strip. The Riemann hypothesis implies results about the distribution of prime
numbers. We get better effective estimates of common number theoretical functions
which are closely linked to ζ zeros like ψ(x), ϑ(x), π(x), or the kth prime number
pk .

Keywords Number theory · Arithmetic functions · Chebyshev’s functions · Estimates
of prime numbers
Mathematics Subject Classification Primary 11N56 · Secondary 11A25, 11N05

1 Introduction

In many applications, it is useful to have explicit error bounds in the prime number
theorem. Rosser [33,34] developed an analytic method which combines a numerical
verification of the Riemann hypothesis with a zero-free region and derived explicit
estimates for some number theoretical functions. The aim of this paper is to find
sharper bounds for the Chebyshev’s functions ψ(x), the logarithm of the least common
multiple of all integers not exceeding x, and ϑ(x), the product of all primes not
exceeding x:



B Pierre Dusart
    pierre.dusart@unilim.fr

1   XLIM - UMR CNRS 7252, Faculté des Sciences et Techniques, Université de Limoges,
    87060 Limoges, France
2   Present Address: Département de Mathématiques, 123 avenue Albert Thomas, 87060 Limoges,
    France


                                                                                         123
228                                                                                 P. Dusart

                                                    
                      ϑ(x) =          ln p, ψ(x) =            ln p.
                               p ⩽x                   p,α
                                                     p α ⩽x


  The prime number theorem could be written as follows:

                          ψ(x) = x + o(x), x → +∞.

   An equivalent formulation of the above theorem should be: for all ε > 0, there
exists x0 = x0 (ε) such that

                          |ψ(x) − x| < ε x     for x ⩾ x0

  or

                          |ϑ(x) − x| < ε x     for x ⩾ x0 .

   This article is an updated version of some known results: the most important works
on effective results have been shown by Rosser and Schoenfeld [35,36,38], Pereira [6],
Robin [31], Robin and Massias [19], Dusart [8], Faber and Kadiri [12], Trudgian [40].
   The proofs for estimates of ψ(x) in [12,36] are based on the verification of Riemann
hypothesis to a given height and an explicit zero-free region [16,20] for ζ whose form
is essentially the classical one of de la Vallée Poussin. Rosser and Schoenfeld [36]
have shown that the first 3 502 500 zeros of ζ (s) lie on the vertical with real part
1/2. Van de Lune et al. [41] have shown that the first 1 500 000 000 zeros are on this
critical line. Wedeniwski [42] and then Gourdon [13] managed to compute zeros in
a parallel way and have proved that the Riemann hypothesis is true at least for first
1013 nontrivial zeros. Ramaré [28] and Kadiri [17] have introduced an explicit density
estimate which improves the location of the zeros in the critical strip.
   This will improve bounds [10] for ψ(x) and ϑ(x) for moderate values of x. Here
and everywhere f (x) = O∗ (g(x)) means | f (x)| ⩽ g(x). We will prove the following
results (Theorems 3.3 and 4.2, respectively):
                                             
                   ψ(x) = x + O∗ 59.2x/ ln4 x    for x ⩾ 2,
                                              
                   ϑ(x) = x + O∗ 151.3x/ ln4 x    for x ⩾ 2.

   We apply the previous result on pk , the kth prime. Denote ln ln x by ln2 x. The
asymptotic expansion of pk is well known; Cesaro [4] then Cipolla [5] expressed it in
1902:
                                                                                3
                          ln2 k − 2 ln22 k − 6 ln2 k + 11                  ln2 k
pk = k ln k + ln2 k − 1 +          −                      +O                              .
                             ln k           2 ln2 k                         ln k

123
Explicit estimates of some functions over primes                                                229


  A more precise work about this can be found in [32,37]. The results on pk are
(Lemma 5.14 and Proposition 5.16):
                                                        
                              ln2 k − 2
    pk = k ln k + ln2 k − 1 +           + O∗ (0.1/ ln k)                   for k ⩾ 178 974.
                                 ln k

   We use the above results to prove (Corollary 5.5) that, for x ⩾ 468 991 632, the
interval

                                     x, x + x/(5000 ln2 x)

contains at least one prime. Denote the number of primes not greater than x by π(x).
We show that (Corollary 5.2)
                                                             
                   x          1     ⩽ π(x) ⩽ x           1.2762
                          1+               x>1       1 +          .
                  ln x       ln x x⩾599        ln x       ln x

   A more precise result on π(x) is also shown:
                                                    
               x          1      2
    π(x) =            1+      + 2 + O∗ 0.53816/ ln2 x                        for x ⩾ 11 813.
              ln x       ln x  ln x

  In this paper, we give also some new effective estimates for the difference between
ψ and ϑ (Corollary 4.5), for ϑ( pk ) (Propositions 5.11 and 5.12), for sums over primes
                        1                          ln p
(Theorem 5.6 for      p p , Theorem 5.7 for      p p ), and for products over primes
(Theorem 5.9).


2 Estimates of prime-related functions using the Riemann zeta theory

2.1 Relation between ψ and ζ

The Riemann zeta function ζ (s) is a function of a complex variable s and can also be
defined for (s) > 1 by the integral
                                                    +∞
                                         1                 x s−1
                                ζ (s) =                          dx.
                                        (s)        0     ex − 1

   Zeros of ζ come in (at least) two different types. The so-called “trivial zeros” occur
at all negative even integers s = −2, −4, −6, . . . , and “nontrivial zeros” at certain
s = σ + it for s in the critical strip 0 < σ < 1.
   A classic explicit formula that relates prime numbers to nontrivial zeros of ζ is
given by [11, §3.8, p. 66]:

                                        xρ                    1
                         ψ(x) = x −                − ln 2π −     ln(1 − x −2 ),                (2.1)
                                        ρ
                                             ρ                 2


                                                                                       123
230                                                                                P. Dusart


when x > 1 is not a prime power. At the jumps x = p n , the value of ψ is defined, as
usual, to be the halfway between the new and the old values ψ(x) = 21 (ψ(x − ε) +
ψ(x + ε)).


2.2 Zeros of the Riemann zeta function

2.2.1 Location of zeros

As the zeros of ζ are closely related to sums over primes by (2.1), the Riemann zeta
function’s zeros location is of great importance in number theory to estimate ψ(x) and
ϑ(x). In 1859, Riemann asserts that the nontrivial zeros of the Riemann zeta function
have real part σ = (s) = 1/2, a line called the critical line. This conjecture is known
as the Riemann hypothesis.
   The Riemann hypothesis was computationally tested and found to be true up to a
height, denoted H for the rest of the paper, covering zeros σ + it in the region 0 <
t < H . The history of Riemann hypothesis verification starts in 1903 by Gram [14],
who computes the first fifteen zeros. The higher result is from Gourdon [13] in 2004
who announced to have used the Odlyzko and Schönhage’s method to verify that
the first ten trillion (1013 ) nontrivial zeros of the ζ function lie on the critical line.
The last computation implies that the Riemann hypothesis is true at least for H2 =
2 445 999 556 030 but remains not really published. The authors of [12] mentioned
the Platt’s result which used another method to verify the hypothesis up to H1 =
30 610 046 000. We use the H2 value in order to achieve comparable results with [12].
   Classically the Riemann hypothesis testing methods do not compute exactly the
zeros of ζ , but to go faster, they merely check that the number of expected zeros by
interval is correct. Nevertheless if you have to compute sum over nontrivial zeros like
(2.1), you must know zero ordinates with accuracy for computing at least partially this
type of sum.
   Odlyzko [23] computes the first 2 001 052 zeros of the Riemann zeta function on
the critical line, accurate to within 4 × 10−9 . Hence one can compute sums over zeros
  = 1/2 + iγ based on this list of zeros. It yields,
                                                        1
Lemma 2.1 Let T0 = 1 132 490.982. Then                     ≤ 11.6377324.
                                                         γ
                                               0<γ ≤T0


2.2.2 Number of zeros

If you have to compute sum over zeros like (2.1), you need also to introduce the
number of nontrivial zeros up to a fixed height. Let T ≥ 2 and N (T ) be the number
of nontrivial zeros = β + iγ in the region 0 ≤ γ ≤ T and 0 ≤ β ≤ 1. In 1941,
Rosser [34, Theorem 19] proved
Theorem 2.2 (Rosser) Let T ≥ 2,

                   T    T    T  7
        F(T ) =      ln   −    + , R(T ) = a1 ln T + a2 ln ln T + a3 ,
                  2π 2π     2π  8

123
Explicit estimates of some functions over primes                                       231


and a1 = 0.137, a2 = 0.443, a3 = 1.588. Then

                                   |N (T ) − F(T )| ≤ R(T ).

   The upper bound R(T ) and

                                                           a1 ln y + a2
                      q(y) = R  (y)/ ln(y/(2π )) =                                  (2.2)
                                                        y ln y ln(y/(2π ))

are used thereafter. A recent work [39] of Trudgian updated these values, but with a
low impact on our computations. In [17], Kadiri detailed the number N (T ) by cutting
the critical strip. Let N (σ0 , T ) is the number of nontrivial zeros of zeta in the region
σ0 ≤ β ≤ 1 and 0 ≤ γ ≤ T . She proved explicit upper bounds for N (σ0 , T ) and
the result was improved by Ramaré [28, Theorem 1.1] in some cases (a factor 1/2 is
required for the consistency of the two author’s definitions).

Theorem 2.3 (Ramaré) Let σ0 ⩾ 0.52. Then for T ≥ 2000,

                                                                   
                                      9.8      8(1−σ0 )/3 5−2σ0        103
 N (σ0 , T ) ≤ F̃(σ0 , T ) = T ln 1 +     (3T )          ln     (T ) +     (ln T )2
                                      2T                                2

   To be compliant with Kadiri’s work we choose c2 = c3 = 0 and c1 = F̃(σ0 , H )/H
to have for σ0 > 5/8,

                              N (σ0 , T ) ⩽ c1 T   for all T ⩾ H.

2.2.3 Zero-free region

We make use of classical type (de la Vallée Poussin type) zero-free region. Taking
over the work of Kadiri [16], the better result of this type is due to Mossinghoff and
Trudgian [20, Theorem 1], with the following

Theorem 2.4 (Mossinghoff and Trudgian) Let R = 5.573412. Then there are no
zeros of ζ (s) in the region

                                               1
                          (s) ≥ 1 −                  and | (s)| ≥ 2.
                                          R ln | (s)|


3 Bound for ψ

We use the Faber and Kadiri’s method [12] who introduce an explicit formula for a
smooth form of ψ(x). Let us introduce their notations:

                                                                                123
232                                                                                    P. Dusart


      • H > 0 is such that if ζ (β + iγ ) = 0 and 0 < γ < H, then β = 1/2,
      • T0 > 2π is such that 0<γ <T0 γ −1 can be directly computed,
      • T1 is a parameter satisfying T0 < T1 < H,
      • R is a constant so that ζ (σ + it) does not vanish in the region                  (3.1)
        σ ≥ 1 − R ln1 |t| and |t| ≥ 2,
      • σ0 is a parameter satisfying 5/8 ≤ σ0 < 1,
      • c1 > 0 depend on σ0 so that N (σ0 , T ) ≤ c1 T for all T ≥ H.

  Like Rosser and Schoenfeld, the authors used the following integral related to the
modified Bessel function of second kind
                                         ∞              z         
                                    1
                     K ν (z, w) =              t ν−1 exp − (t + 1/t) dt,
                                    2    w                2

to explicit more easily the integrals involved in their method and introduced

                                                               
                                               z        2m
                             Jm (Y ) =           K 1 z,    ln Y
                                              2m         z

             
with z = 2       m ln x
                   R . Let

                                         1
                     (2m + 1)!
        M(a, b, m) =                          |Pm (1 − 2u)| ((b − a)u + a)m+1 du,         (3.2)
                        m!               0


where Pm is the m th Legendre polynomial, defined by

                                m  2 
                                                   
                                   m     x + 1 k x − 1 m−k
                     Pm (x) =                                           .
                                         k          2         2
                                k=0


   We rewrite the main theorem of Faber and Kadiri [12]:

Theorem 3.1 Let m ∈ N, m ≥ 2, δ > 0, and the pair (a, b) takes values (1, 1 + δ)
or (1 − δ, 1). Let H, T0 , T1 , R, σ0 , c1 satisfy (3.1). Let b0 be a positive constant. Then
for all x ⩾ eb0 ,

 |ψ(x) − x|          2M(a, b, m)                                                             
                                                 −(1−σ0 )    −σ0 b0          −(1− R ln1 H b0 )
            ⩽ max                   B5 +  B 3 (e          +e        ) + B4 e
     x        (a,b)      δm
                                                       
                                      M(a, b, m)                      δ
              + 2 M(a, b, 0)B1 +                     B2 e−b0 /2 +
                                           δ m                        2
                                M(a,   b, 0)        
              + ln(2π )e−b0 +                e−3b0                                        (3.3)
                                     2

123
Explicit estimates of some functions over primes                                         233


where M(a, b, m) is given by (3.2), and the Bi ’s are defined, respectively, in (3.4),
(3.5), (3.6), (3.7), and (3.8).

                                                                       2R(T )
                            1      1                                              0
B1 (T0 , T1 ) =               +      +q(T0 )    ln(T1 /T0 ) ln( T1 T0 /2π ) +       ,
                            γ     2π                                           T0
                  0<γ ≤T0

                                                                                  (3.4)
                                                                        
                   1                     1 + m ln(T1 /2π ) 1 + m ln(H/2π )    2R(T1 )
B2 (m, T1 , H ) =    +q(T1 )                              −                  + m+1 ,
                  2π                          m 2 T1m          m2 H m          T1
                                                                                  (3.5)
                               
                 1                 1 + m ln(H/2π ) 2R(H )
B3 (m, H ) =         + q(H )                            + m+1 .                        (3.6)
                2π                        m2 H m           H
                               
                             1        1
B4 (m, H, σ0 ) = c1 1+                  .                                              (3.7)
                            m Hm
B5 (x, m, σ0 , H )
     ⎧                                   
     ⎪
     ⎨ c1 1 + R  (ln           H ) 2        − 1
                  2 ln x m R (ln H )2 −1
                                             x R ln H
                                               Hm     if b0 < m R(ln H )2
  =                      ln x                                                          (3.8)
     ⎪
     ⎩ x − R ln1 H
        c1 H m + c1 Jm (H ) in other case.

Proof From [12], we use the expression (2.19) of Lemma 2.4. We delete the s0 term
which is already included in the s1 term. Next, we respectively substitute s1 , s2 , s3 , s4
by B1 , B2 , B3 , B4 (2.22–2.25 of [12]). The s5 term is bounded with (2.27) and can
be bounded by (2.30) if w > 1 (i.e., ln x < m R ln2 H ). The modified Bessel function
K 1 (z, w) can be computed if 0 ⩽ w ≤ 1 using (2.30)      and (2.35) of[36]. Next, for the
                                                                         1       
two choices of the (a, b) pair, it follows by (3.3) that a−1+(b−a) 0 g(u)du  = δ/2.


Proposition 3.2 Let b0 ≥ 0 be a fixed positive constant. Let x ≥ eb0 . Then there
exists ε0 > 0 such that |ψ(x) − x| ≤ ε0 x, where ε0 is given explicitly by (3.3) and is
computed in Table 1 for H2 = 2 445 999 556 030.

Theorem 3.3 We have
                                                     x
                              |ψ(x) − x| < ηk               for x ⩾ 2
                                                   lnk x

     with


k                  0                  1                    2            3               4
ηk                 0.77               0.85                 1.66         8.16            59.18




                                                                                  123
234                                                                  P. Dusart


Table 1 Values of ε(x) for ψ

b             σ0           m    δ            T1                  ε

20            0.86         5    1.595 E−5    1 132 492           1.067 E−3
21            0.86         5    1.468 E−5    1 132 492           6.498 E−4
22            0.86         4    1.282 E−5    1 132 492           3.968 E−4
23            0.86         4    1.160 E−5    1 132 492           2.431 E−4
24            0.85         3    9.778 E−6    1 132 492           1.496 E−4
25            0.86         3    8.629 E−6    1 132 492           9.250 E−5
30            0.86         2    2.554 E−6    1 882 244           9.647 E−6
35            0.86         2    2.458 E−7    19 612 863          1.078 E−6
40            0.87         2    2.756 E−8    161 338 534         1.161 E−7
45            0.87         3    2.721 E−9    2 228 096 512       1.225 E−8
50            0.88         5    2.572 E−10   37 754 757 543      1.275 E−9
55            0.89         15   4.374 E−11   568 871 547 031     1.388 E−10
60            0.90         23   3.812 E−11   973 812 914 637     2.978 E−11
65            0.90         23   3.751 E−11   989 645 080 596     2.039 E−11
70            0.90         22   3.697 E−11   963 148 272 814     1.940 E−11
75            0.90         22   3.658 E−11   973 564 683 528     1.913 E−11
80            0.91         22   3.621 E−11   987 265 077 216     1.893 E−11
85            0.91         22   3.573 E−11   996 465 239 887     1.868 E−11
90            0.91         22   3.533 E−11   1 007 775 601 523   1.847 E−11
95            0.91         21   3.492 E−11   976 821 063 390     1.830 E−11
100           0.91         21   3.464 E−11   987 265 077 216     1.815 E−11
200           0.94         18   2.951 E−11   1 003 417 649 160   1.557 E−11
300           0.95         16   2.642 E−11   1 006 421 703 556   1.404 E−11
400           0.96         14   2.403 E−11   980 285 487 059     1.288 E−11
500           0.96         13   2.255 E−11   977 429 125 922     1.215 E−11
600           0.97         12   2.058 E−11   997 132 955 137     1.115 E−11
700           0.97         11   1.904 E−11   998 061 945 822     1.039 E−11
800           0.97         11   1.801 E−11   1 019 509 030 546   9.826 E−12
900           0.97         10   1.688 E−11   1 019 509 030 546   9.281 E−12
1000          0.97         9    1.574 E−11   1 012 519 261 279   8.743 E−12
1500          0.98         5    8.852 E−12   1 019 509 030 546   5.311 E−12
2000          0.98         2    3.381 E−12   1 364 832 983 117   2.536 E−12
2500          0.98         2    1.193 E−12   2 445 999 556 029   8.941 E−13
3000          0.98         2    4.209 E−13   2 445 999 556 030   3.156 E−13
3500          0.98         2    1.487 E−13   2 445 999 556 030   1.116 E−13
4000          0.98         2    5.262 E−14   2 445 999 556 030   3.946 E−14
4500          0.99         2    1.699 E−14   2 445 999 556 030   1.274 E−14
5000          0.99         2    5.274 E−15   2 445 999 556 030   3.956 E−15
6000          0.99         2    6.524 E−16   2 445 999 556 030   4.893 E−16
7000          0.99         2    8.524 E−17   2 445 999 556 030   6.393 E−17




123
Explicit estimates of some functions over primes                                           235


Table 1 continued

b              σ0             m          δ                       T1                  ε

8000           0.99           2          1.196 E−17              2 445 999 556 030   8.969 E−18
9000           0.99           2          3.236 E−18              2 445 999 556 030   2.427 E−18
10000          0.99           3          1.222 E−17              2 445 999 556 030   8.144 E−18
13900          0.99           2          3.144 E−20              2 445 999 556 030   2.358 E−20




Proof We compute the upper bound ηk step by step up to the end of Table 1. For
example, if εbi is the value obtained for x = ebi we need to have ηk ⩾ εbi · bi+1  k

for e i ⩽ x ⩽ e i+1 (we need to compute some intermediate values of ε(x) between
     b           b

e1500 and e2000 ). For large values outside the table, we use Theorem 1.1 of [10]. We
                                                                                    k
conclude by direct inspection for small values of x. The maximum of |ψ(x) − x| lnx x
is
    • for x ⩾ 2, η0 < (3 − ψ(3− ))/3 ≈ 0.7689509398,
    • for x ⩾ 2, η1 < (3 − ψ(3− ))/3 · ln(3) ≈ 0.8447789518618,
    • for x ⩾ 2, η2 < (17 − ψ(17− ))/17 · ln2 (17) ≈ 1.6583011509743,
    • for x ⩾ 2, η3 < (223 − ψ(223− ))/223 · ln3 (223) ≈ 8.15435775451,
    • for x ⩾ 2, η4 < (1423 − ψ(1423− ))/1423 · ln4 (1423) ≈ 59.1713704.



4 Bounds for ϑ

4.1 Exact computation of ϑ

Lemma 4.1 We have

                ϑ(1015 ) = 999 999 965 752 660.939839805291048 · · · .

Proof From the well-known identity

                                                   ∞
                                                   
                                      ψ(x) =             ϑ(x 1/k ),                       (4.1)
                                                   k=1

we have
                                                     ∞
                                                     
                                  ϑ(x) = ψ(x) −             ϑ(x 1/k ).
                                                     k=2

From some exact values of ψ(x) computed by [7], we obtain Table 2 (Exact values of
ϑ(x))



                                                                                     123
236                                                           P. Dusart


Table 2 Values of ϑ(x) for 1010 ⩽ x ⩽ 1015

x                             ϑ(x)                     ψ(x) − ϑ(x)

1E+10                         9999939830.657757        102289.175716
2E+10                         19999821762.768212       144339.622582
3E+10                         29999772119.815419       176300.955450
4E+10                         39999808348.775748       203538.541084
5E+10                         49999728380.731899       227474.729168
6E+10                         59999772577.550769       249003.320704
7E+10                         69999769944.203933       268660.720820
8E+10                         79999718357.195652       287365.266118
9E+10                         89999644656.090911       304250.688854
1E+11                         99999737653.107445       320803.322857
2E+11                         199999695484.246439      453289.609568
3E+11                         299999423179.995211      554528.646163
4E+11                         399999101196.308601      640000.361434
5E+11                         499999105742.583455      715211.001138
6E+11                         599999250571.436655      783167.715577
7E+11                         699998999499.845475      845911.916175
8E+11                         799999133776.084743      904203.190001
9E+11                         899998818628.952024      958602.924046
1E+12                         999999030333.096225      1009803.669232
2E+12                         1999998755521.470649     1427105.865316
3E+12                         2999997819758.987859     1746299.820370
4E+12                         3999998370195.717561     2016279.693623
5E+12                         4999998073643.711478     2253672.042145
6E+12                         5999997276726.877147     2467566.593710
7E+12                         6999996936360.165729     2665065.541181
8E+12                         7999997864671.383505     2848858.049155
9E+12                         8999996425300.244577     3021079.319393
1E+13                         9999996988293.034200     3183704.089025
2E+13                         19999995126082.228688    4499685.436490
3E+13                         29999995531389.845427    5509328.368277
4E+13                         39999993533724.316829    6359550.652121
5E+13                         49999992543194.263655    7109130.001413
6E+13                         59999990297033.626198    7785491.725387
7E+13                         69999994316409.871731    8407960.376833
8E+13                         79999990160858.304239    8988688.375101
9E+13                         89999989501395.073897    9531798.550749
1E+14                         99999990573246.978538    10045400.569463
2E+14                         199999983475767.543204   14201359.711421
3E+14                         299999986702246.281944   17388356.540338
4E+14                         399999982296901.085038   20074942.600622




123
Explicit estimates of some functions over primes                                                      237


Table 2 continued

x                                  ϑ(x)                                               ψ(x) − ϑ(x)

5E+14                              499999974019856.236519                             22439658.012185
6E+14                              599999983610646.997632                             24580138.242324
7E+14                              699999971887332.157455                             26545816.027402
8E+14                              799999964680836.091645                             28378339.693784
9E+14                              899999961386694.231242                             30098146.961102
1E+15                              999999965752660.939840                             31724269.567843




4.2 On the difference between ϑ and identity function

Theorem 4.2 We have
                                                     x
                                |ϑ(x) − x| < ηk            for x ⩾ xk
                                                   lnk x

with

k     0       1            1               2          2            2                  2
ηk    1       1.2323       0.001           3.965      0.2          0.05               0.01
xk    1       2            908 994 923     2          3 594 641    122 568 683        7 713 133 853

and


k         3            3            3                3                  3                  4
ηk        20.83        10           1                0.78               0.5                151.3
xk        2            32 321       89 967 803       158 822 621        767 135 587        2



Proof We combine the estimates of |ψ(x)  √ − x| given in Proposition 3.2 with the
upper bound of |ψ(x) − ϑ(x)| < 1.4262 x given in [35, Theorem 13]. We proceed
                                    √ For example, if εbi is the value obtained for
step by step up to the end of the table.
x = ebi we have ηk ⩾ (εbi + 1.43/ ebi ) · bi+1
                                            k   for ebi ⩽ x ⩽ ebi+1 . For large values
outside the√table, we
                    √ use [10, Theorem√ 1.1] with R defined in Theorem 2.4 and we
have ηk ⩾ 8/π ( ln(x0 )/R)1/2 · e− ln(x0 )/R · lnk (x0 ) for x ⩾ x0 . The maximum of
             k
|ϑ(x) − x| lnx x is
    • for x ⩾ 1, η0 < (1 − ϑ(1− ))/1 = (2 − ϑ(2− ))/2 = 1,
    • for x ⩾ 2, η1 < (11 − ϑ(11− ))/11 · ln(11) ≈ 1.23227674,
    • for x ⩾ 2, η2 < (59 − ϑ(59− ))/59 · ln2 (59) ≈ 3.964809,
    • for x ⩾ 2, η3 < (1423 − ϑ(1423− ))/1423 · ln3 (1423) ≈ 20.8281933,
    • for x ⩾ 2, η4 < (1423 − ϑ(1423− ))/1423 · ln4 (1423) ≈ 151.2235681.



                                                                                           123
238                                                                                       P. Dusart


4.3 On the difference between ψ and ϑ

As ϑ(2− ) = 0, the summation (4.1) ends:

                       ln x
                        ln 2                                      ln x
                                                                    ln 2 
                                                        √        
             ψ(x) =              ϑ(x   1/k
                                             ) = ϑ(x) + ϑ( x) +              ϑ(x 1/k ).
                       k=1                                         k=3


4.3.1 Lower bound

Proposition 4.3 For x ⩾ 121, we have
                                    √
                              0.9999 x < ψ(x) − ϑ(x),                                        (4.2)
                                  
                                4    √
                            1− 3       x < ψ(x) − ϑ(x).                                      (4.3)
                              ln x

                                                   √      √              
                                                                    2k ηk
Proof Using Theorem 4.2, we have ψ(x) − ϑ(x) ⩾ ϑ( x) ⩾ x 1 − ln       kx    which
                                       √
can be applied with k = 3, ηk = 0.5 for x > 767 135 587. Now by [6, p. 211],

                                      √            1
                      ψ(x) − ϑ(x) = ψ( x) +   ϑ(x 2k+1 ),
                                                        k ⩾1


hence
                                         √
                         ψ(x) − ϑ(x) ⩾ ψ( x) + ϑ(x 1/3 ).

  By Theorem 19 of [35, p. 72], we have
                            √
                ϑ(x 1/3 ) > 3 x − 2x 1/6 for (1423)3 ⩽ x ⩽ (108 )3 ,

and by (7.2) of [38, Theorem 11], we have for x ⩾ e2b ,
                                     √    √      √
                                   ψ( x) > x − εb x

where εb can be found in the Table in p. 358 of [38] (or in Table 1). We verify that
                                    
                             4         √    √
                             3
                                − εb     x + 3 x − 2x 1/6 > 0
                           ln x

for 1016 ⩽ x ⩽ e46 by intervals (we use b = 18.42, 20, 22). By Theorem 24 of [35,
p. 73], we conclude that (4.2) is verified for 121 ⩽ x ⩽ 1016 .


123
Explicit estimates of some functions over primes                                              239


4.3.2 Upper bound

Proposition 4.4 For x > 0, we have
                                             √
                             ψ(x) − ϑ(x) − ϑ( x) < 1.777745x 1/3 .                           (4.4)

Proof For x > 0, we have ϑ(x) < 1.000081x by [38, p. 360]. Hence

                 ln x
                  ln 2                             ln x
                                                     ln 2 
                                                  
                           ϑ(x 1/k ) < 1.000081               x 1/k
                 k=3                                k=3
                                                                                   
                                                                        ln x
                                   < 1.000081 x         1/3
                                                               +               −3 x 1/4
                                                                        ln 2
                                   < 1.2 x 1/3 for x > (1011 )3 .

For small values, using the result ϑ(x) < x for x ⩽ 1011 p. 360 in [38], we proceed by
                                                                                  n+1
intervals such as 2n ⩽ x < 2n+1 where nk=3 ϑ(x 1/k ) < nk=3 x 1/k < nk=3 2 k .
We find the maximal difference of (4.4) by direct computation (maximum is reached
for x=2401). With this result, we update the (3.38) part from Theorem 14 of [35].

Corollary 4.5 For x > 0,
                                                     √
                     ψ(x) − ϑ(x) < (1 + 1.47 · 10−7 ) x + 1.78x 1/3 .
                                  √       √       √
Proof The result follows from ϑ( x) < x for x < 1.39 · 1017 from a com-
putational result [26] of Platt and Trudgian. Next we compute the ε value for
b = ln(1.39 · 1017 ) using Theorem 3.1 and Proposition 4.4 (σ0 = 0.87, m = 2, δ =
3.048E−8, T1 = 157 682 321, ε = 1.467E−7).


5 Estimates of prime-related functions thanks ϑ function

5.1 Estimates of π function

The prime-counting function π(x) is the function counting the number of prime num-
bers less than or equal to some real number x. Let li(x), the logarithmic integral defined
for all positive real numbers x = 1 by the definite integral:
                                             1−ε                     x         
                                                         dt                 dt
                             li(x) = lim                     +                        .
                                     ε→0+     0         ln t           1+ε ln t

   A classical result [15, Theorem 23] makes a link between these two quantities:

                                                           √     
                             if x → ∞, π(x) = li(x) + O xe−C ln x                            (5.1)

                                                                                            123
240                                                                                         P. Dusart


with some constant C > 0. The estimate (5.1) is better than any estimate of the form
                                               
                               π(x) − li(x) = O x/ lnm x).

   Hence the asymptotic development of π(x) is
                                                                          
                                  x  k!
                                           n
                                                                   x
                    π(x) =                    +O                               .
                                 ln x (ln x)k                  (ln x)n+1
                                      k=0


Theorem 5.1 For x ⩾ 4 · 109 ,
                                                     
                       x          1      2       7.32
             π(x) =           1+      + 2 + O∗            .
                     ln x        ln x  ln x      ln3 x

For x > 1,
                                                                         
                             x                 1      2  7.59
                     π(x) ⩽                1+      + 2 + 3                    .
                            ln x              ln x  ln x ln x

Proof We substitute an upper bound for ϑ(x) of the form |ϑ(x) − x| ⩽ ηk lnxk x for
x ⩾ x0 , in Theorem 4.3 of [1]
                                                                   x
                                               ϑ(x0 ) ϑ(x)              ϑ(y)dy
                  π(x) = π(x0 ) −                    +      +
                                               ln x0   ln x        x0   y ln2 y

to introduce
                                                         x                       
                           x          x                             1      ηk
         J (x; ηk ) = K +      + ηk k+1 +                           2
                                                                       + k+2           dy
                          ln x     ln   x                 x0      ln y  ln    y

with
                                                       ϑ(x0 )
                                    K = π(x0 ) −              .
                                                       ln x0

such that, for x ⩾ x0 ,

                              J (x; −ηk ) ⩽ π(x) ⩽ J (x; ηk ).
                      k−1
                   x    n!          c
Let Mk (x; c) =              n   + k       inspired from the beginning of the asymp-
                 ln x      ln x    ln x
                       n=0
totic development of li(x). Let us write the derivatives of J (x; ηk ) and of M(x; c)
with respect to x:

                                                1       ηk      ηk
                          J  (x; ηk ) =            + k+1 − k k+2 ,
                                               ln x  ln    x ln    x

123
Explicit estimates of some functions over primes                                      241



                                               1     c − k! c(k + 1)
                               Mk (x; c) =        + k+1 − k+2 .
                                              ln x  ln    x  ln   x

For the upper bound for π(x), one must choose c ⩾ (k! + ηk − kηk / ln x0 )/(1 −
(k + 1)/ ln x0 ) to have J  < M  for x ⩾ x0 . The bound is valid if J (x0 ; ηk ) ⩽
Mk (x0 ; c). With η3 = 0.5 and x0 = 1015 , we have to choose c ⩾ 7.303. We verify
that J (1015 ; 0.5) < M3 (1015 ; 7.32) using Table 3 of [30] and Table 2. We use the
result of [26, Corollary 1] to limit the computer verification: as π(x) < li(x) for
x < 1.39 · 1017 , the result is valid as li(x) is lower than the upper bound for x >
1.62 · 1010 . The constant 7.5893, which appears in ln3 x term, is reached for p =
110 102 617. For the lower bound, to have J  (x; −ηk ) > Mk (x; c) we have to choose
c < (k! − ηk + kηk / ln x)/(1 − k+1ln x ). With k = 3, we choose c = 0, x 0 = 10 , and
                                                                                11

η3 (1 − 3/ ln x) < 6. As M(x0 ; 0) < J (x0 ; −1) and by direct computation for small
values, we obtain
                                                             
                              x              1      2
                      π(x) >             1+      + 2              for x ⩾ 88 789.
                             ln x           ln x  ln x



   We use the previous result to give bounds for π(x). The lower bounds are the first
terms and the upper bounds are the best bounds (best in terms of last constant) for
x > 1 of first order of the asymptotic development of li(x).
Corollary 5.2

                                        x                    x
                                            ⩽ π(x) ⩽ 1.2551      ,
                                       ln x                 ln x
                                          x ⩾17         x>1                          (5.2)
                                                                
                         x          1               x       1.2762
                                1+        ⩽ π(x) ⩽       1+          ,
                        ln x       ln x            ln x      ln x
                                         x ⩾599         x>1                          (5.3)
                                                                            
            x               1      2                    x        1     2.53816
                      1+        + 2           ⩽ π(x) ⩽       1+      +           .
           ln x            ln x  ln x                  ln x     ln x     ln2 x
                                      x ⩾88 789         x>1                          (5.4)

Proof The upper bounds are reached, respectively, for p30 = 113, p258 = 1627,
and p30392 = 355 111. We also verify that π(x) ⩾ lnxx 1 + ln1x + 2−0.53816
                                                                     ln2 x
                                                                            for
x ≥ 11 813 to complete a result announced in the introduction.

   Using the asymptotic development of 1/ li(x), Panaitopol [25] showed another
formula for π(x) by proving that

                                                         x
                                     π(x) =                        ,
                                                  ln x − 1 − f (x)

                                                                                    123
242                                                                               P. Dusart


where f (x) = k1 / ln(x) + k2 / ln2 (x) + · · · + O(1/ lnm (x)) with ki given by the
recurrence relation

                kn + 1! kn−1 + 2! kn−2 + · · · + (n − 1)! k1 = n · n!.

We obtain this kind of asymptotic development

                                              x
             π(x) =
                      ln x − 1 − 1/ ln(x) − 3 ln2 (x) − 13/ ln3 (x) − · · ·

which is useful [2,3] for bounds for 1/π(x).

Corollary 5.3

                             x                   x
                                  ⩽ π(x) ⩽              ,
                         ln x − 1          ln x − 1.112
                              x ⩾5 393      x>e1.112                                 (5.5)
                      x                               x
                                 ⩽ π(x) ⩽                           .
             ln x − 1 − 1/ ln(x)          ln(x) − 1 − 1.2311/ ln(x)
                            x ⩾468 049      x>5.6                                    (5.6)

Proof The upper bounds are reached, respectively, for p2688 = 24 137 and p246651 =
3 445 943.


5.2 Smallest interval containing primes

The problem of the smallest interval containing primes is linked with the problem of
prime gaps (i.e., the difference between two successive prime numbers) and can be use-
ful for the verification of the ternary Goldbach’s conjecture [18] or for searching primes
[40] between cubes. A result of Schoenfeld [38] showing that, for x ⩾ 2 010 759.9,
the interval ]x, x + x/16597[ contains at least one prime, was improved by [29], [40],
and recently by [18].

Proposition 5.4 For all x ⩾ 89 693, there exists a prime p such that
                                                        
                                                   1
                              x < p ⩽ x 1+                   .
                                                 ln3 x

Corollary 5.5 For all x ⩾ 468 991 632, there exists a prime p such that
                                                
                                          1/5000
                             x < p ⩽ x 1+          .
                                           ln2 x

   This result is better than Trudgian’s one [40]. The specific method used in [29]
gives better results (if we compare with the same order of k, i.e., k = 0) and was
updated by [18].

123
Explicit estimates of some functions over primes                                         243


Proof Let 0 < f (x) < 1 for x ⩾ x0 ,
                                                                          
                                               x(1 + f (x))             x
ϑ (x(1 + f (x))) − ϑ(x) ⩾ x(1 + f (x)) − ηk k                 − x + ηk k
                                            ln (x(1 + f (x)))         ln x
                                                         
                                         2ηk     ηk f (x)
                          > x f (x) − k −                   .
                                        ln x      lnk x

Choose f (x) = lnβk x with β ⩾ 1+η 2η k
                                    / lnk x
                                            to have
                                            k       0

                                                   
                                              β
                                 ϑ   1+              x − ϑ(x) > 0.
                                            lnk x

For k = 3 and x0 = 4 · 1018 , n 3 = 0.499 (Theorem 4.2 with a little more precision),
we have β ⩾ 0.998. Using the work on maximal gaps between primes [21,22] (or
resumed in [24, Table 8]), we proceed as follows. Assume that the maximal gap of all
primes between x1 and x2 is . Therefore pn+1 ⩽ pn +  which is smaller than our
bound as long as lnxk 1x ⩾ /β. Hence we find easily that the result is correct between
                         1
360 653 and 4 × 1018 . We verify by computer the lower bound of the validity range.


5.3 Estimates of sums over primes

Let γ be Euler’s constant (γ ≈ 0.5772157). For more accuracy, one can find more
decimals and bibliography on the On-Line Encyclopedia of Integer Sequences (OEIS).
The Euler’s constant is referenced as sequence A001620.

Theorem 5.6 Let M be the Meissel–Mertens constant (sequence A077761 in OEIS )
given by the infinite sum

                          
             M =γ +              (ln(1 − 1/ p) + 1/ p) ≈ 0.26149 72128 47643.
                             p


We have for x ⩾ 2 278 383,

                              1                                             
                                                              ∗        0.2
                                        = ln ln x + M + O                         .
                             p ⩽x
                                    p                                 ln3 x


Proof The sum of prime reciprocals is related to ϑ(x) by (4.20) of [35],

           1                                            ∞
                                         ϑ(x) − x             (ϑ(y) − y)(1 + ln y)
                     = ln2 x + M +                −                                dy.
          p ⩽x
                 p                        x ln x        x           y 2 ln2 y


                                                                                      123
244                                                                              P. Dusart


Hence
                             
                                            ∞
          1                  |ϑ(x) − x|       |ϑ(y) − y|(1 + ln y)
                − ln   x − M ⩽           +                          dy.
                     2                               y 2 ln2 y
          p⩽x p                 x ln x      x



     With a form of an upper bound like |ϑ(x) − x| ⩽ ηk x/ lnk x (see Theorem 4.2) and
as
                       ∞
                            1 + ln y          1            1
                                      dy =         +                 ,
                      x     y lnk+2 y      k lnk x   (k + 1) lnk+1 x

     we have the result
                                          
                                          
                       1                  ηk /k   ηk (1 + k+1
                                                               1
                                                                 )
                             − ln   x − M  ⩽     +               .                (5.7)
                                  2          k           k+1
                       p⩽x p               ln x       ln     x


  For k = 3 and η3 = 0.5, the result is valid for x ⩾ 767 135 587 by Theorem 4.2.
We check by computer that the result remains valid for 2 278 383 ⩽ x ⩽ 767 135 587.


Theorem 5.7 Let B3 (sequence A083343 in OEIS ) the constant given by the infinite
sum

                               ∞ 
                               
                 B3 = γ +         (ln p)/ p n ≈ 1.33258 22757 33221.
                               n=2 p


We have for x ⩾ 912 560,

                             ln p                                   
                                                               0.3
                                       = ln x − B3 + O∗                   .
                            p ⩽x
                                   p                          ln2 x

Proof By (4.21) of [35],

                ln p                                      ∞
                                       ϑ(x) − x                   ϑ(y) − y
                         = ln x − B3 +          −                          dy.
                       p                  x                   x      y2
               p ⩽x


     Hence
                                  
                                                ∞
                 ln p              |ϑ(x) − x|       |ϑ(y) − y|
                      − ln x + B  ⩽           +                dy.
                                3                       y2
              p⩽x p                    x         x



123
Explicit estimates of some functions over primes                                      245


   As
                                 ∞
                                        dy           1
                                             =                 ,
                                  x
                                          k
                                      y ln y   (k − 1) lnk−1 x

   we obtain
                                      
                                                      
                     ln p                 ηk      ηk
                           − ln x + B  ⩽        +        / lnk−1 x.
                                     3
                                             −
                    p⩽x p                k    1   ln x

   Theorem 4.2 yields the result for x ⩾ 767 135 587 with k = 3 and ηk = 0.5. We
extended the validity range by computer.

Remark 5.8 Considering the definition of ψ̃(x) of [27], the previous theorem states
                          ln p
bounds for ϑ̃(x) =    p ⩽x p . One may find improved constants for ψ̃(x) if the
bounds on ψ(x) in Theorem 3.3 are used in Ramaré’s proof.

5.4 Estimates of products over primes

Theorem 5.9 We have for x ⩾ 2 278 382,

                                                    
                              1     e−γ             0.2
                           1−     =       1 + O∗
                         p ⩽x
                              p     ln x           ln3 x

and
                                                          
                                 p     γ           ∗    0.2
                                    = e ln x 1 + O              .
                                p−1                    ln3 x
                         p ⩽x

Proof By definition of M (see Theorem 5.6) and (5.7), we have
                                            
                       1                   η /k  ηk (1 + k+1
                                                               1
                                                                 )
                                               k
         −γ − ln2 x −       −   ln(1 − 1/ p) ⩽ k +               .
                      p>x
                           p   p
                                               ln x    ln k+1 x

                                                      ∞ 1
   Let S =         p>x (ln(1 − 1/ p) + 1/ p) = −                p>x p n . We have
                                                                    1
                                                      n=2 n

                                                           ηk       (k + 2)ηk
         −γ − ln2 x −             ln(1 − 1/ p) − S ⩾ −          −                 .
                           p ⩽x
                                                             k
                                                         k ln x   (k + 1) lnk+1 x

   Take the exponential of both sides to obtain

               1
                   
                       e−γ
                               
                                        ηk        (k + 2)ηk
                                                               
              1−     ⩽      exp −S +         +                   .
            p ⩽x
                 p     ln x          k lnk x   (k + 1) lnk+1 x


                                                                                    123
246                                                                                      P. Dusart


  We use the lower bound for S given in [35, p. 87]:

                                               1.02
                                     −S <                .
                                            (x − 1) ln x

  Hence, for k = 3, η3 = 0.5, and x ⩾ 767 135 587,

            1
                
                    e−γ                       e−γ
           1−     ⩽      exp(0.1973/ ln3 x) ⩽      (1 + 0.2/ ln3 x).
              p     ln x                      ln x
         p ⩽x


  We also have
                        p−1
                                     ⩾ eγ ln x exp(−0.1973/ ln3 x).
                                 p
                       p ⩽x


  In the same way, as

                                                        ηk       (k + 2)ηk
         −γ − ln2 x −            ln(1 − 1/ p) − S ⩽          +                 ,
                          p ⩽x
                                                          k
                                                      k ln x   (k + 1) lnk+1 x

we obtain the other inequalities since S < 0.


5.5 Estimates involving the kth primes

5.5.1 Useful bounds

Lemma 5.10

                                          pk ⩽ k ln pk for k ⩾ 4,                           (5.8)
                         ln pk ⩽ ln k + ln ln k + 1 for k ⩾ 2.                              (5.9)

Proof We deduce (5.8) from π(x) > lnxx (Corollary 1 of [35]). By Theorem 3 of [35],
we have pk < k(ln k + ln ln k − 1/2) hence pk < ek ln k for k ⩾ 2.

5.5.2 Estimates of ϑ( pk )

We have an asymptotic development of ϑ( pk ) whose the first terms by [5] are
                           
                                                 ln ln k − 2
                ϑ( pk ) = k ln k + ln ln k − 1 +
                                                     ln k
                                                                               
                                  ln ln2 k − 6 ln ln k + 11          ln ln3 k
                              −                             +O                       .
                                           2 ln2 k                    ln3 k

123
Explicit estimates of some functions over primes                                                      247


Massias and Robin [19, Th. B(v)] obtained an upper bound which corresponds to the
first terms of the asymptotic development
                                                      
                                           ln ln k − 2
          ϑ( pk ) ⩽ k ln k + ln ln k − 1 +                            for k ⩾ 198.                 (5.10)
                                               ln k

   Here, we obtain the following lower bounds:
Proposition 5.11
                                                            
                                        ln ln k − 2.050735
      ϑ( pk ) ⩾ k ln k + ln ln k − 1 +                          for pk ⩾ 1011 ,
                                                 ln k
                                                             
                                               ln ln k − 2.04
            ϑ( pk ) ⩾ k ln k + ln ln k − 1 +                     for pk ⩾ 1015 .
                                                     ln k

Proof We proceed in the same manner as [19]. Let f β defined by
                                                                          
                                                    ln ln n − β
                        n → n ln n + ln ln n − 1 +                            .
                                                        ln n

We want to prove that ϑ( pn ) ⩾ f β (n). Define the function h a by

                               h a (n) = n (ln n + ln ln n − a) .

   Suppose there exists a such that pk ⩾ h a (k) for k ⩾ k0 . Hence

                                             
                                             k                  
                                                                k
                   ϑ( pk ) − ϑ( pk0 ) =              ln pn ⩾             ln h a (n).
                                           n=k0 +1             n=k0 +1

We have f β ⩽ ln h a if
                                                                    
               ln ln n − β + 1 ln ln n − β − 1           ln ln n − a
                              −                ⩽ ln  1 +               .                           (5.11)
                      ln n           ln2 n                   ln n

We can rewrite (5.11) as
                                                                 
                                          ln ln n − a                              ln ln n − 1
    β(1 − 1/ ln n) ⩾ 1 + ln ln n − ln 1 +                             ln n −                   .   (5.12)
                                              ln n                                     ln n
                                                                                
For a ∈ [0.95, 1] and t ⩾ 22, the function t → (ln t + 1 − t ln 1 + ln t−a   t    −
   t )/(1 − 1/t) is decreasing. By [9], we can choose a = a0 = 1. For k ⩾ e
ln t−1                                                                           100 ,
the value β = 2.048 satisfies (5.12). For π(1011 ) ⩽ k ⩽ e100 , the value β0 = 2.094
satisfies (5.12). Hence
                                                                
                                                    ln ln k − β0
                   ϑ( pk ) ⩾ k ln k + ln ln k − 1 +                .
                                                         ln k

                                                                                               123
248                                                                                             P. Dusart


   Then pk ⩾ ϑ( pk ) − η2 lnkk by (4.2) and (5.8), hence pk ⩾ h a1 (k) with a1 =
                0 +η2 )
1 − ln ln k−(β
           ln k         . Splitting the interval of k, we use different values of a with adapted
values of η2 . By iterating the process, we obtain β = 2.050735 for k ⩾ k0 = π(1011 ).
This value of β verifies ϑ( pk0 ) ⩾ f β (k0 ).
   By same way, we obtain β = 2.038 for k ⩾ π(1015 ) thanks to Lemma 4.1.
Proposition 5.12 For k ⩾ 781,
                                                               
                                              ln ln k − 2 0.782
             ϑ( pk ) ⩽ k ln k + ln ln k − 1 +            − 2
                                                  ln k    ln k

Proof Use Lemmas 5.14 and 5.13.
Lemma 5.13 Let two integers k0 , k and a real γ > 0. Suppose that for k0 ⩽ n ⩽ k,
                                                             
                                               ln ln n − 1.95
               pn ⩽ n ln n + ln ln n − 1 +                      .
                                                     ln n
                                                       
                                                    γ
Let s(k) = k ln k + ln ln k − 1 + ln lnlnk−2
                                           k   −  ln2 k
                                                         . Let f (k) = s(k)−(ln k+ln ln k+
1). If ϑ( pk0 −1 ) ⩽ f (k0 ) then ϑ( pk ) ⩽ s(k) for all k ⩾ k0 .
Proof Let Sa (n) be an upper bound for pn for k0 ⩽ n ⩽ k where
                                                                
                                                     ln ln n − a
                     Sa (n) = n ln n + ln ln n − 1 +               .
                                                         ln n

Now, for 2 ⩽ k0 ⩽ k, we write

                                     
                                     k−1              
                                                      k−1                   k
       ϑ( pk−1 ) − ϑ( pk0 − 1) =            ln pn ⩽          ln Sa (n) ⩽         ln Sa (n)dn.
                                     n=k0             n=k0                  k0


Next we shall prove that ln Sa (n) ⩽ f  (n). We have

                          ln Sa (n) = ln n + ln ln n + ln(1 + u(n))

   with u(n) = ln lnlnn−1
                      n   + ln ln
                               ln n−a
                                  2n  and

                              ln ln n − 1 ln ln n + γ − 3   2γ  1
 f  (n) = ln n + ln ln n +              −        2
                                                          + 3 − (1 + 1/ ln n).
                                  ln n          ln n       ln n n

   Let β < 1/2 such that ln(1 + u(n)) ⩽ u(n) − βu 2 (n) for n ⩾ k0 . Then ln Sa (n) ⩽
f  (n) if
                                                 2
                        ln ln n − 1 ln ln n − a    2 ln ln n + γ − 3 − a
                β                  +                   −
                            ln n        ln2 n                ln2 n
                    + 2γ / ln n − 1/n − 1/(n ln n) ⩾ 0,
                             3



123
Explicit estimates of some functions over primes                                    249


   that we can simplify in

                 A         B       (ln ln n − a)2
                     + 2       + β                − 1/n − 1/(n ln n) ⩾ 0
               ln2 n     ln3 n          ln4 n
   where

                   A = β ln ln2 n − 2(β + 1) ln ln n + 3 + a + β − γ
                          B = β ln ln2 n − β(a + 1) ln ln n + aβ + γ

We have 1/n + 1/(n ln n) ⩽ 0.02/ ln3 n for n ⩾ 105 .
  We study each parts, denoting ln ln n by X :
 • β X 2 − 2(β + 1)X + 3 + a + β − γ ⩾ 0 for all X if γ − a − 1 + 1/β ⩽ 0,
 • X 2 −(a+1)X +(a+γ /β+0.01/β) ⩾ 0 for all X if a 2 −2a+1−4(γ /β+0.01/β) ⩽
   0,
 • X 2 − 2a X + a 2 = (X − a)2 ⩾ 0.
   We choose γ such that γ −a −1+1/β = 0. We choose β = u(k0 )−ln(1+u(k
                                                                   u 2 (k0 )
                                                                             0 ))
                                                                                  . With
a = 1.95 and k0 = 178974, we have β = 0.461291475 · · · and γ = 0.78217325 · · · .
   Hence ϑ( pk−1 ) − f (k) ⩽ ϑ( pk0 − 1) − f (k0 ). As ϑ( pk0 − 1) ⩽ f (k0 ), we
have ϑ( pk−1 ) − f (k) ⩽ 0. We obtain the upper bound ϑ( pk ) = ϑ( pk−1 ) + ln pk ⩽
f (k) + ln pk < s(k) by (5.9).

5.5.3 Estimates of pk

Lemma 5.14 For k ⩾ 178 974,
                                                         
                                           ln ln k − 1.95
               pk ⩽ k ln k + ln ln k − 1 +                  .
                                                 ln k

Proof Substituting x by pk in |ϑ(x) − x| ⩽ η2 lnx2 x , we obtain

                                                           pk
                                  | pk − ϑ( pk )| ⩽ η2     2
                                                                    .
                                                         ln p   k

By (5.8), we have ln2pkp ⩽ lnkk and
                           k


                                                             k
                                     | pk − ϑ( pk )| ⩽ η2        .               (5.13)
                                                            ln k
Using the upper bound (5.10) of ϑ( pk ), we have
                                                                 
                                                 ln ln k − 2 + η2
                     pk ⩽ k ln k + ln ln k − 1 +                    .
                                                        ln k

We use η2 = 0.05 for pk ⩾ 122 568 683 by Theorem 4.2.

                                                                             123
250                                                                                                P. Dusart


Proposition 5.15 For k ⩾ 688 383,
                                                                
                                                     ln ln k − 2
                         pk ⩽ k ln k + ln ln k − 1 +               .
                                                         ln k

Proof Use Proposition 5.12 with η3 = 0.78 of Theorem 4.2 for ln pk > 27. A
computer verification concludes the proof.

Proposition 5.16 For k ⩾ 3,
                                                                 
                                                    ln ln k − 2.1
                        pk ⩾ k ln k + ln ln k − 1 +                 .
                                                         ln k

Proof Using (5.13), we have

                                                              k
                                       pk ⩾ ϑ( pk ) − η2          .
                                                             ln k

   By Proposition 5.11 and η2 = 0.04913, we conclude the proof.

Acknowledgements The author wishes to thank the anonymous reviewers for their helpful comments.


References
 1. Apostol, T.M.: Introduction to Analytic Number Theory. Springer, New York (1976)
 2. Axler, C.: New bounds for the prime counting function π(x). arXiv: 1409.1780 (2014)
 3. Berkane, D., Dusart, P.: On a constant related to the prime counting function. Mediterr. J. Math. 13(3),
    929–938 (2016). doi:10.1007/s00009-015-0564-9
 4. Cesaro, E.: Sur une formule empirique de M. Pervouchine. Comptes Rendus hebdo. des Séances de
    l’Académie des Sciences CXIX119, 848–849 (1894)
 5. Cipolla, M.: La determinazione assintotica dell’n imo numero primo. Rend. Acad. Sci. Fis. Mat. Napoli
    8, 132–166 (1902)
 6. Costa P.N.: Estimates for the Chebyshev function ψ(x) − ϑ(x). Math. Comput. 44(169), 211–221
    (1985). See corrigendum [Math. Comput. 48(177), 447 (1987)]
 7. Deléglise, M., Rivat, J.: Computing ψ(x). Math. Comput. 67(224), 1691–1696 (1998)
 8. Dusart, P.: Inégalités explicites pour ψ(X ), ϑ(X ), π(X ) et les nombres premiers. C. R. Math. Acad.
    Sci. Soc. R. Can. 21(2), 53–59 (1999)
 9. Dusart, P.: The kth prime is greater than k(ln k + ln ln k - 1) for k ≥ 2. Math. Comput. 68(225), 411–415
    (1999)
10. Dusart, P.: Estimates of ψ, ϑ for large values of x without the Riemann hypothesis. Math. Comput.
    85(298), 875–888 (2016)
11. Edwards, H.M.: Riemann’s Zeta Function. Academic Press, New York–London, 1974. Pure and
    Applied Mathematics, Vol. 58. Reprinted by Dover Publications Inc., Mineola (2001)
12. Faber, L., Kadiri, H.: New bounds for ψ(x). Math. Comput. 84(293), 1339–1357 (2015)
13. Gourdon, X.: The 1013 first zeros of the Riemann zeta function, and zeros computation at very large
    height. http://numbers.computation.free.fr/Constants/Miscellaneous/zetazeros1e13-1e24.pdf (2004).
    Accessed 24 Oct 2004
14. Gram, J.P.: Note sur les zéros de la fonction ζ (s) de Riemann. Acta Math. 27(1), 289–304 (1903)
15. Ingham, A.: The Distribution of Prime Numbers. Cambridge Mathematical Library, Cambridge Uni-
    versity Press, Cambridge (1932)
16. Kadiri, H.: Une région explicite sans zéros pour la fonction ζ de Riemann. Acta Arith. 117(4), 303–339
    (2005)


123
Explicit estimates of some functions over primes                                                          251


17. Kadiri, H.: A zero density result for the Riemann zeta function. Acta Arith. 160(2), 185–200 (2013)
18. Kadiri, H., Lumley, A.: Short effective intervals containing primes. Integers 14, Paper No. A61 (2014)
19. Massias, J.-P., Robin, G.: Bornes effectives pour certaines fonctions concernant les nombres premiers.
    J. Théor. Nombres Bordeaux 8(1), 215–242 (1996)
20. Mossinghoff, M.J., Trudgian, T.S.: Nonnegative trigonometric polynomials and a zero-free region for
    the Riemann zeta-function. J. Number Theory 157, 329–349 (2015)
21. Nicely, T.R.: New maximal prime gaps and first occurrences. Math. Comput. 68(227), 1311–1315
    (1999)
22. Nyman, B., Nicely, T.R.: New prime gaps between 1015 and 5 × 1016 . J. Integer Seq. 6, 3 (2003).
    Article 03.3.1, 6
23. Odlyzko, A.M.: The 1022 -nd zero of the Riemann zeta function. In: van Frankenhuysen, M., Lapidus,
    M.L. (eds.) Dynamical, Spectral, and Arithmetic Zeta Functions. American Mathematical Society,
    Contemporary Mathematics, vol. 290, pp. 139–144 (2001)
24. Oliveira e Silva, T., Herzog, S., Pardi, S.: Empirical verification of the even Goldbach conjecture and
    computation of prime gaps up to 4·1018 . Math. Comput. 83, 288 (2014)
25. Panaitopol, L.: A formula for π(x) applied to a result of Koninck-Ivić. Nieuw Arch. Wiskd. (5) 1,
    55–56 (2000)
26. Platt, D.J., Trudgian, T.S.: On the first sign change of ϑ(x) − x. Math. Comput. 85, 1539–1547 (2016)
27. Ramaré, O.: Explicit estimates for the summatory function of (n)/n from the one of (n). Acta
    Arith. 159(2), 113–122 (2013)
28. Ramaré, O.: An explicit density estimate for Dirichlet L-series. Math. Comput. 85(297), 325–356
    (2016)
29. Ramaré, O., Saouter, Y.: Short effective intervals containing primes. J. Number Theory 98(1), 10–33
    (2003)
30. Riesel, H.: Prime Numbers and Computer Methods for Factorization. Birkhauser Boston, Cambridge,
    MA (1985)
31. Robin, G.: Estimation de la fonction de Tchebychef ϑ sur le k-ième nombre premier et grandes valeurs
    de la fonction ω(n) nombre de diviseurs premiers de n. Acta Arith. 42(4), 367–389 (1983)
32. Robin, G.: Permanence de relations de récurrence dans certains développements asymptotiques. Publ.
    l’Inst. Math. 43(57), 17–25 (1988)
33. Rosser, J.B.: The n-th prime is greater than n ln n. Proc. Lond. Math. Soc. 45, 21–44 (1939)
34. Rosser, B.: Explicit bounds for some functions of prime numbers. Am. J. Math. 63, 211–232 (1941)
35. Rosser, J.B., Schoenfeld, L.: Approximate formulas for some functions of prime numbers. Ill. J. Math.
    6, 64–94 (1962)
36. Rosser, J.B., Schoenfeld, L.: Sharper bounds for the Chebyshev functions ϑ(x) and ψ(x). Math.
    Comput. 29(129), 243–269 (1975)
37. Salvy, B.: Fast computation of some asymptotic functional inverses. J. Symb. Comput. 17(3), 227–236
    (1994)
38. Schoenfeld, L.: Sharper bounds for the Chebyshev functions ϑ(x) and ψ(x). II. Math. Comput. 30(134),
    337–360 (1976)
39. Trudgian, T.: An improved upper bound for the error in the zero-counting formulae for Dirichlet
    L-functions and Dedekind zeta-functions. Math. Comput. 84(293), 1439–1450 (2015)
40. Trudgian, T.: Updating the error term in the prime number theorem. Ramanujan J. 39(2), 225–234
    (2016). doi:10.1007/s11139-014-9656-6
41. van de Lune, J., te Riele, H.J.J., Winter, D.T.: On the zeros of the Riemann zeta function in the critical
    strip. IV. Math. Comput. 46(174), 667–681 (1986)
42. Wedeniwski, S.: Zetagrid. In: Schoder, D., Fischbach, K., Teichmann, R. (eds.) Peer-to-Peer:
    Ökonomische, Technische und Juristische Perspektiven, pp. 173–188. Springer, Berlin, Heidelberg
    (2002)




                                                                                                 123
