Hostname: page-component-5b777bbd6c-cp4x8 Total loading time: 0 Render date: 2025-06-18T23:52:26.198Z Has data issue: false hasContentIssue false

POSITIVE DENSITY FOR CONSECUTIVE RUNS OF SUMS OF TWO SQUARES

Published online by Cambridge University Press:  21 May 2025

Noam Kimmel*
Affiliation:
Raymond and Beverly Sackler School of Mathematical Sciences, Tel Aviv University, Tel Aviv 69978, Israel
Vivian Kuperberg
Affiliation:
Departement Mathematik, ETH Zürich, Rämistrasse 101, 8092 Zürich, Switzerland (vivian.kuperberg@math.ethz.ch)
Rights & Permissions [Opens in a new window]

Abstract

We study the distribution of consecutive sums of two squares in arithmetic progressions. We show that for any odd squarefree modulus q, any two reduced congruence classes $a_1$ and $a_2$ mod q, and any $r_1,r_2 \ge 1$, a positive density of sums of two squares begin a chain of $r_1$ consecutive sums of two squares, all of which are $a_1$ mod q, followed immediately by a chain of $r_2$ consecutive sums of two squares, all of which are $a_2$ mod q. This is an analog of the result of Maynard for the sequence of primes, showing that for any reduced congruence class a mod q and for any $r \ge 1$, a positive density of primes begin a sequence of r consecutive primes, all of which are a mod q.

Type
Research Article
Creative Commons
Creative Common License - CCCreative Common License - BY
This is an Open Access article, distributed under the terms of the Creative Commons Attribution licence (https://creativecommons.org/licenses/by/4.0), which permits unrestricted re-use, distribution and reproduction, provided the original article is properly cited.
Copyright
© The Author(s), 2025. Published by Cambridge University Press

1 Introduction

The sequence of primes is known, by the prime number theorem in arithmetic progressions, to be equidistributed among reduced congruence classes to any modulus q. To be precise, for any modulus q and for any reduced congruence class $a \bmod q$ , let $\pi (x;q,a)$ denote the number of primes $p \le x$ with $p \equiv a \bmod q$ and let $\pi (x)$ denote the number of primes $p\le x$ . Then

$$\begin{align*}\pi(x;q,a) = \frac{\pi(x)}{\phi(q)}(1 + o(1)).\end{align*}$$

Much less is known about analogous questions for strings of consecutive primes. Let $p_n$ denote the sequence of primes in increasing order. For any $M \ge 1$ , for a fixed modulus q and any M-tuple $\mathbf a = [a_1, \dots , a_M]$ of reduced residue classes mod q, let $\pi (x;q,\mathbf a)$ denote the number of strings of consecutive primes matching the residue classes of $\mathbf a$ . That is, define

$$ \begin{align*} \pi(x;q,\mathbf a) := \#\{p_n \le x: p_{n+i-1} \equiv a_i \quad \pmod q \qquad \forall 1 \le i \le M\}. \end{align*} $$

Any randomness-based model of the primes would suggest that M-tuples of consecutive primes equidistribute among the possibilities for $\mathbf a$ , as is the case when $M = 1$ . That is, one would expect that $\pi (x;q,\mathbf a) \sim \frac {\pi (x)}{\phi (q)^M}$ as $x \to \infty $ . Lemke Oliver and Soundararajan [Reference Lemke Oliver and Soundararajan12] provide a heuristic argument based on the Hardy–Littlewood k-tuples conjectures for estimating $\pi (x;q,\mathbf a)$ which agrees with this expectation (although it also predicts large second-order terms creating biases among the patterns).

However, little is known about $\pi (x;q,\mathbf a)$ when $M \ge 2$ . In most cases, it is not even known that $\pi (x;q,\mathbf a)$ tends to infinity as $x \to \infty $ (i.e., it is not known that $\mathbf a$ occurs infinitely often as a consecutive pattern in the sequence of primes mod q). If $\phi (q) = 2$ and $a_1 \ne a_2 \bmod q$ are distinct reduced congruence classes, then $\pi (x;q,[a_1,a_2])$ and $\pi (x;q,[a_2,a_1])$ must each tend to infinity as an immediate consequence of Dirichlet’s theorem for primes in arithmetic progressions; Knapowski and Turán [Reference Knapowski and Turán11] observed that if $\phi (q) = 2$ , all four patterns of length $2$ occur infinitely often.

As for arbitrary q, Shiu [Reference Shiu19] used the Maier matrix method to prove that for any constant tuple $\mathbf a$ of any length, $\pi (x;q,\mathbf a)$ tends to infinity as $x \to \infty $ . That is, for any fixed reduced residue class a mod q, there are infinitely many arbitrarily long strings of consecutive primes, all of which are congruent to a mod q. This result was rederived by Banks, Freiberg and Turnage-Butterbaugh [Reference Banks, Freiberg and Turnage-Butterbaugh2] using new developments in sieve theory. Maynard [Reference Maynard14] showed further that a positive density of primes begin strings of M consecutive primes, all of which are congruent to a mod q – that is, that $\pi (x;q,\mathbf a) \gg \pi (x)$ whenever $\mathbf a$ is a constant pattern.

It is not currently known that $\pi (x;q,\mathbf a)$ tends to infinity for any other case, leading to the question of what more can be proven for other arithmetic sequences. In previous work [Reference Kimmel and Kuperberg10], the authors considered the sequence of integer sums of two squares. Let $\mathbf E$ denote the set of sums of two squares and let $E_n$ denote the increasing sequence of sums of two squares, so that

$$\begin{align*}\mathbf E = \{a^2 + b^2 : a,b \in {\mathbb Z}\} = \{E_n:n \in {\mathbb N}\}.\end{align*}$$

Let $N(x)$ denote the number of sums of two squares less than x. A number n is in $\mathbf E$ if and only if every prime congruent to $3$ mod $4$ divides n to an even power; that is, if n factors as $n = \prod _p p^{e_p}$ , then $e_p$ is even whenever $p \equiv 3 \bmod 4$ . For a modulus $q = \prod _p p^{e_p}$ and a congruence class a mod q, write $(a,q) = \prod _p p^{f_p}$ , where $f_p \le e_p$ for all p. There are infinitely many $n \in \mathbf E$ congruent to a mod q if and only if the following two conditions hold:

  • for any prime $p \equiv 3 \bmod 4$ , $f_p$ is either even or $f_p = e_p$ , and

  • if $e_2 - f_2 \ge 2$ , then $\frac {a}{2^{f_2}} \not \equiv 3 \bmod 4$ .

We will call a congruence class a mod q $\mathbf E$ -admissible if it satisfies these conditions (i.e., if there exists a solution to $x^2 + y^2 \equiv a \bmod q$ ). For a modulus q, an integer $M \ge 1$ , and an M-tuple $\mathbf a = [a_1, \dots , a_M]$ of $\mathbf E$ -admissible residue classes mod q, let

$$ \begin{align*} N(x;q,\mathbf a) := \#\{E_n \le x : E_{n+i-1} \equiv a_i \quad \pmod q\qquad \forall 1 \le i \le M\}. \end{align*} $$

Just as in the prime case, one expects $N(x;q,\mathbf a)$ to tend to infinity for any tuple of $\mathbf E$ -admissible residue classes, and in fact, one expects $N(x;q,\mathbf a) \gg N(x)$ . In other words, one expects $N(x;q,\mathbf a)$ to represent a positive proportion of sums of two squares. When the modulus $q \equiv 1 \bmod 4$ is a prime, David, Devin, Nam and Schlitt [Reference David, Devin, Nam and Schlitt3] develop heuristics for second-order terms in the asymptotics of $N(x;q,\mathbf a)$ analogously to [Reference Lemke Oliver and Soundararajan12]. Their heuristics are based on the analog of the Hardy–Littlewood k-tuples conjecture in the setting of sums of two squares, which was developed in [Reference Freiberg, Kurlberg and Rosenzweig4]. For $\mathbf a$ of length 1, these second-order terms are reminiscent of Chebyshev’s bias, and were considered by Gorodetsky in [Reference Gorodetsky7].

The authors [Reference Kimmel and Kuperberg10] proved that for any modulus q, for any $3$ -tuple of $\mathbf E$ -admissible residue classes $[a_1,a_2,a_3]$ ,

$$ \begin{align*} \lim_{x \to \infty} N(x;q,[a_1,a_2,a_3]) \to \infty. \end{align*} $$

They also showed that for any odd, squarefree modulus q, for any residues $a_1$ and $a_2$ with $(a_i,q) = 1$ , for any tuple of the form $[a_1,\dots ,a_1,a_2,\dots ,a_2]$ (i.e., the concatenation of two constant tuples with values $a_1$ and $a_2$ ),

(1) $$ \begin{align} \lim_{x\to\infty} N(x;q,[a_1, \dots, a_1, a_2, \dots, a_2]) \to \infty. \end{align} $$

Note that this result does not extend to all $\mathbf E$ -admissible residue classes $a_1$ and $a_2$ .

In this paper, we strengthen (1) by proving the following theorem.

Theorem 1. Let $q \ge 1$ be a squarefree odd modulus and let $\tilde {a_1}$ and $\tilde {a_2}$ be reduced residue classes modulo q. Let $M \ge 1$ , and let $\mathbf a = [a_1, \dots , a_M]$ be a tuple of residue classes such that for some $1 \le M_1 \le M$ , $a_i = \tilde {a_1}$ whenever $i \le M_1$ and $a_i = \tilde {a_2}$ whenever $i> M_1$ . Then $N(x;q,\mathbf a) \gg N(x)$ .

That is, any concatenation of two constant tuples appears with positive density among consecutive increasing sums of two squares modulo q.

Remark. Again, this result does not extend to all $\mathbf E$ -admissible residue classes; $\tilde {a_1}$ and $\tilde {a_2}$ must be relatively prime to q. For squarefree odd q, in fact, all residue classes modulo q are $\mathbf E$ -admissible. For fixed squarefree odd q, and for $\tilde {a_1}, \tilde {a_2}$ modulo q such that if $p|(\tilde {a_i},q)$ , then $p \equiv 1 \bmod 4$ , we expect our proof to apply with only minor adjustments in the computations of the technical results. We also expect that Theorem 1 extends with essentially no new ideas to the case where q is not squarefree, if substantially more care is taken on the background lemmas on evaluating sums of two squares in Section 3.3. Finally, our proof may apply essentially as written to the case where $(\tilde {a_i},q)$ is divisible by primes that are $3$ mod $4$ . However, these should appear with a smaller (yet still positive) density (for example, there are more sums of two squares that are $1$ mod $3$ than that are $0$ mod $3$ ), and it may be that understanding the case when q is not squarefree is necessary for understanding this case.

The proof of Theorem 1 follows along the same basic idea as Maynard’s result [Reference Maynard14] that constant tuples appear with positive density among consecutive increasing primes. This work in turn expands on the work of Maynard [Reference Maynard13], in which he shows that for any m, for any large enough k, and for any $\mathcal P$ -admissible (that is, admissible in a precise sense with respect to the sequence of prime numbers) k-tuple of linear forms $\{L_1(n), \dots , L_k(n)\}$ , there exist infinitely many n such that at least m of the $L_i(n)$ are simultaneously prime. In [Reference Maynard14], for a tuple $\{L_1(n) = qn+a_1, \dots , L_k(n)=qn+a_k\}$ where each $L_i(n)$ is chosen such that $L_i(n) \equiv a \bmod q$ for all i, Maynard shows that for infinitely many n, at least m of the $L_i(n)$ are simultaneously prime and the numbers in between the outputs of the $L_i(n)$ have small prime factors (and thus are not themselves prime). He then averages over many such tuples of $L_i(n)$ in order to obtain a lower bound of positive density.

In the setting of sums of two squares, stronger sieving results are available than those that are available in the prime case. McGrath [Reference McGrath15] showed that for any m, for large enough k, for any k-tuple $\{h_1, \dots , h_k\}$ which is $\mathcal P$ -admissible, and for any partition of $\{h_1, \dots , h_k\}$ into m sub-tuples or ‘bins’, for infinitely many n, there exists an $h_i$ in each bin such that $n+h_i \in \mathbf E$ . Banks, Freiberg and Maynard [Reference Banks, Freiberg and Maynard1] use a similar, but weaker, result in the case of primes to show that a positive proportion of real numbers are limit points of the sequence of normalized prime gaps, work which was refined in [Reference Pintz17] and [Reference Merikoski16].

In order to prove Theorem 1, we strengthen the sieve result of McGrath [Reference McGrath15] in the same way that Maynard [Reference Maynard14] had expanded his previous work [Reference Maynard13]. Our paper is organized as follows. In Section 2, we will state our sieve theoretic results and use them to prove Theorem 1. In Section 3, we will prove the sieve theoretic results. Our notation and setup is explained in Section 2.1, with an additional explanation of more technical sieve notation in Section 3.1. Finally, in Section 4, we evaluate certain averages of ‘singular series’ constants that appear in the proof of Theorem 1.

2 Statement of sieve results and proof of the main theorem

2.1 GPY sieve setup

Our argument will follow the Goldston–Pintz–Yıldırım method for detecting primes in $\mathcal P$ -admissible k-tuples, building off of work of Maynard [Reference Maynard14], which uses a rather sophisticated version of this method, and of McGrath [Reference McGrath15], which develops a second-moment version of this method for sums of two squares.

An $\mathcal P$ -admissible k-tuple of linear forms $(\ell _1(n), \dots , \ell _k(n))$ is one such that, for every prime p, there exists some $a \bmod p$ with $\ell _i(a) \ne 0 \bmod p$ for all $1\le i \le k$ . Using the GPY method, Maynard [Reference Maynard13] showed that for all integers $m \ge 2$ , there exists large enough k such that for any $\mathcal P$ -admissible k-tuple of linear forms $(\ell _1(n), \dots , \ell _k(n))$ , there are many integers $n \ge 1$ for which at least m of the values $\ell _1(n), \dots , \ell _k(n)$ are simultaneously prime.

This statement follows from the construction of positive weights $w(n)$ such that for all x,

(2) $$ \begin{align} \sum_{x \le n < 2x} \left(\sum_{i=1}^k \mathbf 1_{\mathcal P}(\ell_i(n)) - m + 1\right) w(n)> 0, \end{align} $$

where $\mathbf 1_{\mathcal P}$ denotes the indicator function of the set $\mathcal P$ of prime numbers. The inequality (2) implies that there exists a strictly positive summand, so that for some n with $x \le n < 2x$ ,

$$ \begin{align*} \sum_{i=1}^k \mathbf 1_{\mathcal P}(\ell_i(n))> m - 1, \end{align*} $$

and thus, there are at least m primes among the values of $\ell _i(n)$ .

We will require a version of this technique that is adapted in three different ways: first, we will detect sums of two squares instead of primes; second, we will need a ‘second moment’ adaptation to detect slightly more delicate patterns among the sequence of sums of two squares; and third, we will exclude certain values of n so that we will be able to average over many different k-tuples.

We begin by defining a certain weighted indicator function of sums of two squares. For any function f (say, the indicator functions $\mathbf 1_{\mathcal P}$ or $\mathbf 1_{\mathbf E}$ ), in practice, applying the ‘second moment’ adaptation requires an understanding of two-point correlations of the form

$$ \begin{align*} \sum_{x \le n < 2x} f(\ell_i(n))f(\ell_j(n)). \end{align*} $$

Estimates for two-point correlations of the standard indicator function of sums of two squares are not known, so we will instead make use of Hooley’s $\rho $ -function, which was first introduced in [Reference Hooley8] and also used in this context by McGrath [Reference McGrath15].

The $\rho $ function is defined by

(3) $$ \begin{align} \rho(n) = r_2(n)t(n), \end{align} $$

where $r_2(n)$ is the representation function of n, given by

(4) $$ \begin{align} r_2(n) &:= \# \{(x,y) \in \mathbb Z^2 : x^2 + y^2 = n\} \\ &= 4\sum_{\substack{d|n \\ d \text{ odd}}} (-1)^{\tfrac{d-1}{2}}\nonumber \end{align} $$

and

(5) $$ \begin{align} t(n) = t_{x,\theta_1}(n) := \sum_{\substack{a|n \\ a \le v \\ p|a \Rightarrow p \equiv 1 \bmod 4}} \frac{\mu(a)}{g_2(a)}\left(1 - \frac{\log a}{\log v}\right), \quad (v = x^{\theta_1}). \end{align} $$

Here, $\theta _1$ is a fixed small constant with $\theta _1 < 1/18$ ; for example, Hooley takes $\theta _1 = 1/20$ . Moreover, $g_2$ is the multiplicative function defined on primes via

(6) $$ \begin{align} g_2(p) = \begin{cases} 2-\tfrac 1p &\text{ if } p \equiv 1 \quad \pmod 4 \\ \tfrac 1p &\text{ if } p \equiv 3 \quad \pmod 4. \end{cases} \end{align} $$

Using the indicator function $\rho $ , McGrath [Reference McGrath15] uses a second-moment bound to prove the existence of sums of two squares in different ‘bins’ of the same tuple. To state this precisely, fix $M,k \ge 1$ , and let K denote the product $K = Mk$ . Let $q \ge 1$ be a fixed odd integer, and fix a tuple $\mathcal H^{*}$ of size K such that $4|h_i$ , $(h_i,q) = 1$ , and for $\ell _i(n) = qn+h_i$ , the tuple of linear forms $\{\ell _1(n), \dots , \ell _{K}(n)\}$ is $\mathcal P$ -admissible (indeed, McGrath’s result is phrased as requiring the tuple to be $\mathcal P$ -admissible, not $\mathbf E$ -admissible). Suppose further that we have a fixed partition $\mathcal H = B_1 \sqcup \cdots \sqcup B_M$ where $|B_i| = k$ for all i. McGrath showed that there exists a real number $u \ge 1$ and a nonnegative weight function $w(n)$ such that for all sufficiently large x,

(7) $$ \begin{align} \sum_{x < n \le 2x} \left[ u^2 - \sum_{i=1}^M \left(\sum_{\ell \in B_i}\rho(\ell(n)) - u\right)^2\right] w(n)> 0. \end{align} $$

The positivity of the left-hand side of (7) implies that for all sufficiently large x, there exists some n with $x < n \le 2x$ such that

$$ \begin{align*} \sum_{i = 1}^M \left(\sum_{\ell \in B_i} \rho(\ell(n)) - u\right)^2 < u^2. \end{align*} $$

If for any bin $B_i$ , there is no $\ell \in B_i$ with $\ell (n) \in \mathbf E$ , then $\sum _{\ell \in B_i} \rho (\ell (n)) = 0$ , and thus,

$$ \begin{align*} u^2 \le \left(\sum_{\ell \in B_i} \rho(\ell(n)) - u\right)^2 \le \sum_{i = 1}^M \left(\sum_{\ell \in B_i} \rho(\ell(n)) - u\right)^2 < u^2, \end{align*} $$

a contradiction. Thus, in particular, the inequality (7) implies that for all sufficiently large x, there exists an n with $x < n \le 2x$ and such that for every bin $B_i$ , there exists an $\ell \in B_i$ with $\ell (n) = qn+h \in \mathbf E$ .

Our aim is to combine this second-moment version of the GPY sieve setup with the goal of excluding certain values of n for each tuple $\mathcal H^{*}$ in order to be able to average over many different tuples. In particular, we will choose weights $w(n)$ such that for any n making a positive contribution to the left-hand side of (7), $\ell _i(n)$ does not have any ‘small’ prime factors $p \equiv 3 \bmod 4$ for any of the $\ell _i$ , and for any $b \le \eta \sqrt {\log x}$ which is not in $\mathcal H$ (i.e., $b\neq h_i$ ), the integer $qn + b$ is divisible exactly once by some ‘small’ prime $p \equiv 3 \bmod 4$ . These may seem like artificial constraints to place on the values n, but in fact, n that do not satisfy these constraints are exceptionally rare; intuitively, although it cannot be proven explicitly, the weights $w(n)$ place emphasis on those n where all $\ell _i(n) \in \mathbf E$ (or close to it), and values $qn+b$ that are outside of the tuple are unlikely to be sums of two squares. In [Reference Maynard14], Maynard takes advantage of a similar device to average over different subsets $\mathcal H^{*}$ , which allows him to prove a lower bound of positive density on the tuples he is counting.

Our precise setup is as follows. As in the setup of Theorem 1, we let q be a fixed odd squarefree modulus, and we also fix the parameters M and two congruence classes $\tilde {a_1}$ and $\tilde {a_2}$ modulo q, as well as $M_1$ with $1 \le M_1 \le M$ . We will consider tuples of length K, where $K = kM$ , split into bins of size k. We define integers $a_1, \dots , a_K$ as follows. For i with $1 \le i \le M_1k$ , we let $a_i$ be the smallest positive integer with $a_i \equiv \tilde {a_1} \bmod q$ and $a_i \equiv 1 \bmod 4$ , whereas for i with $M_1k+1 \le i \le K$ , we let $a_i$ be the second-smallest positive integer with $a_i \equiv \tilde {a_2} \bmod q$ and $a_i \equiv 1 \bmod 4$ (that is, $a_i-4q$ is the smallest such positive integer). The values of $a_i$ for $M_1k+1 \le i \le K$ are shifted by q to ensure that $a_{i_1} < a_{i_2}$ whenever $1 \le i_1 \le M_1k < i_2 \le K$ . Note that there are only two distinct values for the $a_i$ , but for ease of notation, we define K values $a_i$ , even though these values are repetitive.

Then, for any tuple of integers $\mathbf b = (b_1, \dots , b_K)$ with $b_i \equiv 3 \bmod 4$ and $3\le b_i \le \frac {\eta }{q} \sqrt {\log x}$ for all i, we will define the K-tuple $\mathcal L = \mathcal L(\mathbf b) = \{\ell _i(n)\}_{i=1}^K$ of linear forms given by

(8) $$ \begin{align} \ell_i(n) := qn + a_i + qb_i. \end{align} $$

Here, $\eta $ is a positive constant to be set later. Note that the constraints on $a_i$ and $b_i$ modulo $4$ imply that whenever $n \equiv 1 \bmod 4$ , we also have $\ell _i(n) \equiv 1 \bmod 4$ .

We will ultimately average over many different choices of $\mathbf b$ . Our average will be taken over $\mathbf b$ lying in a slightly restricted set of tuples $\mathcal B$ , where we define

(9) $$ \begin{align} \mathcal B := \left\{\mathbf b = (b_1, \dots, b_K) \middle\vert b_i \equiv 3 \bmod 4, \begin{array}{l }b_1 = 3\\ 3\le b_i \le \frac{\eta}{2q}\sqrt{\log x} \: \;\forall \: 2 \le i \le M_1k \\ \frac{\eta}{2q} \sqrt{\log x} < b_i \le \frac{\eta}{q} \sqrt{\log x} \: \;\forall \: M_1k < i \le K \end{array} \right\}. \end{align} $$

The key consequence of this definition (along with the definition of the $a_i$ ’s) is that for any n, $\ell _{i_1}(n) < \ell _{i_2}(n)$ whenever $1 \le i_1 \le M_1k$ and $M_1k+1 \le i_2 \le K$ .

As described above, we will write $\mathcal L = B_1 \sqcup \cdots \sqcup B_M$ , where

(10) $$ \begin{align} B_i := \{\ell_{(i-1)k+1}(n), \dots, \ell_{ik}(n)\}. \end{align} $$

The $B_i$ , which we refer to as bins, partition the tuple $\mathcal L$ into M bins, each of size k.

For certain real numbers $\xi ,\eta> 0$ (to be fixed later), a certain real number u, and a nonnegative weight function $w_n(\mathcal L)$ , we consider a sum of the shape

(11) $$ \begin{align} \sum_{x < n \le 2x} \Bigg[ u^2 - \sum_{i=1}^M \left(\sum_{\ell \in B_i} \rho(\ell(n)) - u\right)^2 - \sum_{j=1}^{K} \sum_{\substack{p < x^\xi \\ p \equiv 3 \bmod 4 \\ p|\ell_j(n)}} u^2 - \sum_{\substack{b \le \eta \sqrt{\log x} \\ \ell^{(b)} \not\in \mathcal L}} \mathbf 1_{S(\xi)}(\ell^{(b)}(n))u^2\Bigg]w_n(\mathcal L),\end{align} $$

where $S(\xi )$ is the set of integers such that for all primes $p < x^\xi $ which satisfy $p \equiv 3 \bmod 4$ , either $p\nmid n$ or $p^2|n$ . We write $\ell ^{(b)}(n) := qn + b$ , so that the final sum in (11) is a sum over $b \le \eta \sqrt {\log x}$ such that $\ell ^{(b)} \not \in \mathcal L$ . A choice of weights $w_n(\mathcal L)$ such that (11) is positive implies that for some n with $x<n \le 2x$ ,

$$ \begin{align*} u^2 - \sum_{i=1}^M \left(\sum_{\ell \in B_i} \rho(\ell(n)) - u\right)^2 - \sum_{j=1}^{K} \sum_{\substack{p < x^\xi \\ p \equiv 3 \bmod 4 \\ p |\ell_j(n)}} u^2 - \sum_{\substack{b \le \eta \sqrt{\log x} \\ \ell^{(b)} \not\in \mathcal L}} \mathbf 1_{S(\xi)}(\ell^{(b)}(n))u^2> 0, \end{align*} $$

which in turn implies that

  • for each i, there exists a linear form $\ell \in B_i$ with $\rho (\ell (n)) \ne 0$ , and thus, $\ell (n) \in \mathbf E$ ;

  • for each j, with $1 \le j \le K$ , $\ell _j(n)$ is not divisible by any prime $p < x^\xi $ with $p \equiv 3 \bmod 4$ ; and

  • for each $b \le \eta \sqrt {\log x}$ with $\ell ^{(b)}$ not in $\mathcal L$ , we have $\ell ^{(b)}(n) \not \in S(\xi )$ , so there exists some prime $p < x^\xi $ with $p \equiv 3 \bmod 4$ such that $p\|\ell ^{(b)}(n)$ .

In order to take advantage of this positivity argument, we will need to evaluate the sums over n appearing in (11). These evaluations are accomplished in Theorem 2, which we state in the next section before completing the proof of Theorem 1.

2.2 Conventions and notation

Before stating our main sieve theorem and presenting the proof of Theorem 1, we first fix some notation and conventions that we will use throughout the paper. An index for key quantities appears after the references.

All asymptotic notation, such as $O(\cdot ),\, o(\cdot ), \ll ,$ and $\gg ,$ should be interpreted as referring to the limit $x \to \infty $ . We will use Vinogradov $f \ll g$ to mean $f = O(g)$ ; that is, $|f| \le Cg$ for some absolute constant C. Any constants are absolute unless otherwise noted. For all sums or products over a variable p (or $p'$ ), the variable p will be assumed to lie in the prime numbers; all other sums and products will be assumed to be taken over variables lying in the natural numbers $\mathbb N_{\ge 1}$ unless otherwise specified.

Recall that the squarefree odd modulus q is fixed throughout. We denote $q = q_1q_3$ , where $q_1$ is a product of primes that are $1$ mod $4$ and $q_3$ is a product of primes that are $3$ mod $4$ .

Let $\theta _2>0$ be a fixed positive real number such that $0 < \theta _1+\theta _2 < 1/18$ , and let $R = x^{\theta _2/2}$ . Letting $D_0 = \eta \sqrt {\log x}$ for a constant $\eta> 0$ to be fixed later, we define

(12) $$ \begin{align} W = \prod_{\substack{p \le D_0 \\ p \equiv 3 \bmod 4 \\ p \nmid q}} p. \end{align} $$

Note that $q_3W$ is the product of all primes $p\le D_0$ which are $3$ mod $4$ . This definition of W differs from that of McGrath [Reference McGrath15] because, while the value of $D_0$ is much larger than that used by McGrath, it is not divisible by any primes $p \equiv 1 \bmod 4$ .

We denote by A the Landau–Ramanujan constant, given by

(13) $$ \begin{align} A = \frac 1{\sqrt 2} \prod_{p \equiv 3 \bmod 4} \left(1-\frac 1{p^2}\right)^{-\tfrac 12} = \frac{\pi}{4}\prod_{p \equiv 1 \bmod 4} \left(1-\frac 1{p^2}\right)^{1/2}. \end{align} $$

We also make use of a normalization constant B, defined as

(14) $$ \begin{align} B = \frac{A}{\Gamma(1/2)\sqrt{L(1,\chi_4)}} \cdot \frac{\phi(q_3W)(\log R)^{1/2}}{q_3W} = \frac{2A}{\pi}\frac{\phi(q_3W)(\log R)^{1/2}}{q_3W}. \end{align} $$

Here, $\chi _4$ denotes the nontrivial Dirichlet character modulo $4$ . Finally, we will denote by V the constant given by

(15) $$ \begin{align} V = \prod_{p \equiv 1 \bmod 4} \left(1 + \frac 1{(2p-1)^2}\right) \approx 1.016. \end{align} $$

For K-tuples in $\mathbb N^K$ , we will use the notation that a boldface letter such as $\mathbf d$ represents a tuple $\mathbf d = (d_1, \dots , d_K)$ , whereas a non-boldface d represents the product of the entries $\prod _{i=1}^K d_i$ . Given tuples $\mathbf d$ and $\mathbf e$ , we will let $[\mathbf d, \mathbf e]$ denote the product of the least common multiples $\prod _{i=1}^K [d_i,e_i]$ , let $(\mathbf d, \mathbf e)$ denote the product of the greatest common divisors $\prod _{i=1}^K (d_i,e_i)$ , and let $\mathbf d|\mathbf e$ denote the K conditions that $d_i|e_i$ for $1 \le i \le K$ .

2.3 Statement of the main sieve theorem

We are now ready to state our main sieving theorem, which we will use in the next section to deduce Theorem 1.

Theorem 2. Fix $\mathbf b \in \mathcal B$ and let $\mathcal L(\mathbf b)$ be the fixed K-tuple of linear forms $\{\ell _i(n)\}_{i = 1}^{K}$ given by (8). Let $\nu _0$ be a fixed residue class modulo W such that for all $\ell \in \mathcal L$ , $(\ell (\nu _0),W) = 1$ . Then there exists a choice of nonnegative weights $w_n(\mathcal L) \ge 0$ , as well as a constant $L_K(F)$ , such that

(16) $$ \begin{align} w_n(\mathcal L) \ll \left(\frac{\log R}{\log D_0}\right)^{K} \prod_{i=1}^K \prod_{\substack{p|\ell_i(n) \\ p \equiv 3 \bmod 4}} 4 \end{align} $$

and the following estimates hold:

  1. a) Let $S_1(\nu _0)$ be the sum defined by

    $$ \begin{align*} S_1(\nu_0) := \sum_{\substack{x<n\le 2x \\ n \equiv 1 \bmod 4 \\ n \equiv \nu_0 \bmod W}} w_n(\mathcal L). \end{align*} $$

    Then

    (17) $$ \begin{align} S_1(\nu_0) = (1+o(1)) \frac{B^Kx}{4W}L_K(F). \end{align} $$
  2. b) Let $S_2^{(m)}(\nu _0)$ be the sum defined by

    $$ \begin{align*} S_2^{(m)}(\nu_0) := \sum_{\substack{x<n\le 2x \\ n \equiv 1 \bmod 4 \\ n \equiv \nu_0 \bmod W}} \rho(\ell_m(n)) w_n(\mathcal L). \end{align*} $$

    Then

    (18) $$ \begin{align} S_2^{(m)}(\nu_0) = (1+o(1)) \frac{4\pi \sqrt{\tfrac{\log R}{\log v}}B^Kx}{(\pi+2)\sqrt{K} W}L_K(F). \end{align} $$
  3. c) Let $S_3^{(m_1,m_2)}(\nu _0)$ be the sum defined by

    $$ \begin{align*} S_3^{(m_1,m_2)}(\nu_0) := \sum_{\substack{x< n \le 2x \\ n \equiv 1 \bmod 4 \\ n \equiv \nu_0 \bmod W}} \rho(\ell_{m_1}(n))\rho(\ell_{m_2}(n))w_n(\mathcal L). \end{align*} $$

    Then

    (19) $$ \begin{align} S_3^{(m_1,m_2)}(\nu_0) \le (1 + o(1)) \frac{64\pi^2\tfrac{\log R}{\log v} B^Kx}{(\pi + 2)^2 K W}V L_K(F), \end{align} $$
    where V is the constant defined in (15).
  4. d) Let $S_4^{(m)}(\nu _0)$ be the sum defined by

    $$ \begin{align*} S_4^{(m)}(\nu_0) := \sum_{\substack{x < n \le 2x \\ n \equiv 1 \bmod 4 \\ n\equiv \nu_0 \bmod W}} \rho(\ell_m(n))^2w_n(\mathcal L). \end{align*} $$

    Then

    (20) $$ \begin{align} S_4^{(m)}(\nu_0) = (1+o(1))\frac{8\pi \sqrt{\frac{\log R}{\log v}} \left(\frac{\log x}{\log v} + 1 \right)B^{K}x} {(\pi + 2)\sqrt{K}W} \prod_{\substack{p \equiv 1 \bmod 4 \\ p\nmid q_1}}\left( 1 + \frac{1}{(2p-1)^2}\right) L_K(F). \end{align} $$
  5. e) Assume that $\xi> 0$ satisfies $\xi < \frac 1K$ , and let $S_5^{(m)}(\nu _0)$ be the sum defined by

    $$ \begin{align*} S_5^{(m)}(\nu_0) := \sum_{\substack{x < n \le 2x\\n \equiv 1 \bmod 4\\ n \equiv \nu_0 \bmod W}}\sum_{\substack{p < x^\xi \\ p \equiv 3 \bmod 4 \\ p|\ell_m(n)}} w_n(\mathcal L). \end{align*} $$

    Then $S_5^{(m)}(\nu _0)$ satisfies

    (21) $$ \begin{align} S_5^{(m)}(\nu_0) \ll \frac{K^2\xi^2}{\theta_2^2} \frac{B^Kx}{W} L_K(F). \end{align} $$
  6. f) Let $\nu _1$ be a congruence class modulo $q_3^2W^2$ such that $(\ell (\nu _1),q_3^2W^2)$ is a square for all $\ell \in \mathcal L$ . Fix $3 < b \le \eta \sqrt {\log x}$ and a constant $\xi $ with $0 < \xi < 1/4$ . Let $S_6^{(b)}(\nu _1)$ be defined by

    $$ \begin{align*} S_6^{(b)}(\nu_1) := \sum_{\substack{x < n \le 2x \\ n \equiv 1 \bmod 4 \\ n \equiv \nu_1 \bmod q_3^2W^2}} \mathbf 1_{S(\xi)}(\ell^{(b)}(n)) w_n(\mathcal L). \end{align*} $$

    Then

    (22) $$ \begin{align} S_6^{(b)}(\nu_1) \ll_K \frac{x}{4q_3^2W^2}\xi^{-1/2} \left(\frac{\theta_2}{2}\right)^{-1/2} \left(\frac{\log R}{\log D_0}\right)^{\frac{K-1}{2}} L_K(F). \end{align} $$

This theorem is key in all of our computations and will be proven in Section 3. In the remainder of this section, we derive our main result as a consequence of Theorem 2.

2.4 Proof of Theorem 1

The goal of this subsection is to prove Theorem 1 as a consequence of Theorem 2 and the evaluations of the linear functionals therein.

We will consider an average of $\mathbf E$ -admissible tuples $\mathcal L = \mathcal L(\mathbf b) = \{\ell _i(n)\}_{i=1}^K$ , given by (8), over the set $\mathcal B$ (defined in (9)) of K-tuples $\mathbf b$ . We consider the sum

(23) $$ \begin{align} S& =\sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L = \mathcal L(\mathbf b) \mathbf E\text{-admissible}}}\sum_{\substack{\nu_1 \bmod q_3^2W^2 \\(\ell(\nu_1),W) = 1 \forall \ell \in \mathcal L}}\;\sum_{\substack{x < n \le 2x \\ n \equiv \nu_1 \bmod q_3^2W^2}}\Bigg[ u^2 - \sum_{i=1}^M \left(\sum_{\ell \in B_i} \rho(\ell(n)) - u\right)^2\\[4pt]&\quad - \sum_{i=1}^{K} \sum_{\substack{p < x^\xi \\ p \equiv 3 \bmod 4 \\ p|\ell_i(n)}} u^2- \sum_{\substack{b \le \eta \sqrt{\log x} \\ \ell^{(b)} \not\in \mathcal L \\ (\ell^{(b)}(\nu_1), q_3^2W^2) = \square}} \mathbf 1_{S(\xi)}(\ell^{(b)}(n))u^2 \Bigg]w_n(\mathcal L).\notag \end{align} $$

For technical reasons involving the final sum, we will initially sum over congruence classes modulo $q_3^2W^2$ instead of modulo W. However, note that the condition that $(\ell (\nu _1),W) = 1$ is determined only by the congruence class of $\nu _1 \bmod W$ , so this is in some sense really a sum over congruence classes modulo W.

Here, $w_n(\mathcal L)$ are the weights given by Theorem 2 for the $\mathbf E$ -admissible set $\mathcal L = \mathcal L(\mathbf b)$ . For fixed $\mathcal L$ , the term in the square parentheses in (23) is positive only if the following conditions all hold:

  1. (i) for each i with $1 \le i \le M$ , there exists some $\ell \in B_i$ with $\rho (\ell (n)) \ne 0$ , or equivalently with $\ell (n) \in \mathbf E$ ;

  2. (ii) for each $\ell \in \mathcal L$ , $\ell (n)$ has no prime factors p with $p < x^\xi $ and $p \equiv 3 \bmod 4$ ; and

  3. (iii) for all other $\ell ^{(b)} \not \in \mathcal L$ with $b \le \eta \sqrt {\log x}$ , and $(\ell ^{(b)}(n),q_3^2W^2)$ a square, $\ell ^{(b)}(n)$ has a prime factor p with $p < x^\xi $ , $p \equiv 3 \bmod 4$ , and $p\|\ell ^{(b)}(n)$ .

This has two crucial implications. One is that no n can make a positive contribution from two different tuples $\mathcal L$ , since if n makes a positive contribution for any $\mathcal L$ , then the values $\ell (n)$ are uniquely determined as the integers in $[qn, qn+\eta \sqrt {\log x}]$ which are

  1. (i) congruent to $1 \bmod 4$ ,

  2. (ii) congruent to $\tilde {a_1} \bmod q$ if they lie in $[qn+a_1,qn+a_1+(\eta /2)\sqrt {\log x}]$ , or congruent to $\tilde {a_2}\bmod q$ if they lie in $[qn+a_K+(\eta /2)\sqrt {\log x},qn+a_K+\sqrt {\log x}]$ , and

  3. (iii) not divisible to an odd power by any primes $p < x^\xi $ with $p \equiv 3 \bmod 4$ .

The second observation is that if n makes a positive contribution for a tuple $\mathcal L$ , then since for all $\ell ^{(b)} \not \in \mathcal L$ with $b \le \eta \sqrt {\log x}$ , $\ell ^{(b)}(n) = qn+b \not \in \mathbf E$ , we have that the sums of two squares appearing in $\mathcal L$ (of which there is at least one in each bin) must be consecutive sums of two squares.

Also, if n makes a positive contribution, then none of the $\ell _i(n)$ can have any prime factors $p \equiv 3 \bmod 4$ which are less than $x^{\xi }$ , so each $\ell _i(n)$ can have at most $O(1/\xi )$ prime factors $p \equiv 3 \bmod 4$ . In particular, this implies by (16) that

(24) $$ \begin{align} w_n(\mathcal L) \ll\left(\frac{\log R}{\log D_0}\right)^{K} \prod_{i=1}^K \prod_{\substack{p\mid \ell_i(n) \\ p \equiv 3 \bmod 4}} 4 \ll \left(\frac{\log R}{\log D_0}\right)^{K} \mathrm{exp}(O(K/\xi)), \end{align} $$

for any pair n and $\mathcal L$ making a positive contribution to (23).

We now evaluate the sum in (23). To begin with, we can swap the order of summation for the various different terms to get

(25) $$ \begin{align} \begin{aligned} S= &\sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L = \mathcal L(\mathbf b) \text{ adm.}}} \Bigg[ \sum_{\substack{\nu_0 \bmod W \\ (\ell(\nu_0),W) = 1 \forall \ell \in \mathcal L}} \bigg( u^2(1-M) S_1(\nu_0) + 2u \sum_{m = 1}^K S_2^{(m)}(\nu_0) \\ & - \sum_{i = 1}^M \sum_{\substack{\ell_{m_1},\ell_{m_2} \in B_i \\ m_1 \ne m_2}} S_3^{(m_1,m_2)}(\nu_0) - \sum_{m=1}^K S_4^{(m)}(\nu_0) - u^2 \sum_{i=1}^K S_5^{(i)}(\nu_0) \bigg) \\ & - u^2 \sum_{\substack{\nu_1 \bmod q_3^2W^2 \\ (\ell(\nu_1),W) = 1 \forall \ell \in \mathcal L}} \sum_{\substack{b \le \eta \sqrt{\log x} \\ \ell^{(b)} \not\in \mathcal L \\ (\ell^{(b)}(\nu_1), q_3^2W^2) = \square}} S_6^{(b)}(\nu_1)\Bigg], \end{aligned} \end{align} $$

where the sums $S_1(\nu _0), S_2^{(m)}(\nu _0), S_3^{(m_1,m_2)}(\nu _0), S_4^{(m)}(\nu _0), S_5(\nu _0)$ and $S_6^{(b)}(\nu _1)$ are in the notation of Theorem 2.

We now wish to use our estimates from Theorem 2. For the sum $S_6^{(b)}(\nu _1)$ , we will require a more careful analysis that takes the averaging over $\mathbf {b}, \nu _1, b$ into account. Specifically, we require the following lemma, which is proven in Section 4.2.

Lemma 3. With the notation above,

$$ \begin{align*} & \sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L = \mathcal L(\mathbf b) \text{ adm.}}} \sum_{\substack{\nu_1 \bmod q_3^2W^2 \\ (\ell(\nu_1),W) = 1 \forall \ell \in \mathcal L}} \sum_{\substack{b \le \eta \sqrt{\log x} \\ \ell^{(b)} \not\in \mathcal L \\ (\ell^{(b)}(\nu_1), q_3^2W^2) = \square}} S_6^{(b)}(\nu_1) \\ &\quad \ll_K { \xi^{-1/2} \theta_2^{\frac{K}{2} - 1} L_K(F) \left(\frac{q_3}{\phi(q_3)}\right)^{K} \frac{\eta^K}{q_3^2q^{K-1}} \frac{\left(\log x\right)^{K - \frac{1}{2}}} {\left(\log D_0\right)^K} x}, \end{align*} $$

where the implied constant depends only on K.

Applying the estimates (17), (18), (19), (20) and (21) from Theorem 2 to (25), we get

(26) $$ \begin{align} \begin{aligned} S&\ge (1 + o(1)) \frac{B^K x}{W} L_K(F) \sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L = \mathcal L(\mathbf b) \text{ adm.}}} \sum_{\substack{\nu_0 \bmod W \\ (\ell(\nu_0),W) = 1 \\ \forall \ell \in \mathcal L}} \left[\rule{0cm}{1.2cm}\right. u^2(1-M) \frac{1}{4} + 2u \sum_{m = 1}^K \frac{4\pi \sqrt{\tfrac{\log R}{\log v}}}{(\pi + 2)\sqrt{K} } \\[6pt] & - \sum_{i = 1}^M \sum_{\substack{\ell_{m_1},\ell_{m_2} \in B_i \\ m_1 \ne m_2}} \frac{64\pi^2\left(\tfrac{\log R}{\log v}\right) }{(\pi+2)^2K}V - \sum_{m=1}^K \frac{8\pi \sqrt{\frac{\log R}{\log v}} \left(\frac{\log x}{\log v} + 1 \right)} {(\pi+2) \sqrt{K} } \prod_{\substack{p \equiv 1 \bmod 4 \\ p\nmid q_1}}\left( 1 + \frac{1}{(2p-1)^2}\right) \\[6pt] & - u^2 \sum_{i=1}^K O\left( \frac{ K^2\xi^2}{4} L_K(F) \right) \left.\rule{0cm}{1.2cm}\right] - u^2 \sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L = \mathcal L(\mathbf b) \text{ adm.}}} \sum_{\substack{\nu_1 \bmod q_3^2W^2 \\ (\ell(\nu_1),W) = 1 \\ \forall \ell \in \mathcal L}} \sum_{\substack{b \le \eta \sqrt{\log x} \\ \ell^{(b)} \not\in \mathcal L \\ (\ell^{(b)}(\nu_1), q_3^2W^2) = \square}} S_6^{(b)}(\nu_1). \end{aligned} \end{align} $$

We now use Lemma 3 to evaluate the last triple sum, and simplify using the facts that $\log R = \tfrac {\theta _2}{2} \log x$ and $\log v = \theta _1 \log x$ , which gives

$$ \begin{align*} S&\ge (1 + o(1)) \!\left(\sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L = \mathcal L(\mathbf b) \text{ adm.}}} \sum_{\substack{\nu_0 \bmod W \\ (\ell(\nu_0),W) = 1 \forall \ell \in \mathcal L}} 1 \!\right)\! \frac{B^K x}{W}L_K(F) \!\left[\rule{0cm}{1cm}\right. \frac{u^2(1-M) }{4} +\frac{8u\pi\sqrt{K}\sqrt{\theta_2/2\theta_1}}{\pi+2} \\[6pt] &\quad - M \frac{k(k+1)}{2}\frac{64\pi^2(\theta_2/2\theta_1)}{(\pi+2)^2K}V - \frac{8\pi\sqrt{K}\sqrt{\theta_2/2\theta_1} \left(\frac{1}{\theta_1} + 1 \right)} {(\pi + 2)} \prod_{\substack{p \equiv 1 \bmod 4 \\ p\nmid q_1}}\left( 1 + \frac{1}{(2p-1)^2}\right) \\[6pt] &\quad - O\left(u^2 K^3\xi^2 \right) \left.\rule{0cm}{1cm}\right] - O\left(u^2 { \xi^{-1/2} \theta_2^{\frac{K}{2} - 1} L_K(F) \left(\frac{q_3}{\phi(q_3)}\right)^{K} \frac{\eta^K}{q_3^2q^{K-1}} \frac{\left(\log x\right)^{K - \frac{1}{2}}} {\left(\log D_0\right)^K} x}\right). \end{align*} $$

We will make the change of variables

$$ \begin{align*} u = \frac{\pi}{\pi+2}\sqrt{\frac{\theta_2}{2\theta_1}} \tilde{u}, \end{align*} $$

so that the sum above simplifies to

$$ \begin{align*} S\ge & (1 + o(1)) \left(\sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L = \mathcal L(\mathbf b) \text{ adm.}}} \sum_{\substack{\nu_0 \bmod W \\ (\ell(\nu_0),W) = 1 \forall \ell \in \mathcal L}} 1 \right) \frac{B^K x}{W}L_K(F) \left[\rule{0cm}{1.2cm}\right. \left(\frac{\pi}{\pi+2}\right)^2 \frac{\theta_2}{2\theta_1} \\ & \left(\rule{0cm}{1cm}\right. \frac{\tilde{u}^2(1-M)}{4} + 8\sqrt{K}\tilde{u} - 32 V\left(\frac{K}{M} + 1\right) \left.\rule{0cm}{1cm}\right) - O_{\theta_1,\theta_2}\left( \sqrt{K}\right) - O\left( u^2 K^3\xi^2 \right) \left.\rule{0cm}{1.2cm}\right] - \\ & O\left(u^2{ \xi^{-1/2} \theta_2^{\frac{K}{2} - 1} L_K(F) \left(\frac{q_3}{\phi(q_3)}\right)^{K} \frac{\eta^K}{q_3^2q^{K-1}} \frac{\left(\log x\right)^{K - \frac{1}{2}}} {\left(\log D_0\right)^K} x}\right). \end{align*} $$

We then set $\tilde {u} = \frac {16\sqrt {K}}{M-1}$ to maximize the expression above, so that (recalling that $K = Mk$ )

$$ \begin{align*} S\ge &(1 + o(1)) \left( \sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L = \mathcal L(\mathbf b) \text{ adm.}}} \sum_{\substack{\nu_0 \bmod W \\ (\ell(\nu_0),W) = 1 \forall \ell \in \mathcal L}} 1 \right) \frac{B^K x}{W}L_K(F) \\ & \times\left[\rule{0cm}{1.2cm}\right. \left(\frac{\pi}{\pi+2}\right)^2 \left(\frac{\theta_2}{2\theta_1}\right)\cdot 32\left(k\frac{(2-V)M+V}{M-1}-V\right) - O_{\theta_1,\theta_2}\left( \sqrt{K}\right) - O\left(u^2K^3\xi^2 \right) \left.\rule{0cm}{1.2cm}\right] \\ &- O\left(u^2{ \xi^{-1/2} \theta_2^{\frac{K}{2} - 1} L_K(F) \left(\frac{q_3}{\phi(q_3)}\right)^{K} \frac{\eta^K}{q_3^2q^{K-1}} \frac{\left(\log x\right)^{K - \frac{1}{2}}} {\left(\log D_0\right)^K} x}\right). \end{align*} $$

Recall that $V \approx 1.016 < 2$ , so for a given M, we can pick k large enough in terms of M, $\theta _1$ and $\theta _2$ so that the quantity

$$ \begin{align*}\Delta = \left(\frac{\pi}{\pi+2}\right)^2 \left(\frac{\theta_2}{2\theta_1}\right)\cdot 32\left(K\frac{(2-V)M+V}{M(M-1)}-V\right) - O_{\theta_1,\theta_2}\left( \sqrt{K}\right) \end{align*} $$

will be positive. We can then pick the constant $\xi $ to be a small enough multiple of $K^{-4}$ so that the term $O\left (u^2 K^3\xi ^2\right )$ will be negligible (for example, smaller than $\frac {\Delta }{100}$ ). Note that this is consistent with the constraint from the evaluation of $S_5^{(m)}$ that $\xi < \frac 1K$ .

By Lemma 21, the sums over $\mathbf b$ and $\nu _0$ are bounded below by

$$\begin{align*}\sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L = \mathcal L(\mathbf b) \text{ adm.}}} \sum_{\substack{\nu_0 \bmod W \\ (\ell(\nu_0),W) = 1 \forall \ell \in \mathcal L}} 1 \gg_{K} \left(\frac{\eta}{q}\right)^{K-1} \left(\log x\right)^{\frac{K-1}{2}} W \left(\frac{\phi(W)}{W}\right)^K. \end{align*}$$

Thus, by definition of B,

$$\begin{align*}\frac{B^K x}{W} \sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L = \mathcal L(\mathbf b) \text{ adm.}}} \sum_{\substack{\nu_0 \bmod W \\ (\ell(\nu_0),W) = 1 \forall \ell \in \mathcal L}} 1 \gg_K \left(\frac{\eta}{q}\right)^{K-1}\left(\frac{q_3}{\phi(q_3)}\right)^K \frac{\left(\log x\right)^{K-\frac{1}{2}}}{(\log D_0)^K} x. \end{align*}$$

Returning to S, we have that

$$ \begin{align*} S &\gg_K \left(\frac{\eta}{q}\right)^{K-1}\left(\frac{q_3}{\phi(q_3)}\right)^K L_K (F) \left( \Delta - \frac{1}{100}\Delta\right) \frac{\left(\log x\right)^{K-\frac{1}{2}}}{(\log D_0)^K} x \\ & \quad + O\left(u^2{ \xi^{-1/2} \theta_2^{\frac{K}{2} - 1} L_K(F) \left(\frac{q_3}{\phi(q_3)}\right)^{K} \frac{\eta^K}{q_3^2q^{K-1}} \frac{\left(\log x\right)^{K - \frac{1}{2}}} {\left(\log D_0\right)^K} x}\right). \end{align*} $$

We can now set the parameter $\eta $ to be sufficiently small (in terms of $K,M,\theta _1,\theta _2,\xi $ ) such that the big-O term will be negligible, which implies that

(27) $$ \begin{align} S \gg_{K,M,\theta_1,\theta_2,\xi,\eta} \left(\frac{1}{q}\right)^{K-1}\left(\frac{q_3}{\phi(q_3)}\right)^K \frac{\left(\log x\right)^{K-\frac{1}{2}}}{(\log D_0)^K} x. \end{align} $$

Equation (24) implies that

$$ \begin{align*}S \ll \#\{E_n \le x : E_{n+i-1} \equiv a_i \bmod q \:\forall 1 \le i \le M\} \times \mathrm{exp}(O(K/\xi)) \left(\frac{\log R}{\log D_0}\right)^K, \end{align*} $$

which along with equation (27) and the fact that $\log R = \tfrac {\theta _2}{2} \log x$ , implies that

$$ \begin{align*} \#\{E_n \le x : E_{n+i-1} \equiv a_i \bmod q \: \forall 1 \le i \le M\} \gg_{K,M,\theta_1,\theta_2,\xi,\eta} \left(\frac{1}{q}\right)^{K-1}\left(\frac{q_3}{\phi(q_3)}\right)^K \frac{x}{\sqrt{\log x}}. \end{align*} $$

This completes the proof.

3 Proofs of sieve results

The goal of this section is to prove Theorem 2. Throughout, fix $\eta> 0$ and let $\mathcal L = \{\ell _i(n)\}_{1 \le i \le K}$ be a fixed tuple of linear forms $\ell _i(n) = qn + a_i + qb_i$ , where $qb_i \le \eta \sqrt {\log x}$ for all i. Let $\nu _0$ be a congruence class modulo W such that $(\ell (\nu _0),W) = 1$ for all $\ell \in \mathcal L$ .

This section will be organized as follows. In Section 3.1, we introduce notation that will be used throughout, and define the sieve weights $w_n(\mathcal L)$ . Sections 3.2 and 3.3 contain lemmas and computations that will be used throughout the proof of Theorem 2; the estimate (16) is proven in Lemma 8. Finally, equations (17), (18), (19), (20), (21) and (22) are proven (respectively) in Sections 3.4, 3.5, 3.6, 3.7, 3.8 and 3.9, which completes the proof of Theorem 2.

3.1 Sieve notation and setup

We begin by fixing some notation in preparation for defining the weights $w_n(\mathcal L)$ . Recall that W is the product of primes $p \equiv 3 \bmod 4$ satisfying $p \le D_0$ and $(p,q) = 1$ . In particular, this means that if a prime $p \equiv 3 \bmod 4$ satisfies $p|\ell _i(n)$ and $p|\ell _j(n)$ for $x < n \le 2x$ and for two distinct linear forms $\ell _i,\ell _j \in \mathcal L$ , then $p|q_3W$ . Let $\mathcal D_{K} \subset \mathbb Z^{K}$ denote the set of K-tuples $\mathbf d = (d_i)$ such that for all i, $(d_i,q_3W) = 1$ , such that $(d_i,d_j) = 1$ for all $i \ne j$ , and such that each $d_i$ is divisible only by primes congruent to $3$ mod $4$ .

Let $F:[0,1]^{K} \to \mathbb R$ be a smooth function defined as follows. Let $R_{K} = \{(x_1, \dots , x_{K}) \in [0,1]^{K} : \sum _{i=1}^{K} x_i \le 1\}$ . Define $F(t_1, \dots , t_K)$ as

(28) $$ \begin{align} F(t_1, \dots, t_{K}) := \prod_{i=1}^{K} g(Kt_i), \end{align} $$

where

(29) $$ \begin{align} g(t) = \begin{cases} \frac 1{1+t}, &\text{ if } t \le 1, \\ 0, &\text{ otherwise.}\end{cases} \end{align} $$

Note that F is supported on the set $R_{K}$ .

We are now ready to define the sieve weights $w_n(\mathcal L)$ , which are nearly identical in structure to the multi-dimensional Selberg sieve weights used in, among other papers, [Reference Maynard13] and [Reference McGrath15]. We define

(30) $$ \begin{align} w_n(\mathcal L) = \Big(\sum_{\substack{\mathbf d\in\mathcal{D}_K \\ d_i\mid \ell_i(n)}}\lambda_{\mathbf d}\Big)^2, \end{align} $$

where

(31) $$ \begin{align} \lambda_{\mathbf d} = \left(\prod_{i=1}^{K} \mu(d_i)d_i\right) \sum_{\substack{\mathbf r \in \mathcal D_{K}\\ d_i|r_i \forall i}} \frac{\mu(r)^2}{\phi(r)} F\left(\frac{\log r_1}{\log R}, \dots, \frac{\log r_K}{\log R}\right). \end{align} $$

We will write

(32) $$ \begin{align} y_{{\mathbf r}} := F\left(\frac{\log r_1}{\log R}, \dots, \frac{\log r_K}{\log R}\right) \end{align} $$

where F is a function defined in (28).

The results of our sieve evaluations will depend on the following functionals on F:

(33) $$ \begin{align} \begin{aligned} &L_K(F) := \int_0^1 \cdots \int_0^1 \left[F(x_1, \dots, x_K)\right]^2 \prod_{i=1}^K \frac{\mathrm dx_i}{\sqrt{x_i}}, \\ &L_{K;m}(F) := \int_0^1 \cdots \int_0^1 \left[\int_0^1 F(x_1, \dots, x_K)\frac{\mathrm dx_m}{\sqrt{x_m}}\right]^2 \prod_{\substack{i = 1 \\ i \ne m}}^K \frac{\mathrm dx_i}{\sqrt{x_i}}, \\ &L_{K;m_1,m_2}(F) := \int_0^1 \cdots \int_0^1 \left[\int_0^1 \left(\int_0^1 F(x_1, \dots, x_K)\frac{\mathrm dx_{m_1}}{\sqrt{x_{m_1}}}\right)\frac{\mathrm dx_{m_2}}{\sqrt{x_{m_2}}}\right]^2 \prod_{\substack{i = 1 \\ i \ne m_1,m_2}}^K \frac{\mathrm dx_i}{\sqrt{x_i}}. \end{aligned} \end{align} $$

Using the function F that is explicitly given by (28) and (29), we can evaluate each of $L_K(F)$ , $L_{K;m}(F)$ , and $L_{K;m_1,m_2}(F)$ ; each of these will be a constant depending only on K. More convenient, however, is using the following lemma, which relates each of these values to $L_K(F)$ .

Lemma 4 ([Reference McGrath15], Lemma 6.4: Evaluation of sieve functionals).

Let $F(t_1, \dots , t_K)$ be given by equation (28) and let $L_K(F)$ , $L_{K;m_1}(F)$ , and $L_{K;m_1,m_2}(F)$ denote the functionals defined in (33). Then for any $m_1, m_2,$

$$ \begin{align*} \frac{L_{K;m_1}(F)}{L_K(F)} = \frac{\pi^2}{\pi + 2} \sqrt{\frac{1}{K}} \quad \text{ and } \quad \frac{L_{K;m_1, m_2}(F)}{L_K(F)} = \left(\frac{\pi^2}{\pi + 2}\right)^2 \frac{1}{K}. \end{align*} $$

3.2 Auxiliary lemmas for sieve weights

This subsection and the next collect various lemmas that will be used throughout our estimates. To begin with, we present several lemmas concerning the sieve weights defined in Section 3.1.

Lemma 5.

  1. (i) Let ${\mathbf r},{\mathbf s} \in \mathcal D_K$ with $s_i = r_i$ for all $i \ne j$ and $s_j = Ar_j$ for some $A \in \mathbb N$ . Then for $y_{{\mathbf r}}$ and $y_{{\mathbf s}}$ defined by (32), we have

    $$ \begin{align*} y_{{\mathbf s}} = y_{{\mathbf r}} + O\left(K \frac{\log A}{\log R}y_{{\mathbf r}}\right). \end{align*} $$
  2. (ii) Let ${\mathbf r},{\mathbf s} \in \mathcal D_K$ with $r = s$ and let A be the product of primes dividing r but not $({\mathbf r},{\mathbf s})$ . Then for $y_{{\mathbf r}}$ and $y_{{\mathbf s}}$ defined by (32), we have

    $$ \begin{align*} y_{{\mathbf s}} = y_{{\mathbf r}} + O\left(K \frac{\log A}{\log R}(y_{{\mathbf r}} + y_{{\mathbf s}})\right). \end{align*} $$

Proof. Recall that $y_{{\mathbf r}} = F\left (\frac {\log r_1}{\log R}, \dots , \frac {\log r_K}{\log R}\right )$ , where $F(t_1, \dots , t_K) := \prod _{i=1}^K g(Kt_i)$ and $g(t) = \frac 1{1+t}$ for $t \le 1$ and $g(t) = 0$ otherwise. Given $u,v \ge 0$ with $|u-v| < \varepsilon $ , we have

$$ \begin{align*} \frac 1{1+Ku} = \frac{1+O(K\varepsilon)}{1+Kv}. \end{align*} $$

Let $u_i = \log r_i/\log R$ , $v_i = \log s_i/\log R$ and $\varepsilon _i = v_i-u_i$ . In part (i), $\varepsilon _i = 0$ for $i \ne j$ and $\varepsilon _j = \log A/\log R$ . Thus,

$$ \begin{align*} \frac 1{1+Kv_j} = \frac{1+O\left(\tfrac{K\log A}{\log R}\right)}{1+Ku_j}. \end{align*} $$

Multiplying by $\prod _{i\ne j} 1/(1+Ku_i)$ gives the result for (i).

Now consider part (ii), and let $\mathbf t$ be the vector with $t_i = [r_i,s_i]$ . Applying part (i) to each component in turn implies that

$$ \begin{align*} y_{\mathbf s}=y_{\mathbf t} + O\left(Ky_{{\mathbf s}} \sum_{i=1}^K \frac{\log\left([r_i,s_i]\right)/s_i}{\log R}\right) = y_{\mathbf t} + O\left(Ky_{{\mathbf s}}\frac{\log A}{\log R}\right). \end{align*} $$

The same holds for ${\mathbf r}$ and $\mathbf t$ , which implies (ii).

The following lemma is a standard evaluation of sums of multiplicative functions that appear frequently in sieve computations.

Lemma 6. Let $A_1,A_2,L>0$ and let $\gamma $ be a multiplicative function satisfying

$$ \begin{align*}0\leq \frac{\gamma(p)}{p} \leq 1 - \frac{1}{A_1} \end{align*} $$

and

$$ \begin{align*}-L \leq \sum_{w\leq p < z} \frac{\gamma(p)\log p}{p} - \frac{1}{2} \log\left(\frac{z}{w}\right) \leq A_2 \end{align*} $$

for $2\leq w \leq z$ . Let g be the multiplicative function defined by $g(p) = \frac {\gamma (p)}{p - \gamma (p)}$ , and let $G: [0,1] \to {\mathbb R}$ be a piece-wise differentiable function. Then

$$ \begin{align*}\sum_{d< z}\mu^2(d)g(d)G\left(\frac{\log d}{\log z}\right) = c_\gamma \frac{(\log z)^{\frac{1}{2}}}{\Gamma\left(1/2\right)} \int_0^1 G(t)\frac{dt}{\sqrt{t}} +O\left(c_\gamma L G_{\mathrm{max}}(\log z)^{-\frac{1}{2}}\right), \end{align*} $$

where

$$ \begin{align*}c_\gamma = \prod_{p}\left(1 - \frac{\gamma(p)}{p}\right)^{-1}\left(1 - \frac{1}{p}\right)^{\frac{1}{2}} \end{align*} $$

and

$$ \begin{align*}G_{\mathrm{max}} = \sup_{t\in [0,1]}\left(|G(t)| + |G'(t)|\right). \end{align*} $$

Proof. This is [Reference Goldston, Graham, Pintz and Yılıd rım6, Lemma 4] with $\kappa = \frac {1}{2}$ .

Using Lemma 6, we show the following lemma, which is similar to [Reference Maynard14, Lemma 8.4].

Lemma 7. Let Q be a squarefree modulus of the form $Q = q_3 W \alpha $ with $\alpha = R^{O(K)}$ . Let f be a multiplicative function with $f(p) = p + O(K)$ , and let $G:{\mathbb R} \to {\mathbb R}$ be a smooth decreasing function supported on $[0,1]$ .

Then for K sufficiently large, we have

$$ \begin{align*} & \sum_{\substack{\mathbf e \in \mathcal{D}_K \\ (e,Q) = 1}} \frac{\mu^2(e)}{f(e)} \prod_{i=1}^K G\left(\frac{\log e_i}{\log R}\right) \\ &\quad = (1+o(1)) \left(\frac{\phi(\alpha)}{\alpha}\right)^{\frac{K}{2}} \left(\frac{e^{-\gamma /2}}{\Gamma(1/2)}\right)^K \left(\frac{\log R}{\log D_0}\right)^{K/2} \left(\int_{t_1, \dots, t_K \ge 0} \prod_{i=1}^K G(t_i) \frac{\mathrm{d}t_i}{\sqrt{t_i}}\right). \end{align*} $$

Proof. We would like to apply Lemma 6 for each variable. However, the variables $e_i$ are not independent, since $\mathbf e \in \mathcal {D}_K$ implies $(e_i,e_j) = 1$ for $i\neq j$ . Our first task is to decouple these variables with a negligible penalty.

Denote the sum evaluated in the lemma by

$$ \begin{align*}S = \sum_{\substack{\mathbf e \in \mathcal{D}_K \\ (e,Q) = 1}} \frac{\mu^2(e)}{f(e)} \prod_{i=1}^K G\left(\frac{\log e_i}{\log R}\right). \end{align*} $$

If $p|(e_r,e_j)$ for some $1\leq r< j \leq K$ , then we must have $p> D_0$ since $(e,Q) = 1$ . Thus, using also the fact that G is decreasing, we have that

$$ \begin{align*} \sum_{\substack{\mathbf e \in \mathbb N_K \\ (e,Q) = 1 \\ p\mid(e_i,e_j)}} &\prod_{j=1}^K \frac{\mu^2(e_j)}{f(e_j)} \prod_{i=1}^K G\left(\frac{\log e_i}{\log R}\right) \\ &\ll \frac{1}{f(p)^2} \sum_{\substack{\mathbf e \in \mathbb N_K \\ (e,Q) = 1}} \prod_{j=1}^K\frac{\mu^2(e_j)}{f(e_j)} G\left(\frac{\log e_r + \log p}{\log R}\right) G\left(\frac{\log e_j + \log p}{\log R}\right) \prod_{\substack{i=1 \\ i \neq r,j}}^K G\left(\frac{\log e_i}{\log R}\right) \\ & \ll (p + O(K))^{-2}S. \end{align*} $$

Writing

$$ \begin{align*}S' = \sum_{\substack{\mathbf e \in\mathbb{N}^ K \\ (e,Q) = 1}} \prod_{j=1}^K \frac{\mu^2(e_j)}{f(e_j)} \prod_{i=1}^K G\left(\frac{\log e_i}{\log R}\right) = \Big(\sum_{\substack{n \in \mathbb N \\ (n,Q) = 1}} \frac{\mu^2(n)}{f(n)} G\left(\frac{\log n}{\log R}\right)\Big)^K , \end{align*} $$

it follows that

$$ \begin{align*}S - S' \ll S \binom{K}{2}\sum_{p> D_0}\frac{1}{(p+O(K))^2} \ll_K \frac{S}{D_0}. \end{align*} $$

We now consider $S'$ in place of S and apply Lemma 6, where we take $g(p) = \frac 1{f(p)}$ and $\gamma (p) = \frac {p}{f(p)+1}$ for $p \nmid Q$ and $g(p) = \gamma (p) = 0$ for $p|Q$ . For this, we need a bound on the constant L from Lemma 6. If we did not have the restriction $g(p) = \gamma (p) = 0$ for $p|Q$ , then using the prime number theorem in arithmetic progressions, we could take L to be a constant, since

$$ \begin{align*}\sum_{\substack{w\leq p < z \\ p\equiv 3 \bmod 4}}\frac{\log p}{p + O(K)} - \frac{1}{2}\log{\left(\frac{z}{w}\right)} \ll_K 1. \end{align*} $$

It follows that in our case, we can choose L satisfying

$$ \begin{align*}L \ll_K 1 + \sum_{\substack{p \leq D_0 \\ p\equiv 3 \bmod 4}}\frac{\log p }{p} + \sum_{p \mid \alpha }\frac{\log p}{p}. \end{align*} $$

The first sum is $(1+o(1))\frac {1}{2}\log {D_0}$ . For the second sum, we have the bound

$$ \begin{align*}\sum_{p|\alpha} \frac{\log p}{p} \ll_{K} \log\log R \end{align*} $$

since $\alpha = R^{O(K)}$ and the sum is dominated by taking the smallest possible primes. This implies that

$$ \begin{align*}L \ll_{K} \frac{1}{2}\log D_0 + \log\log R \ll_{K} \log\log R. \end{align*} $$

We will write

$$ \begin{align*}\Omega_G =G_{\mathrm{max}}\cdot \left(\int_{t\geq 0} G(t)\frac{dt}{\sqrt{t}}\right)^{-1}, \end{align*} $$

where $G_{\mathrm {max}}$ is defined as in Lemma 6. Applying Lemma 6 successively K times, we get

$$ \begin{align*} S' &= \frac{c_\gamma^K}{\Gamma(1/2)^K}(\log R)^{K/2} \left(\int_{t_1, \dots, t_K \ge 0} \prod_{i=1}^K G(t_i) \frac{\mathrm{d}t_i}{\sqrt{t_i}}\right) \left(1 + \sum_{\ell = 1}^K \binom{K}{\ell} O_{K}\left( \frac{\Omega_G \log\log R}{\log R}\right)^\ell \right) \\ &= \frac{c_\gamma^K}{\Gamma(1/2)^K}(\log R)^{K/2} \left(\int_{t_1, \dots, t_K \ge 0} \prod_{i=1}^K G(t_i) \frac{\mathrm{d}t_i}{\sqrt{t_i}}\right) \left( 1 + O_{K,G}\left(\frac{ \log\log R}{\log R}\right)\right), \end{align*} $$

where $c_\gamma $ is given in Lemma 6 and satisfies

$$ \begin{align*}c_\gamma = (1 + o(1)) \prod_{p\mid \alpha}\left(1 - \frac{1}{p}\right)^{\frac{1}{2}} \prod_{p\leq D_0} \left(1 - \frac{1}{p}\right)^{\frac{1}{2}} = (1 + o(1)) \left(\frac{\phi(\alpha)}{\alpha}\right)^{\frac{1}{2}} \frac{e^{-\gamma/2}}{(\log D_0)^{\frac{1}{2}}} \end{align*} $$

Combining our estimates completes the proof.

Lemma 7 will be useful for many of our computations to follow. For now, we use it to verify that the weights $w_n(\mathcal L)$ given in (30) are bounded above as in (16), which we show in the following lemma.

Lemma 8. We have the bounds

  1. (i)

    (34) $$ \begin{align} |\lambda_{\mathbf d}| \ll_K \left(\frac{\log R}{\log D_0}\right)^{K/2}, \end{align} $$
  2. (ii)

    $$\begin{align*}w_n(\mathcal L) \ll_K\left(\frac{\log R}{\log D_0}\right)^{K} \prod_{i=1}^K \prod_{\substack{p|\ell_i(n) \\ p \equiv 3 \bmod 4}}4, \end{align*}$$
  3. (iii)

    (35) $$ \begin{align} w_n(\mathcal L) \ll_K R^{2+o(1)}. \end{align} $$

Lemma 8, (ii) is precisely (16), whereas (i) and (iii) will be used in our sieve estimates.

Proof. By our choice of $y_{\mathbf r}$ , for any $\mathbf d \in \mathcal D_K$ , we have

(36) $$ \begin{align} |\lambda_{\mathbf d}| = \prod_{i=1}^K d_i \sum_{\substack{\mathbf r \in \mathcal D_K \\ \mathbf d|\mathbf r}} \frac{y_{\mathbf r}}{\phi(r)} = \frac{d}{\phi(d)}\sum_{\mathbf d|\mathbf r \in \mathcal D_K} \frac{F\left(\frac{\log r_1}{\log R},\dots, \frac{\log r_K}{\log R}\right)}{\phi(r/d)}. \end{align} $$

Since F is decreasing in each argument, we can bound $|\lambda _{\mathbf d}|$ above by replacing each $\frac {\log r_i}{\log R}$ in the argument of F with $\sigma _i = \frac {(\log r_i/d_i)}{\log R}$ .

We now apply Lemma 7 with $Q = dq_3W$ , which gives

$$ \begin{align*} &\sum_{\mathbf d|\mathbf r \in \mathcal D_K} \frac{F(\sigma_1, \dots, \sigma_K)}{\phi(r/d)} = \sum_{\mathbf d|\mathbf r\in \mathcal D_K} \frac 1{\phi(r/d)} \prod_{i=1}^K g(K\sigma_i) \\& \qquad \sim \left(\frac{\phi(d)}{d}\right)^{\frac{K}{2}} \left(\frac{e^{-\gamma /2}}{\Gamma(1/2)}\right)^K \left(\frac{\log R}{\log D_0}\right)^{K/2} \left(\int_{t_1, \dots, t_K \ge 0} \prod_{i=1}^K g(K t_i) \frac{\mathrm{d}t_i}{\sqrt{t_i}}\right). \end{align*} $$

Evaluating the integral gives

$$ \begin{align*} \int_{t_1, \dots, t_K \ge 0} \prod_{i=1}^K g(Kt_i) \frac{\mathrm dt_i}{\sqrt{t_i}} = \left(\frac{\pi}{2\sqrt{K}}\right)^K. \end{align*} $$

Substituting this expression back into (36), we get that

$$ \begin{align*} |\lambda_{\mathbf d}| \ll_K \left(\frac{\phi(d)}{d}\right)^{\frac{K}{2}-1} \left(\frac{\log R}{\log D_0}\right)^{K/2} \ll \left(\frac{\log R}{\log D_0}\right)^{K/2} \end{align*} $$

for $K\geq 4$ . This completes the proof of (34).

For the second claim, recall that

$$ \begin{align*} w_n(\mathcal L) &= \Big(\sum_{\substack{\mathbf d \in \mathcal D_K \\ d_i\mid\ell_i(n)}} \lambda_{\mathbf d}\Big)^2 \ll_K \left(\frac{\log R}{\log D_0}\right)^{K} \#\{\mathbf d \in \mathcal D_K : d_i\mid \ell_i(n)\}^2 \\ &\ll_K \left(\frac{\log R}{\log D_0}\right)^{K} \prod_{i=1}^K \prod_{\substack{p\mid \ell_i(n) \\ p \equiv 3 \bmod 4}}4, \end{align*} $$

as desired.

For the third claim, note that since $\lambda _{\mathbf d}$ is supported on $d=d_1 \cdots d_K < R$ , we have

$$ \begin{align*} w_n(\mathcal L) &\ll_K \left(\frac{\log R}{\log D_0}\right)^{K} \left(\sum_{d_1\cdots d_K < R} 1\right)^2 \ll_K R^{2+o(1)} \left(\sum_{d_1 \cdots d_K < R} \frac 1{d_1 \cdots d_K}\right)^2 \ll_K R^{2+o(1)}. \end{align*} $$

Finally, throughout our sieve arguments, we will make crucial use of [Reference McGrath15, Lemma 6.6], which we restate below for convenience.

Lemma 9. Let $J \subseteq \{1, \dots , K\}$ (possibly empty) and $p_1, p_2 \in \mathbb P \cup \{1\}$ be fixed. Write $I = \{1, \dots , K\} \setminus J$ . Define the sieve sum $S_{J,p_1,p_2,m} = S_{J,p_1,p_2,m,f,g}$ by

$$ \begin{align*} S_{J,p_1,p_2,m} = \sum_{\substack{\mathbf d, \mathbf e \in \mathcal D_K \\ q_3W,[d_1,e_1], \dots, [d_{K},e_{K}] \text{ coprime} \\ p_1|d_m, p_2|e_m }} \lambda_{\mathbf d} \lambda_{\mathbf e} \prod_{i \in I} f([d_i,e_i]) \prod_{j \in J} g([d_j,e_j]), \end{align*} $$

with weights $\lambda _{\mathbf d}$ defined as in (30). If $J = \emptyset $ , we define $f(p) = 1/p$ (and in this case, there is no dependence on g in the sum). Otherwise, f and g are nonzero multiplicative functions defined on primes by

$$ \begin{align*} f(p) = \frac 1p + O\left(\frac 1{p^2}\right), \quad g(p) = \frac 1{p^2} + O\left(\frac 1{p^3}\right), \end{align*} $$

and moreover, we assume that $f(p) \ne 1/p$ . We write $S_J$ for $S_{J,1,1,m}$ . Then for $|J| \in \{0,1,2\}$ , we have the following:

  1. (i) If $m \in J$ , then

    $$ \begin{align*} S_{J,p_1,p_2,m} \ll \frac{F_{max}^2B^{K+|J|} (\log \log R)^2}{(p_1p_2/(p_1,p_2))^2}. \end{align*} $$
  2. (ii) If $m \not \in J$ , then

    $$ \begin{align*} S_{J,p_1,p_2,m} \ll \frac{F_{max}^2B^{K+|J|} (\log \log R)^2}{p_1p_2/(p_1,p_2)}. \end{align*} $$
  3. (iii) We have

    $$ \begin{align*} S_J = (1+o(1))B^{K+|J|}L_J(F), \end{align*} $$
    where we write $L_J(F)$ as shorthand for $L_{K;j\in J}(F)$ , defined analogously to (33).

Remark. This is [Reference McGrath15, Lemma 6.6] with $q_3W$ in place of W. Note also that the restriction $\mathbf d, \mathbf e \in \mathcal D_K$ in the definition of $S_{J,p_1,p_2,m}$ does not affect the statement since $\lambda _{\mathbf d} = 0$ for $\mathbf d\not \in \mathcal D_K$ .

3.3 Auxiliary lemmas for sums of two squares

In this subsection, we record several useful results on estimates of the functions $\rho $ and $r_2$ . To begin with, we have the following lemma, which is [Reference McGrath15, Lemma 5.3], and will be used in the proof of (18).

Lemma 10. Let $(\alpha ,r) = (d,r) = 1$ , where d and r are squarefree, odd and $\ll x^{O(1)}$ . Then

$$ \begin{align*} \sum_{\substack{n \le x \\ n \equiv \alpha \bmod r \\ n \equiv 1 \bmod 4 \\ d|n}} r_2(n) = \frac{g_1(r)g_2(d)}{2rd} \pi x + R_1(x;d,r), \end{align*} $$

where $g_2$ is defined as in (6), $g_1$ is the multiplicative function defined on primes by

$$ \begin{align*}g_1(p) = 1-\chi(p)/p, \end{align*} $$

and

$$ \begin{align*} R_1(x;d,r) \ll_\varepsilon ((rd)^{\tfrac 12} + x^{\tfrac 13})d^{\tfrac 12}x^\varepsilon. \end{align*} $$

The following lemma is nearly identical to [Reference McGrath15, Lemma A.3] and will be used to prove (19).

Lemma 11. Let r be a modulus and suppose that $(\alpha ,r) = (\alpha +h,r) = (c_1,r) = (c_2,r) = 1$ and $4|h$ , where $c_1,c_2,r$ are squarefree and odd, and of size $\ll x^{O(1)}$ . Then we have

$$ \begin{align*} \sum_{\substack{n \le x \\ n \equiv \alpha \bmod r \\ n \equiv 1 \bmod 4 \\ c_1|n \\ c_2|n+h}} r_2(n)r_2(n+h) = \frac{g_1(r)^2\Gamma(h,c_1,c_2,r)}{r} \pi^2 x + R_2(x;c_1,c_2,r), \end{align*} $$

where

$$ \begin{align*} \Gamma(h,c_1,c_2,r) = \frac{g_2(c_1)g_2(c_2)}{c_1c_2} \sum_{(t,2r) = 1} \frac{c_t(h)(c_1,t)(c_2,t)\chi[(c_1^2,t)]\chi[(c_2^2,t)]}{t^2 \Psi(c_1,t)\Psi(c_2,t)}, \end{align*} $$

where $\Psi (u,t) := g_2((u,t/(u,t)))$ , $c_t(h)$ is the Ramanujan sum $c_t(h) = \sum _{d\mid (t,h)}\mu \left (\frac {t}{d}\right )d$ , and

$$ \begin{align*} R_2(x;c_1,c_2,r) \ll_\varepsilon r^{\tfrac 12}c_1c_2x^{\tfrac 34 + \varepsilon} + c_1^{\tfrac 12}c_2^{\tfrac 12}x^{\tfrac 56 + \varepsilon}. \end{align*} $$

The only difference between Lemma 11 and [Reference McGrath15, Lemma A.3] is that the latter requires the additional constraint that $(c_1,c_2) = 1$ . However, this constraint is not used in the proof, which refers heavily to the proof of [Reference Plaksin18, Lemma 4]. Note that if $(c_1,c_2)\nmid h$ , then the sum over $r_2(n)r_2(n+h)$ is empty; in this case, $\Gamma (h,c_1,c_2,r) = 0$ and the equation still holds. One can see that $\Gamma (h,c_1,c_2,r) = 0$ when $(c_1,c_2)\nmid h$ by noting that $\Gamma $ is multiplicative over primes $p|[h,c_1,c_2,r]$ and that $c_t(h) = \mu (t)$ whenever $(t,h) = 1$ . Then if any prime p divides $(c_1,c_2)$ but $p\nmid h$ , the p-component of $\Gamma (h,c_1,c_2,r)$ is $0$ .

The following lemma is [Reference McGrath15, Lemma 5.5] and will be used in the proof of (20).

Lemma 12. Let $(a,r) = (d,r) = 1$ , where d and r are squarefree, odd, and $\ll x^{O(1)}$ . Then

$$ \begin{align*} \sum_{\substack{n \leq x \\ n\equiv a \bmod r \\n\equiv 1 \bmod 4\\ d\mid n}} r_2^2(n) = \frac{g_3(r)g_4(d)}{rd}\left( \log x + A_2 + 2\sum_{p\mid r}g_5(p) - 2\sum_{p\mid d}g_6(p)\right)x + O_\varepsilon\left(rx^{\frac{3}{4} + \varepsilon}\right), \end{align*} $$

where

$$ \begin{align*} g_3(p) &:=\begin{cases} \tfrac{(p-1)^2}{p(p+1)} &\text{ if } p \equiv 1 \bmod 4 \\ g_1(p) &\text{ if } p \equiv 3 \bmod 4 \end{cases} &\quad g_4(p) &:= \begin{cases} \tfrac{4p^2 - 3p + 1}{p(p+1)} &\text{ if } p \equiv 1 \bmod 4 \\ g_2(p) &\text{ if } p \equiv 3 \bmod 4 \end{cases} \\ g_5(p) &:= \begin{cases} \tfrac{(2p+1)\log p}{p^2 -1} &\text{ if } p \equiv 1 \bmod 4 \\ \tfrac{\log p}{p^2-1} &\text{ if } p \equiv 3 \bmod 4 \end{cases} &\quad g_6(p) &:= \begin{cases} \tfrac{(p-1)^2(2p+1)\log p}{(p+1)(4p^2 - 3p + 1)} &\text{ if } p \equiv 1 \bmod 4 \\ \log p &\text{ if } p \equiv 3 \bmod 4 \end{cases} \\ \end{align*} $$

and $A_2$ is a constant given explicitly in [Reference McGrath15, Lemma 5.5].

The following lemma is [Reference McGrath15, Lemma 5.6], and will be used to prove (18), (19) and (20).

Lemma 13. Let Q be a squarefree integer such that $Q\mid \prod _{p \le (\log \log x)^3} p$ and any prime p dividing Q is $1 \bmod 4$ . Define $X_{x,Q}$ , $Z_{x,Q}^{(1)}$ , and $Z_{x,Q}^{(2)}$ as follows:

$$ \begin{align*} X_{x,Q} &= \sum_{\substack{a \le v \\ (a,Q) = 1 \\ p|a \Rightarrow p \equiv 1 \bmod 4}} \frac{\mu(a)}{a}\log \frac va, \\Z_{x,Q}^{(1)} &= \sum_{\substack{a,b\leq v \\ (a,Q) = (b,Q) = 1 \\ p\mid ab \Rightarrow p\equiv 1 \bmod 4}} \frac{\mu(a)\mu(b)g_4([a,b])}{g_2(a)g_2(b)[a,b]}\log\frac{v}{a}\log\frac{v}{b} \\ Z_{x,Q}^{(2)} &= \sum_{\substack{a,b\leq v \\ (a,Q) = (b,Q) = 1 \\ p\mid ab \Rightarrow p\equiv 1 \bmod 4}} \frac{\mu(a)\mu(b)g_4([a,b])}{g_2(a)g_2(b)[a,b]}\log\frac{v}{a}\log\frac{v}{b} \sum_{p\mid ab}g_6(p). \end{align*} $$

Then

$$ \begin{align*} X_{x,Q} &= (1+o(1)) \frac{8A\log^{\tfrac 12}v}{\pi g_1(Q)}, \\ Z_{x,Q}^{(1)} &= (1+o(1)) 8A \frac{g_7(Q)\log^{\tfrac 12}v}{\phi(Q)g_1(Q)}\prod_{\substack{p \equiv 1 \bmod 4 \\ p\nmid Q}} \left(1 + \frac 1{(2p-1)^2}\right), \text{ and}\\ Z_{x,Q}^{(2)} &= -(1+o(1)) 4A \frac{g_7(Q)\log^{\tfrac 32}v}{\phi(Q)g_1(Q)}\prod_{\substack{p \equiv 1 \bmod 4 \\ p\nmid Q}} \left(1 + \frac 1{(2p-1)^2}\right), \end{align*} $$

where $g_7$ is the multiplicative function defined on primes by $g_7(p) = p+1$ .

Proof. The proof of this lemma is for the most part identical to the proof in Appendix B of [Reference McGrath15], so here we will restrict ourselves to highlighting the differences in the argument.

In general, the application of the Selberg–Delange method is identical to that described in [Reference McGrath15], with the same arguments applying for bounding, for example, relevant analytic functions; the only change that need be made to McGrath’s arguments is replacing W by an arbitrary Q (which must divide the W that McGrath uses) everywhere. Thus, by following McGrath’s proof, we get that, for

$$ \begin{align*} K_1(s)^2 = \left(1-\frac 1{2^s}\right)^{-1}\prod_{p\equiv 3 \bmod 4}\left(1-\frac 1{p^{2s}}\right)^{-1} \end{align*} $$

and

$$ \begin{align*} G_1(Q,s) = \prod_{\substack{p|Q \\ p \equiv 1 \bmod 4 }} \left(1-\frac 1{p^s}\right)^{-1}, \end{align*} $$

we have

$$ \begin{align*} X_{x,Q} = \frac{K_1(1)G_1(Q)}{\Gamma(3/2)\sqrt{L(1,\chi_4)}}(\log v)^{\tfrac 12} + O_\varepsilon\left(\frac{(\log x)^{\varepsilon}}{(\log v)^{\tfrac 12}}\right), \end{align*} $$

which simplifies to the desired expression.

In the same manner, expressions for $Z^{(1)}_{x,Q}$ and $Z^{(2)}_{x,Q}$ can be derived.

3.4 Estimating $S_1$

In this section, we will prove Theorem 2, equation (17), which we restate in the following proposition.

Proposition 14. Consider the sum $S_1(\nu _0)$ defined by

$$\begin{align*}S_1(\nu_0) := \sum_{\substack{x < n \le 2x \\ n \equiv 1 \bmod 4 \\ n\equiv \nu_0 \bmod W}} w_n(\mathcal L).\end{align*}$$

Then

$$\begin{align*}S_1(\nu_0) = (1 + o(1)) \frac{B^K x}{4W} L_K(F).\end{align*}$$

Proof. We have

$$ \begin{align*} S_1(\nu_0) &= \sum_{\substack{x\leq n \leq 2x \\ n\equiv 1\bmod 4 \\ n \equiv \nu_0 \bmod W}}w_n(\mathcal L) = \sum_{\substack{x\leq n \leq 2x \\ n\equiv 1\bmod 4 \\ n \equiv \nu_0 \bmod W}} \left(\sum_{\mathbf d \in \mathcal D_{K}} \lambda_{\mathbf d}\right)^2. \\ \end{align*} $$

By expanding the square and swapping the order of summation, we get that

$$ \begin{align*} S_1(\nu_0) &= \sum_{\substack{\mathbf d, \mathbf e \in \mathcal D_K}} \lambda_{\mathbf d}\lambda_{\mathbf e} \sum_{\substack{x \leq n \leq 2x \\ qn+a_i+qb_i \equiv 0 \bmod{[d_i,e_i]} \\ n\equiv 1 \bmod 4 \\ n \equiv \nu_0 \bmod W}} 1 \\ &= \sum_{\substack{ \mathbf d, \mathbf e \in \mathcal D_K}}\lambda_{\mathbf d}\lambda_{\mathbf e} \left(\frac{x}{4W}\prod_{i=1}^{K}\frac{1}{[d_i,e_i]} + O(1) \right) \\ &= \frac{x}{4W} \sum_{\mathbf d, \mathbf e \in \mathcal D_{K}} \frac{\lambda_{\mathbf d}\lambda_{\mathbf e}}{[\mathbf d, \mathbf e]} +O\left( \sum_{\substack{\mathbf d, \mathbf e \in \mathcal D_K}}\lambda_{\mathbf d}\lambda_{\mathbf e} \right), \end{align*} $$

where the second line follows from the first by the Chinese remainder theorem and the observation that $4$ , W and the $[d_i,e_i]$ are all pairwise relatively prime. In the notation of Lemma 9, the sum in the main term is precisely the sum $S_{\emptyset } = S_{\emptyset ,1,1,m}$ , which by Lemma 9 is equal to $B^KL_K(F)$ .

It remains only to bound the error term; We have

$$ \begin{align*}\left| \sum_{\mathbf d, \mathbf e\in\mathcal D_K}\lambda_{\mathbf d}\lambda_{\mathbf e} \right| \ll \lambda_{\mathrm{max}}^2 |\mathcal D_K|^2. \end{align*} $$

We use (34) to bound $\lambda _{\text {max}}$ , and the bound

(37) $$ \begin{align} |\mathcal D_K| \leq \sum_{n\leq R}\tau_K(n) \ll_\epsilon R^{1 + \epsilon}. \end{align} $$

Since $R = x^{\theta _2/2}$ with $\theta _2<\frac {1}{18}$ , we conclude

$$ \begin{align*}\left| \sum_{\mathbf d, \mathbf e\in\mathcal D_K}\lambda_{\mathbf d}\lambda_{\mathbf e} \right| \ll_{K,\epsilon} R^{2+\epsilon} = x^{\theta_2 + \epsilon} \ll x^{1/18 + \varepsilon}, \end{align*} $$

which is negligible. This completes the proof.

3.5 Estimating $S_2^{(m)}$

In this section, we will prove Theorem 2, equation (18), which we restate in the following proposition.

Proposition 15. For fixed $1 \le m \le K$ , consider the sum $S_2^{(m)}(\nu _0)$ defined by

$$ \begin{align*} S_2^{(m)}(\nu_0) := \sum_{\substack{x < n \le 2x \\ n \equiv 1 \bmod 4 \\ n\equiv \nu_0\bmod W}} \rho(\ell_m(n))w_n(\mathcal L). \end{align*} $$

Then

$$\begin{align*}S_2^{(m)}(\nu_0) = (1+o(1)) \frac{4\pi \sqrt{\frac{\log R}{\log v}} B^Kx}{(\pi + 2)\sqrt{K} W} L_K(F).\end{align*}$$

Proof. By definition of $\rho $ , we have that

$$ \begin{align*} \rho(\ell_m(n)) = \frac{r_2(\ell_m(n))}{\log v}\sum_{\substack{a\mid \ell_m(n) \\ p\mid a \Rightarrow p\equiv 1 \bmod 4 \\ a\leq v}} \frac{\mu(a)}{g_2(a)} \log \left( \frac{v}{a}\right). \end{align*} $$

Note that since $a|\ell _m(n)$ , which is relatively prime to q, we must have $(a,q) = 1$ for any a in the definition of $\rho (\ell _m(n))$ . Since a is only divisible by primes that are $1$ mod $4$ , the only nontrivial constraint on a is that $(a,q_1) = 1$ . By expanding the definitions of $w_n(\mathcal L)$ and $\rho $ in the expression for $S_2^{(m)}(\nu _0)$ and changing the order of summation, we get

(38) $$ \begin{align} S_2^{(m)}(\nu_0) = \frac 1{\log v} \sum_{\mathbf d, \mathbf e \in \mathcal D_K} \lambda_{\mathbf d}\lambda_{\mathbf e} \sum_{\substack{a \le v \\ (a,q_1)=1 \\ p|a \Rightarrow p \equiv 1 \bmod 4}} \frac{\mu(a)}{g_2(a)} \log \frac{v}{a} \sum_{\substack{x < n \le 2x \\ n \equiv 1 \bmod 4 \\ n\equiv \nu_0\bmod W \\ [d_i,e_i]\mid \ell_i(n) \forall i \\ a \mid \ell_m(n) }} r_2(\ell_m(n)). \end{align} $$

The parameter a is supported on integers whose prime factors are all $1 \bmod 4$ , whereas by the definition of $\mathcal D_K$ , each $[d_i,e_i]$ is only divisible by primes that are $3 \bmod 4$ . Thus, the $[d_i,e_i]$ ’s and a are pairwise coprime. Also, all prime factors of each $[d_i,e_i]$ are larger than $D_0$ , whereas each $qb_i < D_0$ , so each $[d_i,e_i]$ is coprime to each $qb_i$ .

Thus, by Lemma 10, (applied with $r = qW\prod _{i\ne m} [d_i,e_i]$ and with $d = a[d_m,e_m]$ ), we get

(39) $$ \begin{align} \sum_{\substack{x < n \le 2x \\ n \equiv 1 \bmod 4 \\ n \equiv \nu_0 \bmod W\\ [d_i,e_i]\mid \ell_i(n) \forall i \\ a \mid \ell_m(n) }} r_2(\ell_m(n)) &= \frac{ g_1\left( qW \prod_{i\neq m}[d_i,e_i]\right) g_2(a[d_m,e_m]) }{2 qW a \prod_i[d_i,e_i]} \pi qx \notag \\ &\quad + O_\epsilon\left(\left((WR^3v)^{1/2} + x^{1/3}\right)v^{1/2}x^{\epsilon}\right).\end{align} $$

Recall that $v = x^{\theta _1}$ , $R^2 = x^{\theta _2}$ , $\theta _1 + \theta _2 < 1/18$ , and $W \ll _\varepsilon x^{\varepsilon }$ for all $\varepsilon> 0$ . Thus,

$$ \begin{align*} & S_2^{(m)}(\nu_0)\\ &\quad = \frac {\pi x}{\log v} \sum_{\mathbf d, \mathbf e \in \mathcal D_K} \lambda_{\mathbf d}\lambda_{\mathbf e} \sum_{\substack{a \le v \\ (a,q_1) = 1 \\ p|a \Rightarrow p \equiv 1 \bmod 4}} \frac{\mu(a)}{g_2(a)} \log \frac{v}{a} \frac{ g_1\left(q W \prod_{i\neq m}[d_i,e_i]\right) g_2(a[d_m,e_m]) }{2 W a \prod_i[d_i,e_i]} + E, \end{align*} $$

where

$$ \begin{align*} |E| &\ll_\varepsilon \frac 1{\log v} \left|\sum_{\mathbf d, \mathbf e \in \mathcal D_K} \lambda_{\mathbf d}\lambda_{\mathbf e} \right| \sum_{\substack{a \le v \\ p|a \Rightarrow p \equiv 1 \bmod 4}} \frac{1}{g_2(a)} \log \frac{v}{a} x^{\frac{1}{3} + (\theta_1 + \theta_2)/2 + \epsilon} \\ & \ll \lambda_{\mathrm{max}}^2 |\mathcal D_K|^2 v x^{\frac{1}{3} + (\theta_1 + \theta_2)/2 + \epsilon} \ll_{\varepsilon'} x^{\frac{1}{3} + (\theta_1 + \theta_2)\frac{3}{2} + \epsilon'} \ll x^{\frac{5}{12} + \epsilon'}, \end{align*} $$

where we used use (34) to bound the $\lambda _{\mathrm {max}}$ and (37) for $|\mathcal D_K|$ .

It remains to consider the main term, which is given by

$$ \begin{align*} &\frac { \pi x}{\log v} \sum_{\mathbf d, \mathbf e \in \mathcal D_K} \lambda_{\mathbf d}\lambda_{\mathbf e} \sum_{\substack{a \le v \\ (a,q_1) = 1 \\ p|a \Rightarrow p \equiv 1 \bmod 4}} \frac{\mu(a)}{g_2(a)} \log\left( \frac{v}{a} \right) \frac{ g_1\left( qW \prod_{i\neq m}[d_i,e_i]\right) g_2(a[d_m,e_m]) } {2 W a \prod_i[d_i,e_i]} \\ = &\frac{\pi x g_1(qW)}{2W\log v} \sum_{\mathbf d, \mathbf e \in \mathcal D_K} \lambda_{\mathbf d} \lambda_{\mathbf e} \frac{g_1\left(\prod_{i\ne m}[d_i,e_i]\right) g_2([d_m,e_m])}{\prod_i[d_i,e_i]} \sum_{\substack{a \le v \\ (a,q_1) = 1 \\ p|a \Rightarrow p \equiv 1 \bmod 4}} \frac{\mu(a)}{a} \log \frac va. \end{align*} $$

The inside sum is exactly $X_{x,q_1}$ , as defined in Lemma 13. Also, all primes dividing $[d_m,e_m]$ are congruent to $3$ mod $4$ , so $g_2([d_m,e_m]) = \frac {1}{[d_m,e_m]}$ . We can thus rewrite the main term as

(40) $$ \begin{align} \frac{X_{x,q_1} \pi x g_1(qW) }{2 W \log v} \sum_{\mathbf d, \mathbf e \in \mathcal D_K} \lambda_{\mathbf d}\lambda_{\mathbf e} \prod_{i \ne m}\left(\frac{g_1([d_i,e_i])}{[d_i,e_i]}\right) \frac 1{[d_m,e_m]^2}. \end{align} $$

By Lemma 13, $X_{x,q_1} = (1+o(1))\frac {8A\sqrt {\log v}}{g_1(q_1)\pi }$ , and by Lemma 9 applied with $f(p) = \frac {g_1(p)}{p}$ and $g(p) = 1/p^2$ ,

$$ \begin{align*} \sum_{\mathbf d, \mathbf e \in \mathcal D_K} \lambda_{\mathbf d}\lambda_{\mathbf e} \prod_{i \ne m}\left(\frac{g_1([d_i,e_i])}{[d_i,e_i]}\right)\frac 1{[d_m,e_m]^2} = S_{\{m\}}=B^{K+1}L_{K;m}(F)(1+o(1)). \end{align*} $$

Then (40) can be rewritten as

$$ \begin{align*}\frac{\pi x g_1(qW)}{2 W \log v}\cdot \frac{8A\sqrt{\log v}}{g_1(q_1)\pi}B^{K+1}L_{K;m}(F)(1+o(1)). \end{align*} $$

By definition of $g_1$ ,

(41) $$ \begin{align} \frac{g_1(q_3W) \phi(q_3W)}{q_3W} = \frac{1}{2A^2} + O\left(\frac{1}{D_0}\right). \end{align} $$

Recalling also that $B = \frac {2A}{\pi }\frac {\phi (q_3W)}{q_3W}(\log R)^{\tfrac 12}$ , we get

$$ \begin{align*} S_2^{(m)}(\nu_0) = (1+o(1))\frac{4\sqrt{\frac{\log R}{\log v}} B^K x}{\pi W} L_{K;m}(F), \end{align*} $$

which, along with the fact from Lemma 4 that $L_{K;m}(F) = \frac {\pi ^2}{\pi +2} \frac {L_K(F)}{\sqrt K}$ , completes the proof.

3.6 Estimating $S_3^{(m_1,m_2)}$

In this section, we will prove Theorem 2, equation (19), which we restate in the following proposition.

Proposition 16. For fixed $1 \le m_1, m_2 \le K$ lying in the same bin of the tuple $\mathcal L$ , consider the sum $S_3^{(m_1,m_2)}(\nu _0)$ defined by

$$\begin{align*}S_3^{(m_1,m_2)}(\nu_0) := \sum_{\substack{x < n \le 2x \\ n \equiv 1 \bmod 4 \\ n \equiv \nu_0 \bmod W}} \rho(\ell_{m_1}(n))\rho(\ell_{m_2}(n))w_n(\mathcal L).\end{align*}$$

Then

$$\begin{align*}S_3^{(m_1,m_2)}(\nu_0) \le (1+o(1)) \frac{64\pi^2 \left(\tfrac{\log R}{\log v}\right) B^K x}{(\pi + 2)^2K W} V L_K(F).\end{align*}$$

Proof. We begin by expanding the definition of $w_n(\mathcal L)$ to rewrite $S_3^{(m_1,m_2)}(\nu _0)$ as

$$ \begin{align*} S_3^{(m_1,m_2)}(\nu_0) = \sum_{\mathbf d, \mathbf e \in \mathcal D_K} \lambda_{\mathbf d} \lambda_{\mathbf e} \sum_{\substack{x < n \le 2x \\ n \equiv 1 \bmod 4 \\ n \equiv \nu_0 \bmod W \\ [d_i,e_i]|\ell_i(n) \forall i}} \rho(\ell_{m_1}(n))\rho(\ell_{m_2}(n)). \end{align*} $$

Upon expanding the definition of $\rho $ and changing the order of summation, the inside sum over n is equal to

$$ \begin{align*} \frac 1{\log^2 v} & \sum_{\substack{a,b \le v \\ (a,q_1) = (b,q_1) = 1 \\ p|a,b \Rightarrow p \equiv 1 \bmod 4}} \frac{\mu(a)\mu(b)}{g_2(a)g_2(b)} \log \frac va \log \frac vb \\ &\quad \times\sum_{\substack{x < n \le 2x \\ n \equiv 1 \bmod 4 \\ n \equiv \nu_0 \bmod W \\ [d_i,e_i]|\ell_i(n) \forall i \\ a|(qn+a_{m_1} + qb_{m_1}) \\ b|(qn+a_{m_2} + qb_{m_2})}} r_2(qn+a_{m_1} + qb_{m_1})r_2(qn+a_{m_2} + qb_{m_2}). \end{align*} $$

Since $\ell _{m_1}(n)$ and $\ell _{m_2}(n)$ are always relatively prime to q, we must also always have $(a,q) = (b,q) = 1$ ; since a and b are only divisible by primes congruent to $1$ mod $4$ , this is equivalent to the constraint that $(a,q_1) = (b,q_1) = 1$ . For the inside sum to be nonzero, $[d_1, e_1], \dots , [d_K,e_K],$ and W must all be pairwise coprime, and each of these must be coprime to both a and b. Moreover, if any prime p divides $(a,b)$ , then $p|q(b_{m_2}-b_{m_1})$ . We thus have

$$ \begin{align*} S_3^{(m_1,m_2)}(\nu_0) &= \sum_{\mathbf d, \mathbf e \in \mathcal D_K} \frac {\lambda_{\mathbf d}\lambda_{\mathbf e}}{\log^2 v} \sum_{\substack{a,b \le v \\ (a,q_1) = (b,q_1) = 1 \\ p|a,b \Rightarrow p \equiv 1 \bmod 4}} \frac{\mu(a)\mu(b)}{g_2(a)g_2(b)} \log \frac va \log \frac vb \\ &\quad \times\sum_{\substack{\ell_{m_1}(x)< n \le \ell_{m_1}(2x) \\ n \equiv 1 \bmod 4 \\ n \equiv \alpha \bmod qW\prod_{i\neq m_1,m_2}[d_i,e_i] \\ a[d_{m_1},e_{m_1}]|n \\ b[d_{m_2},e_{m_2}]|n+h}} r_2(n)r_2(n+h), \end{align*} $$

where $\alpha $ is relatively prime to $qW\prod _{i\neq m_1,m_2}[d_i,e_i]$ and $h = q(b_{m_2} - b_{m_1})$ .

We now apply Lemma 11 to estimate the inner sum, taking $r = qW\prod _{i\ne m_1,m_2}[d_i,e_i]$ , $c_1 = a[d_{m_1},e_{m_1}]$ and $c_2=b[d_{m_2},e_{m_2}]$ . Note that Lemma 11 does not require that $c_1$ and $c_2$ be relatively prime, but that the main term is $0$ unless $(c_1,c_2)|h$ . Thus,

$$ \begin{align*} & S_3^{(m_1,m_2)}(\nu_0) = \sum_{\mathbf d, \mathbf e \in \mathcal D_K} \frac {\lambda_{\mathbf d} \lambda_{\mathbf e}}{\log^2 v} \sum_{\substack{a,b \le v \\ (a,q_1) = (b,q_1) = 1 \\ p|a,b \Rightarrow p \equiv 1 \bmod 4}} \frac{\mu(a)\mu(b)}{g_2(a)g_2(b)} \log \frac va \log \frac vb \\ &\quad \times \Bigg[ \pi^2 q x \frac{g_1^2\left(qW\prod_{i\neq m_1,m_2}[d_i,e_i]\right)} {qW\prod_{i\neq m_1,m_2}[d_i,e_i]} \frac{g_2(a[d_{m_1},e_{m_1}])g_2(b[d_{m_2},e_{m_2}])}{a[d_{m_1},e_{m_1}] b [d_{m_2},e_{m_2}] } \\ &\quad \times \sum_{\left(t, 2qW\prod_{i\neq m_1,m_2}[d_i,e_i]\right) = 1}\frac{c_t(h)}{t^2}\frac{(a,t)(b,t)}{\Psi(a,t)\Psi(b,t)} \prod_{i=1,2} \frac{\left([d_{m_i},e_{m_i}],t\right) \chi\left(([d_{m_i},e_{m_i}]^2,t)\right) }{\Psi\left([d_{m_i},e_{m_i}],t\right)} \\ &\quad + O\left(x^{\frac{5}{6} + \epsilon}a^{\frac{1}{2}}b^{\frac{1}{2}} [d_{m_1},e_{m_1}]^{\frac{1}{2}}[d_{m_2},e_{m_2}]^{\frac{1}{2}} \right) \\ &\quad + O\Big( x^{\frac{3}{4} + \epsilon} \Big(qW\prod_{i\neq m_1,m_2}[d_i,e_i]\Big)^{\frac{1}{2}} a b [d_{m_1},e_{m_1}][d_{m_2},e_{m_2}] \Big) \Bigg]. \end{align*} $$

Taking absolute values and noting that $d_{m_i},e_{m_i}\ll R^{\frac {1}{K}}$ , the first error term is bounded by

$$ \begin{align*}\lambda_{\mathrm{max}}^2 |\mathcal D_K|^2 \left( x^{\frac{5}{6} + \epsilon} v^{\frac{3}{2}} R^{\frac{1}{K}} + x^{\frac{3}{4} + \epsilon} v^{2} R^{2}\right) \ll \lambda_{\mathrm{max}}^2 |\mathcal D_K|^2 x^{\frac{5}{6}}v^{2} R^{2}. \end{align*} $$

Using (34) to bound $\lambda _{\mathrm {max}}$ , (37) for $|\mathcal D_K|$ , and the fact that $\theta _1 + \theta _2 < \frac {1}{18}$ , we get that the error term is bounded by

$$ \begin{align*}\ll_{\epsilon'} x^{\frac{5}{6} + 2(\theta_1 + \theta_2) + \epsilon'} \ll x^{\frac{17}{18} + \epsilon'}, \end{align*} $$

which is negligible.

We return to the main term which, after some simplification, and recalling that $g_2(p) = \frac {1}{p}$ for $p\equiv 3 \bmod {4}$ , becomes

(42) $$ \begin{align} \begin{aligned} S_3^{(m_1,m_2)}(\nu_0) &\sim \frac{\pi^2 x g_1^2\left(qW\right)}{W \log^2 v} \sum_{\mathbf d, \mathbf e \in \mathcal D_K} \lambda_{\mathbf d} \lambda_{\mathbf e} \frac{ \prod_{i\neq m_1,m_2}g_1^2\left([d_i,e_i]\right) }{ [d_{m_1},e_{m_1}]^2 [d_{m_2},e_{m_2}]^2 \prod_{i\neq m_1,m_2}[d_i,e_i] } \\ &\times \sum_{\substack{a,b \le v \\ (a,q_1) = (b,q_1) = 1 \\ p|a,b \Rightarrow p \equiv 1 \bmod 4}} \frac{\mu(a)\mu(b)}{a b } \log \frac va \log \frac vb \sum_{\left(t, 2qW\prod_{i\neq m_1,m_2}[d_i,e_i]\right) = 1}\frac{c_t(h)}{t^2} \\ &\times \prod_{i=1,2} \frac{\left([d_{m_i},e_{m_i}],t\right) \chi\left(([d_{m_i},e_{m_i}]^2,t)\right) }{\Psi\left([d_{m_i},e_{m_i}],t\right) } \frac{(a,t)(b,t)}{\Psi(a,t)\Psi(b,t)}. \end{aligned} \end{align} $$

The sum over t is multiplicative, and can thus be written as a product $\Sigma _1 \times \Sigma _3$ , where $\Sigma _1$ ranges over integers divisible only by primes congruent to $1$ mod $4$ and $\Sigma _3$ ranges over integers divisible only by primes congruent to $3$ mod $4$ . That is,

$$ \begin{align*}\Sigma_3 = \sum_{\substack{t\\ p\mid t \Rightarrow p\equiv 3 \bmod 4 \\ (t,q_3W \prod_{i\neq m_1,m_2}[d_i,e_i])=1}} \frac{c_t(h)}{t^2}\prod_{i=1,2} \frac{\left([d_{m_i},e_{m_i}],t\right) \chi\left(([d_{m_i},e_{m_i}]^2,t)\right) }{\Psi\left([d_{m_i},e_{m_i}],t\right) }, \end{align*} $$

and

$$ \begin{align*}\Sigma_1 = \sum_{\substack{t \\ (t,q_1) = 1\\ p\mid t \Rightarrow p\equiv 1 \bmod 4}} \frac{c_t(h)}{t^2} \frac{(a,t)(b,t)}{\Psi(a,t)\Psi(b,t)}. \end{align*} $$

We have used the fact that in $\Sigma _3$ we have $(a,t) = (b,t) = \Psi (a,t) = \Psi (b,t) = 1$ , and in $\Sigma _1$ we have $\left ([d_{m_i},e_{m_i}],t\right ) = \chi \left (([d_{m_i},e_{m_i}]^2,t)\right ) = \Psi \left ([d_{m_i},e_{m_i}],t\right ) = 1$ .

We begin by considering $\Sigma _3$ . Using the definition $c_t(h) = \sum _{t_1|(t,h)} \mu (t/t_1) t_1$ , and swapping sums and relabeling via $t_2 = t/t_1$ , we get

$$ \begin{align*} \Sigma_3 = \sum_{\substack{t_1,t_2 \ {\mathfrak p}|t_1t_2 \Rightarrow p \equiv 3 \bmod 4 \\ (t_1t_2,q_3W\prod_{i\neq m_1,m_2}[d_i,e_i]) = 1 \ {\mathbf t}_1 \mid h}} \frac{t_1 \mu(t_2)}{(t_1t_2)^2} \prod_{i=1,2} \frac{\left([d_{m_i},e_{m_i}],t_1t_2\right) \chi\left(([d_{m_i},e_{m_i}]^2,t_1t_2)\right) }{\Psi\left([d_{m_i},e_{m_i}],t_1t_2\right) }. \end{align*} $$

Any prime $p|h$ with $p \equiv 3 \bmod 4$ divides $q_3W$ , and $t_1|h$ must be co-prime with $q_3W$ , so $t_1 = 1$ . Furthermore, $t_2$ is squarefree due to the term $\mu (t_2)$ , which implies that $\Psi ([d_{m_i},e_{m_i}],t_2) = 1$ . Thus,

$$ \begin{align*} \Sigma_3 &= \sum_{\substack{t_2\ {\mathfrak p}|t_2 \Rightarrow p \equiv 3 \bmod 4\\ (t_2,q_3W\prod_{i\neq m_1,m_2}[d_i,e_i]) = 1}} \frac{ \mu(t_2)}{t_2^2} \prod_{i=1,2} \left([d_{m_i},e_{m_i}],t_2\right) \chi\left(([d_{m_i},e_{m_i}]^2,t_2)\right) \\ &= \prod_{\substack{p\nmid q_3W\prod [d_i,e_i] \\ p\equiv 3 \bmod 4}} \left(1 - \frac{1}{p^2}\right) \prod_{\substack{p\nmid q_3W\prod_{i\neq m_1,m_2} [d_i,e_i] \\ p\mid \prod_{i=1,2}[d_{m_i},e_{m_i}] \\ p\equiv 3 \bmod 4}} \left(1 + \frac{1}{p}\right). \end{align*} $$

Since $q_3W$ is the product of all primes congruent to 3 mod 4 smaller than $D_0$ , we have

$$ \begin{align*} \Sigma_3 &= \prod_{\substack{p>D_0 \\ p\equiv 1 \bmod 4}}\left(1 - \frac{1}{p^2}\right) \prod_{i\neq m_1,m_2}\left(\prod_{p\mid [d_{i},e_{i}]} \left(1 - \frac{1}{p^2}\right)^{-1}\right) g_1([d_{m_1},e_{m_1}])g_1([d_{m_2},e_{m_2}]) \\ &= \left(1 + o(1)\right) g_1([d_{m_1},e_{m_1}])g_1([d_{m_2},e_{m_2}]) \prod_{i\neq m_1,m_2}f\left([d_i,e_i]\right), \end{align*} $$

where $f(n) = \prod _{p\mid n}\left (1 - \frac {1}{p^2}\right )^{-1}$ .

Plugging this back into (42), we get

$$ \begin{align*} &S_3^{(m_1,m_2)}(\nu_0) \\ &\quad \sim \frac{\pi^2 x g_1^2\left(qW\right)}{W \log^2 v} \sum_{\mathbf d, \mathbf e \in \mathcal D_K} \lambda_{\mathbf d} \lambda_{\mathbf e} \frac{ \prod_{i\neq m_1,m_2}g_1^2\left([d_i,e_i]\right)f\left([d_i,e_i]\right) \prod_{i=1,2}g_1\left([d_{m_i},e_{m_i}]\right) }{ [d_{m_1},e_{m_1}]^2 [d_{m_2},e_{m_2}]^2 \prod_{i\neq m_1,m_2}[d_i,e_i] } \\ &\qquad \times \sum_{\substack{a,b \le v \\ (a,q_1) = (b,q_1) = 1 \\ p|a,b \Rightarrow p \equiv 1 \bmod 4}} \frac{\mu(a)\mu(b)}{a b } \log \frac va \log \frac vb \sum_{\substack{t \\ (t,q_1) = 1\\ p\mid t \Rightarrow p\equiv 1 \bmod 4}} \frac{c_t(h)}{t^2} \frac{(a,t)(b,t)}{\Psi(a,t)\Psi(b,t)}. \end{align*} $$

In the notation of Lemma 9, the sum over $\mathbf d$ and $\mathbf e$ (which is independent of $a,b,t$ ) is of the form $S_J$ for $J = \{m_1,m_2\}$ , so that by Lemma 9, we get

$$ \begin{align*} S_3^{(m_1,m_2)}(\nu_0) &\sim \frac{\pi^2 x g_1^2\left(qW\right)}{W \log^2 v} B^{K+2}L_{K;m_1,m_2}(F) \\ &\quad\times \sum_{\substack{a,b \le v \\ (a,q_1) = (b,q_1) = 1 \\ p|a,b \Rightarrow p \equiv 1 \bmod 4}} \frac{\mu(a)\mu(b)}{a b } \log \frac va \log \frac vb \sum_{\substack{t \\ (t,q_1) = 1\\ p\mid t \Rightarrow p\equiv 1 \bmod 4}} \frac{c_t(h)}{t^2} \frac{(a,t)(b,t)}{\Psi(a,t)\Psi(b,t)}. \end{align*} $$

Switching the order of summation gives

(43) $$ \begin{align} S_3^{(m_1,m_2)}(\nu_0) &\sim \frac{\pi^2 x g_1^2\left(qW\right)}{W \log^2 v} B^{K+2}L_{K;m_1,m_2}(F) \\ &\quad \times \sum_{\substack{t \\ (t,q_1) = 1\\ p\mid t \Rightarrow p\equiv 1 \bmod 4}} \frac{c_t(h)}{t^2} \sum_{\substack{a,b \le v \\ (a,q_1) = (b,q_1) = 1 \\ p|a,b \Rightarrow p \equiv 1 \bmod 4}} \frac{\mu(a)\mu(b)}{a b } \frac{(a,t)(b,t)}{\Psi(a,t)\Psi(b,t)} \log \frac va \log \frac vb.\notag \end{align} $$

Denoting the inner sum as $\Sigma _{a,b}(t)$ , we can write

$$ \begin{align*}\Sigma_{a,b}(t) = \Bigg(\sum_{\substack{a \le v \\ (a,q_1)= 1 \\ p|a \Rightarrow p \equiv 1 \bmod 4}} \frac{\mu(a)(a,t)}{a\Psi(a,t)} \log \frac va \Bigg)^2. \end{align*} $$

The calculations from [Reference Hooley9, Lemma 6] (along much the same lines as Lemma 13) imply that

$$ \begin{align*}\Sigma_{a,b}(t) = \left(\frac{8A}{\pi g_1(q_1)} C(t) \log^{\frac{1}{2}} v + O\left( \frac{t^{\frac{1}{4}}}{\log^{\frac{1}{2}} v} \right)\right)^2, \end{align*} $$

where $C(t)$ is the constant in [Reference Hooley9, Lemma 6], given by

$$ \begin{align*} C(t) = \begin{cases}\prod_{\substack{p\mid t \\ p\equiv 1 \bmod 4}}\left(2 - \frac{1}{p}\right)^{-1} &\text{ if }p|t \text{ and }p \equiv 1 \bmod 4\text{ implies } p^2|t \\ 0 &\text{ otherwise.} \end{cases} \end{align*} $$

Note that in [Reference Hooley9, Lemma 6], the Landau–Ramanujan constant is normalized as $\sqrt {2}A$ , and that the statements of [Reference Hooley9, Lemma 5] and [Reference Hooley9, Lemma 6] are missing another factor of $\sqrt {2}$ .

Plugging this estimate back into (43), we get

$$ \begin{align*} S_3^{(m_1,m_2)}(\nu_0) \sim \frac{64 A^2 x g_1^2\left(q_3W\right) B^{K+2}}{W \log v} L_{K;m_1,m_2}(F) \Bigg(\sum_{\substack{t \\ (t,q_1) = 1\\ p\mid t \Rightarrow p\equiv 1 \bmod 4}} \frac{c_t(h)C^2(t)}{t^2} + O\left(E\right)\Bigg), \end{align*} $$

where

$$ \begin{align*} E &\ll \frac{1}{\log v} \sum_{\substack{t \\ (t,q_1) = 1\\ p\mid t \Rightarrow p\equiv 1 \bmod 4}} \frac{|c_t(h)|C(t)}{t^{\frac{7}{4}}} +\frac{1}{\log^2 v}\sum_{\substack{t \\ (t,q_1) = 1\\ p\mid t \Rightarrow p\equiv 1 \bmod 4}} &\frac{|c_t(h)|}{t^{\frac{3}{2}}}\\ & \ll \frac{1}{\log v} \sum_{\substack{t \\ (t,q_1) = 1\\ p\mid t \Rightarrow p\equiv 1 \bmod 4}} \frac{|c_t(h)|}{t^{\frac{3}{2}}}. \end{align*} $$

From [Reference Hooley9, Eq 15], we have that $E \ll \frac {1}{\log v} \sigma _{-\frac {1}{2}}(h)$ , which implies $E \ll \frac {\log \log x}{\log x}$ since $h \leq \eta (\log x)^{\frac {1}{2}}$ . As for the main term, from [Reference Hooley9, Eq 18], we have

$$ \begin{align*} \sum_{\substack{t \\ (t,q_1) = 1\\ p\mid t \Rightarrow p\equiv 1 \bmod 4}} \frac{c_t(h)C^2(t)}{t^2} = \prod_{\substack{p^\beta \| h\\ p\equiv 1 \bmod 4 \\ p\nmid q_1}} \left(1 + \frac{1}{(2p-1)^2}\left(1 - \frac{1}{p^{\beta -1}} - \frac{1}{p^\beta}\right)\right). \end{align*} $$

Thus,

$$ \begin{align*} & S_3^{(m_1,m_2)} \\ &\sim \frac{64 A^2 x g_1^2\left(q_3W\right) B^{K+2}}{W \log v} \prod_{\substack{p^\beta \| b_{m_2} - b_{m_1}\\ p\equiv 1 \bmod 4 \\ p\nmid q_1}} \left(1 + \frac{1}{(2p-1)^2}\left(1 - \frac{1}{p^{\beta -1}} - \frac{1}{p^\beta}\right)\right) L_{K;m_1,m_2}(F). \end{align*} $$

The product over $p^\beta \|(b_{m_2}-b_{m_1})$ is bounded above by V (defined in (15)), so that

$$ \begin{align*} S_3^{(m_1,m_2)}(\nu_0) \le (1+o(1))\frac{64 A^2 x g_1^2\left(q_3W\right) B^{K+2}}{W \log v} V L_{K;m_1,m_2}(F). \end{align*} $$

Finally, using the identity that $B = \frac {2A}{\pi }\frac {\phi (q_3W)(\log R)^{1/2}}{q_3W}$ as well as applying (41) and Lemma 4 completes the proof.

3.7 Estimating $S_4^{(m)}$

In this section, we will prove Theorem 2, equation (20), which we restate in the following proposition.

Proposition 17. For fixed $1 \le m \le K$ , consider the sum $S_4^{(m)}(\nu _0)$ defined by

$$\begin{align*}S_4^{(m)}(\nu_0) = \sum_{\substack{x < n \le 2x \\ n \equiv 1 \bmod 4 \\ n\equiv \nu_0 \bmod W}} \rho^2(\ell_m(n))w_n(\mathcal L).\end{align*}$$

Then

$$\begin{align*}S_4^{(m)}(\nu_0) = (1+o(1)) \frac{8\pi \sqrt{\frac{\log R}{\log v}} \left(\frac{\log x}{\log v} + 1 \right)B^{K}x} {(\pi + 2)\sqrt{K} W} \prod_{\substack{p \equiv 1 \bmod 4 \\ p\nmid q_1}}\left( 1 + \frac{1}{(2p-1)^2}\right) L_K(F).\end{align*}$$

Proof. We first expand the definitions of $w_n(\mathcal L)$ and $\rho ^2(\ell _m(n))$ and swap the order of summation to write

(44) $$ \begin{align} S_4^{(m)}(\nu_0) = \frac 1{\log^2 v} \sum_{\mathbf d, \mathbf e \in \mathcal D_K} \lambda_{\mathbf d}\lambda_{\mathbf e} \sum_{\substack{a,b \le v \\ (a,q_1) = (b,q_1) = 1 \\ p|ab \Rightarrow p \equiv 1 \bmod 4}} \frac{\mu(a)\mu(b)}{g_2(a)g_2(b)} \log\frac va \log \frac vb \sum_{\substack{x < n \le 2x \\ n \equiv 1 \bmod 4 \\ n\equiv \nu_0 \bmod W \\ [d_i, e_i]\mid \ell_i(n) \forall i \\ [a,b]\mid \ell_m(n) \\ }} r_2^2(\ell_m(n)). \end{align} $$

The quantities $W, [d_1,e_1], \dots , [d_k,e_k]$ , q, and $[a,b]$ must be pairwise coprime because of the support of $\mathcal D_K$ . We use Lemma 12 in order to evaluate the inner sum; we will apply Lemma 12 with $r = qW\prod _{i \ne m} [d_i,e_i]$ and $d = [a,b][d_m,e_m]$ . The sum (44) can then be written as

(45) $$ \begin{align} &\frac 1{\log^2 v} \sum_{\mathbf d, \mathbf e \in \mathcal D_K} \lambda_{\mathbf d}\lambda_{\mathbf e} \sum_{\substack{a,b \le v \\ p|ab \Rightarrow p \equiv 1 \bmod 4}} \frac{\mu(a)\mu(b)}{g_2(a)g_2(b)} \log\frac va \log \frac vb \times \\ &\qquad \left( \frac{g_3(r)g_4(d)}{rd} \left( \log qx + A_2 + 2\sum_{p\mid r}g_5(p) -2\sum_{p\mid d}g_6(p)\right) qx + O_\epsilon\left( (qx)^{\frac{3}{4} + \theta_2 + \varepsilon}\right) \right).\notag \end{align} $$

Taking absolute values, the error term from (45) is bounded by

$$ \begin{align*}\ll_{\varepsilon} \lambda_{\mathrm{max}}^2|\mathcal D_K|^2v^2 (qx)^{\frac{3}{4} + \theta_2 + \varepsilon} \ll_{\varepsilon'} x^{\frac{3}{4} + 2(\theta_2 + \theta_1) + \varepsilon'}, \end{align*} $$

where we used (34) to bound the $\lambda _{\mathrm {max}}$ and (37) for $|\mathcal D_K|$ . This error term is negligible, since $\theta _1+\theta _2 < \frac {1}{18}$ .

We now evaluate the main term via a process that is identical to the one in [Reference McGrath15, Proposition 6.2, part (iv)]. Using the notation from Lemma 13, the main term of (45) is

$$ \begin{align*}(1 + o(1)) \frac{g_3(qW) B^{K+1} qx}{W \log^2 v} \left( Z_{x,q_1}^{(1)}\log x - 2Z_{x,q_1}^{(2)} \right) L_{K;m}(F). \end{align*} $$

By Lemma 13, this is equal to

$$ \begin{align*} & (1 + o(1)) \frac{g_3(qW) B^{K+1} qx}{W \log^2 v} \frac{8 A g_7(q_1) }{\phi(q_1)g_1(q_1)} \sqrt{\log v}(\log x + \log v) \\ & \qquad \times \prod_{\substack{p \equiv 1 \bmod 4 \\ p\nmid q_1}}\left( 1 + \frac{1}{(2p-1)^2}\right) L_{K;m}(F)\\ &\quad = (1 + o(1)) \frac{8 A g_3(qW)g_7(q_1)B^{K+1}\log^{\frac{3}{2}}v \left(\frac{\log x}{\log v} + 1 \right) qx} {qW \phi(q_1)g_1(q_1) \log^2 v } \\ &\qquad \times \prod_{\substack{p \equiv 1 \bmod 4 \\ p\nmid q_1}}\left( 1 + \frac{1}{(2p-1)^2}\right) L_{K;m}(F). \end{align*} $$

Recalling the definition of B and equation(41), we get that

$$ \begin{align*} &S_4^{(m)}(\nu_0) \\& \quad = (1+o(1)) \frac{g_3(q_1)g_7(q_1)}{\phi(q_1)g_1(q_1)} \frac{8 B^{k}\sqrt{\frac{\log R}{\log v}} \left(\frac{\log x}{\log v} + 1 \right)x} {W \pi } \prod_{\substack{p \equiv 1 \bmod 4 \\ p\nmid q_1}}\left( 1 + \frac{1}{(2p-1)^2}\right) L_{K;m}(F). \end{align*} $$

Observing that the factors dividing $q_1$ cancel and applying the identity from Lemma 4 that $L_{K;m}(F) = \frac {\pi ^2}{\pi +2}\frac {L_K(F)}{\sqrt K}$ completes the proof.

3.8 Estimating $S_5^{(m)}$

In this section, we will prove Theorem 2, equation (21), which we restate in the following proposition.

Proposition 18. Let $\xi> 0$ be a constant with $\xi < \tfrac 1K$ . For fixed $1 \le m \le K$ , define $S_5^{(m)}(\nu _0)$ to be the sum

$$ \begin{align*} S_5^{(m)}(\nu_0) := \sum_{\substack{x < n \le 2x \\ n \equiv 1 \bmod 4 \\ n \equiv \nu_0 \bmod W}} \sum_{\substack{p < x^\xi \\ p \equiv 3 \bmod 4 \\ p|\ell_m(n)}} w_n(\mathcal L). \end{align*} $$

Then

$$ \begin{align*} S_5^{(m)}(\nu_0) \ll \frac{K^2\xi^2}{\theta_2^2} \frac{B^Kx}{W}L_K(F). \end{align*} $$

The proof of the proposition relies on the following lemma, which we state and prove before turning to the main proof of Proposition 18.

Lemma 19. Define

$$ \begin{align*} T = \frac xW\sum_{\substack{{\mathbf u},{\mathbf v} \in \mathcal D_K}} \frac{y_{{\mathbf u}}y_{{\mathbf v}}}{\phi(u)\phi(v)} \prod_{\substack{p \mid uv}}\left|\sigma_{p}({\mathbf u},{\mathbf v})\right|, \end{align*} $$

where

$$ \begin{align*} \sigma_{p}({\mathbf u},{\mathbf v}) = \sum_{\substack{\mathbf d \mid {\mathbf u},\; \mathbf e \mid {\mathbf v} \\ d_i,e_i \mid p \; \forall i }} \frac{\mu(d)\mu(e) d e}{[\mathbf d, \mathbf e]} = \begin{cases} p - 1 & \text{if } p\mid({\mathbf u},{\mathbf v}) \\ 0 & \text{if } p\mid uv,\,p\nmid ({\mathbf u},{\mathbf v})\\ 1 & \text{if } p \nmid uv \end{cases}. \end{align*} $$

Then

$$ \begin{align*} T \ll \frac{x}{W} \left(\frac{e^{-\gamma /2}}{\Gamma(1/2)}\right)^K \left(\frac{\log R}{\log D_0}\right)^{K/2} L_K(F). \end{align*} $$

Proof. First note that if $u \ne v$ , then for some prime p, $\sigma _{p}({\mathbf u},{\mathbf v}) = 0$ , so these terms do not contribute. Thus, for a fixed ${\mathbf u} \in \mathcal D_K$ ,

$$ \begin{align*} \sum_{\substack{{\mathbf v} \in \mathcal D_K}} \frac{\prod_{p|uv}|\sigma_{p}({\mathbf u},{\mathbf v})|}{\phi(v)} = \prod_{p|u} \Big(\sum_{\substack{\mathbf w \in \mathcal D_K \\ w_i|p \forall i}} \frac{|\sigma_{p}({\mathbf u},\mathbf w)|}{\phi(w)}\Big) = 1. \end{align*} $$

This, along with the bound that $y_{{\mathbf u}}y_{{\mathbf v}} \ll y_{{\mathbf u}}^2 + y_{{\mathbf v}}^2$ , implies that

$$ \begin{align*} T \ll \frac{x}{W}\sum_{{\mathbf u},{\mathbf v} \in \mathcal D_K} \frac{y_{{\mathbf u}}^2 + y_{{\mathbf v}}^2}{\phi(u)\phi(v)}\prod_{\substack{p|uv }} |\sigma_{p}({\mathbf u},{\mathbf v})| &\ll \frac{x}{W}\sum_{{\mathbf u}\in\mathcal D_K} \frac{y_{{\mathbf u}}^2} {\phi(u)} \left( \sum_{\substack{{\mathbf v} \in \mathcal D_K}} \frac{\prod_{p|uv}|\sigma_{p}({\mathbf u},{\mathbf v})|}{\phi(v)} \right) \\ &\ll \frac{x}{W}\sum_{{\mathbf u}\in\mathcal D_K} \frac{y_{{\mathbf u}}^2} {\phi(u)}. \end{align*} $$

By Lemma 7,

$$ \begin{align*} \sum_{{\mathbf r} \in \mathcal D_K} \frac{y_{{\mathbf r}}^2}{\phi(r)} &= \sum_{{\mathbf r} \in \mathcal D_K} \frac{\mu(r)^2}{\phi(r)}\prod_{i=1}^K g\left(K\frac{\log r_1}{\log R}\right)^2 \ll \left(\frac{e^{-\gamma /2}}{\Gamma(1/2)}\right)^K \left(\frac{\log R}{\log D_0}\right)^{K/2} L_K(F), \end{align*} $$

as desired.

We are now ready to prove Proposition 18.

Proof of Proposition 18.

Expanding the square and swapping the order of summation gives

$$ \begin{align*} S_5^{(m)}(\nu_0) = \sum_{\substack{p < x^\xi \\ p \equiv 3 \bmod 4}} \sum_{\mathbf d, \mathbf e \in \mathcal{D}_K} \lambda_{\mathbf d}\lambda_{\mathbf e} \sum_{\substack{x < n \le 2x \\ n \equiv 1 \bmod 4 \\ n \equiv \nu_0 \bmod W \\ [d_i,e_i]|\ell_i(n) \\ p|\ell_m(n)}} 1. \end{align*} $$

By choice of $\nu _0 \bmod W$ , if $p|\ell _m(n)$ , then $p> D_0$ . Because of the support of $\mathcal {D}_K$ , if $\lambda _{\mathbf d} \ne 0$ and $\lambda _{\mathbf e} \ne 0$ , then any prime $p \equiv 3 \bmod 4$ can divide at most one of the $\ell _i(n)$ . Thus, if $p|\ell _m(n)$ , then $p \nmid \ell _i(n)$ for all $i \ne m$ , which implies that $(d_ie_i,p) = 1$ for all $i \ne m$ . By the Chinese remainder theorem, the inner sum is of the form $\frac xQ + O(1)$ , where $Q = 4W[d_m,e_m,p]\prod _{i \ne m} [d_i,e_i].$ Note that $Q < 4WR^2x^\xi $ , and for any fixed Q, there are $O(\tau _{3k+4}(Q))$ choices of $\mathbf d,\mathbf e, p$ giving rise to the modulus Q. Thus, the error term from the Chinese remainder theorem application and (34) makes a contribution that is

$$ \begin{align*} &\ll \sum_{Q < 4WR^2x^\xi} \tau_{3k+4}(Q) \lambda_{\mathrm{max}}^2 \ll_\varepsilon R^2x^{\xi}x^\varepsilon = x^{\theta_2 + \xi + \varepsilon}, \end{align*} $$

which is negligible for $\xi $ small.

The remaining term is given by

$$ \begin{align*} &\frac x{4W} \sum_{\substack{D_0 < p < x^\xi \\ p \equiv 3 \bmod 4}} \frac 1p \sum_{\substack{\mathbf d, \mathbf e \in \mathcal{D}_K \\ (d_ie_i,p) = 1 \forall i \ne m}} \frac{\lambda_{\mathbf d}\lambda_{\mathbf e}p}{[d_m,e_m,p]\prod_{i\ne m}[d_i,e_i]}. \end{align*} $$

Expanding the definitions of $\lambda _{\mathbf d}, \lambda _{\mathbf e}$ and rearranging, this is

(46) $$ \begin{align} \begin{aligned} &\frac{x}{4W}\sum_{\substack{D_0 < p < x^\xi \\ p \equiv 3 \bmod 4}} \frac 1p \sum_{\substack{\mathbf d, \mathbf e \in \mathcal{D}_K \\ (d_ie_i,p) = 1 \forall i \ne m}} \frac{\mu(d)\mu(e)dep}{[d_m,e_m,p]\prod_{i\ne m}[d_i,e_i]} \sum_{\substack{\mathbf r, \mathbf s \in \mathcal{D}_K \\ \mathbf d|\mathbf r,\mathbf e|\mathbf s}} \frac{y_{\mathbf r} y_{\mathbf s}}{\phi(r)\phi(s)} \\ = &\frac{x}{4W}\sum_{\substack{D_0 < p < x^\xi \\ p \equiv 3 \bmod 4}} \frac 1p \sum_{\substack{\mathbf r, \mathbf s \in \mathcal{D}_K}} \frac{y_{\mathbf r} y_{\mathbf s}}{\phi(r)\phi(s)} \sum_{\substack{\mathbf d, \mathbf e \in \mathcal{D}_K \\ (d_ie_i,p) = 1 \forall i \ne m \\ \mathbf d|\mathbf r, \mathbf e|\mathbf s}} \frac{\mu(d)\mu(e)dep}{[d_m,e_m,p]\prod_{i\ne m}[d_i,e_i]}. \end{aligned} \end{align} $$

The inside sum is multiplicative over $p'|rs$ ; write $\sigma _{p'}(\mathbf r, \mathbf s,p)$ for the $p'$ component. If $p'\ne p$ , then

$$ \begin{align*} \sigma_{p'}({\mathbf r},{\mathbf s},p) =\sum_{\substack{\mathbf d, \mathbf e \in \mathcal{D}_K \\ d_i,e_i \mid p' \; \forall i \\ \mathbf d|\mathbf r, \mathbf e|\mathbf s}} \frac{\mu(d)\mu(e)dep}{[d_m,e_m,p]\prod_{i\ne m}[d_i,e_i]} = \begin{cases} p'-1 &\text{ if } p'|({\mathbf r},{\mathbf s}) \\ -1 &\text{ if } p'|r, p'|s, p'\nmid ({\mathbf r},{\mathbf s}) \\ 0 &\text{ otherwise,} \end{cases} \end{align*} $$

where we recall that $({\mathbf r},{\mathbf s}) = \prod _{i}(r_i,s_i)$ . If $p'= p$ , then

$$ \begin{align*} \sigma_p({\mathbf r},{\mathbf s},p) = \sum_{\substack{\mathbf d, \mathbf e \in \mathcal{D}_K \\ d_m,e_m \mid p \\ d_i=e_i=1 \; \forall i \neq m \\ \mathbf d|\mathbf r, \mathbf e|\mathbf s}} \frac{\mu(d)\mu(e)dep}{[d_m,e_m,p]\prod_{i\ne m}[d_i,e_i]} =\begin{cases} (p-1)^2 &\text{ if } p|(r_m,s_m) \\ -(p-1) &\text{ if } p|r_ms_m, p\nmid(r_m,s_m) \\ 1 &\text{ otherwise.}\end{cases}. \end{align*} $$

Let $f_{\mathbf u}({\mathbf r}) = (r_1,\dots , r_m/(r_m,p), \dots , r_k)$ be the vector formed by removing a possible factor of p from $r_m$ . Then our expression (46) can be written as

$$ \begin{align*} &\frac{x}{4W}\sum_{\substack{D_0 < p < x^\xi \\ p \equiv 3 \bmod 4}} \frac 1p\sum_{\substack{\mathbf{u}, \mathbf s \in \mathcal{D}_K \\ (u_m,p) = 1}} \frac{y_{\mathbf s}}{\phi(s)} \sum_{\substack{{\mathbf r} \\ f_{\mathbf u}({\mathbf r}) = {\mathbf u}}} \frac{ y_{{\mathbf r}}}{\phi(r)} \prod_{p'|rs} \sigma_{p'}({\mathbf r},{\mathbf s},p). \end{align*} $$

We split the sum above into several parts. Let $\Sigma _1$ be the summands where $p|u_j$ for some $j \ne m$ , and let $\Sigma _2$ be the summands where $p\nmid u_i$ for all i. Define

(47) $$ \begin{align} T = \frac xW \sum_{\substack{{\mathbf u},{\mathbf v} \in \mathcal{D}_K}} \frac{y_{{\mathbf u}}y_{{\mathbf v}}}{\phi(u)\phi(v)} \prod_{\substack{p' \mid uv}}\left|\sigma_{p'}({\mathbf u},{\mathbf v})\right|, \end{align} $$

where

$$ \begin{align*} \sigma_{p'}({\mathbf u},{\mathbf v}) = \sum_{\substack{\mathbf d \mid {\mathbf u},\; \mathbf e \mid {\mathbf v} \\ d_i,e_i \mid p' \; \forall i }} \frac{\mu(d)\mu(e) d e}{[\mathbf d, \mathbf e]}.\end{align*} $$

We will bound both $\Sigma _1$ and $\Sigma _2$ in terms of T, showing first that $\Sigma _1 \ll \frac 1{D_0}T$ . We have

$$ \begin{align*} \Sigma_1 = \frac x{4W}\sum_{\substack{D_0 < p < x^\xi \\ p \equiv 3 \bmod 4}} \frac 1p \sum_{i\neq m} \sum_{\substack{\mathbf u, \mathbf s \in \mathcal{D}_K \\ (u_m,p) = 1 \\ p|u_i}} \frac{y_{\mathbf s}}{\phi(s)} \sum_{\substack{{\mathbf r} \\ f_{\mathbf u}({\mathbf r}) = {\mathbf u}}} \frac{y_{{\mathbf r}}}{\phi(r)} \sigma_p({\mathbf r},{\mathbf s}, p)\prod_{\substack{p'\mid rs \\ p' \ne p}}\sigma_{p'}({\mathbf r},{\mathbf s},p). \end{align*} $$

Given $\mathbf u$ , there is only one vector ${\mathbf r}$ such that $f_{\mathbf u}({\mathbf r}) = {\mathbf u}$ ; namely, ${\mathbf r} = {\mathbf u}$ . Thus,

$$ \begin{align*} \Sigma_1 = \frac x{4W}\sum_{\substack{D_0 < p < x^\xi \\ p \equiv 3 \bmod 4}} \frac 1p \sum_{i\neq m} \sum_{\substack{\mathbf u, \mathbf s \in \mathcal{D}_K \\ (u_m,p) = 1 \\ p|u_i}} \frac{y_{\mathbf s} y_{{\mathbf u}}}{\phi(s)\phi(u)} \sigma_p({\mathbf u},{\mathbf s}, p)\prod_{\substack{p'\mid us \\ p' \ne p}}\sigma_{p'}({\mathbf u},{\mathbf s}). \end{align*} $$

Denote by ${\mathbf u}'$ the vector obtained from ${\mathbf u}$ by removing all factors of p. Then $\phi (u) = (p-1)\phi (u')$ and $\sigma _p({\mathbf u},{\mathbf s},p) = \sigma _p({\mathbf u}',{\mathbf s},p) = \mu ((s_m,p))\phi ((s_m,p))$ , which is independent of ${\mathbf u}$ because we already require $(u_m,p) = 1$ . Thus,

$$ \begin{align*} \Sigma_1 = \frac x{4W} \sum_{{\mathbf s} \in \mathcal{D}_K} \frac{y_{{\mathbf s}}}{\phi(s)} \sum_{\substack{D_0 < p < x^\xi \\ p \equiv 3 \bmod 4}} \frac 1p \sum_{\substack{{\mathbf u}' \in \mathcal{D}_K \\ p\nmid u_i^{\prime}}} \frac{1}{\phi(u')} \sigma_p({\mathbf u}',{\mathbf s},p) \prod_{\substack{p'\mid u's\\ p'\ne p}}\sigma_{p'}({\mathbf u}',{\mathbf s}) \sum_{\substack{{\mathbf u} \in \mathcal{D}_K\\ {\mathbf u}\rightarrow{\mathbf u}'}} \frac{y_{{\mathbf u}}}{(p-1)}. \end{align*} $$

By Lemma 5, we have $y_{{\mathbf u}} = y_{{\mathbf u}'}\left ( 1+ O\left (K\xi \right )\right )$ . By assumption, $K\xi \ll 1$ , so (recalling that the weights $y_{{\mathbf r}}$ are nonnegative), $y_{{\mathbf u}} \ll y_{{\mathbf u}'}$ and

$$ \begin{align*} \Sigma_1 \ll \frac xW (K-1) \sum_{{\mathbf s} \in \mathcal{D}_K} \frac{y_{{\mathbf s}}}{\phi(s)} \sum_{\substack{D_0 < p < x^\xi \\ p \equiv 3 \bmod 4}} \frac 1 {p(p-1)} \sum_{\substack{{\mathbf u}' \in \mathcal{D}_K \\ p\nmid u_i^{\prime}}} \frac{ y_{{\mathbf u}'}}{\phi(u')} |\sigma_p({\mathbf u}',{\mathbf s},p)| \prod_{\substack{p'\mid u's\\ p'\ne p}}|\sigma_{p'}({\mathbf u}',{\mathbf s})|. \end{align*} $$

To bound $\Sigma _1$ , we now further split it into subsums. First, let $T_1$ consist of all those terms with ${\mathbf s}$ such that $p \nmid s_i$ for all i. In this case, $\sigma _p({\mathbf u}',{\mathbf s}, p) = 1$ , so

$$ \begin{align*} T_1 \ll \frac xW(K-1) \sum_{\substack{D_0 < p < x^\xi \\ p \equiv 3 \bmod 4}} \frac 1 {p(p-1)} \sum_{\substack{{\mathbf s} \in \mathcal{D}_K \\ p\nmid s_i \; \forall i}} \frac{y_{{\mathbf s}}}{\phi(s)} \sum_{\substack{{\mathbf u}'\in \mathcal{D}_K \\ p\nmid u_i^{\prime} \; \forall i}} \frac{y_{{\mathbf u}'}}{\phi(u')} \prod_{\substack{p'\mid u's}}\left|\sigma_{p'}({\mathbf u}',{\mathbf s})\right|. \end{align*} $$

Dropping the requirement that $p\nmid s_i$ , $p\nmid u^{\prime }_i$ only increases $T_1$ . The sum over p is then independent of the rest of the expression, and converges to a constant that is $\ll \frac 1{D_0}$ , which in turn implies that $T_1 \ll \frac K{D_0}T$ , where T is defined in (47).

Now consider $T_2$ , the terms ${\mathbf s}$ in $\Sigma _1$ such that $p\mid s_i$ for some $i\neq m$ . In this case, $\sigma _p({\mathbf u}',{\mathbf s}, p) = 1$ , so

$$ \begin{align*} T_2 \ll \frac xW (K-1)^2 \sum_{D_0 < p < x^\xi} \frac 1 {p(p-1)} \sum_{\substack{{\mathbf s} \in \mathcal{D}_K \\ p\mid s_1}} \frac{y_{{\mathbf s}}}{\phi(s)} \sum_{\substack{{\mathbf u}' \in \mathcal{D}_K \\ p\nmid u_i^{\prime} \; \forall i}} \frac{y_{{\mathbf u}'}}{\phi(u')} \prod_{\substack{p'\mid u's \\ p' \ne p}}\left|\sigma_{p'}({\mathbf u}',{\mathbf s})\right|. \end{align*} $$

Let ${\mathbf s}'$ be the vector obtained by removing the factor of p from ${\mathbf s}$ . Once again, $y_{{\mathbf s}} \ll y_{{\mathbf s}'}$ , so

$$ \begin{align*} T_2 \ll \frac xW (K-1)^2 \sum_{\substack{D_0 < p < x^\xi \\ p \equiv 3 \bmod 4}} \frac 1 {p(p-1)^2} \sum_{\substack{{\mathbf s}'\in \mathcal{D}_K \\ p\nmid s_i \; \forall i}} \frac{y_{{\mathbf s}'}}{\phi(s')} \sum_{\substack{{\mathbf u}'\in \mathcal{D}_K \\ p\nmid u_i^{\prime} \; \forall i}} \frac{y_{{\mathbf u}'}}{\phi(u')} \prod_{\substack{p'\mid u's}}\left|\sigma_{p'}({\mathbf u}',{\mathbf s})\right|. \end{align*} $$

Once more, we can remove the constraints that $p\nmid s_i$ and $p\nmid u^{\prime }_i$ and evaluate the sum over p to get that $T_2 \ll \frac {K^2}{D_0^2} T$ .

Finally, consider $T_3$ , the subsum of $\Sigma _1$ with those ${\mathbf s}$ such that $p\mid s_m$ . In this case, $\sigma _p({\mathbf u}',{\mathbf s}, p) = -(p-1)$ . A similar computation gives

$$ \begin{align*} T_3 \ll \frac xW \sum_{\substack{D_0 < p < x^\xi \\ p \equiv 3 \bmod 4}} \frac 1 {p(p-1)^2} \sum_{\substack{{\mathbf s}'\in \mathcal{D}_K \\ p\nmid s_i \; \forall i}} \frac{y_{{\mathbf s}'}}{\phi(s')} \sum_{\substack{{\mathbf u}'\in \mathcal{D}_K \\ p\nmid u_i^{\prime} \; \forall i}} \frac{y_{{\mathbf u}'}}{\phi(u')} (p-1) \prod_{\substack{p'\mid u's}}\left|\sigma_{p'}({\mathbf u}',{\mathbf s})\right| \ll \frac{1}{D_0}T. \end{align*} $$

Thus, $|\Sigma _1| \ll T_1 + T_2 + T_3 \ll \frac {K^2}{D_0} T$ .

Now consider $\Sigma _2$ , given by

$$ \begin{align*} \Sigma_2 = \frac x{4W} \sum_{\substack{D_0 < p < x^\xi \\ p \equiv 3 \bmod 4}} \frac 1p \sum_{\substack{{\mathbf u},{\mathbf s} \in \mathcal D_K \\ (u_i,p) = 1 \forall i}} \frac{y_{{\mathbf s}}}{\phi(s)} \sum_{\substack{{\mathbf r} \in \mathcal D_K \\ f_{{\mathbf u}}({\mathbf r}) = {\mathbf u}}} \frac{y_{{\mathbf r}}}{\phi(r)} \prod_{p'|rs} \sigma_{p'}({\mathbf r},{\mathbf s},p). \end{align*} $$

Observe that for fixed ${\mathbf u}, {\mathbf s} \in \mathcal {D}_K$ with $p\nmid u_i$ for all i,

(48) $$ \begin{align} \sum_{\substack{{\mathbf r} \in \mathcal{D}_K \\ f_{{\mathbf u}}({\mathbf r})={\mathbf u}}} \frac{\sigma_p({\mathbf r},{\mathbf s},p)}{\phi(r)} = \frac{\mu((s_m,p))\phi((s_m,p))}{\phi(u)}\left(1 -\frac{p-1}{p-1}\right) = 0. \end{align} $$

We substitute $y_{{\mathbf r}} = y_{{\mathbf u}} + (y_{{\mathbf r}}-y_{{\mathbf u}})$ into $\Sigma _2$ . By (48), the $y_{{\mathbf u}}$ do not contribute, leaving only the contribution from $(y_{{\mathbf r}}-y_{{\mathbf u}})$ . The only terms remaining have ${\mathbf r} \ne {\mathbf u}$ , so that $p|r_m$ . Thus,

$$ \begin{align*} \Sigma_2= &\frac x{4W}\sum_{\substack{D_0 < p < x^\xi \\ p \equiv 3 \bmod 4}} \frac 1p\sum_{\substack{\mathbf r, \mathbf s \in \mathcal{D}_K \\ p|r_m}} \frac{y_{\mathbf s}(y_{{\mathbf r}}-y_{{\mathbf u}})}{\phi(r)\phi(s)}\prod_{p'|rs} \sigma_{p'}({\mathbf r},{\mathbf s},p). \end{align*} $$

By running the same argument for ${\mathbf s}$ and a tuple ${\mathbf v}$ obtained from ${\mathbf s}$ by removing a factor of p from $s_m$ (including bounding the terms where $p|v_i$ for some $i \ne m$ by $\frac {K^2}{D_0}T$ using identical arguments to the bound on $\Sigma _1$ ), we can also replace $y_{{\mathbf s}}$ by $y_{{\mathbf s}}-y_{{\mathbf v}}$ . By Lemma 5, we have

$$ \begin{align*} (y_{{\mathbf r}}-y_{{\mathbf u}})(y_{{\mathbf s}}-y_{{\mathbf v}}) \ll y_{{\mathbf u}}y_{{\mathbf v}}K^2 \frac{(\log p)^2}{(\log R)^2}, \end{align*} $$

so $\Sigma _2$ is given by

$$ \begin{align*} \Sigma_2 =&\frac x{4W}\sum_{\substack{D_0 < p < x^\xi \\ p \equiv 3 \bmod 4}} \frac 1p \sum_{\substack{{\mathbf r},{\mathbf s} \in \mathcal{D}_K \\ p|(r_m,s_m)}} \frac{(y_{{\mathbf r}}-y_{{\mathbf u}})(y_{{\mathbf s}}-y_{{\mathbf v}})}{\phi(r)\phi(s)} \prod_{p'|rs} \sigma_{p'}({\mathbf r},{\mathbf s},p) + O\left(\frac{K^2T}{D_0}\right) \\\ll &\frac{xK^2}{W} \sum_{\substack{D_0 < p < x^\xi \\ p \equiv 3 \bmod 4}} \frac 1p\left(\frac{\log p}{\log R}\right)^2 \sum_{\substack{{\mathbf u}, {\mathbf v} \in \mathcal{D}_K \\(uv,p) = 1}} y_{{\mathbf u}}y_{{\mathbf v}} \prod_{\substack{p'|uv \\ p'\ne p}} |\sigma_{p'}({\mathbf u},{\mathbf v})|\sum_{\substack{{\mathbf r},{\mathbf s} \in \mathcal{D}_K \\ r_m = pu_m \\ s_m = pv_m \\ r_i = u_i \forall i\neq m \\ s_i = v_i \forall i\neq m}}\frac{|\sigma_p({\mathbf r},{\mathbf s},p)|}{\phi(r)\phi(s)} + \frac{K^2T}{D_0}. \end{align*} $$

The sum over ${\mathbf r}$ and ${\mathbf s}$ is equal to $\phi (u)^{-1}\phi (v)^{-1}$ , so

$$ \begin{align*} \Sigma_2 &\ll \frac{xK^2}{W} \sum_{\substack{D_0 < p < x^\xi\\ p \equiv 3 \bmod 4}} \frac 1p\left(\frac{\log p}{\log R}\right)^2 \sum_{\substack{{\mathbf u}, {\mathbf v} \in \mathcal{D}_K \\ (uv,p) = 1}} \frac{y_{{\mathbf u}}y_{{\mathbf v}}}{\phi(u)\phi(v)} \prod_{\substack{p'|uv \\ p'\ne p}} |\sigma_{p'}({\mathbf u},{\mathbf v})| + \frac{K^2T}{D_0} \\ & \ll \frac{xK^2\xi^2}{W\theta_2^2} \sum_{\substack{{\mathbf u}, {\mathbf v} \in \mathcal{D}_K}} \frac{y_{{\mathbf u}}y_{{\mathbf v}}}{\phi(u)\phi(v)} \prod_{\substack{p'|uv}} |\sigma_{p'}({\mathbf u},{\mathbf v})| + \frac{KT}{D_0} \ll \left(K^2\frac{\xi^2}{\theta_2^2} + \frac{K^2}{D_0}\right) T. \end{align*} $$

Altogether, we get that $S_5^{(m)}(\nu _0) \ll \left (\frac {K^2\xi ^2}{\theta _2^2} + \frac {K^2}{D_0}\right )T$ . The contribution from the $\frac {K^2}{D_0}$ term vanishes as x grows large. The quantity T is evaluated in Lemma 19, giving

$$ \begin{align*} S_5^{(m)}(\nu_0) &\ll \frac{xK^2\xi^2}{W\theta_2^2} \left(\frac{e^{-\gamma /2}}{\Gamma(1/2)}\right)^K \left(\frac{\log R}{\log D_0}\right)^{K/2} L_K(F). \end{align*} $$

From the definition of B and Mertens’ theorem, we get

$$ \begin{align*}\left(\frac{e^{-\gamma /2}}{\Gamma(1/2)}\right)^K \left(\frac{\log R}{\log D_0}\right)^{K/2} \sim B^k, \end{align*} $$

which completes the argument.

3.9 Estimating $S_6^{(b)}$

In this section, we will prove Theorem 2, equation (22), which we restate in the following proposition.

Proposition 20. Let $\nu _1$ be a congruence class modulo $q_3^2W^2$ such that $(\ell (\nu _1),q_3^2W^2)$ is a square for all $\ell \in \mathcal L$ . Fix $3 < b \le \eta \sqrt {\log x}$ and consider the linear form $\ell ^{(b)}(n) := qn+b$ . Fix a constant $\xi $ with $0 < \xi < 1/4$ , and define

$$\begin{align*}S_6^{(b)}(\nu_1) := \sum_{\substack{x < n \le 2x \\ n \equiv 1 \bmod 4 \\ n \equiv \nu_1 \bmod q_3^2W^2}} \mathbf 1_{S(\xi)}(\ell^{(b)}(n)) w_n(\mathcal L),\end{align*}$$

where $S(\xi )$ is the set described in (11). Then

$$\begin{align*}S_6^{(b)}(\nu_1) \ll_K \frac{x}{4q_3^2W^2}\xi^{-1/2} \left(\frac{\theta_2}{2}\right)^{-1/2} \left(\frac{\log R}{\log D_0}\right)^{\frac{K-1}{2}} L_K(F). \end{align*}$$

Proof. We will apply Selberg’s sieve to bound the function $\mathbf 1_{S(\xi )}(\ell (n))$ , while also evaluating the sum over sieve weights $w_n(\mathcal L)$ . We begin by defining the additional sieve weights.

Recall that $S(\xi )$ denotes the set of integers such that for all primes $p < x^{\xi }$ with $p \equiv 3 \bmod 4$ , either $p \nmid n$ or $p^2|n$ . Thus, for each prime $p \equiv 3 \bmod 4$ , with $D_0 < p < x^{\xi }$ , we sieve by the set $\mathcal A_p$ of integers $x \le n \le 2x$ such that $p \mid \ell (n)$ but $p^2\nmid \ell (n)$ . The sieving set $\mathcal A_p$ has density function

$$ \begin{align*} g(p) &= \begin{cases} \frac{1}{p} - \frac{1}{p^2}& p> D_0 \text{ and } p\equiv3 \bmod 4 \\ 0 & \text{otherwise.} \end{cases} \end{align*} $$

We extend both $g(p)$ and $\mathcal A_p$ multiplicatively to squarefree d, so that

$$ \begin{align*}|r_d| := |\mathcal{A}_d - g(d) x| \ll \tau(d). \end{align*} $$

We will use the upper bound Selberg sieve

$$ \begin{align*} \mathbf 1_{\mathcal S(\xi)}(\ell(n)) \le \sum_{f|\ell(n)} \mu^+(f)|\mathcal A_f|, \end{align*} $$

where

$$ \begin{align*} \mu^+(f) = \frac{1}{\tilde{\lambda_{1}}^2}\sum_{[d_0,e_0] = f}\tilde{\lambda_{d_0}} \tilde{\lambda_{e_0}}, \end{align*} $$

and $\tilde {\lambda _d}$ is a sequence of weights defined as follows. Define ‘diagonalizing vectors’ $\tilde {y_{r_0}}$ via

$$ \begin{align*} \tilde{y_{r_0}} := \begin{cases} 1 &\text{ if } (r_0,q_3W) = 1, r_0 < x^{\xi}, \text{ and } p|r_0 \Rightarrow p \equiv 3 \bmod 4 \\ 0 &\text{ otherwise,}\end{cases} \end{align*} $$

and define $\tilde {\lambda _{d_0}}$ to be

(49) $$ \begin{align} \tilde{\lambda_{d_0}} := \mu(d_0) \frac{d_0^2}{\phi(d_0)} \sum_{d_0|r_0} \frac{\tilde{y_{r_0}}}{\phi(r_0)}. \end{align} $$

By Möbius inversion, we also have the relation that

$$ \begin{align*} \tilde{y_{r_0}} = \mu(r_0)\phi(r_0)\sum_{r_0|d_0} \frac{\tilde{\lambda_{d_0}}\phi(d_0)}{d_0^2}. \end{align*} $$

Note that $\tilde {\lambda _{d_0}}$ is supported on squarefree $d_0$ with $(d_0,q_3W) = 1$ , $d_0<x^{\xi }$ , and $d_0$ only divisible by primes congruent to $3$ mod $4$ . Also, with this choice,

(50) $$ \begin{align} \tilde{\lambda_{1}} = \sum_{\substack{r_0 < x^{\xi} \\ (r_0,q_3W) = 1 \\ p|r_0 \Rightarrow p \equiv 3 \bmod 4}} \frac{1}{\phi(r_0)} \gg \sqrt{\frac{\xi \log x}{\log D_0}}.\end{align} $$

For what follows, we will fix the notation that

$$ \begin{align*} \phi_{\omega^{*}}(n) = n\prod_{p\mid n}\left(1 - \frac{K+1 }{p}\right), \end{align*} $$

and define further ‘cross’-diagonalizing vectors

(51) $$ \begin{align} y_{{\mathbf r},r_0} := \mu(r_0r)\phi_{\omega^{*}}(r_0r) \sum_{\substack{{\mathbf r}|\mathbf d \\ r_0|d_0\\ (d_0,d) = 1}} \frac{\lambda_{\mathbf d}\tilde{\lambda}_{d_0}\phi(d_0)}{dd_0^2}, \end{align} $$

which satisfy the inverse relation that

(52) $$ \begin{align} \lambda_{\mathbf d}\tilde{\lambda_{d_0}} = \frac{\mu(d_0d)dd_0^2}{\phi(d_0)} \sum_{\substack{\mathbf d|\mathbf r \\ d_0|r_0 \\ (r_0,r) = 1}} \frac{y_{\mathbf r,r_0}}{\phi_{w^{*}}(r_r)}. \end{align} $$

We are now ready to apply Selberg’s sieve, which gives that

$$ \begin{align*} S_6^{(b)}(\nu_1) &\leq \frac{1}{\tilde{\lambda_{1}}^2} \sum_{d_0,e_0, \mathbf d, \mathbf e} \tilde{\lambda_{d_0}} \tilde{\lambda_{e_0}} \lambda_{\mathbf d} \lambda_{\mathbf e} \sum_{\substack{x < n \le 2x \\ [d_i,e_i]|\ell_i(n) \\ p\mid d_0e_0 \Rightarrow p\|\ell(n) \\ n \equiv 1 \bmod 4 \\ n \equiv \nu_1 \bmod q_3^2W^2}} |\mathcal A_{[d_0,e_0]}| \\ &= \frac{1}{\tilde{\lambda_{1}}^2} \sum_{\substack{d_0,e_0, \mathbf d, \mathbf e \\ (d_0e_0,de) = 1}} \tilde{\lambda_{d_0}} \tilde{\lambda_{e_0}} \lambda_{\mathbf d} \lambda_{\mathbf e} \left(\frac{xg([d_0,e_0])}{4q_3^2W^2 \prod_{i=1}^K [d_i,e_i]} + O(\tau([d_0,e_0]))\right). \end{align*} $$

The contribution from the $O(\tau ([d_0,e_0]))$ term satisfies

$$ \begin{align*} \frac 1{\tilde{\lambda_1}^2} \sum_{\substack{d_0,e_0,\mathbf d, \mathbf e \\ (d_0e_0,de) = 1}} |\tilde{\lambda_{d_0}}||\tilde{\lambda_{e_0}}||\lambda_{\mathbf d}||\lambda_{\mathbf e}| \tau([d_0,e_0]) &\ll R^{2+o(1)} \frac 1{\tilde{\lambda_1}^2} \sum_{\substack{d_0,e_0}} |\tilde{\lambda_{d_0}}||\tilde{\lambda_{e_0}}| \tau([d_0,e_0]). \end{align*} $$

By construction of $\tilde {\lambda _{1}}$ and $\tilde {\lambda _{d_0}}$ , we always have that $|\tilde {\lambda _{d_0}}|/|\tilde {\lambda _1}| \le \frac {d_0^2}{\phi (d_0)^2}$ . Thus, this term contributes $\ll _\varepsilon R^{2+\varepsilon }x^{2\xi +\varepsilon } \ll x^{\theta _2 + 2\xi +2\varepsilon }$ , which is negligible since $\xi < 1/4$ .

The remaining ‘main’ term is given by

(53) $$ \begin{align} \frac{x}{4q_3^2W^2\tilde{\lambda_{1}}^2} \sum_{\substack{d_0,e_0 \\(d_0,e_0,q_3W) = 1}} \tilde{\lambda_{d_0}}\tilde{\lambda_{e_0}} g([d_0,e_0]) \sum_{\substack{\mathbf d, \mathbf e \in \mathcal D_K\\ (de,d_0e_0) = 1}} \frac{\lambda_{\mathbf d}\lambda_{\mathbf e}}{\prod_{i=1}^K [d_i,e_i]}. \end{align} $$

Substituting the formula (52) for $\lambda _{\mathbf d}\tilde {\lambda _{d_0}}$ into (53), we get that (53) is equal to

$$ \begin{align*} &= \frac{x}{4q_3^2W^2\tilde{\lambda_{1}}^2} \sum_{\substack{\mathbf d, \mathbf e \in \mathcal{D}_K \\ d_0,e_0 \\ (d_ie_i, d_je_j) = 1 \; \forall 0\leq i < j \leq k}} \frac{\mu(d_0 d)\mu(e_0 e)d_0^2 d e_0^2 e g([d_0, e_0])}{[\mathbf{d}, \mathbf{e}]\phi(d_0)\phi(e_0)} \\ &\quad \times\sum_{\substack{\mathbf d \mid \mathbf r , \mathbf e \mid \mathbf s \\ d_0\mid r_0, e_0\mid s_0 }} \frac{y_{{\mathbf r},r_0} y_{{\mathbf s},s_0}}{\phi_{\omega^{*}}(r_0r) \phi_{\omega^{*}}(s_0s)} \\ &= \frac{x}{4q_3^2W^2\tilde{\lambda_{1}}^2} \sum_{\substack{\mathbf r, \mathbf s \in \mathcal{D}_K \\ r_0,s_0 \\ (r_0s_0, rs) = 1}} \frac{y_{{\mathbf r},r_0} y_{{\mathbf s},s_0}}{\phi_{\omega^{*}}(r_0r) \phi_{\omega^{*}}(s_0s)} \\ &\quad \times \sum_{\substack{\mathbf d \mid \mathbf r,\; \mathbf e \mid \mathbf s \\ d_0 \mid r_0,\; e_0\mid s_0 \\ (d_ie_i, d_je_j) = 1 \; \forall 0\leq i < j \leq k}} \frac{\mu(d_0 d)\mu(e_0 e)d_0^2 d e_0^2 e g([d_0, e_0])}{[\mathbf{d}, \mathbf{e}]\phi(d_0)\phi(e_0)}. \end{align*} $$

The inner sum is multiplicative over $p\mid rsr_0s_0$ , where the pth factor is given by

$$ \begin{align*}\sigma_p(\mathbf r, \mathbf s, r_0, s_0) = \begin{cases} p-1 & p\mid r_i,\; p\mid s_i,\; i\geq 1 \\ \frac{p^2}{p-1} - 1 & p\mid r_0,\; p\mid s_0\; \\ - 1 & p\mid r_i,\; p\mid s_j,\; i\neq j, \;i,j\geq 0\\ 0 & p \text{ divides exactly one of }rr_0 \text{ and } ss_0. \\ \end{cases} \end{align*} $$

The product $\prod _{p\mid rsr_0s_0}\sigma _p(\mathbf r, \mathbf s, r_0, s_0)$ is $0$ unless $rr_0 = ss_0$ . Then using the bound $y_{{\mathbf r},r_0} y_{{\mathbf s},s_0} \leq y_{{\mathbf r},r_0}^2 + y_{{\mathbf s},s_0}^2$ we see (by symmetry) that (53) is

(54) $$ \begin{align} &\le \frac{x}{4q_3^2W^2\tilde{\lambda_{1}}^2} \sum_{{\mathbf r} , r_0} \frac{y_{{\mathbf r},r_0}^2}{\phi_{\omega^{*}}^2(rr_0)} \sum_{\substack{{\mathbf s}, s_0 \\ ss_0 = rr_0}} \prod_{p \mid rr_0}|\sigma_p({\mathbf r},{\mathbf s},r_0,s_0)| \nonumber \\ &=\frac{x}{4q_3^2W^2\tilde{\lambda_{1}}^2} \sum_{{\mathbf r} , r_0} \frac{y_{{\mathbf r},r_0}^2}{\phi_{\omega^{*}}^2(rr_0)} \prod_{p\mid r} \left(K + p - 1\right) \prod_{p\mid r_0} \left(K + \frac{p^2}{p-1}- 1\right) \nonumber \\ &\le \frac{x}{4q_3^2W^2\tilde{\lambda_{1}}^2} \sum_{{\mathbf r} , r_0} y_{{\mathbf r},r_0}^2 \prod_{p\mid rr_0} \left( \frac{K + \frac{p^2}{p-1}- 1}{(p - K -1)^2} \right) \nonumber \\ &\ll \frac{x}{4q_3^2W^2\tilde{\lambda_{1}}^2} \sum_{{\mathbf r} , r_0} \frac{y_{{\mathbf r},r_0}^2}{\prod_{p\mid rr_0}\left(p + O(K) \right)}. \end{align} $$

In order to estimate this sum, we wish to express $y_{{\mathbf r},r_0}$ in terms of $y_{{\mathbf r}}$ and $\tilde {y_{r_0}}$ . This is very similar to the computation done in [Reference Maynard14, Proposition 9.4]. Writing $y_{{\mathbf r},r_0}$ as in (51) and using the definition of $\lambda _{\mathbf d}$ in (31) and $\tilde {\lambda _{d_0}}$ in (49), we get

$$ \begin{align*} y_{{\mathbf r},r_0} &= \mu(r_0r)\phi_{\omega^{*}}(r_0r) \sum_{\substack{{\mathbf r}|\mathbf d \\ r_0|d_0\\ (d_0,d) = 1}} \frac{\lambda_{\mathbf d}\tilde{\lambda_{d_0}}\phi(d_0)}{dd_0^2} \\ &= \mu(r_0r)\phi_{\omega^{*}}(r_0r) \sum_{r_0\mid d_0}\mu(d_0) \sum_{d_0 \mid f_0} \frac{\tilde{y_{f_0}}}{\phi(f_0)} \sum_{\substack{{\mathbf r} \mid \mathbf d \\ (d, d_0) = 1}} \mu(d)\sum_{\mathbf d \mid {\mathbf f}}\frac{y_{{\mathbf f}}}{\phi(f)} \\ &= \mu(r_0r)\phi_{\omega^{*}}(r_0r) \sum_{\substack{f_0, {\mathbf f} \\ r_0\mid f_0 , {\mathbf r} \mid {\mathbf f}}} \frac{y_{{\mathbf f}} \tilde{y_{f_0}}}{\phi(f_0)\varphi(f)} \sum_{\substack{d_0, \mathbf d \\ r_0\mid d_0, {\mathbf r} \mid \mathbf d \\ d_0 \mid f_0 , \mathbf d \mid {\mathbf f} \\ (d,d_0) = 1}}\mu(d)\mu(d_0). \end{align*} $$

The inner sum is 0 unless every prime dividing one of f and $f_0$ but not the other is a divisor of $rr_0$ ; in that case, the inner sum is $\pm 1$ . Thus, using the fact that $y_{\mathbf {r}} \geq y_{\mathbf {f}}$ (since F is decreasing), as well as the fact that $\tilde {y_{r_0}} \geq \tilde {y_{f_0}}$ , we get that

$$ \begin{align*} y_{{\mathbf r},r_0} \leq \phi_{\omega^{*}}(r_0r) y_{\mathbf{r}} \tilde{y_{r_0}} \sum_{\substack{f_0 \\ r_0 \mid f_0 \\ (f_0, q_3W) = 1}} \sum_{\substack{ {\mathbf f} \in \mathcal{D}_K\\ {\mathbf r} \mid {\mathbf f} \\ f f_0 / (f,f_0)^2 \mid rr_0}}\frac{\mu^2(f_0)}{\phi(f_0)\phi(f)}. \end{align*} $$

Let $f_0 = r_0 f_0^{\prime } g_0$ and $f_i = r_i f_i^{\prime } g_i$ for $1\leq i \leq K$ , where $f_i^{\prime } = f_i / (f_i, r r_0)$ is the largest divisor of $f_i$ that is relatively prime to $rr_0$ . In particular, $g_0\mid r$ and $g_i\mid r_0$ for $1\leq i \leq K$ . Since $f f_0 / (f,f_0)^2 \mid rr_0$ , we must have $f_0^{\prime } = \prod _{i=1}^{K} f_i^{\prime }$ . Thus, $y_{{\mathbf r},r_0}$ is bounded by

$$ \begin{align*} y_{{\mathbf r},r_0} &\leq \phi_{\omega^{*}}(r_0r) y_{\mathbf{r}} \tilde{y_{r_0}} \frac{1}{\phi(r_0 r)} \sum_{{\mathbf f}'\in \mathcal D_K} \frac{1}{\phi^2(f')} \sum_{\substack{\mathbf g \in \mathcal D_K \\ g_i\mid r_0 \forall 1\leq i \leq k}}\frac{1}{\phi(g)} \sum_{\substack{g_0 \mid r}}{\frac{1}{\phi(g_0)}} \\ &\leq \phi_{\omega^{*}}(r_0r) y_{\mathbf{r}} \tilde{y_{r_0}} \prod_{\substack{p> D_0 \\ p\equiv 3 \bmod{4}}}\left( 1 + \frac{K}{(p-1)^2}\right) \prod_{\substack{p\mid r_0 }}\left( 1 + \frac{K}{(p-1)}\right) \prod_{\substack{p\mid r }}\left( 1 + \frac{1}{(p-1)}\right). \end{align*} $$

The first product is $\ll O_K(1)$ . By the definition of $\phi _{\omega ^{*}}$ , we then have

$$ \begin{align*} y_{{\mathbf r},r_0} \ll y_{\mathbf{r}} \tilde{y_{r_0}} \prod_{p\mid r_0} \left(1 + \frac{K}{p-1}\right)\left( 1 - \frac{K+1}{p}\right) \prod_{p\mid r} \left(1 + \frac{1}{p-1}\right)\left( 1 - \frac{K+1}{p}\right), \end{align*} $$

which in turn implies that $y_{\mathbf r,r_0} \ll y_{\mathbf r} \tilde {y_{r_0}}$ because both products are $\le 1$ .

Plugging this into (54), we get that

(55) $$ \begin{align} S_6^{(b)}(\nu_1) \ll \frac{x}{q_3^2W^2\tilde{\lambda_{1}}^2} \Bigg(\sum_{\substack{r_0 \leq x^{\xi} \\ (r_0,W) = 1}} \frac{\tilde{y_{r_0}}^2}{\prod_{p\mid r_0}(p+O(K))}\Bigg) \left(\sum_{\textbf{r}\in\mathcal{D}_K} \frac{y_{\textbf{r}}^2}{\prod_{p\mid r}(p+O(K))}\right). \end{align} $$

Recalling that $\tilde {y_{r_0}} = 1$ for $r_0 \le x^{\xi }$ and $(r_0,q_3W) = 1$ , we have

$$ \begin{align*}\sum_{\substack{r_0 \leq x^{\xi} \\ (r_0,q_3W) = 1}} \frac{\tilde{y_{r_0}}^2}{\prod_{p\mid r_0}(p+O(K))} \ll \left(\frac{\xi\log x}{\log D_0}\right)^{1/2}. \end{align*} $$

We can bound the sum over $\mathbf r$ using Lemma 7. From the definition of $L_K(F)$ , we then get

$$ \begin{align*}\sum_{\textbf{r}\in\mathcal{D}_K} \frac{y_{\textbf{r}}^2}{\prod_{p\mid r}(p+O(K))} \ll \left(\frac{e^{-\gamma /2}}{\Gamma(1/2)}\right)^K \left(\frac{\log R}{\log D_0}\right)^{K/2} L_K(F). \end{align*} $$

Using these estimates as well as the bound (50) on $\lambda _{\mathbf r}$ , equation (55) becomes

$$ \begin{align*} S_6^{(b)}(\nu_1) &\ll_K \frac{x}{q_3^2W^2} \frac{\log D_0}{\xi\log x} \left(\frac{\xi \log x}{\log D_0}\right)^{1/2} \left(\frac{\log R}{\log D_0}\right)^{K/2}L_K(F) \\ &\ll \frac{x}{q_3^2W^2}\xi^{-1/2}\theta_2^{-1/2} \left(\frac{\log R}{\log D_0}\right)^{\frac{K-1}{2}} L_K(F), \end{align*} $$

as desired.

4 Singular series estimates

We now prove several computational lemmas providing bounds on sums over $\mathbf E$ -admissible tuples $\mathcal L = \mathcal L(\mathbf b)$ for $\mathbf b \in \mathcal B$ . We begin with an average that appears in the sums over the terms $S_1(\nu _0)$ through $S_5^{(m)}(\nu _0)$ in the proof of Theorem 1, before turning to bounding $S_6^{(b)}(\nu _1)$ on average over different values of b.

4.1 Averaging over $\mathcal B$ and $\nu _0$

Lemma 21. In the notation of Section 2,

$$\begin{align*}\sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L = \mathcal L(\mathbf b) \text{ adm.}}} \sum_{\substack{\nu_0 \bmod W \\ (\ell(\nu_0),W) = 1 \forall \ell \in \mathcal L}} 1 \gg_{K} \left(\frac{\eta}{q}\right)^{K-1} \left(\log x\right)^{\frac{K-1}{2}} \left(\frac{\phi(W)}{W}\right)^K W. \end{align*}$$

Proof. We first consider the number of $\mathbf b \in \mathcal B$ that will produce an admissible tuple $\mathcal L (\mathbf b)$ . If $\mathcal L (\mathbf b)$ is not admissible, then there is some prime $p\leq K$ , $p\equiv 3 \bmod 4$ , $p\nmid q$ such that $\prod _{\ell \in \mathcal L (\mathbf b)}\ell (n)$ is always divisible by p. In order to prevent this situation, we can consider only those $\mathbf b$ for which each $b_i$ , $i\geq 2$ satisfies $q + a_i + qb_i \not \equiv 0,1 \bmod {p}$ for all $p\leq K$ , $p\equiv 3 \bmod 4$ , $p\nmid 2q$ . Having excluded two congruence classes for each prime p, together with the linear form corresponding to $b_1$ , the tuple $\mathcal {L}(\mathbf b)$ cannot cover all of the congruence classes mod p.

Thus, for each $2\leq i \leq K$ , we can choose $b_i$ from a set of size

$$ \begin{align*}\frac{\eta}{8q}\sqrt{\log x} \prod_{\substack{p\mid W \\ 2<p\leq K } } \left(1 - \frac{2}{p}\right) \gg_K \frac{\eta}{q}\sqrt{\log x} \end{align*} $$

while ensuring that the resulting $\mathbf b$ is admissible. It follows that there are at least $\gg _K (\frac {\eta }{q})^{K-1}(\log x)^{(K-1)/2}$ choices of $\mathbf b \in \mathcal B$ with $\mathcal L(\mathbf b)$ admissible.

For each $\mathbf b$ with $\mathcal L(\mathbf b)$ , we now consider the sum over $\nu _0$ . For fixed $\mathbf b$ , this is bounded by

$$ \begin{align*}\sum_{\substack{\nu_0 \bmod W \\ (\ell(\nu_0),W) = 1 \forall \ell \in \mathcal L}} 1 \gg W \prod_{\substack{p\mid W \\2<p\leq K }}\left(\frac{1}{p}\right) \prod_{\substack{p\mid W \\ p>K }}\left(1 - \frac{K}{p}\right) \gg_K W \left(\frac{\phi(W)}{W}\right)^K, \end{align*} $$

which, along with the number of choices of $\mathbf b$ yielding admissible tuples, completes the proof.

4.2 Averaging over $S_6^{(b)}(\nu _1)$

In this section, we will analyze the sum over $S_6^{(b)}(\nu _1)$ terms appearing in the proof of Theorem 1, and in particular provide the proof of Lemma 3. To begin with, the $S_6^{(b)}(\nu _1)$ sum can be bounded via Theorem 2 by

(56) $$ \begin{align} &\sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L = \mathcal L(\mathbf b) \text{ adm.}}} \sum_{\substack{\nu_1 \bmod W^2 \\ (\ell(\nu_1),W) = 1 \forall \ell \in \mathcal L}} \sum_{\substack{b \le \eta \sqrt{\log x} \\ qn + b \not\in \mathcal L \\ (q\nu_1 + b, W^2) = \square}} S_6^{(b)}(\nu_1) \\ &\qquad \ll_K \frac x{q_3^2W^2} \xi^{-1/2}\theta_2^{-1/2} \left(\frac{\log R}{\log D_0}\right)^{\tfrac{K-1}{2}} L_K(F) \sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L = \mathcal L(\mathbf b) \text{ adm.}}}\sum_{\substack{b \le \eta \sqrt{\log x} \\ qn + b \not\in \mathcal L}} \sum_{\substack{\nu_1 \bmod W^2 \\ (\ell(\nu_1),W) = 1 \forall \ell \in \mathcal L\\ (q\nu_1 + b, W^2) = \square}} 1.\notag \end{align} $$

Our next task is estimating the sums over $\mathbf b, b$ and $\nu _1$ . The constraints on $\nu _1 \bmod W^2$ are multiplicative, so we can understand them separately for each $p\mid W$ . For a fixed $p\mid W$ , let $\tilde {N_{p^2}}(\mathcal L,b)$ denote the number of congruence classes $\nu \bmod p^2$ such that $p\mid \ell (\nu )$ for some $\ell \in \mathcal L$ or such that $p\mid \ell ^b(\nu )$ but $p^2\nmid \ell ^b(\nu )$ . Then we have, for fixed $\mathcal L(\mathbf b)$ and fixed b, that

$$ \begin{align*} \sum_{\substack{\nu_1 \bmod W^2 \\ (\ell(\nu_1),W) = 1 \forall \ell \in \mathcal L\\ (q\nu_1 + b, W^2) = \square}} 1 = \prod_{\substack{p \mid W}} (p^2-\tilde{N_{p^2}}(\mathcal L,b)) = W^2\left(\frac{\phi(W)}{W}\right)^{K+1} \prod_{p \mid W} \frac{1-\tilde{N_{p^2}}(\mathcal L,b)/p^2}{(1-1/p)^{K+1}}. \end{align*} $$

The remaining sum over $\mathbf b$ and b is bounded in the following proposition.

Proposition 22. We have

$$ \begin{align*} \sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L(\mathbf b) \text{adm.}}} \sum_{\substack{b \le \eta \sqrt{\log x} \\ qn + b \not\in \mathcal L}} \prod_{p|W} \frac{1-\tilde{N_{p^2}}(\mathcal L,b)/p^2}{(1-1/p)^{K+1}} \ll_{K} \frac{(\eta\sqrt{\log x})^{K}}{(8q)^{K-1}}, \end{align*} $$

where the implied constant depends only on K.

Plugging this estimate into (56), we have

$$ \begin{align*} \sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L = \mathcal L(\mathbf b) \text{ adm.}}} &\sum_{\substack{\nu_1 \bmod W^2 \\ (\ell(\nu_1),W) = 1 \forall \ell \in \mathcal L}} \sum_{\substack{b \le \eta \sqrt{\log x} \\ qn + b \not\in \mathcal L \\ (q\nu_1 + b, W^2) = \square}} S_6^{(b)} \\ &\ll_K \frac x{q_3^2W^2} L_K(F) \xi^{-1/2}\theta_2^{-1/2} \left(\frac{\log R}{\log D_0}\right)^{\tfrac{K-1}{2}} W^2 \frac{\phi(W)^{K+1}}{W^{K+1}} \frac{(\eta\sqrt{\log x})^K}{(8q)^{K-1}}. \end{align*} $$

Using the fact that

$$ \begin{align*}\frac{\phi(W)}{W} \asymp \frac{q_3}{\phi(q_3)}(\log D_0)^{-1} \end{align*} $$

and that $\log R = \theta _2 \log x$ , we get

$$ \begin{align*} \sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L = \mathcal L(\mathbf b) \text{ adm.}}} &\sum_{\substack{\nu_1 \bmod W^2 \\ (\ell(\nu_1),W) = 1 \forall \ell \in \mathcal L}} \sum_{\substack{b \le \eta \sqrt{\log x} \\ qn + b \not\in \mathcal L \\ (q\nu_1 + b, W^2) = \square}} S_6^{(b)} \\ & \ll_K \xi^{-1/2} \theta_2^{\frac{K}{2} - 1} L_K(F) \left(\frac{q_3}{\phi(q_3)}\right)^{K+1} \frac{\eta^K}{q_3^2q^{K-1}} \frac{\left(\log x\right)^{K - \frac{1}{2}}} {\left(\log D_0\right)^K} x, \end{align*} $$

which completes the proof of Lemma 3.

It remains to prove Proposition 22. To do so, we will make use of the following lemma.

Lemma 23. Let $\tilde {N_{p^2}}(\mathcal L,b)$ denote the number of congruence classes $\nu \bmod p^2$ such that $p \mid \ell (\nu )$ for some $\ell \in \mathcal L$ or such that $p \mid \ell ^b(\nu )$ but $p^2\nmid \ell ^b(\nu )$ . Let $N_p(\mathcal L,b)$ denote the number of congruence classes $\nu \bmod p$ such that $p \mid \ell (\nu )$ for some $\ell \in \mathcal L$ or such that $p \mid \ell ^b(\nu )$ . Then

$$ \begin{align*} \prod_{\substack{p \mid W}} \frac{1-\tilde{N_{p^2}}(\mathcal L,b)/p^2}{(1-1/p)^{K+1}} \ll_K \prod_{\substack{p \mid W \\ p> K+1}} \frac{1-N_p(\mathcal L,b)/p}{(1-1/p)^{K+1}}, \end{align*} $$

where the implied constant depends only on K.

Proof. By definition, $\tilde {N_{p^2}}(\mathcal L,b)$ almost consists of all elements of a certain set of congruence classes modulo p when lifted to $\mathbb Z/p^2\mathbb Z$ , with the possible exception of one congruence class $\nu $ modulo $p^2$ such that $\ell ^b(\nu ) \equiv 0 \bmod p^2$ . In particular, this implies that

$$ \begin{align*} \tilde{N_{p^2}}(\mathcal L,b) = pN_p(\mathcal L,b) - E, \end{align*} $$

where E is either $0$ or $1$ . Thus,

$$ \begin{align*} \prod_{\substack{p \mid W}} \frac{1-\tilde{N_{p^2}}(\mathcal L,b)/p^2}{(1-1/p)^{K+1}} \le \prod_{\substack{p \mid W}} \frac{1-N_p(\mathcal L,b)/p + 1/p^2}{(1-1/p)^{K+1}}, \end{align*} $$

since the numerator of each factor in the product is either unchanged or has increased.

We can then rewrite the right-hand side as

$$ \begin{align*} &\prod_{\substack{p|W}} \frac{1-N_p(\mathcal L,b)/p + 1/p^2}{(1-1/p)^{K+1}} = \prod_{\substack{p|W \\ p \le K+1}} \frac{1-N_p(\mathcal L,b)/p + 1/p^2}{(1-1/p)^{K+1}} \prod_{\substack{p|W \\ p> K+1}} \frac{1-N_p(\mathcal L,b)/p + 1/p^2}{(1-1/p)^{K+1}} \\ &\qquad \qquad \qquad \le \prod_{\substack{p \le K+1}} \frac{1-1/p}{(1-1/p)^{K+1}}\prod_{\substack{p|W \\ p > K+1}} \frac{(1-N_p(\mathcal L,b)/p)}{(1-1/p)^{K+1}} \left(1 + \frac 1{p(p-N_p(\mathcal L,b))} \right)\\ &\qquad \qquad \qquad \ll_K \prod_{\substack{p|W \\ p > K+1}} \frac{(1-N_p(\mathcal L,b)/p)}{(1-1/p)^{K+1}} \prod_{\substack{p|W \\ p > K+1}} \left(1+\frac 1{p(p-K-1)}\right). \end{align*} $$

The second Euler product converges to a constant dependent only on K when extended over all primes $p> K+1$ , which completes the proof.

We are now ready to prove Proposition 22. This estimate is an analog of Gallagher’s result [Reference Gallagher5] that the average value of the singular series constants appearing in the Hardy–Littlewood k-tuples conjecture is $1$ . Our proof will closely follow Gallagher’s argument.

Proof of Proposition 22.

We begin by applying Lemma 23 to bound the left-hand side by

$$ \begin{align*} \ll_K \sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L(\mathbf b) \text{adm.}}} \sum_{\substack{b \le \eta \sqrt{\log x} \\ qn + b \not\in \mathcal L}} \prod_{\substack{p|W \\ p> K +1}} \frac{1-N_p(\mathcal L,b)/p}{(1-1/p)^{K+1}}, \end{align*} $$

where $N_p(\mathcal L,b)$ is the number of congruence classes $\nu \bmod p$ such that $p|\ell (\nu )$ for some $\ell \in \mathcal L$ or such that $p|\ell ^b(\nu )$ .

Let $\Delta (\mathcal L, b)$ denote the product

$$ \begin{align*} \Delta(\mathcal L, b) := \prod_{1 \le i_1 < i_2 \le K}(q(b_{i_2}-b_{i_1}) + a_{i_2}-a_{i_1}) \prod_{1 \le i \le K} (b-qb_i - a_i). \end{align*} $$

Thus, $1 \le N_p(\mathcal L,b) \le K+1$ , with equality on the right if and only if $p \nmid \Delta (\mathcal L,b)$ . Define $a(p,N_p)$ via

$$ \begin{align*} \frac{1-N_p/p}{(1-1/p)^{K+1}} = 1 + a(p,N_p), \end{align*} $$

and for squarefree r, define $a_{\mathcal L,b}(r)$ multiplicatively via $ a_{\mathcal L,b}(r) = \prod _{p|r} a(p,N_p(\mathcal L,b)), $ so that

$$ \begin{align*} \prod_{p|W}\frac{1-N_p(\mathcal L,b)/p}{(1-1/p)^{K+1}} = \sum_{r|W} a_{\mathcal L,b}(r). \end{align*} $$

By the same reasoning as in Gallagher’s proof of equation (3) in [Reference Gallagher5], for a constant x to be fixed later and for all $\varepsilon> 0$ , we have

(57) $$ \begin{align} &\sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L(\mathbf b) \text{ adm.}}} \sum_{\substack{b \le \eta \sqrt{\log x} \\ qn + b \not\in \mathcal L}} \prod_{\substack{p|W \\ p> K +1}} \frac{1-N_p(\mathcal L,b)/p}{(1-1/p)^{K+1}} \\ &\qquad = \sum_{r \le x} \sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L(\mathbf b) \text{ adm.}}} \sum_{\substack{b \le \eta \sqrt{\log x} \\ qn + b \not\in \mathcal L}} a_{\mathcal L,b}(r) + O_{K,\varepsilon}(\eta^K(\log x)^{K/2}(x\eta\log x)^{\varepsilon}/x).\notag \end{align} $$

The inner sums over $\mathbf b \in \mathcal B$ and b are equal to

$$ \begin{align*} \sum_{(N_p)_p} \prod_{\substack{p|r \\ p>K+1}} a(p,N_p) \left\{ \sideset{}{'}\sum 1 + O((\eta\sqrt{\log x})^{K-1})\right\}, \end{align*} $$

where each $(N_p)_p$ is a vector with positive integer entries for each prime $p|r$ with $p>K+1$ , and where $\sideset {}{'}\sum $ denotes the number of ways to choose values $b_2, \dots , b_K$ and b, not necessarily distinct, such that each $b_i \equiv 3 \bmod 4$ , such that $1 < qb_i \le \frac {\eta }{2}\sqrt {\log x}$ for $2 \le i \le jM$ , such that $\frac {\eta }{2}< qb_i \le \eta \sqrt {\log x}$ for $jM+1 \le i \le K$ , such that $b \le \eta \sqrt {\log x}$ , and most crucially, such that $b_1, \dots , b_K, b$ occupy precisely $N_p$ congruence classes modulo p for each $p|r$ . Recall that $b_1 = 3$ is fixed for all $\mathbf b \in \mathcal B$ .

By the Chinese remainder theorem, for $r \le \eta \sqrt {\log x}$ ,

$$ \begin{align*} \sideset{}{'}\sum = \left\{\left(\frac{\eta\sqrt{\log x}}{8qr}\right)^{K-1}\left(\frac{\eta\sqrt{\log x}}r\right) + O\left(\frac{\eta\sqrt{\log x}}{r}\right)^{K-1}\right\} \times \prod_{p|r} \binom{p-1}{N_p-1}\sigma(K,N_p), \end{align*} $$

where $\sigma (K,N_p)$ denotes the number of surjective maps from $\{1,\dots , K\}$ onto $\{1,\dots ,N_p\}$ . Thus, the inner sum is

$$ \begin{align*} \left(\frac{\eta\sqrt{\log x}}{8qr}\right)^{K-1}\left(\frac{\eta\sqrt{\log x}}{r}\right)A(r) + O\left(\left(\frac{\eta\sqrt{\log x}}{r}\right)^{K-1}B(r)\right) + O\left((\eta\sqrt{\log x})^{K-1}C(r)\right), \end{align*} $$

where

$$ \begin{align*} A(r) &= \sum_{(N_p)_{p|r}} \prod_{p|r} a(p,N_p)\binom{p}{N_p} \sigma(K,N_p), \\ B(r) &= \sum_{(N_p)_{p|r}} \prod_{p|r} |a(p,N_p)|\binom{p}{N_p} \sigma(K,N_p), \text{ and} \\ C(r) &= \sum_{(N_p)_{p|r}} \prod_{p|r} |a(p,N_p)|. \end{align*} $$

One can show via a combinatorial argument (identical to the one performed in [Reference Gallagher5]) that $A(r) = 0$ whenever $r> 1$ . Also by the same arguments as in [Reference Gallagher5], we have $B(r) \le C^{\omega (r)}\frac {r^K}{\phi (r)}$ and $C(r) \le C^{\omega (r)}\frac {r}{\phi (r)}$ for a suitable constant C.

Altogether, we get that

$$ \begin{align*} \sum_{\substack{\mathbf b \in \mathcal B \\ \mathcal L(\mathbf b) \text{ adm.}}} &\sum_{\substack{b \le \eta \sqrt{\log x} \\ qn + b \not\in \mathcal L}} \prod_{\substack{p|W \\ p> K +1}} \frac{1-N_p(\mathcal L,b)/p}{(1-1/p)^{K+1}} \\&= \left(\frac{\eta\sqrt{\log x}}{8q}\right)^{K-1}(\eta\sqrt{\log x}) + O\left((\eta\sqrt{\log x})^{K-1} \sum_{r \le x} \frac{C^{\omega(r)}r}{\phi(r)}\right) \\& \quad + O(\eta^K(\log x)^{K/2}(x\eta\log x)^{\varepsilon}/x) \\&= \frac{(\eta\sqrt{\log x})^{K}}{(8q)^{K-1}} +O_{K,\varepsilon,q}((\eta\sqrt{\log x})^{K-1/2 + \varepsilon}), \end{align*} $$

choosing $x = (\eta \sqrt {\log x)})^{1/2}.$ This completes the proof.

Competing interests

The authors have no competing interests to declare.

Data availability statement

Data availability is not applicable to this article as no data was created or analysed.

Index of Notation

Footnotes

N.K. was supported by the European Research Council (ERC) under the European Union’s Horizon 2020 research and innovation program (Grant agreement No. 786758). V.K. was supported by the NSF Mathematical Sciences Research Program through the grant DMS-2202128. The authors would like to thank the anonymous referee for helpful comments

References

Banks, WD, Freiberg, T and Maynard, J (2016) On limit points of the sequence of normalized prime gaps. Proc. Lond. Math. Soc. (3) 113(4), 515539. MR 355649010.1112/plms/pdw036CrossRefGoogle Scholar
Banks, WD, Freiberg, T and Turnage-Butterbaugh, CL (2015) Consecutive primes in tuples. Acta Arith. 167(3), 261266. MR 331646010.4064/aa167-3-4CrossRefGoogle Scholar
David, C, Devin, L, Nam, J and Schlitt, J (2022) Lemke Oliver and Soundararajan bias for consecutive sums of two squares. Math. Ann. 384(3–4), 11811242. MR 449847110.1007/s00208-021-02307-2CrossRefGoogle Scholar
Freiberg, T, Kurlberg, P and Rosenzweig, L (2017) Poisson distribution for gaps between sums of two squares and level spacings for toral point scatterers. Commun. Number Theory Phys. 11(4), 837877. MR 373376710.4310/CNTP.2017.v11.n4.a3CrossRefGoogle Scholar
Gallagher, PX (1976) On the distribution of primes in short intervals. Mathematika 23(1), 49. MR 40938510.1112/S0025579300016442CrossRefGoogle Scholar
Goldston, DA, Graham, SW, Pintz, J and Yılıd rım, CY (2009) Small gaps between products of two primes. Proc. Lond. Math. Soc. (3) 98(3), 741774. MR 250087110.1112/plms/pdn046CrossRefGoogle Scholar
Gorodetsky, O (2023) Sums of two squares are strongly biased towards quadratic residues. Algebra Number Theory 17(3), 775804. MR 457800610.2140/ant.2023.17.775CrossRefGoogle Scholar
Hooley, C (1963) On the number of divisors of a quadratic polynomial. Acta Math. 110, 97114. MR 15364810.1007/BF02391856CrossRefGoogle Scholar
Hooley, C (1971) On the intervals between numbers that are sums of two squares. Acta Math. 127, 279297. MR 29428110.1007/BF02392056CrossRefGoogle Scholar
Kimmel, N and Kuperberg, V (2023) Consecutive runs of sums of two squares. arXiv preprint 2306.12855.Google Scholar
Knapowski, S and Turán, P (1977) On prime numbers $\equiv 1$ resp. $3$ . In Number Theory and Algebra. New York: Academic Press, 157165. MR 0466043Google Scholar
Lemke Oliver, RJ and Soundararajan, K (2016) Unexpected biases in the distribution of consecutive primes. Proc. Natl. Acad. Sci. USA 113(31), E4446E4454. MR 362438610.1073/pnas.1605366113CrossRefGoogle ScholarPubMed
Maynard, J (2015) Small gaps between primes. Ann. of Math. (2) 181(1), 383413. MR 327292910.4007/annals.2015.181.1.7CrossRefGoogle Scholar
Maynard, J (2016) Dense clusters of primes in subsets. Compos. Math. 152(7), 15171554. MR 353045010.1112/S0010437X16007296CrossRefGoogle Scholar
McGrath, O (2022) A variation of the prime k-tuples conjecture with applications to quantum limits. Math. Ann. 384(3–4), 13431407. MR 449847510.1007/s00208-021-02321-4CrossRefGoogle Scholar
Merikoski, J (2020) Limit points of normalized prime gaps. J. Lond. Math. Soc. (2) 102(1), 99124. MR 414372810.1112/jlms.12314CrossRefGoogle Scholar
Pintz, J (2018) A note on the distribution of normalized prime gaps. Acta Arith. 184(4), 413418. MR 385537510.4064/aa171127-15-8CrossRefGoogle Scholar
Plaksin, VA (1988) The distribution of numbers represented by the sum of two squares. Dokl. Akad. Nauk SSSR 299(6), 13201323. MR 947418Google Scholar
Shiu, DKL (2000) Strings of congruent primes. J. London Math. Soc. (2) 61(2), 359373. MR 176068910.1112/S0024610799007863CrossRefGoogle Scholar