1 Introduction
Brun’s constant is a fundamental constant, arising in the study of twin primes, that is, pairs of prime numbers that differ by
$2$
. Set
$P_2 := \{p\text { prime}:p+2 \text { is prime}\}$
. Unlike the sum of the reciprocals of all prime numbers which diverges, the sum of the reciprocals of twin primes converges to a finite value, known as Brun’s constant. This result was first established in 1919 by Brun [Reference Brun1].
Brun’s proof did not yield a numerical upper bound for B. The first such bound,
$B < 2.347$
, was established by Crandall and Pomerance [Reference Crandall and Pomerance3]. Since then, improvements have been made, with the current best unconditional bound
$B < 2.288\,51$
obtained by Platt and Trudgian [Reference Platt, Trudgian, Bailey, Borwein, Brent, Burachik, Osborn, Sims and Zhu11]. Nicely [Reference Nicely9] conjectured that
$B = 1.902\,160\,583\,209 \pm 0.000\,000\,000\,781$
, demonstrating the scope of potential improvements to be made.
One approach to refining these bounds is to assume the generalised Riemann hypothesis (GRH). This method was employed by Klyve to derive the bound
$B < 2.1754$
[Reference Klyve7], and it will be the approach taken here. Although our improvement is small, Klyve never published his result, and utilised numerical integration to calculate his subsequent bound on B. To our knowledge, our work represents the first mathematically rigorous upper bound on B assuming GRH.
Theorem 1.1. Assume GRH. Then
$B < 2.1594$
.
To achieve this, we combine previously computed values of B (up to a fixed threshold
$x_0$
), along with the estimation of the tail end of the sum provided by Selberg’s sieve. This estimation proceeds by computing the intermediate sums

where
$m_1 = x_0$
and
$i=1,\ldots , k$
. These sums are then combined to evaluate
$B(m_1,\infty )$
.
This intermediate sum approach is advantageous due to its flexibility, as different methods of estimating B may yield tighter bounds over different regions. By combining these results, a sharper overall bound can be obtained. To facilitate further improvements, we provide explicit bounds for each
$B(m_i,m_{i+1})$
.
The structure of this paper is as follows. Section 2 introduces the sieve framework, defines key notation, and derives a bound for the twin prime counting function. Section 3 extends this bound to Brun’s constant using partial summation. Section 4 focuses on parameter optimisation and presents the numerical computations. Finally, Section 5 discusses potential refinements and further improvements to this method.
2 Upper bound on
$\pi _2(x)$
To calculate B, we require an upper bound on the twin prime counting function
$\pi _2(x) := \#\{p \text { prime}: p+2 \text { also prime}\}$
. We derive this bound using Selberg’s sieve by sieving on the set of odd numbers n such that
$n-2$
is prime. If n is removed by the sieve (that is, n is not prime), then
$(n-2,n)$
cannot form a twin prime pair.
2.1 Preliminaries
For an introduction to Selberg’s sieve, see [Reference Halberstam and Richert5]. We begin by defining some preliminary notation. Our set of twin prime candidates is given by

and our set of sieving primes by

We will be sieving using odd primes less than or equal to z, and so we set

Next,
$\mathcal {A}_d$
is the set of twin prime candidates that are divisible by a specific prime d, and

By the prime number theorem in arithmetic progressions, we can estimate
$\pi (x;d,-2)$
by
${\text {li}(x)}/{\varphi (d)}$
, and so we define the error in our estimation to be

where

As we take li to be truncated at 2, it will be useful to define the offset as

The twin prime constant is

Following Klyve [Reference Klyve7, page 128], we take

And finally, we set

Theorem 2.1 [Reference Klyve7, Theorem 5.7].
For
$0<z<x$
,

where we have defined

2.2 Bounding
$V^{-1}(z)$
We need to provide an upper bound on
$V^{-1}(z)$
for all z. As z increases, computing
$V(z)$
directly becomes infeasible, requiring a trade-off between accuracy and efficiency. To address this, we will consider three separate intervals (separated by values
$L_1$
and
$L_2$
), with different bounds on
$V(z)$
for each interval. For our calculations, we set
$L_1 = 10^8$
and
$L_2 = 10^{10}$
.
For the first interval (
$z < L_1$
), we compute
$V(z)$
exactly. For the second interval (
$L_1 < z \leq L_2$
), we compute
$V(z')$
exactly, where
$z' \in \{L_1<z\leq L_2: z=k\cdot 10^4, k \in \mathbb {N}\}$
(that is, every
$10^4$
th number). For the values of z such that
$10^4 \nmid z$
, we can round z down to the nearest
$z'$
to give an upper bound on
$V^{-1}(z)$
. For the third interval, we will use the approximation of
$V(z)$
derived in [Reference Klyve7, Section 5.5.2], namely

where

The following lemma summarises these arrangements.
Lemma 2.2. For any z, we have

2.3 Bounding
$R(x,z)$
Next, we need an upper bound on
$R(x,z)$
for all x and z. We will start by proving an inequality that will allow us to bound one of the terms of
$R(x,z)$
. This inequality holds for any fixed prime p, but becomes less useful as the size of p increases relative to the size of z. We have excluded some slight optimisations on the order of
$z^{1/2}$
for the sake of readability, and the range of permissible values of z can be lowered at a similar cost. For our case, we will be setting
$p=2$
.
Proposition 2.3. Let p be a prime and
$z \geq 2\,768\,896$
. Then

Proof. To start, note that we can write

where we have taken

Also, for
$p'$
any prime number,

Now we can bound the difference

We now apply explicit bounds on the square-free summation function provided in [Reference Cohen, Dress, Daboussi, Deshouillers and Liardet2], in conjunction with partial summation, to note that

Applying this substitution, and simplifying terms, we conclude that

Combining this result with the first inequality proves the lemma.
In a similar manner to
$V(z)$
, the sum
$\sum _{ {d \leq z,\, \mathrm {gcd}(2,d)=1}}{\mu ^2(d)}$
becomes infeasible to compute for large values of z. We employ a similar technique of approximating
$\sum _{{d \leq z, \,\mathrm {gcd}(2,d)=1}}{\mu ^2(d)}$
for z larger than a specific cut-off value
$L_3$
(using Proposition 2.3), and calculating it exactly for the remaining values. We take
$L_3=10^7$
for our calculations.
Lemma 2.4. For any z,

Theorem 2.5. Assuming GRH, for
$x \geq 4\cdot 10^{18}$
and
$z<x^{{1}/{4}}$
,

where

Proof. We will use [Reference Johnston and Starichkova6, Lemma 5.1] to bound under GRH, noting that for
$z<x^{{1}/{4}}$
,
$[d_1,d_2]<d_1d_2 < z^2 < \sqrt {x}$
. Thus, for
$x \geq 4\cdot 10^{18}$
and
$z<x^{{1}/{4}}$
,

by applying Lemma 2.4 on the second last line.
3 Upper bound on B
From [Reference Platt, Trudgian, Bailey, Borwein, Brent, Burachik, Osborn, Sims and Zhu11, Lemma 6],

Now, using our bound on
$\pi _2(x)$
, we can apply partial summation to calculate
$B(m_1,\infty )$
. Let
$z_i$
be fixed for each interval
$[m_i,m_{i+1}]$
(the values of each
$z_i$
and the intervals
$[m_i,m_{i+1}]$
will be determined later).
Lemma 3.1. Assuming GRH, for
$m_1 \geq 4\cdot 10^{18}$
and
$z_i<m_i^{{1}/{4}}$
,

where

Proof. We have

The value of
${\pi _2(m_k)}/{m_k}$
will cancel in a further calculation, and the value of
${\pi _2(m_1)}/{m_1}$
can be calculated exactly using the computations performed by Oliveira e Silva [Reference Oliveira e Silva10]. For the remaining term, we proceed by

We now apply some simplifications to these integrals to allow us to compute them analytically. Firstly, note that
$V(z_i)$
and
$r(z_i)$
are fixed for each interval
$[m_i,m_{i+1}]$
. Also, note that
$c_{\pi }(t)$
is monotonically decreasing and so
$c_{\pi }(t) \leq c_{\pi }(m_i)$
for
$x \in [m_i,m_{i+1}]$
. Consequently,

In computing the integral we note that

To avoid computing li
$(x)$
directly, we use Schoenfeld’s bound on
$|\pi (x)-\text {li}(x)|$
assuming the Riemann hypothesis [Reference Schoenfeld13, (6.18)], and Dusart’s bounds on
$\pi (x)$
[Reference Dusart4, Theorem 5.1 and Corollary 5.2], to find (for
$x \geq 4 \cdot 10^9$
) that

And so

and finally,

Combining the above equations gives the desired result.
Lemma 3.2. We have

Proof. We use [Reference Platt, Trudgian, Bailey, Borwein, Brent, Burachik, Osborn, Sims and Zhu11, Lemma 3] to bound the tail end of B, so that

Combining the above two lemmas with [Reference Platt, Trudgian, Bailey, Borwein, Brent, Burachik, Osborn, Sims and Zhu11, Lemma 6] gives the following result.
Theorem 3.3. We have

4 Calculating B
The final step is to determine the optimal parameters for the theorem. This involves selecting appropriate intervals
$[m_i,m_{i+1}]$
and choosing corresponding values of
$z_i$
for each interval. Generally, increasing the number of intervals reduces the overall error, though with diminishing returns as the interval size decreases. Based on this principle, we set
$m_i \in \{4 \cdot 10^{18}\} \cup \{10^i: i = 19, 19.2, \ldots , 1999.8, 2000\}$
. To determine
$z_i$
, we employ the Optim package in Julia [Reference Mogensen and Riseth8] to optimise
$z_i$
within a specified domain. Since the optimal value of
$z_i$
increases with i, we can restrict the search domain accordingly. Finally, all of the computations for B were performed using the IntervalArithmetic package in Julia [Reference Sanders and Benet12], ensuring rigorous explicit bounds.
A subset of the optimised parameter ranges is presented in Table 1. The full set of intermediate calculations, along with the optimised values of
$z_i$
for each interval, is available in the linked GitHub repository (https://github.com/LachlanJDunn/B_Under_GRH). This repository also includes the functions used to compute B and perform the parameter sweep. Additionally, it provides a method for estimating bounds on
$B(a,b)$
for
$4\cdot 10^{18} \leq m_1 \leq a < b \leq m_k$
, by computing
$B(m_i,m_j)$
for the smallest interval that fully contains
$[a,b]$
.
Table 1
$B(m_i,m_{i+1})$
for chosen intervals (rounded to 4 significant figures).

5 Potential improvements
We conclude by discussing several potential improvements to the presented method of bounding B.
-
• As discussed earlier, splicing together different bounds for B over disjoint intervals could provide stronger estimates than restricting to only one method. The intermediate sums computed in this paper have been made available to facilitate this.
-
• Computing
$B(x_0)$ for a larger
$x_0$ would reduce approximation errors, leading to a more precise bound.
-
• Refining the choices of parameters
$\{m_i\}$ and
$\{z_i\}$ could potentially yield a more accurate result.
Acknowledgements
This work was completed during and funded by the School of Mathematics and Physics Summer Research program at the University of Queensland. I would like to thank Adrian Dudek for supervising me throughout the program and for all his help during and after the program ended. I would also like to thank Daniel Johnston and Dave Platt for their very helpful discussions and the referee for helpful comments.