1. BASIC SIEVE METHODS AND APPLICATIONS - Math

114
SIEVE METHODS LECTURE NOTES, SPRING 2020 KEVIN FORD 1. BASIC SIEVE METHODS AND APPLICATIONS A sieve is a technique for bounding the size of a set after the elements with “undesirable properties” (usually of a number theoretic nature) have been removed. The undesirable properties could be divisibility by a prime from a given set, other multiplicative constraints (divisibility by a perfect square for example) or inclusion in a set of residue classes. Inclusion-exclusion yields an exact formula, however for k properties this produces 2 k summands which is usually too much to effectively deal with. A sieve is a procedure to estimate the number of “desirable” elements of the set using k Op1q summands. While inexact, oftentimes the sieve is capable of estimating the size very accurately. The original sieve is, of course, the Sieve of Eratosthenes, the familiar process of creating a table of prime numbers by systematically removing those integers divisible by small primes (but keeping the primes them- selves). The modern sieve was created by Viggo Brun in the period 1915-1922 as a way of attacking famous unsolved problems such as Golbach’s Conjecture and the Twin Prime problem (both, so far, unsuccessfully). Sieve methods have since found enormous application in number theory, often used as tools in many other types of problems, e.g. in studying Diophantine equations. 1.1. Notational conventions. τ pnq is the number of positive divisors of n ωpnq is the number of distinct prime factors of n Ωpnq is the number of prime factors of n counted with multiplicity μpnq is the M ¨ obius’s function; μpnq “ p´1q ωpnq if n is squarefree and μpnq“ 0 otherwise. P ` pnq is the largest prime factor of n; P ` p1q“ 0 by convention P ´ pnq is the smallest prime factor of n; P ´ p1q“8 by convention Ppz q is the set of positive squarefree integers composed only of primes ď z Λpnq denotes the von Mangoldt function X is the indicator function of the statement X or of the set X the symbol p, with or without subscripts, always denotes a prime πpx; q,aq is the number of primes p ď x in the progression a mod q. P denotes probability and E expectation log k x is the k-th iterate of the logarithm of x 1.2. General sieve setup. A sieve problem A is a probability space pΩ, F , Pq, together with a “total mass” quantity M and events A p , one for each prime p. The “sifting function” is S pA,z q“ M ¨ Ppnot A p , @p ď z q. Oftentimes Ω will be a finite set of integers, with Ppn P Ωq“ 1{|Ω| for each n P Ω (the uniform probability measure), M “|Ω| and A p is the event that p|n, that is, A p “tn P Ω: p|nu. This is the standard “small 1

Transcript of 1. BASIC SIEVE METHODS AND APPLICATIONS - Math

SIEVE METHODS LECTURE NOTES, SPRING 2020

KEVIN FORD

1. BASIC SIEVE METHODS AND APPLICATIONS

A sieve is a technique for bounding the size of a set after the elements with “undesirable properties”(usually of a number theoretic nature) have been removed. The undesirable properties could be divisibilityby a prime from a given set, other multiplicative constraints (divisibility by a perfect square for example) orinclusion in a set of residue classes. Inclusion-exclusion yields an exact formula, however for k propertiesthis produces 2k summands which is usually too much to effectively deal with. A sieve is a procedure toestimate the number of “desirable” elements of the set using kOp1q summands. While inexact, oftentimesthe sieve is capable of estimating the size very accurately.

The original sieve is, of course, the Sieve of Eratosthenes, the familiar process of creating a table of primenumbers by systematically removing those integers divisible by small primes (but keeping the primes them-selves). The modern sieve was created by Viggo Brun in the period 1915-1922 as a way of attacking famousunsolved problems such as Golbach’s Conjecture and the Twin Prime problem (both, so far, unsuccessfully).Sieve methods have since found enormous application in number theory, often used as tools in many othertypes of problems, e.g. in studying Diophantine equations.

1.1. Notational conventions. τpnq is the number of positive divisors of nωpnq is the number of distinct prime factors of nΩpnq is the number of prime factors of n counted with multiplicityµpnq is the Mobius’s function; µpnq “ p´1qωpnq if n is squarefree and µpnq “ 0 otherwise.P`pnq is the largest prime factor of n; P`p1q “ 0 by conventionP´pnq is the smallest prime factor of n; P´p1q “ 8 by conventionPpzq is the set of positive squarefree integers composed only of primes ď z

Λpnq denotes the von Mangoldt function1X is the indicator function of the statement X or of the set Xthe symbol p, with or without subscripts, always denotes a primeπpx; q, aq is the number of primes p ď x in the progression a mod q.P denotes probability and E expectationlogk x is the k-th iterate of the logarithm of x

1.2. General sieve setup. A sieve problem A is a probability space pΩ,F ,Pq, together with a “total mass”quantity M and events Ap, one for each prime p. The “sifting function” is

SpA, zq “M ¨ Ppnot Ap,@p ď zq.

Oftentimes Ω will be a finite set of integers, with Ppn P Ωq “ 1|Ω| for each n P Ω (the uniform probabilitymeasure), M “ |Ω| and Ap is the event that p|n, that is, Ap “ tn P Ω : p|nu. This is the standard “small

1

2 KEVIN FORD

sieve” problem, where SpA, zq is the number of n P Ω with p - n for all p ď z; these are called the “unsiftednumbers”. In the above definitions, M can be anything, but in practice it has some arithmetical meaning.

Some specific examples:

‚ Eratosthenes sieve for primes. Ω “ r1, xs X N, uniform probabilities on Ω, M “ |Ω| “ txu, andAp “ tn P Ω : p|nu. Then SpA,

?xq “ πpxq´πp

?xq` 1, as the unsifted elements are the primes

in p?x, xs together with the number 1.

‚ Twin primes. Ω “ r1, xs X N, Ap “ tn P Ω : p|npn ` 2qu. The unsifted numbers are numbers nsuch that npn ` 2q has no prime factor ď z. In particular, SpA,

?x` 2q counts k P p

?x` 2, xs

for which both k and k ` 2 are prime.Equivalently, Ap is the set of n that avoid the residue classes 0 mod p and ´2 mod p.

‚ Twin primes, weighted version. Ω “ r2, xs X N, and

Ppn P Ωq “Λpn` 2q

M, M “

ÿ

2ďnďx

Λpn` 2q,

Ap “ tn P Ω : p|nu. Here M “ř

2ďnďx Λpn` 2q „ x by the Prime Number Theorem, and

SpA,?xq “

ÿ

2ďnďxP´pnqą

?x

Λpn` 2q “ÿ

?xăpďx

Λpp` 2q

“ÿ

?xăpďx

p`2 prime

logpp` 2q `Opx12q,

the error term coming from terms p` 2 “ qb where q is prime and b ě 2.‚ Prime tuples. Let a1, ¨ ¨ ¨ , ak P N and b1, . . . , bk P Z. Put Ω “ r1, xs X N, and1

Ap “ tn P Ω : p|pa1n` b1q ¨ ¨ ¨ pakn` bkqu.

For an appropriate c ą 0, which depends on a1, a2, . . . , ak, bk, SpA, c?xq counts those n ď x for

which a1n` b1, . . . , akn` bk are simultaneously prime.‚ Prime values of a polynomial. Let f : Z Ñ Z be an irreducible polynomial of degree h ě 1, put

Ω “ r1, xsXZ, Ap “ tn P Ω : p|fpnqu. Let C be large enough so that |hpnq| ď Cnh for all n ě 1.Then, as before, SpA,

?Cxhq captures values of n for which fpnq is prime.

‚ Goldbach’s problem. Let N be an even, positive integer, put Ω “ t1, 2, . . . , N ´ 1u, M “ |Ω| “

N ´ 1, and Ap “ tk P Ω : p|kpN ´ kqu. Then SpA,?Nq counts numbers k P p

?N,N s for which

both k and N ´ k are prime. In particular, SpA,?Nq ą 0 implies that N is the sum of two primes.

If one shows this for all N ě 4, one deduces Goldbach’s Conjecture.‚ Primes in an arithmetic progression. Fix coprime positive integers a and q, let

Ω “ t1 ď n ď x : n ” a pmod qqu,

Ap “ tn P Ω : p|nu. Then SpA,?xq captures primes in p

?x, xs that are in the arithmetic progres-

sion a mod q.

1Unless otherwise specified, from now on whenever Ω is a finite set, the probability measure on Ω will be the uniform measure,and M will be the number of elements of Ω.

SIEVE METHODS LECTURE NOTES, SPRING 2020 3

‚ Sums of two squares. Ω “ r1, xs X Z,

Ap “

#

tn P Ω : pen for some odd eu p ” 3 pmod 4q

H otherwise.

Then SpA, xq counts integers n ď x, for which we don’t have pen for any prime p ” 3 pmod 4q

and odd exponent e. That is, SpA, xq is the number of integers n ď x which are the sum of twosquares.

‚ Sieve by multiple residue classes. Let M,N be two integers, Ω “ tN ` 1,M ` 2, . . . , N `Mu

and for each prime p let Ip be some subset (possibly empty) of the residue classes modulo p. Put

Ap “ tn P Ω : n mod p R Ipu.

Here SpA, zq counts the integers in pN,M ` N s avoiding all the residue classes Ip for primesp ď z. If |Ip| is bounded or bounded on average, then this is a very general sieving problem of“small sieve” type, whereas if |Ip| is unbounded on average, the problem falls under the umbrellaof the “large sieve”. The case of prime values of a polynomial, see above, is a special case with

Ip “ tn P ZpZ : fpnq ” 0 pmod pqu.

‚ Multivariate polynomial sieve. Let F pxq : Zk Ñ Zk be a multivariate polynomial of x “

px1, . . . , xkq, take any finite Ω P Zk, and Ap “ tx P Ω : p|F pxqu. Then SpA, zq counts x P Ω forwhich F pxq has no prime factor p ď z.

‚ The square-free sieve. Let Ω be a finite set of integers and for each prime p let Ap “ tn P

Ω : p2|nu. Then SpA, zq, with an appropriately large z, will count the elements of Ω which aresquarefree. A famous application is for squarefree values of a polynomial, e.g. Ω “ tfpnq : 1 ď

n ď xu, where f is an irreducible polynomial.One can similarly set up a k-free sieve problem.

‚ Elliptic curve sieve. Fix and elliptic curve E over Q Let Ω be the set of primes q ď x. LetAp “ tq P Ω : p|#EFqu, where EFq is the reduction of E modulo q. It is known that #EFq ďq ` 1` 2

?q, and thus SpA, 2

?xq counts those q for which #EFq is prime.

If d is a square-free integer composed only of primes in P , define

(1.1) Ad “č

p|d

Ap, Ad “M ¨ PpAdq.

In particular, A1 “ M . In the case where Ω is a finite set of integers with uniform measure, M “ |Ω|, andAp “ tn P Ω : p|nu, Ad counts the number of n P Ω divisible by d.

In this notation, inclusion-exclusion gives

(1.2) SpA, zq “ÿ

P`pdqďz

µpdqAd.

1.3. Legendre’s sieve for primes (Legendre, 1808). Let Ω “ r1, xs X Z, Ap “ tn P Ω : p|nu. ThenSpA, zq counts the positive integers n ď x with no prime factor ď z; in particular, this includes all of theprimes between z and x. Also, for each aquarefree d, Ad “ tn P Ω : d|nu and thus

Ad “ |Ad| “ txdu “ xd`Op1q.

4 KEVIN FORD

By (1.2),

πpxq ´ πpzq ď SpA, zq “ÿ

P`pdqďz

µpdq´x

d`Op1q

¯

“ xÿ

P`pdqďz

µpdq

d`OpτpP qq

“ xź

pďz

ˆ

1´1

p

˙

`O´

2πpzq¯

.

Taking z “ log x, and using the crude bound πpzq ď z together with Mertens’ bound, we conclude that

πpxq ď z `x

log z

`

e´γ ` op1q˘

`Op2log xq “ O

ˆ

x

log2 x

˙

.

Remark: We can do better by observing that in factAd “ 0 for d ą x (cf. Hooley [86]), and thus restrictingthe sums to such d.

1.4. The role of independence. If the events Ap are independent, then the sieving problem is trivial, forthen

(1.3) SpA, zq “Mź

pďz

p1´ PApq.

In practice, the events are not independent, but are close to being so, especially for small primes. For exam-ple, in Legendre’s sieve for primes, Ad “ txdu is very close to xd. Even with this strong approximation,however, the accumulation of error terms (coming from k-correlations) becomes unwieldy when z is muchlarger than log x.

1.5. Main goals. We will see that the right side of (1.3) is a good approximation to SpA, zq under verygeneral conditions. We will accomplish this by a judicious pruning of the summands in (1.2).

To set things up, we adopt some additional notation. Take X to be an approximation of M (this can beanything, but in practice it is very close to M ). We assume that there is a function g satisfying

(g) 0 ď gppq ă 1 pall primes pq,

which, when extended to a multiplicative function by gpdq “ś

p|d gppq, gives Ad « Xgpdq for squarefreed; that is, we require that the “remainders”

(r) rd :“ Ad ´Xgpdq

to be “small on average”. In the case where the events Ap are independent, taking gppq “ PAp yields rd “ 0

for all d and we recover (1.3). In practice, however, we will not take gppq “ PAp but something very closewhich is convenient for calculations. We also adopt the short-hand

(V ) V pzq “ź

pďz

p1´ gppqq.

In this notation, the right side of (1.3) is about XV pzq.

SIEVE METHODS LECTURE NOTES, SPRING 2020 5

Broadly speaking, if rd is not more than 1X on average over “small” d, we will be able to prove thefollowing:

(asymptotic) SpA, zq „ XV pzq pz “ Xop1qq;

(upper bound) SpA, zq ! XV pzq pz ď Xq;

(lower bound) SpA, zq " XV pzq pz ď Xcq,

(1.4)

where the constant c depends on the nature of the sieve problem A.In plain language, we can prove the expected asymptotic formula for small z, an upper bound of the

expected order for all z, and a lower bound of the expected order if z is at most a small power of X . Theupper bound in (1.4) is amazing in its generality, and it has enormous utility as an auxilliary counting devicein many problems.

1.6. Sifting density / dimension, and level of distribution. For most sieving problems, we have gppq «κp on average over p (we’ll make this precise below). In this case κ is referred to as the sifting densityor sifting dimension. In the literature, the linear sieve refers to dimension 1. Various sieving procedureshave been optimized for sieves of a particular density, e.g. the Rosser-Iwaniec theory of the linear sieve, andIwaniec’s theory of the half-dimensional sieve.

Roughly speaking, the level of distribution of a sieve problem A is the largest D for whichÿ

dďD,P`pdqďz

µ2pdq|rd| ď εXV pzq,

where ε ą 0, X and z are given, and ε is small. The larger the level of distribution, the better quality of thebounds we can prove in (1.4).

1.7. More examples. There are limitations of the sieve, which are illustrated by the following examples.

1.7.1. Eratosthenes sieve. . The asymptotic in (1.4) cannot be expected to hold for z being a fixed powerof X . Take Ω “ r1, xs X Z, X “ x, and set Ap “ tn P Ω : p|nu. As before,

Ad “ #tn ď x : d|nu “ txdu “ xd`Op1q

Thus, taking gpdq “ 1d, we see that the error terms rd “ Op1q. Also,

SpA,?xq “ πpxq ´ πp

?xq ` 1 „

x

log x

by the Prime Number Theorem. However, Mertens’ theorem gives

XV pzq “ xź

pď?x

ˆ

1´1

p

˙

„2e´γx

log x,

with 2e´γ “ 1.122 . . .. The discrepancy between SpA,?xq and XV pzq comes from the large amount of

dependence among the events Ap for large primes p; e.g. Ap XAp1 XAp2 “ H if p ą p1 ą p2 ą x13. Infact, for fixed c ą 0, one has SpA, xcq „ wpcqXV pzq, where wpcq ‰ 1 for almost all c P p0, 1s. Thus, ingeneral the condition z “ Xop1q is necessary in order to conclude the asymptotic in(1.4).

6 KEVIN FORD

1.7.2. Twin primes. . Take Ω “ r1, xs X Z, X “ x, Ap “ tn P Ω : p|npn ` 2qu. Here SpA,?x` 2q

counts the number of twin prime pairs between?x` 2 and x. Hardy and Littlewood [72, Conjecture B]

conjectured that the count of such pairs is „ Cx log2 x where

C “ 2ź

pą2

ˆ

1´1

pp´ 1q2

˙

« 1.32.

For a heuristic explanation of this formula, see Section 1.10 below. By breaking up r1, xs into subintervalsof length d, we easily derive

Ad “ #tn ď x : d|npn` 2qu “ xρpdq

d`Opρpdqq,

whereρpdq “ #t0 ď k ď d´ 1 : kpk ` 2q ” 0 pmod dqu.

By the Chinese remainder theorem, ρ is multiplicative, ρp2q “ 1 and ρppq “ 2 for p ą 2. Thus, this is asieve problem of dimension 2 (or sifting density 2). Putting gpdq “ ρpdqd and applying Mertens, we getthat

(1.5) XV pzq “x

2

ź

3ďpďz

ˆ

1´2

p

˙

„p4e´2γqCx

log2 x.

As in Example (a) above,XV pzq differs by a constant multiplicative factor from what is expected to be true.Sieve methods deliver an upper bound of the expected order (take z “

?x)

#tn ď x : n and n` 2 are both primeu ! xV pzq —x

log2 x.

Sieve methods only, however, deliver a lower bound for somewhat smaller z. For example, it is known that

SpA, x15q " XV pzq —x

log2 x.

From the last estimate, we conclude that there are" x log2 x values of k ď x for which each of k and k`2

has at most 4 prime factors. We will prove a somewhat weaker version of this below (with 4 replaced by10). This is a typical conclusion from a lower bound sieve. This is proved using the “linear variant” of thetwin prime sieving problem. Here take Ω “ tp ` 2 : p ď xu a set of shifted primes, Ap “ tn P Ω : p|nu.In this set-up,

Ad “ πpx; d,´2q „lipxq

φpdqp2 - dq

by the prime number theorem in arithmetic progressions. For the application to the sieve, we need a uniformestimate on πpx; d,´2q, at least on average over d. Here we take X “ lipxq, ad gppq “ 1

p´1 for odd p.Since gppq « 1p, this is a sieve problem of dimension 1. Oftentimes, this process of “dimension lowering”yields stronger results, as the sieve procedures for smaller dimension are at present stronger.

1.7.3. Prime k-tuples. . Let a1, ¨ ¨ ¨ , ak P N and b1, . . . , bk P Z. Put Ω “ r1, xs X N, and

Ap “ tn P Ω : p|pa1n` b1q ¨ ¨ ¨ pakn` bkqu.

An easy counting yields

Ad “ xρpdq

d`Opρpdqq,

SIEVE METHODS LECTURE NOTES, SPRING 2020 7

Admissible Non-admissible

pn, n` 2kq; k P N pn, n` 1q

pn, 2n` 1q pn, 3n` 1q

pn, n` 2, n` 6q pn, n` 2, n` 4q

whereρpdq “ #t0 ď n ă d : pa1n` b1q ¨ ¨ ¨ pakn` bkq ” 0 pmod dqu.

By the Chinese Remainder Theorem, ρpdq is multiplicative. We say that the collection of linear formsa1n ` b1, . . . , akn ` bk is admissible if ρppq ă p for all primes p. In the contrary case, for all n, one ofthe forms ajn ` bj is divisible by p and hence there are only finitely many n making all of the ajn ` bjsimultaneously prime. Some examples:

We set gppq “ ρppqp. Note that if

p -kź

i“1

aiź

1ďiăjďk

paibj ´ ajbiq,

then ρppq “ k (see Theorem 2.5 below). In particular, ρppq “ k for all sufficiently large p, and hence this isa sieve problem of density k (or dimension k). At present, sieve methods can deliver bounds of the form

#tn ď x : ajn` bj are prime for all ju ď Cx

plog xqk,

where C is an explicit function of a1, b1, . . . , ak, bk. If k ě 2 we still do not know how to show that the leftside goes to8 as xÑ8.

1.7.4. Selberg’s examples. [123]. The values of c for which sieve method deliver lower bounds (1.4) areinvariable smaller than we would like. There is a fundamental barrier at work which explains this, knownas the “parity barrier”. Roughly speaking, the small sieve works with inputs X , the function g and esti-mates for the remainders rd. However, even if the level of distribution is very large, say x1´op1q, the sievefundamentally cannot distinguish between numbers with an odd number of prime factors from those withan even number of prime factors. Consider two sequences defined as follows. Recall the Liouville func-tion λpnq “ p´1qΩpnq (the completely multiplicative function which is -1 at all primes). Let A`, A´ beprobability spaces on the sets

Ω` “ t1 ď n ď x : λpnq “ 1u, Ω´ “ t1 ď n ď x : λpnq “ ´1u,

respectively, and Ap “ tn P Ω : p|nu for each p.The prime number theorem (with classical error term) implies

ÿ

nďx

λpnq “ Opxe´c1?

log xq, some c1 ą 0.

Therefore,

#tn P Ω˘ : d|nu “ÿ

mďxd

1˘ λpdmq

2“

1

2

Yx

d

]

˘λpdq

2

ÿ

mďxd

λpmq

“x

2d`O

´x

de´c?

logpxdq¯

.

8 KEVIN FORD

In particular, taking d “ 1, we wee that |Ω˘| „ x2 . Take X “ x

2 and gpdq “ 1d for all d. For both sequences,

the level of distribution is x1´op1q (pretty much the best range that one can hope for), and for both sieveproblems we have

V pzq „2e´γ

log x.

However, numbers n ď x that have no prime factor ď?x are prime or 1, thus

SpA`,?xq “ 1, while SpA´,

?xq „

x

log x“

2X

log x.

Thus, although the sieve inputs (quantity X and bounds on Ad) are identical in both problems, the truth isvery different. In order to distinguish primes from integers with 2 prime factors, say, further inputs into thesieve are required. Sieve procedures which include as hypotheses bilinear sum bounds for Ω have proven tobe very successful in detecting primes, e.g. Friedlander-Iwaniec [56] and Harman [76].

1.8. The small sieve. Viggo Brun’s fundamental idea was to replace the huge sum on the right side of(1.2) with a sum over a much smaller range of d, at the expense of replacing the equality in (1.2) with aninequality. In general, a sieve (or small sieve) is a sequence λ “ pλdq supported on squarefree integers dwhich replaces µpdq in (1.2). We will suppose that either λ “ λ` “ pλ`d q satisfies

(λ`) λ`1 “ 1,ÿ

d|m

λ`d ě 0 pm ą 1q

or that λ “ λ´ “ pλ´d q satisfies

(λ´) λ´1 “ 1,ÿ

d|m

λ´d ď 0 pm ą 1q.

We call λ` an upper bound sieve and λ´ a lower bound sieve, which comes from the following easy result:

Lemma 1.1. For z ě 2 let Ppzq denote the set of squarefree positive integers, divisible only by primesp ď z. Assume (λ`) and (λ´). Then, for any sieve problem and and z ě 2,

(1.6)ÿ

dPPpzq

λ´d Ad ď SpA, zq ďÿ

dPPpzq

λ`d Ad.

Further, for any multiplicative function g such that 0 ď gppq ă 1 for each p ď z, we have

(1.7)ÿ

dPPpzq

λ´d gpdq ďź

pďz

p1´ gppqq ďÿ

dPPpzq

λ`d gpdq.

Proof. For any ω P Ω, letmω “

ź

pďzωPAp

p.

Then, by (λ`),

SpA, zq “MPpmω “ 1q “M ¨ E1mω“1

ďM ¨ Eÿ

d|mω

λ`d “ÿ

dPPpzq

λ`d Ad,

SIEVE METHODS LECTURE NOTES, SPRING 2020 9

and similarly by (λ´),

SpA, zq ěM ¨ Eÿ

d|mω

λ´d “ÿ

dPPpzq

λ´d Ad.

The claim (1.7) is a special case, where our probability space has independent events Ap such that PAp “

gppq, so that SpA, zq “Mś

pďzp1´ gppqq and Ad “Mgpdq.

The major goal of sieve methods is to construct good sieve parameters λ˘, with small support and withthe sums in (1.6) mimicking SpA, zq as closely as possible. With this notation and (r), we have

(1.8)ÿ

dPPpzq

λdAd “ Xÿ

dPPpzq

gpdqλd `ÿ

dPPpzq

λdrd.

As λd is a replacement for µpdq, it is reasonable to suppose (if we have constructed our sieve well) thatÿ

dPPpzq

gpdqλd «ÿ

dPPpzq

gpdqµpdq “ź

pďz

p1´ gppqq “ V pzq.

1.9. Legendre’s sieve, general version.

Theorem 1.2. Let A be a sieve problem, assume (g), (r) and adopt notation (V ). Then2

(1.9) SpA, zq “ XV pzq `O

ˆ

ÿ

dPPpzq

|rd|

˙

.

Proof. Trivially, the weights λ˘d “ µpdq satisfy (λ`) and (λ´) with equality. By (1.6),

SpA, zq “ Xÿ

dPPpzq

µpdqgpdq `ÿ

dPPpzq

µpdqrd “ XV pzq `O

ˆ

ÿ

dPPpzq

|rd|

˙

.

Although this sieve suffers from the large number, 2πpzq, of remainder summands, it is useful in situationswhere the “densities” gppq are rather small on average, and so the product on the right hand side of (1.9)captures the true behavior of set of interest for relatively small z. A prominent example of the use ofLegendre’s sieve was given by C. Hooley [82], who deduced Artin’s primitive root conjecture from theGeneralized Riemann Hypothesis for Dedekind zeta functions of certain number fields. Details will begiven later in Section 2.2.6.

1.10. The prime k-tuples conjecture. Much of sieve theory has been driven by attempts to prove specialcases of the general Prime k-tuples Conjecture. The setup is a finite collection f1, . . . , fk of nonconstantirreducible (over Q) polynomials in m variables, with integer coefficients. For each prime p, let

ρppq “ #tx “ px1, . . . , xmq mod p : f1pxq ¨ ¨ ¨ fkpxq ” 0 pmod pqu.

Definition 1. The set pf1, . . . , fkq is admissible if the fi are distinct and ρppq ă pm for all p.

Conjecture 1.3 (General Prime k-tuples Conjecture). Let f1, . . . , fk be an admissible collection of polyno-mials from Zm to Z. Then

(1.10) #t0 ď xi ă x p1 ď i ď mq : f1pxq, . . . , fkpxq are all prime u „S

śki“1 degpfiq

xm

plog xqk,

2Recall that rd is supported on squarefree integers d. Thus, for any sum involving rd, the sums is restricted to squarefreeintegers.

10 KEVIN FORD

where degpfiq is the total degree of fi, and

S “ Spf1, . . . , fkq “ź

p

ˆ

1´ρppq

pm

˙ˆ

1´1

p

˙´k

is the so-called singular series associated with f1, . . . , fk.

One can show that ρppqpm´1 is k on average and this implies that the infinite product converges (detailsbelow in the case of univariate polynomials).

This conjecture subsumes a large number of conjectures that have been made over time, in various degreesof generality. We mention here the conjectures of Bunyakowsky [15], Dickson [27], Hardy-Littlewood [72],Schinzel [119], and Bateman-Horn [10].

Some special cases.

‚ Primes in an arithmetic progression. m “ 1, k “ 1, f1pnq “ qn` a, where pa, qq “ 1. Dirichletproved [28] in 1837 that there are infinitely many n with f1pnq prime; the Prime Number Theoremfor arithmetic progressions (de la Valee Poissin, 1896) gives the full asymptotic (1.10).

‚ Twin primes. m “ 1, k “ 2, f1pnq “ n, f2pnq “ n` 2. Here S “ C :“ 2ś

pą2p1´1

pp´1q2q “

1.32 . . . is the “twin prime constant”.‚ “Sexy” primes. m “ 1, k “ 2, f1pnq “ n, f2pnq “ n ` 6. Here S “ 2C since ρp2q “ ρp3q “ 1

and ρppq “ 2 for p ą 3. That is, there are twice as many “sexy primes” as twin primes.‚ Sophie Germain primes. m “ 1, k “ 2, f1pnq “ n, f2pnq “ 2n` 1.‚ Primes of form n2 ` 1. m “ 1, k “ 1, f1pnq “ n2 ` 1.‚ k-term arithmetic progressions of primes. m “ 2, forms n1, n1`n2, n1`2n2, . . . , n1`pk´1qn2.

When k “ 3, the asymptotic in Conjecture 1.3 was essentially proved by Vinogradov in 1937. Balog[5] extended this to include many other collections of forms withm ě 2. Green and Tao [65] showedthat there are infinitely many k-term arithmetic progressions of primes for any k ě 4, and this wasextended by Green and Tao and by Green, Tao and Ziegler [66, 67, 68, 69] in 2010–12 to provethe full asymptotic in (1.10). Their theory extends to many other collections of linear forms whenm ě 2.

‚ Primes of the form x2 ` y2. m “ 2, k “ 1, f1px, yq “ x2 ` y2. Fermat showed that every primep ” 1 pmod 4q is the sum of two squares.

‚ Primes of the form x2` y4. m “ 2, k “ 1, f1px, yq “ x2` y4. The infinitude of such primes, andin fact the full asymptotic (1.10), is a celebrated theorem of Friedlander and Iwaniec [55] in 1998.

The only case of (1.10) which is known when m “ 1 is the single linear f1 case. In fact, other than thecase k “ 1 and f1 linear, it is not known a single specific example of a set of forms for which there areinfinitely many n P Z making all of fipnq simultaneously prime.

There is a relatively easy heuristic for (1.10). According to the Prime Number Theorem, a randomlychosen integer near x has a likelihood of about 1

log x of being prime. Assuming that the fipxq behaverandomly, the likelihood of fipxq being prime should be about 1

log fipxq„ 1

degpfiq log x if each xi P r1, xs.This leads to the prediction that

#t0 ď xi ă x p1 ď i ď mq : f1pxq, . . . , fkpxq are all prime u „1

śki“1 degpfiq

xm

plog xqk.

This matches (1.10) except for the singular series factor. Implicit in the “randomness” hypothesis is theassumption that for any prime p, the likelihood that each of fipxq is coprime to p is about p1´ 1pqk. This

SIEVE METHODS LECTURE NOTES, SPRING 2020 11

is not correct, however, and if x is chosen randomly modulo p, then the likelihood that each of the fipxq iscoprime to p is exactly 1´ ρppqpm. Thus, in our heuristic we should insert a correction factor

ˆ

1´ρppq

pm

˙ˆ

1´1

p

˙´k

.

Doing this for all p produces a correction factor equal to Spf1, . . . , fkq, and leads to the more preciseprediction (1.10).

1.11. Brun’s pure sieve. Brun’s sieve is based on a simple truncated version of inclusion-exclusion, due toBrun (1915).

Lemma 1.4 (Inclusion-exclusion). Let u be a non-negative integer. Then, for any k P N,

1u“0 “

8ÿ

r“0

p´1qrˆ

u

r

˙

kÿ

r“0

p´1qrˆ

u

r

˙

` p´1qk`1

ˆ

u´ 1

k

˙

,

where we set`

´1j

˘

“ 0 for all j.

Proof. We may assume that u ě 1, as the statement is trivial when u “ 0. The first equality is trivial fromthe binomial theorem. For the second, when u ě 1 we have

8ÿ

r“k`1

p´1qrˆ

u

r

˙

8ÿ

r“k`1

p´1qr„ˆ

u´ 1

r ´ 1

˙

`

ˆ

u´ 1

r

˙

“ p´1qk`1

ˆ

u´ 1

k

˙

.

Theorem 1.5 (Brun’s pure sieve). Let k be a nonnegative integer and define

λd “

#

µpdq if ωpdq ď k

0 otherwise;.

Then λ satisfies (λ`) if k is even and (λ´) if k is odd. Thus, if ke is even and ko is odd, then for any sieveproblem A and any z ě 2 we have

(1.11)ÿ

dPPpzqωpdqďko

µpdqAd ď SpA, zq ďÿ

dPPpzqωpdqďke

µpdqAd.

Proof. Let k ě 0. Then, by Lemma 1.4,

1m“1 “ 1ωpmq“0 “

kÿ

r“0

p´1qrˆ

ωpmq

r

˙

` p´1qk`1W, W “

ˆ

ωpmq ´ 1

k

˙

ě 0,

kÿ

r“0

p´1qrÿ

d|mωpdq“r

1` p´1qk`1W

“ÿ

ωpdqďk

µpdq ` p´1qk`1W

“ÿ

d

λd ` p´1qk`1W,

from which follows (λ`) if k is even and (λ´) if k is odd. The final claim (1.11) follows from (1.6).

12 KEVIN FORD

In probability theory, the inequalities in Theorem 1.5 were later rediscovered by Bonferroni, and are oftenreferred to as the “Bonferroni inequalities”.

Lemma 1.6. Let z ě 2 and 0 ď fppq ď 1 for each prime p ď z. Let k be a non-negative integer. Extend fmultiplicatively by defining fpdq “

ś

p|d fppq for any squarefree d with d P Ppzq. Then

ÿ

dPPpzqωpdqďk

µpdqfpdq “ź

pďz

p1´ fppqq ` p´1qkW,

where

0 ďW ďÿ

dPPpzqωpdq“k`1

fpdq ď1

pk ` 1q!

ˆ

ÿ

pďz

fppq

˙k`1

.

Proof. By Theorem 1.5 and (1.7),ź

pďz

p1´ fppqq “ÿ

ωpdqďk

µpdqfpdq ` p´1qk`1W, 0 ďW ďÿ

ωpdq“k`1

fpdq.

The final inequality for W comes from expanding the pk ` 1q-fold sum (this is an old Erdos trick).

Theorem 1.7. Let A be a sieve problem, assume (g) and (r). Then

SpA, zq “ XV pzq `OpXV pzq32q `O

ˆ

ÿ

dďz4 logp1V pzqq`1

|rd|

˙

.

where V pzq is given by (V ).

Proof. Assume V pzq ą 0 otherwise there is nothing to prove. Now apply Theorem 1.5 with k “Y

4 log 1V pzq

]

,followed by an application of Lemma 1.6. This gives

SpA, zq “ÿ

dPPpzqωpdqďk

µpdqAd `O

ˆ

ÿ

dPPpzqωpdq“k`1

Ad

˙

“ Xÿ

dPPpzqωpdqďk

µpdqgpdq `O

ˆ

Xÿ

dPPpzqωpdq“k`1

gpdq

˙

`R

“ XV pzq `O

ˆ

X1

pk ` 1q!

ˆ

ÿ

pďz

gppq

˙k`1˙

`R,

where

|R| ďÿ

dPPpzqωpdqďk`1

|rd|.

SIEVE METHODS LECTURE NOTES, SPRING 2020 13

Lastly, by our definition of k,

1

pk ` 1q!

ˆ

ÿ

pďz

gppq

˙k`1

ď1

pk ` 1q!

ˆ

ÿ

pďz

´ logp1´ gppqq

˙k`1

“1

pk ` 1q!

ˆ

log1

V pzq

˙k`1

ď

˜

e log 1V pzq

k ` 1

¸k`1

ď pe4qk`1 ! V pzq4 log 4´4 ď V pzq32.

(1.12)

This completes the proof.

Remarks. We have imposed virtually no hypotheses on the sieve problem A in this theorem. In ap-plications, one has typically V pzq — plogXq´κ for some fixed κ, and thus we have applied (1.11) withk « 4κ log2X . Typically in the sum in identity (1.2) and the sums in Brun’s inequalities (1.11), the sum-mands corresponding to d ą X are negligible (or identically zero). Hardy and Ramanujan [74] in 1917showed that most integers d ď X have about log2X prime factors, and thus it is natural to choose ksomewhat larger than log2X in order to capture the bulk of the sum.

1.11.1. Example: twin primes. As before, let Ω “ r1, xs X Z, Ap “ tk P Ω : p|kpk ` 2qu. Take

gppq “ρppq

p, ρp2q “ 1, ρppq “ 2 pp ą 2q

and then, for squarefree d we have|rd| ď ρpdq ď τpdq.

By Mertens’ estimate (cf., (1.5)), V pzq „ cplog zq´2 for some constant c. Take

z “ x1

16 log2 x ,

so that in the summation of the error terms rd we have

z4 logp1V pzqq`1 “ z8 log2 z`Op1q ! x12`op1q.

Thus,ÿ

dPPpzqωpdqď4 logp1V pzqq`1

|rd| ďÿ

dďz4 logp1V pzqq`1

τpdq ! x12`op1q.

By Theorem 1.5,

SpA, zq „ XV pzq „cx

log2 z„ 256cx

ˆ

log2 x

log x

˙2

.

As SpA, zq ě #tz ă k ď x : k, k ` 2 both primeu, we see that

#tk ď x : k, k ` 2 both primeu ! x

ˆ

log2 x

log x

˙2

,

which misses the conjectured order by a factor plog2 xq2. Applying partial summation gives an immediate

corollary.

14 KEVIN FORD

Corollary 1.8 (Brun [18], 1919). We haveÿ

p:p,p`2 prime

1

pă 8.

Remarks. Applying Theorem 1.5 to the sieve of Eratosthenes yields πpxq ! x log2 xlog x , missing the true

order of πpxq by a factor log2 x.

Brun later [19] gave a much more complicated version of his sieve, where the simple truncation (1.11)is replaced by sieves where one considers the summation over integers d with restricted prime factors ofvarious sizes. A greatly simplified version of this idea was found by Hooley, and which will be the subjectof the following section.

SIEVE METHODS LECTURE NOTES, SPRING 2020 15

2. THE BRUN-HOOLEY SIEVE

In this section and the next, we present a variation of Brun’s pure sieve due to C. Hooley [87], which isvery simple, from a combinatorial viewpoint, and yet powerful enough to deliver quickly each of the desiredsieve bounds in (1.4). Some general estimates using this method were given by Ford and Halberstam [51].

2.1. Upper bounds. The fundamental idea of the upper bound sieve is to partition the primes into setsP1, . . . ,Pt and apply the Brun sieve bounds on each set Pi separately. The partition may be finite orinfinite, that is, we allow t “ 8.

Lemma 2.1. Partition the primes as P1 Y ¨ ¨ ¨ Y Pt. For each i, let λpiq “ pλpiqd qd be an upper bound sieve.For any squarefree d, let

λ`d “tź

i“1

λpiqdi,

where d1, . . . , dt are defined uniquely by

(2.1) d “ d1 ¨ ¨ ¨ dt, p@i, p|di ñ p P Piq.

Then λ` is an upper bound sieve, i.e., satisfies (λ`).

Proof. Clearly λ` “ 1. Also, for any m ą 1, m has a unique decomposition as m “ m1 ¨ ¨ ¨mt, where foreach i, all of the prime factors of mi are in Pi. Then, by (λ`),

ÿ

d|m

λ` “tź

i“1

ˆ

ÿ

di|mi

λpiqdi

˙

ě 0,

as required.

Taking each λpiqd to be an upper bound Brun sieve (from Theorem 1.5) with k “ ki even, we arrive at

Lemma 2.2 (The Brun-Hooley upper bound sieve). Let P1 Y ¨ Y Pt be any partition of the primes, and letk1, . . . , kt be arbitrary non-negative even integers. Then the sequence λ given by

(2.2) λ`d “

#

µpdq if ωpdjq ď kj p1 ď j ď tq

0 otherwise

is an upper bound sieve satisfying (λ`). Here d uniquel decomposes as in (2.1).

The number theoretic motivation for this comes from looking at the statistical distribution of prime factorsof integers ď X . Not only does a typical integer have about log2X prime factors, but the prime factorsthemselves are typically uniformly distributed on a log2-scale; that is, there are about log2 t prime factorsď t, uniformly for t ď X . With Lemma 2.2, we can restrict the number of large prime factors of thesummands d while still retaining almost all significant summands.

Suppose that we have a sieve problem A, z ě 2 and assume (g) and (r). Define

Pi “ź

pPPipďz

p p1 ď i ď tq

16 KEVIN FORD

From Lemma 2.2 and (1.6) we immediately get

SpA, zq ďÿ

d1|P1

ωpd1qďk1

¨ ¨ ¨ÿ

dt|Ptωpdtqďkt

µpd1q ¨ ¨ ¨µpdtqAd1¨¨¨dt

“ XU1 ¨ ¨ ¨Ut `R,

where

(2.3) Uj “ÿ

dj |Pjωpdjqďkj

µpdjqgpdjq, R “ÿ

d1|P1

ωpd1qďk1

¨ ¨ ¨ÿ

dt|Ptωpdtqďkt

µpd1 ¨ ¨ ¨ dtqrd1¨¨¨dt .

Define

(2.4) Vj “ź

pPPjpďz

p1´ gppqq, Lj “ log1

Vj.

Notice that V1 ¨ ¨ ¨Vt “ V pzq. Lemma 1.6 plus gppq ď ´ logp1´ gppqq implies

Vj ď Uj ď Vj `Lkj`1j

pkj ` 1q!“ Vj

˜

1` eLjLkj`1j

pkj ` 1q!

¸

ď Vj exp

#

eLjLkj`1j

pkj ` 1q!

+

.

The last inequality appears wasteful, but in practice the quantity in the exponential is small. When kj “ 0

we can omit the factor eLj sinceUj “ 1 “ VjV

´1j “ Vje

Lj .

This leads to small improvements in numerical constants. Multiplying these inequalities together for all j,we have

(2.5) V pzq ď U1 ¨ ¨ ¨Ut ď eEV pzq,

where

(2.6) E :“tÿ

j“1

eLj1kją0

Lkj`1j

pkj ` 1q!, .

We conclude from (1.6) and (1.8) the following.

Theorem 2.3. Let A be a sieve problem and assume (g), (r) and (V ). Partition the set of primes in r1, zsinto P1 Y ¨ ¨ ¨ Y Pt, let Pi “

ś

pPPi p and let k1, . . . , kt be non-negative even integers. Then

SpA, zq ď XV pzqeE `R1,

where E is given by (2.6) and

(2.7) R1 :“ÿ

ωppd,Pjqqďkj p1ďjďtq

P`pdqďz

|rd|.

In particular, defining λ`d as in Lemma 2.2, we have

(2.8)ÿ

d

λ`d gpdq ď eEV pzq.

SIEVE METHODS LECTURE NOTES, SPRING 2020 17

To make further progress and produce an upper bound of general utility, we make a very mild assumptionon the function g, which is satisfied in a large number of cases. It is sometimes called the Iwaniec condition.We assume that for some κ ě 0 and B ą 0 that

(Ω)ź

yďpďw

p1´ gppqq´1 ď

ˆ

logw

log y

˙κ

exp

ˆ

B

log y

˙

p2 ď y ď w ď zq

Roughly speaking, this states that gppq À κp on average over p. Although B, κ are not uniquely definedby (Ω), the smallest admissible value of κ (with B remaining bounded) is sometimes referred to as the“dimension” or “sifting density”. It is easy to show (cf., Exercise 2.1 below), that condition (Ω) is impliedby the condition

(Ω0) gppq ď min pκp, 1´ δq ,

with the same value of κ and δ ą 0 depending on κ and B. Although (Ω0) is easy to verify, for manyproblems we have (Ω) holding with a smaller value of κ than the global bound (Ω0), and this producesquantitatively better sieve bounds.

We can now obtain a general purpose upper bound of type in (1.4). In sums of remainders rd we recallthat rd is supported only on squarefree d.

Theorem 2.4. Let A be a sieve problem, let z ě 2 and assume (g), (r) and (V ). Let κ0 ą 0 and B0 ě 0.Assume (Ω) with 0 ď κ ď κ0 and 0 ď B ď B0. Then for any z ě 2 we have

SpA, zq ď Oκ0,B0pXV pzqq `ÿ

dďz

|rd|,

the implied constant depending only on κ0, B0.

Proof. Before invoking (Ω), we will work out a general procedure for producing upper bounds from Theo-rem 2.3. We suppose that

zt`1 “ 2 ă zt ă zt´1 ă ¨ ¨ ¨ ă z1 “ z

Pj “ tp prime : zj`1 ă p ď zju p1 ď j ď t´ 1q,

Pt “ tp prime : zt`1 ď p ď ztu.

(2.9)

This way, P1, . . . ,Pt partition the primes in r2, zs. The primes ą z play no role in SpA, zq and may beignored (or assigned arbitrarily to P1, for example). In the sum (2.7) defining R1, we have

d1 ¨ ¨ ¨ dt ď zk11 ¨ ¨ ¨ zktt .

A convenient choice iszj “ z14j´1

p1 ď j ď tq,

where t is chosen maximally so that (2.9) holds. We also take

k1 “ 0, kj “ 2j´1 pj ě 2q.

In (2.7), we have

(2.10) d ď zk11 ¨ ¨ ¨ zktt ď z

Invoking (Ω) and taking logarithms, we have

Lj “ÿ

zj`1ăpďzj

´ logp1´ gppqq ď κ log 4`B

log zj`1ď κ0 log 4`

B0

log 2“: L.

18 KEVIN FORD

Therefore, in the notation of Theorem 2.3,

(2.11) E ďtÿ

j“1

eLjLkjj

kj !ď eL

8ÿ

j“1

L2j`1

2j´1!!κ0,B0 1.

The theorem now follows from Theorem 2.3.

2.2. Applications of the upper bound sieve. Theorem (2.4) is very easy to apply in practice. It suffices toverify that the sifting function gppq has regular behavior ((Ω) or (Ω0)) and that the remainders rd are smallon average in some reasonable range.

2.2.1. Primes. Take the Eratosthenes sieve Ω “ r1, xs X N, Ap “ tn P Ω : p|nu, X “ x, gppq “ 1p,z “ X12. Then, by Theorem 2.4,

πpxq ď SpA, zq ` z ! XV pzq `Opzq !x

log x,

matching Chebyshev’s bound.

2.2.2. Prime k-tuples.

Theorem 2.5. Let a1, . . . , ak be non-zero integers and b1, . . . , bk integers. Let ρpdq be the number ofsolutions modulo d of

pa1n` b1q ¨ ¨ ¨ pakn` bkq ” 0 pmod dq,

and assume that ρppq ă p for all primes p (that is, the linear forms ain ` bi, 1 ď i ď k, are admissible).Also assume that E ‰ 0, where

E “

ˇ

ˇ

ˇ

ˇ

i“1

aiź

iăj

paibj ´ ajbiq

ˇ

ˇ

ˇ

ˇ

.

Then ρppq ‰ k if and only if p|E, and furthermore,

#tn ď x : ain` bi prime , 1 ď i ď ku !kSx

logk x

!kx

logk x

ź

p|E

ˆ

1´1

p

˙ρppq´k

!kx

logk x

ˆ

E

φpEq

˙k

,

where

S “ź

p

ˆ

1´ρppq

p

˙ˆ

1´1

p

˙´k

and the implied constants may depend on k alone.

Proof. Define our sieve problem as follows. Let Ω “ r1, xs X Z and

Ap “ tn P Ω : p|pa1n` b1q ¨ ¨ ¨ pakn` bkqu

for each prime p. Let X “ x and put z “ X12. For squarefree d, let ρpdq be the number of solutions nmod d of the congruence

pa1n` b1q ¨ ¨ ¨ pakn` bkq ” 0 pmod dq.

SIEVE METHODS LECTURE NOTES, SPRING 2020 19

By the Chinese remainder theorem, ρ is multiplicative. Now let p be prime and consider ρppq. Sinceρppq ă p, it follows that pai, biq “ 1 for all i. Then the congruence ain ` bi ” 0 pmod pq has a solutionif and only if p - ai. Hence, if p|ai for some i, then ρppq ă k. Now suppose that p - a1 ¨ ¨ ¨ ak, and for eachi let ri be the unique residue class modulo p with airi ` bi ” 0 pmod pq. It is clear that ri “ rj if andonly if p|paibj ´ ajbiq. Thus, if p|E then ρppq ă k, and if p - E then r1, . . . , rk all exist and are distinct, soρppq “ k. This proves the first claim.

Setting gppq “ ρppqp, we see that (Ω0) holds with δ “ 1pk`1q and κ “ k. Then (Ω) holds with κ “ k

and some B depending only on k. Moreover,

Ad “ xρpdq

d` rd, |rd| ď ρpdq,

and thusÿ

dďz

|rd| ďÿ

dďx12

ρpdq ď x12ÿ

dďx12

ρpdq

dď x12

ź

pďz

ˆ

1`k

p

˙

!k x12plog xqk

by Mertens’ theorem. By Theorem 2.4 plus the easy bound

V pzq "kź

2kăpďz

p1´ kpq "k1

logk z"k

1

logk x,

we haveSpA, zq !k xV pzq ` x12plog xqk ! xV pzq.

There are at most z values of n ď x such that ain` bi are all prime and ď z. Thus,

#tn ď x : ain` bi prime , 1 ď i ď ku ď z ` SpA, zq ! x12 ` xV pzq ! xV pzq.

Next,

V pzq “ź

pďz

ˆ

1´ρppq

p

˙

!k1

plog zqk

ź

pďz

ˆ

1´ρppq

p

˙ˆ

1´1

p

˙´k

“S

plog zqk

ź

pąz

ˆ

1´ρppq

p

˙´1 ˆ

1´1

p

˙k

!kS

plog xqk

ź

pą2k

ˆ

1´k

p

˙´1 ˆ

1´1

p

˙k

!kS

plog xqk.

Finally, since ρppq “ k if and only if p - E, p1´kpqp1´1pq´k “ 1`Okp1p2q and 1´ρp ď p1´1pqρ,

we have

S !k

ź

p|E

ˆ

1´ρppq

p

˙ˆ

1´1

p

˙´k

ďź

p|E

ˆ

1´1

p

˙ρppq´k

ď

ˆ

E

φpEq

˙k

.

Remarks. Examining the proof, we see that S "k 1, that is , S is bounded away from zero. On the otherhand, S is not bounded above as one of the following examples shows.

20 KEVIN FORD

Corollary 2.6. We have, for positive m,

#tp ď x : p, p` 2m both primeu !2m

φp2mq

x

log2 x,

#tp ď x : p, 2p` 1 both primeu !x

log2 x,

#tp, q prime : p` q “ 2mu !σpmq

m

m

log2m.

Proof. The count of generalized twin primes is the special case k “ 2 with the forms n, n ` 2m. Hereρppq “ 1 for p|2m and ρppq “ 2 otherwise, and we have

S —ź

p|2m

ˆ

1´1

p

˙´1

“2m

φp2mq.

Also, E “ 2m. The count of Sophie Germain is easier: here we use the forms n, 2n` 1 and E “ 2. For theapplication to Goldbach’s Conjecture, take the forms n, 2m ´ n, which gives E “ 2m. The final estimatecomes from the elementary bound m

φpmq !σpmqm .

2.2.3. The Brun-Titchmarsh inequality. Denote by πpx; q, aq the number of primes p ď x satisfying p ” a

pmod qq.

Theorem 2.7 (Brun-Titchmarsh inequality). There is a constantC so that uniformly for 1 ď a ď q ă y ď x

and pa, qq “ 1,

πpx; q, aq ´ πpx´ y; q, aq ď Cy

φpqq logpyqq.

Remarks. The case a “ q “ 1, that is, showing that πpxq ´ πpx ´ yq ! y log y, was asserted byHardy and Littlewood [72, p. 69] without proof, the authors claiming that it followed from the method ofBrun [19]. Using the Eratosthenes sieve, Hardy and Littlewood [72, Theorem G] showed the weaker boundπpxq ´ πpx ´ yq ! y

log2 y. The case x “ 0 with an arbitrary a, q was shown by Titchmarsh [129]. The

constant C “ 2 is admissible by work of Montgomery and Vaughan [100]. The utility of this bound isits uniformity in x, y, a, q. If πpx; q, aq :“ #tp ď x : p ” a pmod qqu, the prime number theorem forarithmetic progressions implies that

πpx; q, aq „x

φpqq log x

for every individual q, a. Issues of uniformity are crucially important, and are intimately connected toquestions of the existence of zeros of L-functions lying off the critical line (especially so-called Siegelzeros, real zeros lying very close to 1). If one assumes the Generalized Riemann Hypothesis, then the aboveasymptotic holds uniformly for q ď

?x or so, and in a smaller range if one considers primes in “short”

intervals px´ y, xs. On the other hand, the Brun-Titchmarsh inequality gives an upper bound of the correctorder even for very large moduli q “ x1´ε and for very short intervals yq “ xε (ε ą 0 fixed).

Proof. WLOG assume that y ą 2q, for otherwise trivially the left side is ď 2 while the right side isě C logpyqq ě C log 2. Write

tx´ y ă n ď x : n ” a pmod qqu “ tqph` 1q ` a, . . . , qph`mq ` au.

SIEVE METHODS LECTURE NOTES, SPRING 2020 21

Apply Theorem 2.5 with k “ 1 and the single form qn`pqh`aq, where 1 ď n ď m. Here E “ q and thus

πpx; q, aq ´ πpx´ y; q, aq !q

φpqq

m

logm.

Since m — yq, the theorem follows.

2.2.4. Romanoff’s Theorem.

Theorem 2.8 (Romanoff [115], 1934). A positive proportion3 of positive integers can be expressed as p`2k

where p is prime and k is a non-negative integer.

Proof. We start with a common device for lower-bounding the size of a set defined by solutions of someequation. Let

rpnq “ #tpp, kq : k ě 1, n “ p` 2ku

and Bpxq “ #tn ď x : rpnq ą 0u. We need to show that Bpxq " x for large x. Assume that x ě 100. ByCauchy-Schwarz,

ˆ

ÿ

nďx

rpnq

˙2

ˆ

ÿ

nďx

rpnq1rpnqą0

˙2

ďÿ

nďxrpnqą0

1ÿ

nďx

rpnq2

“ Bpxqÿ

nďx

rpnq2.

On the other hand,ÿ

nďx

rpnq ě #tpp, kq : p ď x2, 2k ď x2u " πpx2q log x " x

and, since n ď x implies that p ď x and 2k ď x,ÿ

nďx

rpnq2 “ÿ

nďx

#tpp1, p2, k1, k2q : p1 ` 2k1 “ p2 ` 2k2 “ nu

ď D :“ #tpp1, p2, k1, k2q : pj ď x, 2kj ď x for j “ 1, 2; p1 ` 2k1 “ p2 ` 2k2u.

It follows that

(2.12) Bpxq "x2

D.

There are Opxq quadruples pp1, p2, k1, k2q with p1 “ p2 and k1 “ k2. Thus,

D ! x`#tpp1, p2, k1, k2q : p1 ă p2 ă x, 2kj ď x for j “ 1, 2; p2 “ p1 ` 2k1 ´ 2k2u.

Now fix k1 ą k2 ě 1. Now apply Corollary 2.6 with 2m “ 2k1 ´ 2k2 . With k1 and k2 fixed, the number ofpossible pairs p1, p2 with p1 ď x is

!2k1 ´ 2k2

φp2k1 ´ 2k2q

x

log2 x

3If A is a set of natural numbers with counting function Apxq “ #ta ď x : a P Au satisfying lim infxÑ8Apxqx ą 0, wesay that A contains a positive proportion of all positive integers.

22 KEVIN FORD

and hence

D ! x`x

log2 x

ÿ

0ăk2ăk1ďlog xlog 2

2k1 ´ 2k2

φp2k1 ´ 2k2q.

Factoring out 2k2 we see that

2k1 ´ 2k2

φp2k1 ´ 2k2q!

2l ´ 1

φp2l ´ 1q, l “ k1 ´ k2.

Also,2l ´ 1

φp2l ´ 1q!σp2l ´ 1q

2l ´ 1“

ÿ

d|2l´1

1

d.

For each l there are Oplog xq pairs pk1, k2q with k1 ´ k2 “ l and thus

D ! x`x

log x

ÿ

1ďlď log xlog 2

ÿ

d|2l´1

1

d

! x`x

log x

ÿ

dďxd odd

1

d

ÿ

1ďlď log xlog 2

d|2l´1

1.

If spdq denotes the order of 2 modulo d, then the inner sum counts l ď log xlog 2 which are divisible by spdq and

is therefore Op log xspdq q. We arrive at

(2.13) D ! x` xÿ

dďxd odd

1

dspdq.

Following Erdos, we show that the sum on d converges, when extended to a sum over all odd positiveintegers. To this end, define

tk “ÿ

d oddspdqďk

1

d,

which is finite since spdq " log d. Partial summation gives

(2.14)ÿ

d

1

dspdq“

ÿ

k

tkkpk ` 1q

.

LettingNk “

ź

iďk

p2i ´ 1q,

we see that spdq ď k implies that d|Nk. Also Nk ď 21`2`¨¨¨`k ă 2k2, and so

tk ďÿ

d|Nk

1

d“σpNkq

Nk! log2Nk ! log k.

Thus, the sum on the right side of (2.14) converges, as desired. Consequently, by (2.13), D ! x. Recalling(2.12), the proof is complete.

SIEVE METHODS LECTURE NOTES, SPRING 2020 23

Remark 1. Evidently, almost all even integers are not of the form p` 2k. Erdos [35] showed that a positiveproportion of odd numbers are not of the form p` 2k. This paper introduced the notion of covering systemsof congruences.

2.2.5. Sums of primes: Schnirelmann’s theorem. In the 1933, Schnirelmann [121] showed that there is aconstant k so that every positive integer ě 2 is the sum of at most k primes. This was a huge step in thedirection of Goldbach’s Conjecture. His proof combined the sieve upper bound with a very elementaryargument.

Given a set A Ă N Y t0u, let ApNq be the counting function of A (excluding zero), that is, ApNq “#tn P A : 1 ď n ď Nu. The Schnirelmann density σpA q of A is defined as

σpA q “ infNě1

ApNq

N.

Examples:‚ σpA q “ 1 if and only if A Ą N‚ if 1 R A then σpA q “ 0.‚ σpt1, 3, 5, 7, 9, 11, . . .uq “ 12.‚ σpt1, 4, 9, 16, 25, . . .uq “ 0.

Given any two sets A ,B of integers, define the sumset A `B by

A `B “ ta` b : a P A , b P Bu.

We denote the k-fold subset kA inductively as kA “ pk´ 1qA `A , so that kA is the set of integers thatcan be written as the sum of k (not necessarily distinct) elements of A .

Theorem 2.9 (Shnirelmann [121], 1933). (a) Suppose that 0 P B and 1 P A . Then

σpA `Bq ě σpA q ` σpBq ´ σpA qσpBq.

(b) If 0 P A , 0 P B and σpA q ` σpBq ě 1 then A `B “ NY t0u.

The conclusion of part (a) is conveniently written as

1´ σpA `Bq ď p1´ σpA qqp1´ σpBqq.

In general, the conclusion is best possible, for example if

A “ t1, 5, 6, 7, 8, 9, . . .u, B “ t0, 1, 4, 5, 6, 7, 8, . . .u

then A `B “ t1, 2, 5, 6, 7, 8, 9, . . .u, σpA q “ 14 , σpBq “ 1

3 and σpA `Bq “ 12 .

Corollary 2.10 (Schnirelmann [121]). Suppose that 0 P A and σpkA q ą 0 for some k P N. Then for someh P N, hA “ NY t0u.

Proof that Theorem 2.9 implies Corollary 2.10. Let B “ kA . Obviously 0 P B. Since σpBq ą 0, wehave 1 P B. Hence, t0, 1u Ă rB for all r P N. By Theorem 2.9 (a), for any r P N we have

1´ σppr ` 1qBq ď p1´ σpBqqp1´ σprBqq.

By induction,1´ σprBq ď p1´ σpBqqr

Hence, for some r, σprBq ě 12. Then, by Theorem 2.9 (b), we conclude that σp2rBq “ 1, that is,

2rkA “ 2rB “ NY t0u,

24 KEVIN FORD

as required.

Proof of Theorem 2.9. We begin with (a). Let N P N and enumerate the elements of A X r1, N s as 1 “

a1 ă a2 ă . . . ă ar ď N . These integers are separated by gaps of gi “ ai`1 ´ ai ´ 1 numbers not in A ,plus a final gap of gr “ N ´ ar integers from ar ` 1 to N . Let C “ A `B. Then C X r1, N s containsA X r1, N s, plus additional numbers ai ` b, where b P B, 1 ď b ď gi. The number of such elements b isě giσpBq. It follows that

CpNq ě ApNq `rÿ

i“1

σpBqgi

“ ApNq ` σpBqpN ´ApNqq

“ ApNqp1´ σpBqq `NσpBq

ě N´

σpA qp1´ σpBqq ` σpBq¯

.

As this is true for every N , σpC q ě σpA q ` σpBq ´ σpA qσpBq.To prove (b), first observe that 1 P A YB, so that 1 P A `B. Suppose that A `B ‰ N Y t0u and

that n R A `B. Then n ě 2, n R A and n R B. Thus,

Apn´ 1q `Bpn´ 1q “ Apnq `Bpnq ě npσpA q ` σpBqq ě n.

Now letC “ ta P A : 1 ď a ď n´ 1u, D “ tn´ b : 1 ď b ď n´ 1, b P Bu.

Then |C | ` |D | ě n. But C ,D Ă r1, n ´ 1s, hence by the pigeonhole principle, C and D must have acommon element, thus n P A `B, a contradiction. Therefore, A `B “ NY t0u.

We now apply these results to primes. Let P denote the set of primes and set P0 “ P Y t0, 1u. NowσpP0q “ 0 by the prime number theorem. However, by Exercise 2.5 below, we have σp2P0q ą 0. Hence,by Corollary 2.10, there is an h so that hP0 “ N Y t0u. We also have h ě 3, since 27 R 2P0. Thus, forany positive integer n ě 4, we have

n´ 2 “ p1 ` ¨ ¨ ¨ ` pr ` s ¨ 1

where p1, . . . , pr are primes, r ě 0, s ě 0 and r ` s ď h. Now 2 ` s “ 2k ` 3l where k ě 0, l ě 0 andk ` l ď s` 1. Thus, n is the sum of at most r ` s` 1 “ h` 1 primes. We conclude that

Theorem 2.11 (Schnirelmann [121], 1933). For some h P N, every positive integer ě 2 is the sum of atmost h primes.

2.2.6. Primitive roots of primes. Are there infinitely many primes p for which the fraction 1p has periodp ´ 1 in base 10? Equivalently, is 10 a primitive root of p for infinitely many primes p? This question wasaddressed by Gauss in his Disquisitiones Arithmeticae (1801). In 1927, E. Artin conjectured an asymptoticformula for the number of primes p ď x for which a given squarefree integer a is a primitive root; his formulawas later discovered not to hold up against numerical data by D. H. Lehmer, and a revised conjecture waslater proposed by H. Heilbronn and others. In 1967, C. Hooley deduced the revised conjecture from theGeneralized Riemann Hypothesis for certain Dedekind zeta functions ζKpsq [82]; see also [86, Ch. 3].The theorem makes use of sieve methods. Here we will specialize to the case a “ 2. For background onDedekind zeta functions, see [89, Sec. 5.10].

SIEVE METHODS LECTURE NOTES, SPRING 2020 25

Theorem 2.12 (Hooley [82]). Assume the Generalized Riemann Hypothesis for ζKpsq for the number fieldsK “ Qp k

?2, e2πikq, k running over all squarefree integers. Then

#tp ď x : 2 is a primitive root of pu „ Cπpxq, C “ź

q prime

ˆ

1´1

qpq ´ 1q

˙

.

Proof. We set this up as a general sieve problem as follows. Let Ω be the set of primes p ď x, and for anyprime q, let

Aq “

!

p P Ω : q|p´ 1 and 2pp´1qq ” 1 pmod pq)

.

Clearly, 2 is a primitive root of p (order p ´ 1) if and only if p R Aq for all primes q (and it suffices tocheck for primes q ď p). We need good, uniform bounds for Ad. Bounds for individual d, but with pooruniformity, are available unconditionally by the analog of the prime number theorem for the number fieldsK (the prime ideal theorem of Landau), but the uniformity is very poor, especially for xop1q ă d ď

?x, and

not good enough for our application.

Lemma 2.13 (Hooley [82]). Assume the Generalized Riemann Hypothesis for the Dedekind zeta functionsζKpsq for all of the number fields K “ Qp k

?2, e2πikq, k running over all squarefree integers. Then,

uniformly for squarefree d ď x,

Ad “lipxq

dφpdq`Op

?x log xq.

Define the cutoffs

z1 “1

6log x, z2 “

?xplog xq´2, z3 “

?x log x.

Evidently,

(2.15) SpA, z1q ě #tp ď x : 2 is a primitive root of pu ě SpA, z1q ´ S1 ´ S2 ´ T,

where

S1 “ÿ

z1ăqďz2

Aq, S2 “ÿ

z2ăqďz3

Aq, T “ #tp ď x : p P Aq for some q ą z3u.

Using the Legendre sieve (Theorem 1.2) with X “ lipxq and with gpdq “ 1dφpdq , Lemma 2.13 gives

SpA, z1q “ lipxqź

qďz1

ˆ

1´1

qpq ´ 1q

˙

`Op?xplog xq2πpz1qq

ˆ

C `O

ˆ

1

log x

˙˙

lipxq “

ˆ

C `O

ˆ

1

log x

˙˙

πpxq.

For S1, we again use Lemma 2.13 and obtain

S1 “ÿ

z1ăqďz2

ˆ

lipxq

qpq ´ 1q`Op

?x log xq

˙

!lipxq

log x`?xplog xqπpz2q !

πpxq

log x.

26 KEVIN FORD

For S2, the bounds from Lemma 2.13 are too poor, but we do better by observing that Aq ď πpx; q, 1q andusing Theorem 2.7 (the Brun-Titchmarsh inequality):

S2 ďÿ

z2ăqďz3

πpx; q, 1q !ÿ

z2ăqďz3

x

q log x!

x

log2 x

ÿ

z2ăqďz3

log q

q

!x

log2 xlog

z3

z2!x log2 x

log2 x! πpxq

log2 x

log x.

Finally, if p P Aq for some q ą z3, then p|p2m ´ 1q for some positive integer m ď?x log x. Thus, p|M ,

whereM “

ź

mď?x log x

p2m ´ 1q.

Thus,

T ď #tp|M : p primeu ďlogM

log 2!

ˆ ?x

log x

˙2

“x

log2 x!πpxq

log x.

Combining the estimates for SpA, z1q, S1, S2 and T with (2.15) proves the theorem.

In 1986, Heath-Brown [80] showed that for all but at most two primes r,

tp : r is a primitive root of pu

is infinite. We cannot say which two prime might be exceptional, or even give a bound on the exceptionalprimes. We will revisit this type of result later.

2.3. Exercises.

Exercise 2.1. Assume condition (Ω0). Show that (Ω) holds with the same value of κ and with B dependingonly on δ, κ.

Exercise 2.2. For each prime, let Ip denote a set of residue classes modulo p. suppose that |Ip| ď κ for allp. Show that

#tx ă n ď x` y : @p ď z, n mod p R Ipu !κ yź

pďz

ˆ

1´|Ip|p

˙

,

uniformly for 2 ď z ď y and all x.

Exercise 2.3. Let k be a positive, even integer. Assuming Conjecture 1.10 for the pair of linear formspn, n` kq, prove that

#tn ď x : n and n` k are consecutive primesu „apkqx

log2 xpxÑ8q,

where

apkq “ Cź

p|k,pą2

p´ 1

p´ 2, C “ 2

ź

pě3

ˆ

1´1

pp´ 1q2

˙

,

C being the “twin prime constant”.

Exercise 2.4. Show that for any odd N ,

#tpp1, p2, p3q : N “ p1 ` p2 ` p3u !N2

log3N,

the constant being absolute.

SIEVE METHODS LECTURE NOTES, SPRING 2020 27

Exercise 2.5. We say that an even number k is a Goldbach number if there exists primes p1, p2 such thatk “ p1 ` p2. Show that a positive proportion of all positive integers are Goldbach numbers.

Exercise 2.6. Let Ξpx, y, zq denote the number of integers n ď x which have no prime factor in py, zs.Prove that uniformly in 1.5 ď y ď z ď x, we have

Ξpx, y, zq !x log y

log z.

Exercise 2.7. Prove thatÿ

pďx

Ωpp´ 1q !x log2 x

log x,

where Ωpnq is the number of prime power divisors of n.

Exercise 2.8. Let S denote the set of integers that are the sum of two squares.

(a) Show that S has counting function Opxplog xq´12q.(b) Let h P N. Show that, uniformly in h,

#tn ď x : n P S, n` h P Su !ź

p|hp”3 pmod 4q

ˆ

1`1

p

˙

x

log x.

Exercise 2.9. (Landau-Lehmer problem). Let q P N, q ě 2, and let R be a collection of reduced residueclasses modulo q. Prove that the number of integers n ď x lacking any prime factor that lies in one of thecongruence classes of R is bounded above by

!qx

plog xq|R|φpqq.

Exercise 2.10. Let A denote the set of positive, squarefree integers.(a) Show that the Schnirelmann density σpA q ą 12.(b) Show that every integer n ě 2 is the sum of exactly two squarefree integers.(This does not follow

immediately from Theorem 2.9 (b)).

Exercise 2.11. Let B be the set of primes that are of the form a2 ` b4 for some integers a, b. Prove that

#tp ď x : p P Bu ! x34

log x.

Exercise 2.12. Let 1 ď a ď q, pa, qq “ 1. Prove that uniformly in a, q and x ě 10 we have

ÿ

qďpďxp”a pmod qq

1

p!

log2 x

φpqq.

Note that the condition p ě q is necessary, as the least prime that is ” a pmod qq might be a, which couldbe very small.

28 KEVIN FORD

2.4. The Brun-Hooley sieve: lower bounds. Our lower bound for SpA, zq is derived from the upper boundin Lemma 2.2 by subtracting off appropriate quantities. We use the following simple inequality:

Lemma 2.14. Suppose that 0 ď xj ď yj for 1 ď j ď t. Then

x1 ¨ ¨ ¨xt ě y1 ¨ ¨ ¨ yt ´tÿ

`“1

py` ´ x`qtź

j“1j‰`

yj .

Proof. The inequality is an equality when t “ 1, and follows by induction on t using

y1 ¨ ¨ ¨ yt ´ x1 ¨ ¨ ¨xt “ py1 ¨ ¨ ¨ yt´1 ´ x1 ¨ ¨ ¨xt´1qyt ` x1 ¨ ¨ ¨xt´1pyt ´ xtq

ď py1 ¨ ¨ ¨ yt´1 ´ x1 ¨ ¨ ¨xt´1qyt ` y1 ¨ ¨ ¨ yt´1pyt ´ xtq.

As before, partition the primes in r2, zs into sets P1, . . . ,Pt and let k1, . . . , kt be nonnegative even inte-gers. We apply Lemma 2.14 with

xj “ÿ

d|pn,Pjq

µpdq, yj “ÿ

d|pn,Pjqωpdqďkj

µpdq p1 ď j ď tq,

where k1, . . . , kt are even, nonnegative integers. From Lemma 1.6 (with fppq “ 1 for each p) we have that

0 ď y` ´ x` ďÿ

d|pn,P`qωpdq“k``1

1.

Hence by Lemma 2.2 and Lemma 2.14, for any n with P`pnq ď z we obtain

(2.16) 1n“1 “ÿ

d|n

µpdq ětź

j“1

ÿ

dj |pn,Pjqωpdjqďkj

µpdjq ´tÿ

`“1

ˆ

ÿ

d`|pn,P`qωpd`q“k``1

1

˙ tź

j“1j‰`

ÿ

dj |pn,Pjqωpdjqďkj

µpdjq.

Thus, we have a lower bound sieve with coefficients (here d “ d1 ¨ ¨ ¨ dt with di “ pd, Piq for each i)

(2.17) λ´d “

$

&

%

µpdq if dj |Pj , ωpdjq ď kj p1 ď j ď tq

µpdq if dj |Pj p1 ď j ď tq, D` : ωpdjq ď kj pj ‰ `q, ωpd`q “ k` ` 1

0 otherwise.

From (1.6),

SpA, zq ěÿ

d1,...,dt@j:dj |Pj ,ωpdjqďkj

µpd1q ¨ ¨ ¨µpdjqAd1¨¨¨dt ´tÿ

`“1

ÿ

d1,...,dtdj |Pj ,ωpdjqďkj pj‰`qd`|P`,ωpd`q“k``1

µ

ˆ

d1 ¨ ¨ ¨ dtd`

˙

Ad1¨¨¨dt .

As before, introduce the conditions (g) and (r), and the shorthand notation (V ). Adopting our previousnotation (2.3) for quantities Uj , we can rewrite this as

SpA, zq ě XU1 ¨ ¨ ¨Ut

˜

1´tÿ

`“1

1

U`

ÿ

d`|P`ωpd`q“k``1

gpd`q

¸

´ rR,

SIEVE METHODS LECTURE NOTES, SPRING 2020 29

whererR “

ÿ

dPD|rd|,

and D is the set of squarefree numbers d that satsify P`pdq ď z, ωppd, Pjqq ď kj ` 1 for all j andωppd, Pjqq “ kj ` 1 for at most one j. Define Vj and Lj by (2.4). By Lemma 1.6, Ui ě Vi for every i, thusin particular

U1 ¨ ¨ ¨Ut ě V pzq, 1U` ď eL`1k`ą0 .

Another invocation of the Erdos trick (cf., the proof of Lemma 1.6) gives

ÿ

d`|P`ωpd`q“k``1

gpd`q ď1

pk` ` 1q!

ˆ

ÿ

pPP`

gppq

˙k``1

ďLk``1`

pk` ` 1q!.

We partition the primes in r2, zs as in (2.9). Then

rR ďÿ

P`pdqďzdďD

µ2pdq|rd|, D “ zk1`11 zk22 ¨ ¨ ¨ zktt .

We arrive at a first general lower bound sieve.

Theorem 2.15. Let A be a sieve problem and assume (g), (r) and (V ). Partition the set of primes in r2, zsas in (2.9) and let k1, . . . , kt be nonnegative even integers. Then

SpA, zq ě XV pzqp1´ Eq ´R2,

where E is given by (2.6) and

(2.18) R2 “ÿ

P`pdqďz

dďzk1`11 z

k22 ¨¨¨z

ktt

µ2pdq|rd|,

In terms of the lower bound sieve coefficients (2.17), we have shown that

(2.19) p1´ EqV pzq ďÿ

d

λ´d gpdq ď V pzq,

where E is given by (2.6) and the upper bound comes from (1.7).Incorporating (Ω), we can derive a lower bound of general utility.

Theorem 2.16. Let A be a sieve problem and assume (g), (r) and (V ). Assume also (Ω) with κ ą 0. Then,if z is large enough as a function of κ,B, we have

SpA, zq ě 0.0001XV pzq ´ÿ

P`pdqďz

dďzfpκq

µ2pdq|rd|,

where

fpκq “ 1`8ÿ

m“1

2m

expt0.26249m2κu.

Moreover, we have fpκq ď 1 ` 3.81κ for all κ ą 0, fpκq ď 56 ` 3.81κ for κ ě 0.05 and fpκq Ñ 1 as

κÑ 0`.

30 KEVIN FORD

Proof. Let ξ “ 0.26249 and define αj “ exptξpj ´ 1q2κu and

zj “ z1αj p1 ď j ď tq

in (2.9), where t is maximally chosen satisfying the first line of (2.9). Also take kj “ 2j ´ 2 for all j. By(2.4) and (Ω),

(2.20) Lj ď κ logαj`1 ´ κ logαj `B

log zj`1“ ξp2j ´ 1q `

αj`1B

log z.

We bound E by separating the sum appearing in (2.6) into those summands with αj`1 ď?

log z and thosewith αj`1 ą

?log z. The former summands contribute

ď eB?

log z8ÿ

j“1

eξp2j´1q1ją1

`

ξp2j ´ 1q `B?

log z˘2j´1

p2j ´ 1q!

8ÿ

j“1

eξp2j´1q1ją1pξp2j ´ 1qq2j´1

p2j ´ 1q!`OB,κ

ˆ

1?

log z

˙

ă 0.99967``OB,κ

ˆ

1?

log z

˙

.

Since αj`1 ą?

log z implies that j "a

log2 z, and eξpξeq ď 0.95, the terms with αj`1 ą?

log z

contribute

ď eB log 2ÿ

αj`1ą?

log z

eξp2j´1q pξp2j ´ 1q `B log 2q2j´1

p2j ´ 1q!“ oκ,Bp1q pz Ñ8q.

Therefore, for large enough z,E ď 0.9999.

Finally, for R2 we have

zk1`11 zk22 zk33 ¨ ¨ ¨ ď z1`2α2`4α3`6α4`¨¨¨ “ zfpκq.

Invoking Theorem 2.15, the proof is complete. The bounds on fpκq are straightforward, and given asExercise 2.15 (a).

2.4.1. Application: twin primes. We take Ω “ r1, xs X Z, Ap “ tn P Ω : p|npn` 2qu, X “ x. As we sawpreviously, gppq “ ρppqp with ρp2q “ 1, ρppq “ 2 for p ą 2, so (Ω0) holds with κ “ 2, as does Ω. Here,fp2q ď 8.46. Taking z “ x18.5 we have

ÿ

dďzfp2q

µ2pdq|rd| ďÿ

dďzfp2q

τpdq ! zfp2q log z ! x0.996,

which is negligible. Since V pzq " 1 log2 z " 1 log2 x we conclude from Theorem 2.16 that

SpA, zq " x

log2 x.

We conclude that there are " x log2 x integers n ď x, such that each of n and n` 2 have at most 8 primefactors, as these factors are ą z.

Now we approach the problem as in Example (c) (this is A. Renyi’s approach), taking

Ω “ tp` 2 : p prime ď xu, X “ lipxq,

SIEVE METHODS LECTURE NOTES, SPRING 2020 31

and Ap “ tn P Ω : p|nu. Here

Ad “ πpx; d,´2q “lipxq

φpdq` rd,

where rd is expected to be small by the prime number theorem for arithmetic progressions. Taking gpdq “1φpdq, we easily verify the (Ω) holds with κ “ 1. Indeed, for y ě 3, Mertens’ bounds give

ź

yďpďw

p1´ gppqq´1 “ź

yďpďw

ˆ

1´1

p´ 1

˙´1

“ź

yďpďw

ˆ

1´1

p

˙´1 ˆ

1´1

pp´ 1q2

˙´1

ďlogw

log y

ˆ

1`O

ˆ

1

log y

˙˙

.

For the error terms rd, we use the famous theorem of Bombieri and Vinogradov:

Theorem 2.17 (Bombieri-A.I.Vinogradov, 1965). For every A ą 0 there is a B ą 0 so thatÿ

qďx12plog xq´B

maxyďx

maxpa,qq“1

ˇ

ˇ

ˇ

ˇ

πpy; q, aq ´lipyq

φpqq

ˇ

ˇ

ˇ

ˇ

!x

plog xqA.

In Theorem 2.16, we have fp1q ď 4.65. Take z “ x19.4 so that zfp1q ď x0.499. Hence, Theorem BV

impliesÿ

dďzfp1q

|rd| “ÿ

dďzfp1q

ˇ

ˇ

ˇ

ˇ

πpx; d,´2q ´lipxq

φpdq

ˇ

ˇ

ˇ

ˇ

!x

plog xq10.

We conclude that for large x,SpA, zq " XV pzq "

x

log2 x.

Finally, we observe that SpA, zq counts primes p such that p`2 has no prime factorď z; in particular, p`2

has at most 9 prime factors.

2.4.2. Prime values of polynomials. Generalizing greatly the study of twin primes, we can use the sieve tostudy prime values of arbitrary polynomials.

Theorem 2.18. Let F1, . . . , Fk be distinct, irreducible polynomials in Zrxs, each with positive leadingcoefficient. Put F “ F1 ¨ ¨ ¨Fk, ` “ degpF q. Suppose pF1, . . . , Fkq is admissible. Then

(2.21) #tn ď x : Fipnq prime for every iu !Fx

logk x.

Further, there is an integer m “ Opk`q such that for large x,

(2.22) #tn ď x : ΩpFipnqq ď m p1 ď i ď kqu "Fx

logk x.

Proof. We will show the upper bound (2.21), leaving (2.22) as an exercise (cf., Exercise 2.13 below). Let xbe large, Ω “ r1, xs X N, Ap “ tn P Ω : p|F pnqu for primes p, X “ x, z “ x12. Generically write

ρGpdq “ #t0 ď n ă d : Gpnq ” 0 pmod dqu,

where G is any polynomial. As with twin primes, we have

Ad “ρF pdq

dX ` rd, |rd| ď ρF pdq,

32 KEVIN FORD

and so we set gpdq “ ρF pdqd. Now ρF is multiplicative by the Chinese remainder theorem. Also,

ρF ppq ă p by hypothesis,

ρF ppq ď ` by Lagrange’s theorem.

In particular, (Ω0) holds with κ “ ` and δ “ 1`. Thus,ÿ

dďz

|rd| ďÿ

dďx12

dgpdq ď x12ÿ

dPPpzq

gpdq “ x12ź

pďz

p1` gppqq

ď x12ź

pďz

ˆ

1``

p

˙

!` x12plog xq` !` x

23.

By Theorem 2.4 and the trivial lower bound V pzq "F plog xq´`, we have

SpA, zq ! XV pzq.

As before, the left side is at least as large as the count of k ď x such that each Fipkq is prime and ą z (andthere are OF pzq values of k with each of Fipkq prime, and one of them is ď z). It remains to bound V pzqfrom above. To do this, we need the following two facts:

ρF ppq “ ρF1ppq ` ¨ ¨ ¨ ` ρFkppq for all but finitely many p,(2.23)

ÿ

pďy

ρFippq

p“ log2 y ` CpFiq `OFi

ˆ

1

log y

˙

p1 ď i ď kq(2.24)

where CpFiq is a constant depending on Fi. From (2.23) and (2.24) we deduce that

log V pzq “ÿ

pďz

log

ˆ

1´ρF ppq

p

˙

“ OF p1q ´ÿ

pďz

ρF ppq

p

“ OF p1q ´ÿ

pďz

kÿ

j“1

ρFj ppq

p“ ´k log2 z `OF p1q,

and thus V pzq —F plog zq´k. In fact, (2.23) and (2.24) imply that (Ω) holds with κ “ k (this will be neededin the lower bound argument). In conclusion,

#tk ď x : Fipkq prime for every iu ď OF pzq ` SpA, zq !Fx

plog xqk.

Proof of (2.23): Suppose the equation in (2.23) does not hold. Then there are i ‰ j and some n withp|Fipnq and p|Fjpnq, i.e., p|pFipnq, Fjpnqq. As Fi and Fj are distinct, irreducible and have no fixed primefactor (in particular, neither is a multiple of the other), pFi, Fjq “ 1 over Qrxs. Hence, there are G,H P

Qrxs such that FiG`FjH “ 1. Clearing denominators gives rG, rH P Zrxs with Fi rG`Fj rH “ Cij , whereCij P Z. It follows that p|Cij . As there are only finitely many pairs i, j, there are finitely many possible p.

Comments on (2.24): this is a consequence of the Prime Ideal Theorem of Landau [93]; see also [22, p.33–38]. In some special cases, it follows from Mertens theorem for primes in arithmetic progressions, e.g.if F pxq “ x2 ` 1, then

ÿ

pďx

ρF ppq

p“ 1` 2

ÿ

pďxp”1 pmod 4q

1

p“ log2 x`Op1q.

SIEVE METHODS LECTURE NOTES, SPRING 2020 33

2.5. Sieving limits. One sees from Theorem 2.16 the effect of the dimension κ on the quality of the esti-mates. In order to ensure the remainder terms

ř

|rd| are small, one needs zfpκq to be smaller than the sievinglimit for the sieve problem A (this is generally less than x), hence the range of permissible z is limited bythe value of fpκq.

Definition 2. In the literature, the sieve limit ( or sifting limit) βpκq, for a given κ, is the infimum ofexponents u so that for any sieve problem A satisfying (g), (r), and (Ω), we have for some positive c thebound

SpA, zq ě cXV pzq ´ÿ

dďzu

|rd|.

Some authors, e.g. Selberg, refer to 1βpκq as the sieve limit.Theorem (2.16) implies that βpκq ď fpκq ď 1` 3.841κ for all κ and that βpκq ď 1` op1q as κÑ 0`.

Choosing the parameters αj in a more optimal manner leads to better bounds for large κ, namely βpκq ďpc` op1qqκ where c “ 3.59112 . . . is the solution of e1`1c “ c. See Exercise 2.15 below. This matches theasymptotic upper bound for βpκq achievable from the very complicated “β-sieve”; see [57, Ch. 11].

The exact value of βpκq is known only for κ P r0, 12s Y t1u, in these cases βpκq “ 1 for κ ď 12 andβp1q “ 2. See [57, Ch. 11] for details. The lower bound βp1q ě 2 is clear from Selberg’s examples inSection 1.7.4. The very complicated combinatorial sieves given in [26] give the best known upper bounds onβpκq for small κ (less than 10, say), see Table 1. Selberg [124, eq. (14.40)] showed that βpκq ď 2κ`0.4454

for sufficiently large κ. The exact value of βpκq is unknown in all cases κ ą 12 except for κ “ 1.

κ βpκq ď

0.5 1.01.0 2.02.0 4.26653.0 6.6409

TABLE 1. Known upper bounds on the sieving limit βpκq

2.6. The small z case. Asymptotic formula for the sifting function (Fundamental Lemma). We com-bine the upper and lower bound sieve theorems to achieve an asymptotic formula for the sifting functionwhen z is small compared with x. The bounds below are of the same strength, as s becomes large, as [70,Theorem 2.5], which is derived from a later, complicated sieve developed by Brun. In particular, this givesthe promised asymptotic formula in (1.4) as long as κ is fixed, z “ xop1q and the remainders |rd| are smallenough on average.

Theorem 2.19 (Fundamental Lemma). (a) For any pair pz,Dq of positive integers with 2 ď z ď D, thereare sieves λ` and λ´ satisfying (λ`) and (λ´), respectively, satisfying |λ˘d | ď 1 for all d, with supportin Dpz,Dq :“ td P N : µ2pdq “ 1, P`pdq ď z, d ď Du, and such that for any multiplicative function gsatisfying (Ω), we have

ÿ

d

λ˘pdqgpdq “´

1`O´

e´s log s`s log3 s`Oκ,Bpsq¯¯

ź

pďz

p1´ gppqq,

where s “ logDlog z .

34 KEVIN FORD

(b) Let κ0 ą 0 and B0 ą 0. Assume A is a sieve problem, such that (g), (r) and that (Ω) holds for someconstants 0 ď κ ď κ0 and 0 ď B ď B0. For any 2 ď z ď D, we have

SpA, zq “ XV pzq´

1`O´

e´s log s`s log3 s`Oκ0,B0psq¯¯

`∆ÿ

dďDP`pdqďz

|rd|,

where s “ logDlog z and |∆| ď 1.

Proof. Firstly, we observe that part (b) is immediate from part (a), the bound |λ˘d | ď 1 and (1.8). To prove(a), we take Brun-Hooley sieves, that is, sieves given in Lemma (2.2) (upper bound sieve) and (2.17) (lowerbound sieve) and additionally supported on Dpz,Dq. In light of (2.8), (2.11) and (2.19), it suffices to provethat there is a choice of parameters zj and kj such that

(2.25) E ! e´s log s`s log3 s`Oκ0,B0psq.

As before, we will partition the primes in r2, zs as in (2.9) and let k1, . . . , kt be nonnegative even integers.Let s0pκ0, B0q ě 100 be sufficiently large. When s ď s0pκ0, B0q, the trivial lower bound SpA, zq ě 0 isgood enough, and thus we need only establish E ! 1 in the upper bound sieve. We’ll take, similar to theproof of Theorem 2.4, the parameters k1 “ 0, kj “ 2j´1 (j ě 2), and zj “ z14j´1

for each j ě 1. Thenand d ď zk11 zk22 ¨ ¨ ¨ ď z ď D. As before, Lj ď L for all j, where L is a constant that depends only onκ0, B0. It then follows from (2.6) that E !κ0,B0 1, and this implies (2.25) in this case.

When s ą s0pκ0, B0q we take the parameters

θ “ log s, zj “ z1θj´1, p1 ď j ď tq,

where t is maximally chosen to satisfy (2.9), and

kj “ 2

Z

s

2

ˆ

1´1

θ

˙^

´ 6` 2j p1 ď j ď tq.

Note that θ ě log 100 ą 4 and kj ď sp1´ 1θq ´ 6` 2j for all j. These sieves are supported on integers dsatisfying

d ď zk1`11 zk22 ¨ ¨ ¨ zktt ď z1`psp1´1θq´6qp1´1θq`2p1´1θq2 ď zs “ D.

In the notation (2.4), we have by (Ω) the bound

Lj ď κ log θ `B

log zj`1ď κ0 log θ ` 2B0 “: L.

For large enough s0pκ0, B0q, if s ą s0pκ0, B0q then

k1 ě sp1´ 1θq ´ 6 ě 3s4´ 6 ě 2L.

SIEVE METHODS LECTURE NOTES, SPRING 2020 35

Thus, using Stirling’s formula, we find that

E ď eLtÿ

j“1

Lkj`1

pkj ` 1q!

! eLLk1`1

pk1 ` 1q!ď eL

ˆ

eL

k1 ` 1

˙k1`1

! eOpB0qplog sqκ0 exp

"

´ k1 log k1 `Opk1q ` k1 logpκ0 log θ ` 2B0q

*

! e´s log s`s log3 s`Oκ0,B0psq.

This gives (2.25) and completes the proof.

2.6.1. Application: Buchstab’s function. Buchstab’s function

Φpx, zq “ #tn ď x : P´pnq ą zu

is perhaps the most basic sieve function. Here we take gppq “ 1p for all p so that (Ω) holds with κ “ 1.

Theorem 2.20 (No small prime factors). (i) Uniformly for x ě 0 and 2 ď z ď y, we have

Φpx` y, zq ´ Φpx, zq !y

log z;

(ii) Uniformly for x ě 2z ě 4 we haveΦpx, zq "

x

log z.

(iii) Uniformly for exptplog2 xq2u ď z ď x, we have

Φpx, zq “`

1`Ope´u log u`Opu log3 uqq˘

pďz

p1´ 1pq,

where u “ log xlog z .

Proof. For (i), we may suppose that z ď?y, for the estimate with z ą

?y follows from that for z “

?y.

We let Ω “ px, x`ysXN, X “ y, Ap “ tn P Ω : p|nu, gpdq “ 1d and then (Ω) holds with κ “ 1. Part (i)is then immediate from Theorem 2.4. For parts (ii) and (iii), let Ω “ r1, xsXN,X “ x, Ap “ tn P Ω : p|nu,gpdq “ 1d and again (Ω) holds with κ “ 1. Part (ii) follows from (2.16) when z ď x15 and x is large,since fp1q ă 5 and thus

ř

dďzfp1q |rd| ! xfp1q5. When x15 ă z ď x2 and x is large, the Prime numbertheorem implies

Φpx, zq ě πpxq ´ πpzq "x

log x"

x

log z.

Finally, when x is small, we have Φpx, zq ě 1 " x log z. This proves (ii).For part (iii), take D “ x

log xe´u log u in Theorem 2.19, and define s by D “ zs. Then the error terms

satisfyÿ

dďD

|rd| ď D ! e´u log uXV pzq

since V pzq — 1 log z. By hypothesis, u ď log xplog2 xq

2 ďlog xlog u and hence

s “u

log xplog x´ log2 x´ u log uq “ u

ˆ

1´O

ˆ

1

log u

˙˙

.

Inserting this into the conclusion of Theorem 2.19 completes the proof of (iii).

36 KEVIN FORD

2.7. Small κ The petite sieve. In the previous sections, we showed an asymptotic formula for SpA, zqwhenever κ,B are bounded and logD

log z Ñ 8. In this section, we show an asymptotic formula for SpA, zqwhen D “ zOp1q and κÑ 0. First, we mention a very general principle.

Definition 3. Let A be a sieve problem, and let p be a prime and p ą w ě 2. Then

SpAp, wq :“MP´

Apzď

qďw

Aq

¯

.

This corresponds to Sp rA, wq, where rA is the sieve problem with space prΩ,F ,Pq inherited from A, that is,rΩ “ Ap, rAd “ Ap XAd, rX “ gppqX , gpdq “ gpdq and rd “ rpd.

In the case where Ω is a finite set, SpAp, wq counts those elements of Ω which have property Ap but notany of the properties Aq for q ď w.

Lemma 2.21 (Buchstab’s identity). Let A be a sieve problem, and z ą w ě 2. Then

(2.26) SpA, zq “ SpA, wq ´ÿ

wăpďz

SpAp, p´ 1q.

Proof. Suppose that Aq does not occur for all primes q ď w, but Ap does holds for some p P pw, zs. Lettingp be the largest such prime and summing over p yields the lemma.

Theorem 2.22 (The petite sieve). Let A be a sieve problem and assume (g), (r) and define V pzq by (V ).Assume g satisfies (Ω) for some κ P p0, 1s and B ą 0. Then, uniformly for 2 ď s ď log z with κ log s ď 1

we have

SpA, zq “ˆ

1`OB

ˆ

κ log s`s

log z` e´

12s log s

˙˙

XV pzq `O

ˆ

ÿ

dďz1`1s

|rd|

˙

.

Proof. Letw “ z1s

so that w ě e ą 2. By Buchstab’s identity (2.26) and the fact that SpAp, zq is decreasing in z, we have

SpA, wq ě SpA, zq ě SpA, wq ´ÿ

wăpďz

SpAp, wq.

By Theorem 2.19, with κ0 “ 1 and B0 “ B, we have

SpA, wq “ p1`OBpe´12s log sqqXV pwq `∆

ÿ

dďz

|rd|

where |∆| ď 1. By Theorem 2.4, again with κ0 “ 1 and B0 “ B we have

SpAp, wq ď OBpXgppqV pwqq `ÿ

dďw

|rpd|.

Summing over all p P pw, zs we use thatÿ

wăpďz

gppq ď ´ÿ

wăpďz

logp1´ gppqq

ď κ log

ˆ

log z

logw

˙

`B

logw

“ κ log s`Bs

log z.

SIEVE METHODS LECTURE NOTES, SPRING 2020 37

We conclude that

(2.27) SpA, zq “ˆ

1`OB

ˆ

e´12s log s ` κ log s`

s

log z

˙˙

XV pwq `O

ˆ

ÿ

dďzw

|rd|

˙

.

Finally,

V pzq ď V pwq “ V pzqV pwq

V pzqď V pzq

ˆ

log z

logw

˙κ

p1`OBp1 logwqq

“ V pzqsκp1`OBp1 logwqq

“ V pzqp1`OBpκ log s` s log zqq.

Inserting this into (2.27) completes the proof.

Corollary 2.23. Assume that z Ñ8, κÑ 0, and that the remainders satisfyÿ

dďz1`δ

|rd| “ opXV pzqq

for some fixed δ ą 0. ThenSpA, zq „ XV pzq

Proof. Take s “ 2`minplogp1κq, log2 zq in Theorem 2.22. For large z, s ě 1δ. By hypothesis, sÑ 8

and slog z Ñ 0, and κ log sÑ 0.

2.8. Exercises.

Exercise 2.13. Prove the lower bound (2.22) in Theorem 2.18.

Exercise 2.14. Prove the bounds claimed for fpκq in Theorem 2.16.

Exercise 2.15. (a) Let γpκq be the infimum of

k1 ` 1` α2k2 ` α3k3 ` ¨ ¨ ¨

over all choices of non-negative, even integers ki and real numbers 1 “ α1 ą α2 ą ¨ ¨ ¨ satisfying

8ÿ

j“1

ˆ

αjαj`1

˙κ

´

κ logpαjαj`1q

¯kj`1

pkj ` 1q!ă 1.

Show that βpκq ď γpκq.(b) Let κ “ 1. Find more efficient choice of k1, . . . and α1, . . . which shows that βp1q ă 4.5. You may

use a computer search. Use this to show that there are infinitely many primes p such that Ωpp` 2q ď 8.(c) Prove the asymptotic upper bound βpκq ď pc ` op1qqκ, where c “ 3.59112 . . . is the solution of

e1`c “ c.

Exercise 2.16. Show that for all sufficiently large even N , there is a prime p and a number q with Ωpqq ď 9

such that N “ p` q.

Exercise 2.17. Almost primes in short intervals. Prove that for every δ ą 0, there is a natural number kso that whenever x ě x0pδq, then the interval px, x` xδs contains an integer q with Ωpqq ď k.

38 KEVIN FORD

Exercise 2.18. Show the equivalence of the following two forms of the Bombieri-Vinogradov Theorem:

@A ą 0 DB :ÿ

qďx12 logB x

maxpa,qq“1

max2ďyďx

ˇ

ˇ

ˇ

ˇ

πpy; q, aq ´lipyqφpqq

ˇ

ˇ

ˇ

ˇ

!Ax

plog xqA,

and

@A ą 0 DB :ÿ

qďx12 logB x

maxpa,qq“1

max2ďyďx

ˇ

ˇ

ˇ

ˇ

ψpy; q, aq ´y

φpqq

ˇ

ˇ

ˇ

ˇ

!Ax

plog xqA.

Hereψpx; q, aq “

ÿ

nďxn”a pmod qq

Λpnq.

Exercise 2.19 (˚). Let S denote the set of integers which are the sum of two squares(a) Show that a positive proportion of integers have the form a2 ` b2 ` 2c

2for non-negative integers

a, b, c. You may use as a fact that the counting function of S is " x?

log x.(a) Show that a positive proportion of integers do not have the form a2 ` b2 ` 2c

2for non-negative

integers a, b, c.

SIEVE METHODS LECTURE NOTES, SPRING 2020 39

3. SELBERG’S SIEVE

For any real numbers λpdq satisfying λp1q “ 1, and for any natural number m, we have

1m“1 “ÿ

d|m

µpdq ď

ˆ

ÿ

d|m

λpdq

˙2

.

Thus, any choice of λpdq produces a valid upper bound sieve λ` with

λ`e “ÿ

rd1,d2s“e

λpd1qλpd2q.

Selberg calls this the Λ2-sieve, terminology used also by Friedlander and Iwaniec [57]. Our goal is tooptimize the choice of pλpdqqdě1. Let A be a sieve problem, and assume (g) and (r). Then

SpA, zq ďÿ

d1,d2P`pd1d2qďz

λpd1qλpd2qArd1,d2s

ď Xÿ

d1,d2P`pd1d2qďz

λpd1qλpd2qgprd1, d2sq `ÿ

d1,d2P`pd1d2qďz

|λpd1qλpd2qrrd1,d2s|

“: XG`R,

say. Minimizing XG ` R is quite difficult. However, if we restrict the support of λpdq to d ď?D, it is

relatively easy to minimize G. Since primes with gppq “ 0 do not contribute anything to G, we let

P “ź

pďzgppqą0

p

and restrict the support of λpdq to d|P . Define

(3.1) hpdq “ź

p|d

gppq

1´ gppqfor d|P.

Since rd1, d2s “d1d2pd1,d2q

is squarefree, we have

gprd1, d2sq “gpd1qgpd2q

gppd1, d2qq.

Inverting (3.1) gives1

gpmq“

ź

p|m

ˆ

1`1

hppq

˙

“ÿ

d|m

1

hpdqpm|P q,

so that

G “ÿ

d1|P,d2|P

λpd1qλpd2qgpd1qgpd2qÿ

d|pd1,d2q

1

hpdq

“ÿ

d|P

1

hpdq

ÿ

d1|P,d2|Pd|d1,d|d2

λpd1qλpd2qgpd1qgpd2q “ÿ

d|P

1

hpdq

ˆ

ÿ

d|m

λpmqgpmq

˙2

.

40 KEVIN FORD

If we define

(3.2) ξpdq “µpdq

hpdq

ÿ

d|m

λpdqgpmq pd|P pzq, d ď?Dq,

then we haveG “

ÿ

d

hpdqξpdq2.

This quadratic form in the λpdq is minimized using Cauchy’s inequality. First, we invert (3.2). Sinceÿ

k

hpklqξpklq “ µplqÿ

k

µpkqÿ

kl|m

λpmqgpmq

“ µplqÿ

l|m

λpmqgpmqÿ

k|ml

µpkq “ µplqλplqgplq,

and thus

(3.3) λplq “µplq

gplq

ÿ

l|d

hpdqξpdq pl|P q.

In particular, by Cauchy’s inequality,

1 “ λp1q2 “

˜

ÿ

dď?D

hpdq12ξpdqhpdq12

¸2

ď

˜

ÿ

dď?D

hpdqξpdq2

¸

J “ GJ, J “ÿ

dď?D

hpdq,

with equality if and only if ξpdq is constant; i.e., ξpdq “ 1J for every d ď?D, d|P . By (3.3), this is

attained by taking

(3.4) λplq “µplq

Jgplq

ÿ

l|d

dď?D

hpdq “µplqhplq

Jgplq

ÿ

mď?Dl

pm,lq“1

hpmq.

We conclude that

SpA, zq ď X

J`R.

To handle R, we need an upper bound on λplq. Observe that for any l ě 1,

J “ÿ

k|l

ÿ

dď?D

pd,lq“k

hpdq “ÿ

k|l

hpkqÿ

mď?Dk

pm,lkq“1

hpmq

ěÿ

k|l

hpkqÿ

mď?Dl

pm,lq“1

hpmq “hplq

gplq

ÿ

mď?Dl

pm,lq“1

hpmq.

Comparing with (3.4), we see that |λplq| ď 1 for all l, and therefore that

(3.5) R ďÿ

d1,d2ď?D

P`pd1d2qďz

|rrd1,d2s| ďÿ

dďDP`pdqďz

3ωpdq|rd|.

Since hpdq “ 0 for d - P , we arrive at the following general theorem.

SIEVE METHODS LECTURE NOTES, SPRING 2020 41

Theorem 3.1 (Selberg’s sieve). Let A be a sieve problem, and assume (g), (r). Let z ě 2 and D ě 1. Then

SpA, zq ď X

J`

ÿ

d1,d2ď?D

P`pd1d2qďz

|rrd1,d2s| ďX

J`

ÿ

dďDP`pdqďz

3ωpdq|rd|,

where J “ř

nď?D µ

2pnqhpnq, and h is the multiplicative function defined on primes p ď z by hppq “gppq

1´gppq .

3.1. Application. The Brun-Titchmarch inequality revisited.

Theorem 3.2 (Brun-Titichmarch inequality, v.2). For x ě y ě q ě 1 and pa, qq “ 1, we have

πpx; q, aq ´ πpx´ y; q, aq ď2y

φpqq logp5yqq

ˆ

1`O

ˆ

log2p5yqq

logp5yqq

˙˙

.

We need the following auxilliary lemma.

Lemma 3.3. For k P N and x ě 1, define

Hkpxq :“ÿ

dďxpd,kq“1

µ2pdq

φpdq.

Then(i) Hkpxq ě

φpkqk H1pxq for all k, x;

(ii) H1pxq ě log x for x ě 1.

Proof. We first write

H1pxq “ÿ

`|k

ÿ

dďxpd,kq“`

µ2pdq

φpdq.

Write d “ `h and observe that any nonzero summand corresponds to squarefree d, so ph, `q “ 1 andph, k`q “ 1. Thus, ph, kq “ 1 and we have

H1pxq “ÿ

`|k

µ2p`q

φp`q

ÿ

hďx`ph,kq“1

µ2phq

φphq“

ÿ

`|k

µ2p`q

φp`qHkpx`q ď Hkpxq

ÿ

`|k

µ2p`q

φp`q.

Inequality (i) follows from the identityÿ

`|k

µ2p`q

φp`q“

ź

p|k

ˆ

1`1

p´ 1

˙

“k

φpkq.

Next, define spdq “ś

p|d p to be the squarefree kernel of d. Then

ÿ

spdq“m

1

d“

ź

p|m

ˆ

1

p`

1

p2` ¨ ¨ ¨

˙

“µ2pmq

φpmq.

Hence, for x ě 2 we have

H1pxq “ÿ

mďx

ÿ

sphq“m

1

h“

ÿ

sphqďx

1

ÿ

hďx

1

ż tx`1u

1

dt

t“ log tx` 1u ě log x.

42 KEVIN FORD

Proof of Theorem 3.2. As with the proof of Theorem 2.7, let

Ω “ tx´ y ă n ď x : n ” a pmod qqu, X “ yq,

and let gppq “ 1p for p - q and gppq “ 0 for p|q. Then

Ad “ gpdqX ` rd, |rd| ď 1

AlsoSpA, zq ě πpx; q, aq ´ πpx´ y; q, aq ´ z.

In the notation of Theorem 3.1, we have

hpdq “µ2pdq

φpdqfor pd, qq “ 1.

Let z “?D. By Lemma 3.3,

J “ Hqp?Dq ě

φpqq

2qlogD.

By Theorem 3.1,

SpA, zq ď X

J`

ÿ

d1,d2ď?D

1 ďX

J`D ď

2y

φpqq logD`D,

henceπpx; q, aq ´ πpx´ y; q, aq ď

2y

φpqq logD`D `

?D.

A near-optimal choice for D is

D “ max

ˆ

2,5yq

log2p5yqq

˙

,

and this gives the theorem upon using that1

logD“

1

logp5yqq

ˆ

1`O

ˆ

log2p5yqq

logp5yqq

˙˙

.

3.2. Asymptotic formulas. It is possible, under two-sided bounds on gppq, to obtain an asymptotic formulafor J . The theorem below illustrates some useful techniques for analyzing sums of multiplicative functions.

Theorem 3.4. Let A1, A2, L, κ ą 0, and let g be a multiplicative function supported on squarefree integerssatisfying

(3.6) 0 ď gppq ď 1´A1 pp primeq

and

(3.7) ´ L ďÿ

wďpďy

gppq log p´ κ logy

wď A2 p2 ď w ď yq.

Let h be the multiplicative function supported on squarefree integers and defined by

hppq “gppq

1´ gppqpp primeq.

Then, uniformly for x ě 2,ÿ

nďx

µ2pnqhpnq “ Spgqplog xqκ

Γpκ` 1q`Oκ,A1,A2

`

Spgq“

pL` 1qplog xqκ´1 ` pL` 1qκ‰˘

,

SIEVE METHODS LECTURE NOTES, SPRING 2020 43

where

Spgq “ź

p

p1´ gppqq´1p1´ 1pqκ.

Remarks. It is important that the dependence on L be made explicit in the error term, as in manyapplications L is not uniformly bounded, whereas κ,A1, A2 are usually uniformly bounded. That is, wemay wish to apply the result with a sequence of functions g1, g2, . . ., and typically the same κ,A1, A2 willwork for every gi but the corresponding numbers L (call them Li, say) may not be bounded; see TheoremTP2 below for an example.

The sum on the left side depends only on gppq for primes p ď x, whereas the singular series is definedin terms of gppq for all primes p. It might seem more natural to replace the infinite product defining Spgq

with a finite product over primes p ď x, but the given form of the theorem is easier to apply in practice. Theinclusion of “extraneous factors” in Spgq does force us to include the additional error term SpgqpL ` 1qκ,which is in fact best possible as the following example shows: fix κ ą 0, consider a large L (say going to8as x Ñ 8), gppq “ 0 for p ă eL2κ and gppq “ κp for p ě eL2κ. One easily verifies (3.6) and (3.7), andcomputes that Spgq ! L´κ. If 1 ă x ă eopLq, then the sum in the lemma is just hp1q “ 1, while the “mainterm” and first error term on the right side are both op1q.

The second error term SpgqpL ` 1qκ is frequently missing in versions of Theorem gh appearing in theliterature, e.g. some of the recent work on prime gaps [61, Lemma 4], [97, Lemma 6.1]. These two worksultimately depend on [70, Lemma 5.3 (2.5)], which claims, in our notation, that

ź

pďz

p1´ gppqq “ Spgq´1 e´γκ

plog zqκ

ˆ

1`O

ˆ

L` 1

log z

˙˙

for all z ě 2. The above example clearly shows this claim to be false in some cases when 2 ď z ă

eopLq. The error in the proof can be traced to [70, p. 146], two lines after (2.7), where it is written thatp1 ` OpL log zqq´1 “ p1 ` OpL log zqq, a relation which is only true when z ą eCL for some positiveconstant C.

Proof. We will use a technique due to E. Wirsing. Assume throughout that g and h are supported onsquarefree integers, so that all sums are over squarefree integers, and let

Hpxq “ÿ

nďx

hpnq.

By partial summation,

Hpxq log x “ÿ

nďx

hpnq´

log n` logx

n

¯

“ÿ

nďx

hpnq log n`

ż x

1

Hpuq

udu.

We rewrite the right hand sum asÿ

nďx

hpnq log n “ÿ

nďx

hpnqÿ

pďx

log p “ÿ

pďx

log pÿ

mďxpp-m

hppqhpmq.

44 KEVIN FORD

Using the relation hppq “ gppq ` gppqhppq, the right side transforms into

“ÿ

pďx

gppq log p

"

ÿ

mďxp

hpmq ´ÿ

mďxpp|m

hpmq ` hppqÿ

mďxpp-m

hpmq

*

“ÿ

pďx

gppq log p

"

ÿ

mďxp

hpmq ´ hppqÿ

lďxp2

p-l

hplq ` hppqÿ

mďxpp-m

hpmq

*

“ÿ

pďx

gppq log p

"

ÿ

mďxp

hpmq ` hppqÿ

xp2ămďxpp-m

hpmq

*

.

Interchanging the order of summation yields

(3.8)ÿ

nďx

hpnq log n “ÿ

mďx

hpmq

"

ÿ

pďxm

gppq log p`ÿ

?xmăpďxm

p-m

gppqhppq log p

*

.

Applying (3.7) (with y “ w “ p) followed by (3.6), we see that for every p,

gppq ďA2

log pand hppq ď

A2 log p

A1.

Hence, by another application of (3.7), we obtainÿ

?xmďpďxm

gppqhppq log p ďA2A1

loga

xm

ÿ

?xmďpďxm

gppq log p ! 1 pm ď x4q,

the sum being triviallyOp1qwhenm ą x4 (here and throughout he proof, constants implied byO-symbolsmay depend on κ,A1, A2 but not on any other parameter). By (3.7),

ÿ

pďxm

gppq log p “ κ logx

m`OpL` 1q,

and thus relation (3.8) becomesÿ

nďx

hpnq log n “ÿ

mďx

hpmq

"

κ logx

m`OpL` 1q

*

“ κ

ż x

1

Hpuq

udu`OppL` 1qHpxqq.

Hence

Hpxq log x “ pκ` 1q

ż x

1

Hpuq

udu`∆˚pxq, ∆˚pxq ! pL` 1qHpxq.

It is convenient to slightly alter this relation, using the fact that Hpuq “ 1 for 1 ď u ă 2. Thus

(3.9) Hpxq log x “ pκ` 1q

ż x

2

Hpuq

udu`∆pxq px ě 2q, ∆pxq ! pL` 1qHpxq.

We treat ∆pxq like an error term, and consider the integral equation forH given by (3.9). The “unperturbed”equation fpxq log x “ pκ ` 1q

şx2 fpuqu du has general solution fptq “ Cplog tqκ for some constant C,

and our aim is to prove an asymptotic of this shape forHpxq. First, we bound ∆pxq using the crude estimate

(3.10) Hpxq ďź

pďx

p1` hppqq “ Spxqź

pďx

ˆ

1´1

p

˙´κ

! plog xqκSpxq,

SIEVE METHODS LECTURE NOTES, SPRING 2020 45

whereSpxq “

ź

pďx

p1´ gppqq´1p1´ 1pqκ.

We must relate Spxq to Spgq by estimating the contribution of the large primes p ą x to Spgq; that is, the“extraneous” primes that are not involved in the sum

ř

nďx hpnq (cf. the Remarks). Let x ě 2. Now

logpSpxqSpgqq “ logź

pąx

p1´ gppqqp1´ 1pq´κ ďÿ

pąx

ˆ

κ

p´ gppq `

κ

p2

˙

.

By (3.7) and partial summation, when x ě eL`1 we get

ÿ

pąx

κ

p´ gppq “

ÿ

pąx

κ log pp ´ gppq log p

log p“

ż 8

x

ÿ

xăpďt

ˆ

κ log p

p´ gppq log p

˙

dt

t log2 t!L` 1

log x! 1.

When x ă eL`1, however, we do better using the trivial observation gppq ě 0:ÿ

pąx

κ

p´ gppq ď

ÿ

xăpďeL`1

κ

p`

ÿ

pąeL`1

κ

p´ gppq “ κ log

ˆ

L` 1

log x

˙

`Op1q.

Therefore we have

(3.11) Spxq “ SpgqSpxq

Spgq!

ˆ

1`

ˆ

L` 1

log x

˙κ˙

Spgq.

The example described in the Remarks shows that (3.11) is in fact best possible. Combining (3.11) with(3.10) yields the estimates

Hpxq ! pplog xqκ ` pL` 1qκqSpgq px ě 2q,(3.12)

∆pxq !`

pL` 1qplog xqκ ` pL` 1qκ`1˘

Spgq px ě 2q.(3.13)

Returning to (3.9), we replace x with t, divide through by tplog tqκ`2 and integrate from 2 to x. Thisgives

ż x

2

Hptq

tplog tqκ`1dt´

ż x

2

κ` 1

tplog tqκ`2

ż t

2

Hpuq

udu “

ż x

2

∆ptq

tplog tqκ`2dt.

After interchanging the order of integration, we see that the double integral equalsż x

2

Hpuq

u

ˆ

1

plog uqκ`1´

1

plog xqκ`1

˙

du,

which implies thatż x

2

Hpuq

udu “ plog xqκ`1

ż x

2

∆ptq

tplog tqκ`2dt.

Comparing this with (3.9) yields

(3.14) Hpxq “ pκ` 1qplog xqκż x

2

∆ptq

tplog tqκ`2dt`

∆pxq

log xpx ě 2q.

By (3.13), the integral above converges as xÑ8 (the tail being ! pL` 1qSpgq log x for x ą eL`1), thusż 8

2

∆ptq

tplog tqκ`2dt “ C

46 KEVIN FORD

for some constantC. Therefore, combining (3.14) and (3.13) (when x ě eL`1) and (3.12) (when x ă eL`1),we conclude that

(3.15) Hpxq “ Cpκ` 1qplog xqκ `O`

Spgq“

pL` 1qplog xqκ´1 ` pL` 1qκ‰˘

px ě 2q.

It remains to determine C. For real s ą 0 let

ζhpsq :“8ÿ

m“1

hpmqm´s “ s

ż 8

1Hpxqx´s´1 dx “ s

ż 8

0Hpetqe´st dt.

By (3.15), as sÑ 0` we have

ζhpsq „ sCpκ` 1q

ż 8

0tκe´st dt “ s´κCpκ` 1q

ż 8

0uκe´u du “ s´κCpκ` 1qΓpκ` 1q.

Since ζps` 1q „ 1s as sÑ 0`, we obtain

limsÑ0`

ζps` 1q´κζhpsq “ Cpκ` 1qΓpκ` 1q.

On the other hand,

ζps` 1q´κζhpsq “ź

p

ˆ

1´1

ps`1

˙κˆ

1`hppq

ps

˙

.

Using (3.7), we see that the Euler product is uniformly convergent for s ě 0 (Exercise). Therefore,

Cpκ` 1qΓpκ` 1q “ limsÑ0`

ź

p

ˆ

1´1

ps`1

˙κˆ

1`hppq

ps

˙

“ź

p

ˆ

1´1

p

˙κ

p1` hppqq “ Spgq. .

3.3. Application: twin primes.

Theorem 3.5. Let k be an even, positive integer. Then, uniformly in k ď x,

#tp ď x : p` k primeu ď Cź

p|kpą2

ˆ

p´ 1

p´ 2

˙

x

log2 x

ˆ

4`O

ˆ

log2 x

log x

˙˙

,

where

C “ 2ź

p

ˆ

1´1

pp´ 1q2

˙

is the “twin prime constant”.

Proof. Let Ω “ tp` k : p ď xu. Then

Ad “ Xgpdq ` rd, X “ lipxq, gpdq “

#

1φpdq if pd, kq “ 1

0 if pd, kq ą 1.

SIEVE METHODS LECTURE NOTES, SPRING 2020 47

Let D “ z “ x12plog xq´B , where B is sufficiently large. We have |rd| ! xd trivially, and therefore bythe Bombieri-Vinogradov theorem and Cauchy’s inequality,

ÿ

dďD

3ωpdqµ2pdq|rd| !ÿ

dďD

µ2pdq3ωpdq´x

d

¯12|rd|

12

ď x12

˜

ÿ

dďD

µ2pdq9ωpdq

d

¸12˜ÿ

dďD

|rd|

¸12

! x12

˜

ź

pďD

ˆ

1`9

p

˙

¸12ˆ

x

plog xq20

˙12

!x

plog xq5.

Since gppq “ 1p´1 for primes p - k, the hypotheses of Theorem 3.4 hold with κ “ 1, A1 and A2 absolute

constants, and with

L “ Op1q `ÿ

p|k

log p

p´ 1!

ÿ

p“Oplog kq

log p

p´ 1! log2 k.

We also have hppq “ 1p´2 for p - k. Theorem 3.4 implies that

J “ Spgq´

log?D `Oplog2 kq

¯

“ Spgq`

14 log x`Oplog2 xq

˘

,

where

Spgq “1

2C

ź

p|kpą2

p´ 2

p´ 1.

Finally, Theorem 3.1 gives

#tp ď x : p` k primeu ď D ` SpA, Dq ď D `X

J`

ÿ

dďD

µ2pdq3ωpdq|rd|

ď Cź

p|kpą2

ˆ

p´ 1

p´ 2

˙

x

log2 x

ˆ

4`O

ˆ

log2 x

log x

˙˙

.

Remarks. Assuming the Elliott-Halberstam conjecture, we may take D “ x1´ε for any positive ε in theabove argument, and replace the 4 with 2` op1q in the conclusion. This is only a factor two worse than theHardy-Littlewood conjectured asymptotic formula for the left hand side.

For fixed k, Bombieri, Friedlander and Iwaniec showed that one may replace 4 with 3.5 (the error term isnot uniform in k).

Using the very same analysis, one can also prove, for even N ě 4,

#tp1, p2 : N “ p1 ` p2u ď Cź

p|Npą2

p´ 1

p´ 2

N

log2N

ˆ

4`O

ˆ

log2N

logN

˙˙

.

We leave this as an exercise.

48 KEVIN FORD

3.4. Selberg’s sieve is best possible in dimension 1. Consider Selberg’s example Ω “ tn ď x : λpnq “

´1u, where λ is Liouville’s function. As before, we saw that pRpθ,Aqq holds for all θ ă 1 and A ą 0,X “ x2, gpdq “ 1d and thus hppq “ 1pp´ 1q. Take z “ D “ x12´ε for small, positive ε. In Theorem3.4, we have S “ 1, and so by Theorem 3.1,

SpA, zq ď X

J`O

ˆ

x

log5 x

˙

“x

p1´ 2εq log x`O

ˆ

x

log2 x

˙

.

But SpA, zq “ πpxq ´ πp?xq ` 1 „ x log x by the prime number theorem. Thus, Selberg’s upper bound

sieve cannot be improved, in general, for κ “ 1.

3.5. Exercises.

Exercise 3.1. As in the proof of Lemma 3.3, let

H1pxq “ÿ

nďx

µ2pnq

φpnq.

Show that H1pxq “ log x` c` op1q, where

c “ γ `ÿ

p

log p

ppp´ 1q“ 1.332 . . .

and γ “ 0.5772 . . . is Euler’s constant.

Exercise 3.2. Prove that for even N ě 4,

#tp1, p2 : N “ p1 ` p2u ď Cź

p|Npą2

p´ 1

p´ 2

N

log2N

ˆ

4`O

ˆ

log2N

logN

˙˙

.

Exercise 3.3. (Asymptotic for J in Selberg’s sieve). Let A1, A2, L, κ ą 0, and let g be a multiplicativefunction satisfying (3.6) and (3.7). Let h be the multiplicative function defined by hppq “ gppq

1´gppq for primep.

(i) Prove that uniformly for 2 ď w ď y and s ě 0,ź

wďpďy

ˆ

1´1

ps`1

˙κˆ

1`hppq

ps

˙

“ 1`O

ˆ

L` 1

logw

˙

.

The implied constant in the O´term may depend only on A1, A2, L, κ. Hint: be careful. You may want toconsider separately the cases w ă eL`1 and w ě eL`1.

(ii) Use (i) to show that

limsÑ0`

ź

p

ˆ

1´1

ps`1

˙κˆ

1`hppq

ps

˙

“ź

p

ˆ

1´1

p

˙κ

p1` hppqq .

SIEVE METHODS LECTURE NOTES, SPRING 2020 49

4. SMOOTH NUMBERS

In what follows we will need the Erdos notation for iterates of the logarithm:

logk x “ log ¨ ¨ ¨ logloooomoooon

k

x.

The basic functionΨpx, yq “ #tn ď x : P`pnq ď yu

is widely used in number theory. In contrast with Φpx, zq, which eliminates numbers with small primefactors, Ψpx, yq eliminates numbers with large prime factors. One can use the small sieve (Theorem 2.4) tobound Ψpx, yq but we obtain only

Ψpx, yq ! xlog y

log xwith no lower bound. The truth, however, is very different, owing to the non-independence of large primesdividing n, e.g. the events p|n and p1|n are exclusive if p ą p1 ą

?x.

Theorem 4.1. Uniformly for x ě 10 and log x ď y ď x we have

Ψpx, yq “ xe´u log u`Opu log2p10uqq, u “log x

log y.

Remarks. There is a change of behavior around y “ log x, due to the fact that for smaller y,ś

pďy p ă x,and this forces at least some of the exponents of prime dividing n to be large.

We note some special cases which we will find useful for applications:

(4.1) Ψpx, log xq “ exp

"

O

ˆ

plog xq log3 x

log2 x

˙*

“ xop1q pxÑ8q,

(4.2) Ψpx, plog xqcq “ x1´1c`op1q pxÑ8q

for any fixed c ě 1, and

(4.3) Ψpx, xcplog3 xq log2 xq “x

plog xqc`op1qpxÑ8q.

We first need a combinatorial lemma, which is similar to devices we used to develop the Brun-Hooleysieve.

Lemma 4.2. Let I be a finite set of positive integers, and k P N. Thenÿ

n1,...,nkPIn1ăn2㨨¨ănk

1

n1 ¨ ¨ ¨nkě

1

k!

ˆ

ÿ

nPI

1

n´k ´ 1

min I

˙k

,

provided that the expression in parentheses is ě 0.

Proof. This is straightforward. We haveÿ

n1,...,nkPIn1ăn2㨨¨ănk

1

n1 ¨ ¨ ¨nk“

1

k!

ÿ

n1,...,nkPIdistinct

1

n1 ¨ ¨ ¨nk

“1

k!

ÿ

n1PI

1

n1

ÿ

n2PIn2‰n1

1

n2¨ ¨ ¨

ÿ

nkPInkRtn1,...,nk´1u

1

nk.

50 KEVIN FORD

Each sum over ni is at leastř

nPI 1n´ pi´ 1qmin I , independent of the choice of n1, . . . , ni´1, and theproof is complete.

Proof of Theorem 4.1. We begin with the upper bound, and we will in fact prove a stronger bound

(4.4) Ψpx, yq ď xe´u log u`Opuq.

Define

α “ 1´log u

log y.

By our hypothesis that log x ď y ď x,

(4.5) 1 ď u ďlog x

log2 x,

log3 x

log2 xď α ď 1.

For all w ą 0, logpwαq ď wα and thus logw ď α´1wα. Hence,

(4.6) plog xqΨpx, yq “ÿ

nďxP`pnqďy

logpxnq ` log n ď α´1xαS `ÿ

nďxP`pnqďy

ÿ

pa|n

log p,

where

S “ÿ

P`pnqďy

1

nα.

In the double-sum on the right side of (4.6), let n “ pam, and separate into cases depending on a “ 1 ora ą 1. The a “ 1 terms contribute

ďÿ

mďxP`pmqďy

ÿ

pďminpy,xmq

log p !ÿ

mďxP`pmqďy

minpy, xmq ďÿ

P`pmqďy

y1´α´ x

m

¯α“ uxαS.

The terms with a ą 1 contribute

ďÿ

pďy2ďa!log x

log pÿ

mďxpa

P`pmqďy

1 ďÿ

pďy2ďa!log x

log pÿ

P`pmqďy

ˆ

x

pam

˙α

“ xαST,

where

T “ÿ

pďy2ďa!log x

log p

paα.

If α ě 23 then clearly T ! 1. If 0 ă α ă 23 then y ď plog xq3 and u ě log x3 log2 x

, thus crudely

T ! plog xqÿ

pďy

log p ! y log x ! plog xq4 ! u5.

Putting together the a “ 1 and a ą 1 terms, we conclude from (4.5) and (4.6) that

(4.7) plog xqΨpx, yq ! xαSpα´1 ` u` u5q ! u5xαS “ xu5e´u log uS.

It remains to bound S. We have

S “ź

pďy

ˆ

1`1

pα`

1

p2α` ¨ ¨ ¨

˙

“ź

pďy

ˆ

1`1

pα ´ 1

˙

ď exp

"

ÿ

pďy

1

pα ´ 1

*

.

SIEVE METHODS LECTURE NOTES, SPRING 2020 51

First consider the case α ě 23. For any 0 ď z ď 1 and c ě 0 we have

ecz “8ÿ

k“0

pczqk

k!ď 1` z

8ÿ

k“1

ck

k!ď 1` ecz,

hence1

pα“

1

peplog uq log p

log y ď1

p

ˆ

1` elog u log p

log y

˙

.

Thus, by Mertens bounds,

logS ď Op1q `ÿ

pďy

1

ď Op1q `ÿ

pďy

1

p`

u

log y

ÿ

pďy

log p

p

ď log2 y `Opu` 1q.

Thus, S ! plog yqeOpuq. Combining this with (4.7), we get (4.4) in this case.Now assume 0 ă α ă 23. Then y ď u3 ď log3 x and u — log x

log2 x. We then have, using (4.5) again,

logS !ÿ

pď21α

1

α log p`

ż y

1

dt

! α´121α `y1´α

1´ α

! plog xqop1q ` u ! u.

Again, plugging this into (4.7) yields the claimed upper bound in (4.4).

Now we prove the lower bound in Theorem 4.1. This breaks into two cases,

(i) log x ď y ď exptplog2 xq10u;

(ii) exptplog2 xq10 ď y ď x.

In each case we may assume that x ě x0, a sufficiently large constant, since for x ď x0, Ψpx, yq ě 1 andthe result follows.

We begin with the easier case (i), following ideas from Tenenbaum [127, Ch. III.5.1]. Here

(4.8)log x

plog2 xq10ď u ď

log x

log2 x.

Let v “ tuu and k “ πpyq. Let p1, . . . , pk be the primes ď y. Then Ψpx, yq counts at least every number ofthe form pν11 ¨ ¨ ¨ p

νkk where ν1 ` ¨ ¨ ¨ ` νk ď v. Thus,

Ψpx, yq ě

ˆ

k ` v

v

˙

.

By (4.8), u ! y log y — k . Thus, by Stirling’s formula and v “ u`Op1q, we deduce

log Ψpx, yq ě pk ` vq logpk ` vq ´ k log k ´ v log v `Oplogpk ` vqq

“ pk ` uq logpk ` uq ´ k log k ´ u log u`Oplog yq

“ ´u log u` u log k ` pk ` uq logp1` ukq `Oplog yq.

52 KEVIN FORD

Again, (4.8) implies that log2 y ! log3 x ! log2 u, hence

u log k “ u log y `Opu log2 yq “ log x`Opu log2 uq.

Also,

pk ` uq logp1` ukq ďpk ` uqu

kď u`

u2

k! u.

Hence,log Ψpx, yq ě log x´ u log u`Opu log2 uq,

as desired.In case (ii), we will first show a weaker bound

(4.9) Ψpx, yq " xe´3u log u p1 ď y ď xq.

If y ă log x then 3u log u ą log x and (4.9) is trivial, and if log x ď y ď exptplog2 xq10u then (4.9)

follows from the bound proved in case (i). Now suppose y ą exptplog2 xq10u. Let k “ tuu ` 1 and let

I “ NX px1k`1 , x

1k s. Then Ψpx, yq counts all numbers of the form n “ p1 ¨ ¨ ¨ pkm ď x with pi P I (these

numbers are distinct since m ď x1k`1 ). We observe that

x1k`1 ě x

1u`2 ě x

13u “ y13 ą exptplog2 xq

9u.

By the Prime Number Theorem, we thus have for some constant c ą 0

ÿ

pPI

1

p“ log

ˆ

k ` 1

k

˙

`O´

e´c?

log x1pk`1q¯

“ log

ˆ

k ` 1

k

˙

`Op1 log10 xq.

Hence, by Lemma 4.2,

Ψpx, yq ěÿ

p1,...,pkPIp1ăp2㨨¨ăpk

Z

x

p1 ¨ ¨ ¨ pk

^

ěÿ

p1,...,pkPIp1ăp2㨨¨ăpk

x

2p1 ¨ ¨ ¨ pk

ěx2

k!

ˆ

ÿ

pPI

1

k

x1k`1

˙k

ěx

k!

ˆ

logp1` 1kq ´O

ˆ

1

k2 log2 x

˙˙k

"x

kk k!" xe´2k log k`Opkq

and (4.9) follows.Now we use (4.9) as a bootstrap for a better estimate. Suppose that exptplog2 xq

10u ď y ď x. Assumeu ě e4, since the desired lower bound in Theorem 4.1 follows from (4.9) for 1 ď u ď e4. Let k “ tuu` 1,let η “ 1

log u ď14 and I “ N X py1´2η, y1´ηs. Consider integers n “ p1 ¨ ¨ ¨ pkm, where pi P I for all i,

p1 ă ¨ ¨ ¨ ă pk and P`pmq ď y1´2η. These integers are distinct and counted by Ψpx, yq. Then

Ψpx, yq ěÿ

p1,...,pkPIp1㨨¨ăpk

Ψ

ˆ

x

p1 ¨ ¨ ¨ pk, y1´2η

˙

.

Now p1 ¨ ¨ ¨ pk ě ykp1´2ηq ě yup1´2ηq “ x1´2η and thusx

p1 ¨ ¨ ¨ pkď x2η “ y2ηu ď py1´2ηq4ηu,

SIEVE METHODS LECTURE NOTES, SPRING 2020 53

using that η ď 14 . Hence, by (4.9),

Ψpx, yq " xÿ

p1,...,pkPIp1㨨¨ăpk

1

p1 ¨ ¨ ¨ pke´12ηu logp4ηuq

" xe´Opuqÿ

p1,...,pkPIp1㨨¨ăpk

1

p1 ¨ ¨ ¨ pk.

Invoking Lemma 4.2 and using the Prime Number Theorem as in case (i), we conclude that

Ψpx, yq "xe´Opuq

k!

ˆ

ÿ

pPI

1

p`O

ˆ

1

k100 log x

˙˙k

"xe´Opuq

k!

ˆ

1

2 log u

˙k

“ xe´u log u`Opu log2p10uqq.

This completes the proof of the lower bound in Theorem 4.1.

Exercise 4.1. (a) Show, using elementary estimates, that

Ψpx, x1uq “ xp1´ log uq `Opx log xq

uniformly for 1 ď u ď 2.(b) Show that for y ă z ă x that

Ψpx, yq “ Ψpx, zq ´ÿ

yăpďz

Ψpxp, pq.

(c) Let ρpuq be the Dickman-de Bruijn function, defined recursively by

ρpuq “ 1 p0 ď u ď 1q, ρpuq “ 1´

ż u

1

ρpv ´ 1q

vdv pu ą 1q.

Using (b) and induction on tuu, show that for any k ą 1, uniformly for 1 ď u ď k we have

Ψpx, x1uq “ ρpuqx`Ok

ˆ

x

log x

˙

.

Exercise 4.2. Prove that uniformly for 10 ď log z ď y ď z ď x,

Θpx, y, zq :“ #

#

n ď x :ź

pvnpďy

pv ą z

+

“ xe´u log u`Opu log2p3uqq, u “log z

log y.

That is, counting numbers which have a large y-smooth part.

Exercise 4.3. Let S denote the set of integers with pP`pnqq2|n. Show that

#tn ď x : n P Su ! x exp!

´ p?

2` op1qqa

log x log2 x)

.

54 KEVIN FORD

5. COUNTING PRIME FACTORS

Letπkpxq “ #tn ď x : ωpnq “ ku.

Using the Prime Number Theorem, Landau proved an asymptotic for πkpxq for each fixed k.Theorem (Landau, 1900). For every fixed k,

πkpxq „x

log x

plog2 xqk´1

pk ´ 1q!.

This already suggests that ωpnq has a Poisson distribution, although Landau never wrote this explicitly. Itwas Hardy and Ramanujan in 1917 who analyzed the behavior of πkpxq uniformly in k, showingTheorem (Hardy-Ramanujan, 1917). Uniformly for x ě 2 and k ě 1,

πkpxq ď C1x

log x

plog2 x` C2qk´1

pk ´ 1q!,

where C1, C2 are certain absolute constants.Summing the upper bound for k ě p1 ` εq log2 x and k ď p1 ´ εq log2 x, with ε ą 0 fixed, and using

standard bounds on the tail of the Poisson distribution (see Lemma 5.3 below), one obtains a sum of opxq.Consequently, most n ď x have close to log2 x distinct prime factors. This result is sometimes referred toas the birth of probabilistic number theory.

Motivated by the fact that the Poisson distribution tends to the Gaussian as the parameter tends to infinity,Erdos and Kac proved their celebrated “Central Limit Theorem” for ωpnq in 1939:Theorem (Erdos-Kac, 1939 [42]). For any real z,

1

x#

#

n ď x :ωpnq ´ log2 x

a

log2 xď z

+

Ñ Φpzq :“1?

ż z

´8

e´12t2 dt pxÑ8q.

Much further work was done starting in the 1940s, examining the distribution of the entire sequence ofprime factors of integers (equivalently, studying the distribution of arbitrary additive functions). Perhapsthe most notable was the work of Kubilius, who developed a probabilistic model of integers which providesa kind of meta-tool for studying al kinds of statistical questions about the distribution of prime factors. Akey concept in the theory is independence, the idea that if p and q are small primes, then the “events” p|nand q|n are nearly independent, from a probabilistic viewpoint; this idea also played a prominent role inthe development of sieve methods. The theory leads to a “Poisson model” of prime factors; namely thatthe number of prime factors in an interval peea , eebs has roughly Poissonpb ´ aq distribution, with disjointintervals having independent distributions.

Denote by ωpn, T q the number of distinct prime factors of n that lie in T .Lemma 5.1. Let T be a finite set of primes, and m ě 0. Then

1

m!

ˆ

ÿ

pPT

1

m

min T

˙m

ďÿ

n:p|nñpPTωpn;T q“m

1

1

m!

ˆ

ÿ

pPT

1

p´ 1

˙m

.

Proof. The first inequality follows from Lemma 4.2 upon considering squarefree n. By grouping products,we see that

ˆ

ÿ

pPT

1

p`

1

p2` ¨ ¨ ¨

˙m

SIEVE METHODS LECTURE NOTES, SPRING 2020 55

is at least m! times the sum on the left. This gives the second inequality.

Theorem 5.2 (Prime factors in sets). Let T1, . . . , Tr be arbitrary disjoint, nonempty subsets of the primesď x. For any k1, . . . , kr ě 0 we have

#tn ď x : ωpn; Tjq “ kj p1 ď j ď rqu ! xrź

j“1

˜

Hkjj

kj !e´Hj

¸˜

1`rÿ

j“1

kjHj

¸

ď xrź

j“1

e´Hjˆ

Hkj´1j

pkj ´ 1q!`Hkjj

kj !

˙

,

where, for each j,

Hj “ÿ

pPTj

1

p´ 1.

When kj “ 0 the corresponding term Hkj´1j pkj ´ 1q! is to be omitted.

Proof. Let

L “ÿ

hďxωph;Tjq“kj p1ďjďrq

1

h, Lt “

ÿ

hďxωph;Tjq“kj pj‰tqωph;Ttq“kt´1

1

h.

We use the “log-trick” again (due to E. Wirsing). For any n ď x write

log x “ log n` logpxnq “ÿ

pan

log pa ` logpxnq ďÿ

pan

log pa ` xn.

This gives

plog xq#tn ď x : ωpn; Tjq “ kj p1 ď j ď rqu ď xL`ÿ

nďxωpn;Tjq“kj p1ďjďrq

ÿ

pan

log pa.

In the double sum, let n “ pah and observe that ωph, Tjq “ kj ´ 1 if p P Tj and ωph, Tjq “ kj otherwise(note that the former case is only possible if kj ą 0). That is, h is either counted by L or h is counted by Ltfor some t, 1 ď t ď r. Hence

plog xq#tn ď x : ωpn; Tjq “ kj p1 ď j ď rqu ď 2xL`ÿ

t:ktą0

ÿ

hďxωph;Tjq“kj´1j“t p1ďjďrq

ÿ

paďxh

log pa.

Using Chebyshev’s Estimate for primes, the innermost sum over pa is Opxhq and thus

#tn ď x : ωpn; Tjq “ kj p1 ď j ď rqu !x

log x

ˆ

L`ÿ

1ďjďr:kją0

Lj

˙

.

To bound the sum in L and in Lt, write the denominator h “ h1 ¨ ¨ ¨hrh1, where, for 1 ď j ď r, hj is

composed only of primes from Tj , ωphj ; Tjq “ kj ´ 1t“j , and h1 is composed of primes in r2, xszpT1 Y

56 KEVIN FORD

¨ ¨ ¨ Y Trq. For brevity, write mj “ ωph; Tjq. Using Lemma 5.1 and Mertens, we obtain

ÿ

hďxωph;Tjq“mj p@jq

1

j“1

ÿ

ωphj ;Tjq“mjp|hj ùñ pPTj

1

hj

ź

pďxpRT1Y¨¨¨YTr

ˆ

1`1

p`

1

p2` ¨ ¨ ¨

˙

ď

j“1

Hmjj

mj !

ź

pďxpRT1Y¨¨¨YTr

ˆ

1´1

p

˙´1

! plog xqrź

j“1

Hmjj

mj !

ź

pPT1Y¨¨¨YTr

ˆ

1´1

p

˙

.

We conclude that

#tn ď x : ωpn; Tjq “ kj p1 ď j ď rqu ! xrź

j“1

Hkjj

kj !

˜

1`rÿ

j“1

kjHj

¸

ź

pPT1Y¨¨¨YTr

ˆ

1´1

p

˙

.

Finally, using the elementary inequality 1` y ď ey, we see thatź

pPT1Y¨¨¨YTr

ˆ

1´1

p

˙

ď exp

"

´ÿ

pPT1Y¨¨¨YTr

1

p

*

“ exp

"

Op1q ´ÿ

pPT1Y¨¨¨YTr

1

p´ 1

*

! e´H1´¨¨¨´Hr ,

and the proof is complete.

Remark. Theorem 5.2 is similar to [130, Theorem 2].

In the special case of a single set of primes, we have

(5.1) #tn ď x : ωpn; T q “ ku ! xe´H

˜

Hk´1

pk ´ 1q!`Hk

k!

¸

, H “ÿ

pPT

1

p´ 1.

In particular,

#tn ď x : ωpn; T q “ 0u ! xe´H — xź

pPT

ˆ

1´1

p

˙

.

This matches the sieve upper bound in Theorem 2.4 in the special case Ω “ r1, xsXN, Ap “ tn P Ω : p|nu

for p P T .To use (5.1), one often sums up the bound for kj in an interval. The bound in Theorem 5.2 looks like the

product of independent Poisson distributions with parameters Hj .

Lemma 5.3 (Poisson tails). Let X be a Poisson random variable with parameter λ. Then

PpX ď αλq ď e´Qpαqλ p0 ď α ď 1q, PpX ě αλq ď e´Qpαqλ pα ě 1q,

where

(5.2) Qpxq “ x log x´ x` 1.

SIEVE METHODS LECTURE NOTES, SPRING 2020 57

Proof. We use the idea behind Chernoff’s inequality, Markov’s inequality, and the easy identity EcX “

epc´1qλ for c ą 0. Let b “ logα. Then

PpX ď αλq “ P´

ebX ě ebαλ¯

ďEebX

ebαλ“

epeb´1qλ

ebαλ“ e´Qpαqλ.

Similarly,

PpX ě αλq “ P´

ebX ě ebαλ¯

ďEebX

ebαλ“

epeb´1qλ

ebαλ“ e´Qpαqλ.

We record frequently needed bounds on the function Qpxq.

Lemma 5.4 (Q bounds). We have

(5.3) Qpxq “

ż x

1log t dt pall xq “

8ÿ

k“2

p´1qk

kpk ´ 1qpx´ 1qk p|x´ 1| ă 1q,

and

(5.4)x2

3ď Qp1` xq ď x2 p|x| ď 1q.

Corollary 5.5 (Prime factors in intervals). Let ωpn, tq “ #tp|n : p ď tu.

(a) Uniformly for 3 ď t ď x and 0 ď λ ď 1, we have

#tn ď x : ωpn, tq ď λ log2 tu ! xplog tq´Qpλq.

Let λ0 ą 1.(b) Uniformly for 3 ď t ď x and 1 ď λ ď λ0, we have

#tn ď x : ωpn, tq ě λ log2 tu !λ0 xplog tq´Qpλq.

(c) Uniformly for 3 ď t ď x and 0 ď ψ ďa

log2 t, we have

#tn ď x : |ωpn, tq ´ log2 t| ą ψa

log2 tu ! xe´13ψ2.

Proof. Let T denote the set of primes in r2, ts. By Mertens, H “ log2 t ` Op1q. The given bounds nowfollow from Theorem 5.2 together with the tail bounds in Lemma 5.3. For (a),

#tn ď x : ωpn, tq ď λ log2 tu !x

log t

ÿ

kďλ log2 t

plog2 t`Op1qqk

k!

“x

log t

ÿ

kďλ log2 t

plog2 tqkp1`Op1 log2 tqq

k

k!

!x

log t

ÿ

kďλ log2 t

plog2 tqk

k!

ď xplog tq´Qpλq.

58 KEVIN FORD

For (b), there is some C such that

#tn ď x : ωpn, tq ě λ log2 tu !x

log t

ÿ

kěλ log2 t´1

plog2 t` Cqk

k!

“x

log t

ÿ

kěλ˚plog2 t`Cq

plog2 t` Cqk

k!,

where λ˚ “ λ`Op1 log2 tq. Since Qpλ˚q “ Qpλq `Oλ0p1 log2 tq, applying Lemma 5.3 gives

#tn ď x : ωpn, tq ě λ log2 tu ! xe´plog2 t`CqQpλ˚q !λ0 xplog tq´Qpλq.

Part (c) follows from (a) and (b) plus Lemma 5.4.

5.1. Primes counted with multiplicity. The results of the previous section may be extended to the distri-bution of the function Ωpnq. There is, however, a change of behavior of #tn ď x : Ωpnq “ ku in thevicinity of k “ 2 log2 x, due to the influence of powers of 2.

Lemma 5.6. Uniformly for x ě 2 and 0 ď y ă 2 we haveÿ

nďx

yΩpnq !x

p2´ yqplog xqy´1.

Proof. Again, use the log-trick. We have

plog xqÿ

nďx

yΩpnq ďÿ

nďx

yΩpnq pxn` log nq

ď xS `ÿ

nďx

yΩpnqÿ

q|n

Λpqq, S “ÿ

nďx

yΩpnq

n.

Write n “ qm and note that Ωpnq “ Ωpqq ` Ωpmq. Thenÿ

nďx

yΩpnqÿ

q|n

Λpqq “ÿ

mďx

yΩpmqÿ

qďxm

ΛpqqyΩpqq

!ÿ

mďx

yΩpmqpxmq “ xS.

Therefore,ÿ

nďx

yΩpnq !x

log xS ď

x

log x

ź

pďx

ˆ

1`y

p`y2

p2` ¨ ¨ ¨

˙

“x

log x

ź

pďx

ˆ

1`y

p´ y

˙

!x

2´ yplog xqy´1.

Theorem 5.7. (a) Uniformly for 0 ď λ ď 1 we have

#tn ď x : Ωpnq ď λ log2 xu !x

plog xqQpλq.

(b) Uniformly for 1 ď λ ă 2 we have

#tn ď x : Ωpnq ě λ log2 xu !x

p2´ λqplog xqQpλq.

SIEVE METHODS LECTURE NOTES, SPRING 2020 59

(c) Uniformly for k ě 1 we have

#tn ď x : Ωpnq ě ku !xk log x

2k.

Remarks. Estimate (c) is most useful when k ě 2 log2 x. Estimates (b) and (c) smoothly interpolate,since Qp2q “ log 4´ 1, and thus when k “ 2 log2 x`Op1q both bounds take the form

!x log2 x

plog xqlog 4´1.

Proof. (a) Take y “ λ in Lemma 5.6, obtaining

#tn ď x : Ωpnq ď λ log2 xu ďÿ

nďx

λΩpnq´λ log2 x ! xplog xq´Qpλq.

(b) Similarly, apply Lemma 5.6 with y “ λ:

#tn ď x : Ωpnq ě λ log2 xu ďÿ

nďx

λΩpnq´λ log2 x !x

p2´ λqplog xqQpλq.

(c) Take y “ 2´ 1k in Lemma 5.6. Then

#tn ď x : Ωpnq ě ku ďÿ

nďx

yΩpnq´k

! y´kx

2´ yplog xqy´1

ďxk

2kp1´ 12k q

kplog xq1´1k !

xk log x

2k.

5.2. Application: Erdos’ multiplication table problem. In 1955, Erdos [36] posed the following prob-lem: Estimate the number, ApNq, of distinct products of the form ab with a ď N , b ď N . Erdos provedthat ApNq “ opN2q, and later in 1960 [38] refined the estimates to prove that ApNq “ N2plogNq´E`op1q,where

E “ Qp1 log 2q “ 1´1` log log 2

log 2“ 0.08607 . . . .

Theorem 5.8. We have ApNq ! N2

plogNqE.

Proof. Let k0 “log2pN

2q

log 2 “log2Nlog 2 ` 1. By Theorem 5.7, the number of distinct products with Ωpabq ě k0

is bounded above by

#tm ď N2 : Ωpmq ě k0u ! N2plogNq´Qp1 log 2q “ N2plogNq´E .

If Ωpabq ă k0, then ωpaq “ h, ωpbq “ j with h`j “ k ă k0. The number of pairs pa, bqwith h ď 12 log2N

or j ď 12 log2N is

ď 2N#ta ď N : ωpaq ď 12 log2Nu ! N2plogNq´Qp12q ! N2plogNq´0.15 ! N2plogNq´E .

If h and j are fixed, and both larger than 12 log2N , we apply Theorem 5.2, taking T as the set of all primes

ď N , so that H “ log2N `Op1q. The number of pairs pa, bq is thus

!N2plog2Nq

h`j

plogNq2h!j!.

60 KEVIN FORD

Summing first over all j, h with h` j “ k using the binomial theorem, and then over k ă k0 using Lemma5.3, we obtain an upper bound for the total number of pairs a, b with Ωpabq ă k0 of

!N2

log2N

ÿ

kăk0

p2 log2Nqk

k!! N2plog2Nq´Qp1 log 4q “ N2plogNq´E .

The upper bound in Theorem 5.8 is close to the truth. In fact [47],

ApNq —N2

plogNqEplog2Nq32.

5.3. Exercises.

Exercise 5.1. Let S denote the set of numbers that are the sum of two squares. Show that for any ε P p0, 1s,

#tn ď x, n P S : |ωpnq ´ 12 log2 x| ą ε log2 xu !

x

plog xq12`ε26.

SIEVE METHODS LECTURE NOTES, SPRING 2020 61

6. STRUCTURE OF SHIFTED PRIMES

Throughout, we will work with sets Pa “ tp ` a : p prime u, for a fixed nonzero a. The structure ofthese sets have numerous applications, particularly when a “ ´1 or a “ 1. These include

(1) The study of Euler’s totient function φpnq;(2) The study of the sum-of-divisors function σpnq;(3) Problems about orders and primitive roots modulo primes;(4) Carmichael numbers; analyzing primality tests

6.1. The number of prime factors of shifted primes. In 1935, Erdos [31] showed that for any fixed a ‰ 0,the function ωpp` aq has normal order log2 p. To accomplish this, Erdos proved an upper bound of Hardy-Ramanujan type for the number of primes p ď x with ωpp` aq “ k. Here we prove a best-possible versionof this estimate. Theorem 6.2 below improves the uniformity of Theorem 1 of Timofeev [128], who showedthis bound uniformly for k ď b log2 x for any fixed b.

Lemma 6.1. Fix b ě 0. Uniformly for x ě 2 and ` ě 0 we haveÿ

ωprq“`rP`prqďx

1

φprq logbpxrq!bplog2 x`Op1qq

`

`! logb x.

Proof. If ` “ 0 then r “ 1 and the result is trivial. Now suppose ` ě 1. Then 2 ď r ď x2. We separatelyconsider r in log-dyadic ranges. Let Qj “ x12j for j ě 0 and define

Tj “

"

2 ď r ď x2 : ωprq “ `, rP`prq ď x,x

Qj´1ă r ď

x

Qj

*

.

For r P Tj , P`prq ď xr ď Qj´1. Also, if Tj is nonempty then Qj´1 ě 2. We haveÿ

rPTj

1

φprq logbpxrqď

1

logbQj

ÿ

rPTj

1

φprq.

For the sum on the right side, we’ll use a trick that was useful in the study of Ψpx, yq. Let α “ 110 logQj

.

Since Qj´1 ě 2, Qj ě?

2 and thus 0 ă α ď 13 . We’ll encode the condition r ě xQj´1 with

1

φprq“

1

φprqαφprq1´α!

1

rα2φprq1´α!

1

xα2φprq1´α,

since pxrqα2 ď Qα2j´1 “ Qαj “ e110. Now

ÿ

P`prqďQj´1

ωprq“`

1

φprq1´αď

1

`!

"

ÿ

pďQj´1

1

pp´ 1q1´α`

1

pppp´ 1qq1´α` ¨ ¨ ¨

*`

“1

`!

"

Op1q `ÿ

pďQj´1

1

p1´α

*`

.

Since log p ď logQj´1 “ 2 logQj , we have pα “ 1`Opα log pq. It follows thatÿ

pďQj´1

1

p1´αď

ÿ

pďQj´1

1

p`O

ˆ

α log p

p

˙

ď log2Qj´1 `Op1q ď log2 x`Op1q.

62 KEVIN FORD

Putting everything together, we see thatÿ

rPTj

1

φprq logbpxrq!

1

xα2 logbQj

ÿ

P`prqďQj´1

ωprq“`

1

φprq1´α

!1

xα2 logbQj

plog2 x`Op1qq`

`!

“2bj exp

´ 120 ¨ 2

j(

logb x

plog2 x`Op1qq`

`!.

Summing over j completes the proof.

Theorem 6.2. Fix a ‰ 0. Uniformly for x ě 4|a| and k P N we have

#t2` |a| ă p ď x : ωpp` aq “ ku !ax

log2 x

plog2 x`Op1qqk´1

pk ´ 1q!p2|aq

and

#t2` |a| ă p ď x : ωpp`a2 q “ ku !ax

log2 x

plog2 x`Op1qqk´1

pk ´ 1q!p2 - aq.

Proof. Let

s “

#

1 2|a

2 2 - a.

Suppose p ą 2 ` |a| ě 3 is prime and ωpp`as q “ k. Define q “ P`pp`as q and write p`as “ qr. Either

ωprq “ k ´ 1 or ωprq “ k, and r is odd if 2|a. Also, rP`prq ď rq ď px` aqs. Define, for ` ě 0,

R` “ tr P N : rP`prq ď x`as , ωprq “ `; r odd if 2|au.

We separately consider two cases. First, suppose that 1 ď k ď log2 x. Let L “ expt?

log xu. UsingTheorem 4.1, we have

(6.1) #t2` |a| ă p ď x : q2|p`as u ď Ψpx` a, Lq

looooomooooon

qďL

`ÿ

qąL

x` a

q2!a

x

L.

We use Theorem 2.5 to bound the contribution of those p with qpp` aq thus:

#t2` |a| ă p ď x : ωpp`as q “ k, q2 - p`as u ďÿ

rPRk´1

#tq ď x`ars : q, qsr ´ a

loooomoooon

E“|rsa|

both primeu

!ÿ

rPRk´1

|ars|

φp|ars|q

x` a

rs log2 x`ars

!a xÿ

rPRk´1

1

φprq log2 x`ar

.

Invoking Lemma 6.1, we conclude that

#t2` |a| ă p ď x : ωpp`as q “ ku !ax

log2 x

plog2 x`Op1qqk´1

pk ´ 1q!`x

L.

The final term xL is negligible since k ď log2 x implies that the first term on the right is " x log2 x. Thisconcludes the proof when k ď log2 x.

SIEVE METHODS LECTURE NOTES, SPRING 2020 63

Now assume k ą log2 x. Here we do not separately consider the case q2|p`as q and do not use (6.1). We

must then retain both cases ωprq “ k ´ 1 and ωprq “ k. Arguing as before, we obtain from Theorem 2.5and Lemma 6.1 the estimate

#t2` |a| ă p ď x : ωpp`as q “ ku !aÿ

rPRk´1YRk

x

φprq log2ppx` aqrq

!ax

log2 x

ˆ

plog2 x`Op1qqk´1

pk ´ 1q!`plog2 x`Op1qq

k

k!

˙

“x

log2 x

plog2 x`Op1qqk´1

pk ´ 1q!

ˆ

1`plog2 x`Op1qq

k

˙

Recalling that k ě log2 x, this concludes the proof.

6.2. Large prime factors of shifted primes. It is conjectured that P`pp ` aq has a distribution roughlythe same as the distribution of P`pnq over all integers n ď x. We are far from proving this, in fact thefollowing is not known:

Conjecture 6.3. For any 0 ă u ă 1, there are infinitely many primes p with P`pp` aq ă pu and infinitelymany primes p with P`pp` aq ą pu.

The second assertion measures progress toward a special case of the Prime k´tuples conjecture 1.3.Letting s “ 1 for even a and s “ 2 for odd a, it’s conjectured that infinitely often, p`as is prime.

At present, it is know that P`pp` aq ă p0.2961 infinitely often and P`pp` aq ě p0.677 infinitely often.The first result in this direction is due to Erdos.

Theorem 6.4 (Erdos [31], 1935). For some u ă 1 there are infinitely many primes p with P`pp` aq ă pu.

Definition 4. Let µ1 denote the infimum of all real numbers µ such that for all a ‰ 0,

#tp ď x : P`pp` aq ď xµu ą x1´op1q.

Upper bounds on µ1 have been given in a series of papers, see Table 2.

Upper bound on µ1 Author year

2?

2´ 2 “ 0.82842 . . . Wooldridge [133] 1979625512e “ 0.44907 . . . Pomerance [110] 1980

12e´12.73 “ 0.34664 . . . Balog [4] 198412e´12 “ 0.30326 . . . Friedlander [54] 1989

0.2961 Baker and Harman [7] 1998

TABLE 2. Progression of results on smooth shifted primes

Here, we present an argument due to Balog which gives quantitatively better constants. The main input isa hypothesis known as the Brun-Titmarsch on average hypothesis. Here N “ Npxq is some function of x.

Hypothesis BTpx,N,´a;λq. For all but opNq moduli n P pN, 2N s (as N Ñ8), we have

(6.2) πpx;n,´aq ď λx

φpnq log x.

64 KEVIN FORD

By Theorem 3.2, for any ε ą 0, any 1 ă N ă x with x sufficiently large (depending on ε), and any a, wehave (6.2) with λ “ p2` εq log x

logpxNq . The first result showing Hypothesis BTpx,N,´a;λq with a value of λsmaller than that achievable pointwise (that is, for all n, a) is due to Hooley [83], with further improvementsdue to Hooley [85], Fouvry [53], Bombieri, Friedlander and Iwaniec [14] and Baker and Harman [6, 7].

Theorem 6.5 (Balog [4], 1984). Let x be large,M “ xξ ě x12 logA x, whereA is a large enough constant.Assume that λ ě 1 and Hypothesis BTpx,N ;λq holds for all M ă N ďM log x. Then for any u satisfying

(6.3) ξ ą u ą`

e´1ξλp1´ ξq˘

11`λ ,

there are "u x log5 x primes p ď x so that P`pp` aq ă xu.

Take ξ ą 12, then BTpx, xξ; a, 4` εq holds, where εÑ 0 as ξ Ñ 12 and xÑ8. We conclude that

Corollary 6.6. For any u ą 12e´15 “ 0.409365 . . ., there are"u x log5 x primes p ď x with P`pp`aq ă

xu.

Bombieri, Friedlander and Iwaniec [14] showed that Hypothesis BTpx, x12 logA x, a; 1`εq holds for allA ą 0 and all ε ą 0, if x is sufficiently large. It follows that (6.3) holds for all u ą 1

2e´12 “ 0.303 . . .,

giving Friedlander’s result [54].

Proof of Theorem 6.5. Let y “ xu, and for |a| ă p ď x let

gppq “ #tpm,nq : p` a “ mn,P`pmnq ď y,M ă n ďM log xu.

By Cauchy-Schwarz (see §2.2.4) we have

(6.4) #tp ď x : P`pp` aq ď yu ě

´

ř

pďx gppq¯2

ř

pďx gppq2.

We bound the denominator crudely as

(6.5)ÿ

pďx

gppq2 ďÿ

pďx

p#tm|p` auq2 ďÿ

nďx`a

τpnq2 ! x log3 x.

Evidently,

gppq ě #tpm,nq : p` a “ mn,P`pmq ď y,M ă n ďM log xu

´#tpm,nq : p` a “ mn,M ă n ďM log x, P`pnq ą yu,

where we have ignored the condition P`pmq ď y in the subtracted term. Thus

(6.6)ÿ

pďx

gppq ě S1 ´ S2,

where, ignoring the terms with m ď x`aM log x , which are negligible,

S1 ěÿ

P`pmqďyx`a

M log xămďx`a

M

πpx;m,´aq ´ πpMm´ a;m,´aq

and, writing n “ q` with q “ P`pnq,

S2 “ÿ

yăqďM log x

ÿ

Mqă`ďpM log xqqP`p`qďq

πpx; `q,´aq.

SIEVE METHODS LECTURE NOTES, SPRING 2020 65

Since x`aM ! x12plog xq´A, we use the Bombieri-Vinogradov theorem for S1, obtaining

S1 ěÿ

P`pmqďyx`a

M log xămďx`a

M

x´Mm

φpmq log x`O

ˆ

x

log x

˙

ěx

log x

ÿ

P`pmqďyx`a

M log xămďx`a

M

1

φpmq`O

ˆ

x

log x

˙

using the elementary boundÿ

mďz

m

φpmq“ Opzq.

We will also need the asymptotic

(6.7)ÿ

mďz

1

φpmq“ C1 log z `Op1q

for some constant C1 ą 0. If P`pmq ą y write m “ qm1 where q “ P`pmq. Thenÿ

P`pmqďyx`a

M log xămďx`a

M

1

φpmqě

ÿ

x`aM log x

ămďx`aM

1

φpmq´

ÿ

yăqďx`aM

1

q ´ 1

ÿ

x`aMq log x

ăm1ďx`aMq

1

φpm1q.

The contribution from primes q ą xpM log xq is ! plog2 xq2

log x by Mertens’ theorem and (6.7). For y ă q ď

xpM log xq we use (6.7) again and see that the sum on m1 is C1 log2 x`Op1q. Therefore,

S1 ěx

log xpC1 log2 xq

ˆ

1´ loglogpxMq

log y` op1q

˙

“x

log xpC1 log2 xq

ˆ

1´ log1´ ξ

u` op1q

˙

.

(6.8)

Now we bound S2 from above. The terms corresponding to M ă q ď M log x contribute, by theBrun-Titchmarsh inequality,

!x

log x

ÿ

MăqďM log x

1

q

ÿ

Mqă`ďpM log xqq

1

φp`q!xplog2 xq

2

log2 x.

Let E denote the set of n P pM,M log xs such that πpx;n,´aq ą λ xφpnq log x . By our hypothesis (6.2) and

the Brun-Titchmarsh inequality,ÿ

nPE

πpx;n,´aq !x

log x

ÿ

nPE

1

φpnq“ o

ˆ

x log2 x

log x

˙

.

Using (6.7) gain, the terms with q ďM and q` R E contribute

ďλx

log x

ÿ

yăqďM

ÿ

Mqă`ďpM log xqqq`RE

1

φpq`q

ď pλ logpξuq ` op1qqx

log xpC1 log2 xq .

66 KEVIN FORD

Therefore,

(6.9) S2 ď pλ logpξuq ` op1qqx

log xpC1 log2 xq .

Combining (6.8) and (6.9), we conclude thatÿ

pďx

gppq ěx

log xpC1 log2 xq

ˆ

1´ log1´ ξ

u´ λ log

ξ

u` op1q

˙

as xÑ8. The hypothesis (6.3) implies that

1´ log1´ ξ

u´ λ log

ξ

uą 0.

Inserting the lower bound forř

pďx gppq into (6.4) and recalling (6.5), the proof is complete.

Now we turn to the problem of showing that P`pp` aq is often large.

Definition 5. Let µ2 denote the supremum of all real numbers µ such that for any a ‰ 0

#tp ď x : P`pp` aq ą xµu "µx

log x

The progression of records for the lower bound on µ2 is given in Table 3.

Lower bound on µ2 Author year

1´ 12e´14 “ 0.6105 . . . Goldfeld [58] 1969

1´ 12e´14 “ 0.6105 . . . Motohashi [101] 1970

12 `

32p1´ e

´112q “ 0.61993 . . . Hooley [83] 197258 “ 0.625 Hooley [84] 1973

0.6683 Fouvry [53] 4 19850.676 Baker and Harman [6] 19960.677 Baker and Harman [7] 1998

TABLE 3. Progression of results on large prime factors of shifted primes

Here we show the theorem proved independently by Goldfeld and Motohashi. We will then indicatewhere in the proof the further improvements come from.

Theorem 6.7. We have µ2 ě 1´ 12e´14.

Proof. We use a device due to Chebyshev, in connection with the largest prime factor of polynomials. Let12 ă θ ă 1´ 1

2e´14 and define

M “ logź

|a|ăpďx

pp` aq.

Let B be the exponent in the Bombieri-Vinogradov Theorem (Theorem 2.17) corresponding to A “ 2, andlet Q “ x12plog xq´B . Let P denote the set of primes |a| ă p ď x so that there is a prime power qb ą Q

with b ě 2 and qb|pp` aq. Define exponents αpqq by the prime factorizationź

|a|ăpďxpRP

pp` aq “ź

qďx`a

qαpqq.

SIEVE METHODS LECTURE NOTES, SPRING 2020 67

ThenM “M1 `M2 `M3 `M4,

where

M1 “ logź

pPP

pp` aq,

M2 “ logź

qďQ

qαpqq.

M3 “ logź

Qăqďxθ

qαpqq,

M4 “ logź

xθăqďx`a

qαpqq.

Our goal is to prove that M4 " x. We accomplish this by first observing that

(6.10) M „ x

by the Prime Number Theorem, and then upper bounding M1,M2,M3. For M1, if p P P then p ` a isdivisible by d2 for some d ą Q13. Hence

M1 ! plog xqÿ

dąQ13

x

d2! x67.

We handle M2 with the Bombieri-Vinogradov Theorem. Letting Epx; s, cq “ πpx; s, cq ´ lipxqφpsq wehave

M2 “ÿ

qbďQ

plog qqπpx; qb,´aq

“ÿ

qbďQ

plog qq

ˆ

lipxq

φpqbq` Epx; qb,´aq

˙

„ lipxq logQ „x

2.

We cannot evaluate M3 asymptotically, but a good upper bound will suffice. The most crude method is touse the Brun-Titchmarsh inequality, Theorem 3.2 with explicit constant. This gives

M3 “ÿ

Qăqďxθ

plog qqπpx; q,´aq

ď p2` op1qqÿ

Qăqďxθ

x log q

pq ´ 1q logpxqq

“ p2` op1qqx

ż xθ

Q

dt

t logpxtq

´

2 log1

2´ 2θ

¯

x.

Combining the estimates for M1,M2 and M3, we find that

M1 `M2 `M3 ď p1` op1qq

ˆ

1

2` 2 log

1

2´ 2θ

˙

x.

68 KEVIN FORD

Recalling the bound on θ, and comparing this with (6.10), we find that M4 "θ x. As each number p` a isdivisible by at most one prime ą xθ we see that

#tp ď x : P`pp` aq ą xθu ěM4

logpx` aq"θ

x

log x,

as desired.

Remarks. Most improvements to Theorem 6.7 come from better estimates of M3 using HypothesisBTpx,N, a;λq (an exception is the work of Hooley [84], which makes use of a Selberg-type sieve). Thesein turn rely on a variety of tools, from complicated sieves to bounds on Kloosterman sums.

The bound µ2 ą 23 of Fouvry enabled Adleman and Heath-Brown [1] to deduce that the first case ofFermat’s Last Theorem is true for infinitely many primes p; this is now a historical point in light of Wiles’sproof 10 years later.

The bound on µ2 also played an important role in the original AKS polynomial-time algorithm [2] fordetermining the primality of numbers.

6.3. Application to Carmichael numbers. A composite number n is a Carmichael number if for allpa, nq “ 1, an´1 ” 1 pmod nq. Such a number mimics a prime w.r.t. the Fermat congruence. An oldcriteria of Korselt says that n is a Carmichael number if and only if n is squarefree and pp ´ 1q|pn ´ 1q

for every prime p|n. The smallest Carmichael numbers are 561, 1105 and 1729. One way to constructCarmichael numbers is to observe that if k P N, and 6k ` 1, 12k ` 1 and 18k ` 1 are all prime, thenn “ p6k ` 1qp12k ` 1qp18k ` 1q is a Carmichael number. By the Prime k-tuples conjecture (Conjecture1.3), there are „ C x

log3 xsuch numbers k ď x.

Alford, Granville and Pomerance showed unconditionally in 1994 [3] that there are infinitely manyCarmichael numbers. Moreover, they showed a lower bound Cpxq " x27 for the counting function Cpxqof Carmichael numbers. A key ingredient is finding many smooth shifted primes p ´ 1. In fact, Alford,Granville and Pomerance proved that

Cpxq " x512p1´µ1q´op1q.

With Baker and Harman’s [7] value µ1 ď 0.2961, we get an exponent of 0.29329 . . .. The 512 fraction

comes from lower bounds for prime in progressions to “virtually all” moduli. Harman [75, 77] improvedthe exponent, showing

Cpxq " x0.4736p1´µ1q´op1q,

where now the exponent is a bit larger than 13.

6.4. Applications to Euler’s function and the sum of divisors function.

6.4.1. Popular values of Euler’s function. Let Apmq “ #tm : φpmq “ nu. Erdos [31] showed that thereis a constant c ą 0 such that Apmq ą mc infinitely often. A key ingredient in the proof is Theorem 6.4. Theargument was sharpened by Pomerance [110], to connect c with the exponent in Theorem 6.4.

Theorem 6.8 (Erdos; Pomerance). For every ε ą 0 there are infinitely many n such that Apnq ą n1´µ1´ε.

Currently, the best bound we know is µ1 ď 0.2961 due to Baker and Harman [7], while it is conjecturedthat µ1 “ 0. The conclusion then would be best possible since trivially

Apmq ď #tn : φpnq ď mu — m log2m.

SIEVE METHODS LECTURE NOTES, SPRING 2020 69

Proof. Fix µ1 ă ν ă 1 and let z be large. Let

P “ tp ď plog zq1ν : P`pp´ 1q ď log zu.

By hypothesis, #P ě plog zq1ν´op1q as z Ñ8. Let

M “

Z

ν log z

log log z

^

,

and let N denote the set of all integers which are the product of M distinct primes from P . Note that forall n P N , φpnq ď n ď z and P`pφpnqq ď log z. Hence, there is an m P tφpnq : n P N u such that

Apmq ě#N

Ψpz, log zq

By Theorem 4.1 ( inequality (4.1)), Ψpz, log zq “ zop1q. Also, as z Ñ8, we have

#N “

ˆ

#P

M

˙

ě

ˆ

#P

M

˙M

ě

˜

plog zqp1´op1qqν

M

¸M

ě plog zq

1ν´1´op1q

¨

ν log zlog2 z

´1‰

“ z1´ν´op1q.

Hence there is anm ď z withApmq ě z1´ν´op1q. Taking ν arbitrarily close to µ1, the theorem follows.

6.4.2. The range of Euler’s function. Let

V “ tφpnq : n P Nu “ t1, 2, 4, 6, 8, 10, 12, 16, 18, 20, 22, 24, 28, . . .u

denote the range of Euler’s totient function φpnq, and let V pxq “ #tm P V : m ď xu be its countingfunction. Evidently V contains only one odd number, namely 1, but what can we say about the growth ofV pxq? Since φppq “ p´ 1 for all primes p, trivially

V pxq ě πpxq „x

log x.

Pillai [105] gave the first non-trivial upper bound on V pxq, namely

V pxq !x

plog xqplog 2qe.

Using sieve methods, Erdos [31] improved this to

V pxq “x

plog xq1´op1qpxÑ8q.

Upper and lower bounds for V pxq were sharpened in a series of papers by Erdos [34], Erdos and Hall[40, 41], Pomerance [111], Maier and Pomerance [95], and finally by Ford [45]. The exact order of V pxq isnow known [45, Theorem 1], namely

V pxq “x

log xexptCplog3 x´ log4 xq

2 `D log3 x´ pD ` 12´ 2Cq log4 x`Op1qu,

where C “ 0.81781464640083632231 . . . and D “ 2.17696874355941032173 . . . are specific constantsdefined in [45]. Sieve methods played a crucial role in these investigations. Below we use the results aboutthe normal behavior of ωpnq and ωpp` aq to provide nontrivial upper and lower boudns for V pxq.

70 KEVIN FORD

Theorem 6.9. We have

V pxq "x log2 x

log x.

Proof. Let y “ expt?

log xu and let

B “ tpq : q ď y ă p ď xq, p and q primeu.

Evidently φpmq ď x for m P B. Our goal is to show that there is little overlap among the numbers φpmq.By simple inclusion-exclusion,

(6.11) V pxq ě |B| ´ Z, Z :“ #tm1,m2 P B : m1 ‰ m2, φpm1q “ φpm2qu.

By Mertens,

|B| “ÿ

qďy

πpxqq ´ πpyq "ÿ

qďy

x

q log x"x log2 x

log x.

Also, Z is the number of solutions of

pp´ 1qpq ´ 1q “ pp1 ´ 1qpq1 ´ 1q pp ‰ p1, pq P B, p1q1 P Bq.

Fix q and q1, and write

g “ pq ´ 1, q1 ´ 1q, r “q ´ 1

g, s “

q1 ´ 1

g.

Then the above equation reduces topp´ 1qr “ pp1 ´ 1qs,

where pr, sq “ 1. Thus, for some n ď xpqsq we have p “ 1 ` rn and p1 “ 1 ` sn. Apply Theorem 2.5with the pair of linear forms rn` 1, sn` 1. Here E “ rs|r ´ s| ! x3. Hence

#tn ď xpqsq : nr ` 1, ns` 1 both primeu !xpqsq

log2pxpqsqqplog2 xq

2

!xplog2 xq

2

log2 x

g

qq1

We now sum over q, q1 using Exercise 2.12. This gives

ÿ

q,q1ďyq‰q1

pq ´ 1, q1 ´ 1q

qq1ď

ÿ

gďy2

g

ˆ

ÿ

qďyq”1 pmod gq

1

q

˙2

! plog2 xq2

ÿ

gďy2

g

φpgq2

ď plog2 xq2ź

pďy2

ˆ

1`p

pp´ 1q2`O

ˆ

1

p2

˙˙

! plog2 xq2a

log x.

It follows that

Z !xplog2 xq

4

plog xq32.

Combined with (6.11), this completes the proof.

SIEVE METHODS LECTURE NOTES, SPRING 2020 71

Theorem 6.10. We haveV pxq !

x

log xexp

33plog3 xq2(

.

Proof. Letε “ 0.001, δ “ Qp1´ εq ě ε23.

LetS “ tp : ωpp´ 1q ď p1´ εq log2 pu

and let Spxq be the counting function of S . By Theorem 6.2, and Lemma 5.3,

Spxq ď #tp ď x : ωpp´ 1q ď p1´ εq log2 xu

!x

log2 x

ÿ

kďp1´εq log2 x

plog2 x`Op1qqk´1

pk ´ 1q!

!x

log2 x

ÿ

kďp1´εq log2 x

plog2 xqk´1

pk ´ 1q!

!x

plog xq1`δ.

(6.12)

Also define

W pxq “ maxyďx

log y

yV pyq.

Although log yy V pyq may not be monotone, W pxq is and this will be convenient in the proof.

Let x be large. Then there is a y ď x with

W pxq “log y

yV pyq.

By Theorem 6.9, W pxq Ñ 8 as xÑ8 and hence y Ñ8 as xÑ8. We now bound V pyq. Let

θ “ 0.97, y1 “ exp

"

plog yqθ

3 log2 y

*

.

Associate to each v P V with v ď y a preimage n, that is, φpnq “ v. We have n ! y log2 y by a classicalestimate.

We divide these v into four classes:

(a) V1 “ tv : Ωpvq ě 2.9 log2 y or Ωpnq ě 2.9 log2 yu;(b) V2 “ tv : p2|n for some p ą y1u;(c) V3 “ tv R V1 Y V2 : p|n for some p ą y1, p P Su;(d) V4 “ V X r1, xszpV1 Y V2 Y V3q (the remaining v).

Theorem 5.7 (c) implies immediately that

(6.13) |V1| !yplog2 yq

2

plog yq2.9 log 2´1!

y

plog yq1.01.

Trivially,

(6.14) |V2| !ÿ

pąy1

y log2 y

p2!

y

plog yq100.

72 KEVIN FORD

Now suppose that v P V3. Then p|n for some p P S, p ą y1. Since v R V2, v “ pp´ 1qφpnpq “ pp´ 1qw

for some w P V , w ď yp´1 . Thus,

|V3| ďÿ

y1ăpďypPS

V

ˆ

y

p´ 1

˙

! Spyqloomoon

pąy2

`W pyqyÿ

y1ăpďy2pPS

1

p logpypq.

A standard partial summation argument, together with (6.12), yields

ÿ

y1ăpďy2pPS

1

p logpypq!Spyq

y`

ż y2

y1

Sptq

t2 logpytqdt

!1

plog yq1`δ`

1

plog y1qδ

ż y2

y1

dt

tplog tq logpytq

!plog2 yq

2

plog yq1`δθ.

Therefore, by the monotonicity of W pq and (6.12),

(6.15) |V3| !W pyqplog2 yq

2

yplog yq1`δθ!

yW pxq

plog yq1`δθ2.

Finally, suppose that v P V4. Let

y2 “ y3 log2 y1 “ exptplog yqθu.

We claim that

v “ w, v “ pp´ 1qw or v “ pp´ 1qpp1 ´ 1qw pw P V , w ď y2q,

where p, p1 are primes ą y1. Since v R V3, any prime factor of n which is ą y1 is not in S. This impliesthat n has at most two prime factors which are ą y1. If n has three or more such factors, then none of themis in S and thus

Ωpvq ě 3p1´ εq log2 y1 ą 3p1´ εqpθ ´ op1qq log2 y ą 2.9 log2 y,

contradicting that v R V1. Thus, n “ qm, where q is 1, a prime ą y1 or the product of two primes ą y1,and P`pmq ď y1. But then m ď y

Ωpmq1 ď y

Ωpnq1 ď y2 since v R V1 and φpnq “ φpqqφpmq. This proves the

claim with w “ φpmq. Thus,

|V4| ď V py2q `ÿ

p´1ďy

V

ˆ

min

ˆ

y2,y

p´ 1

˙˙

`ÿ

pp´1qpp1´1qďy

V

ˆ

min

ˆ

y2,y

pp´ 1qpp1 ´ 1q

˙˙

.

For t ď y2, V ptq “ tlog tW ptq ď

tlog tW py2q. again separating out the terms with p ą y2 or with pp1 ą y2

we find that

|V4| !W py2q

y

log y`

ÿ

pďy2

y

p logpypq`

ÿ

pp1ďy2

y

pp1 logpypp1q

!W py2qyplog2 yq

2

log y.

SIEVE METHODS LECTURE NOTES, SPRING 2020 73

Combining this with (6.13), (6.14) and (6.15) gives

W pxq !1

plog yq0.01`

W pxq

plog yqδθ2`W py2qplog2 yq

2.

Again, using the monotonicity of W pq,

W py2q ďW`

exptplog xqθu˘

.

Also recall that W pxq Ñ 8 as xÑ8, and we obtain

W pxq ď Kplog2 xq2W

´

exptplog xqθu¯

for some absolute constant K ą 0. Iterating this expression yields

W pxq ď Kkθkpk´1qplog2 xq2kW

´

exptplog xqθku

¯

provided that plog xqθk" 1. Taking

k “

Z

log3 x

´ log θ

^

producesW pxq ď exptp´1 logpθqqplog3 xq

2 `Oplog3 xqu ! expt33plog2 xq2u.

This completes the proof.

6.5. Exercises.

Exercise 6.1. Show that for every α ă 12 , a positive proportion of primes p satisfy both P`pp ´ 1q ą pα

and P`pp` 1q ą pα.

Exercise 6.2. Improve the upper estimate (6.5) forř

pďx gppq2.

Exercise 6.3 (Ford, 1995 - see [45]). (a) Suppose than Apmq “ k. Also suppose that p ą 2m`1 is a primesuch that

(i) 2p` 1 and 2mp` 1 are both prime;(ii) dp` 1 is composite for all d|2m except for d “ 2, d “ 2m.

Show that Ap2mpq “ k ` 2.(b) Assume the Prime k-tuples conjecture, Conjecture 1.3. Show that a prime p satisfying the above

conditions always exists. Conclude that for any k ě 2 that there is a number m with Apmq “ k. [This is aconjecture of Sierpinski (see [116] and [37]), which was proved for even k by Ford and Konyagin [52] andfor odd k by Ford [46].]

Exercise 6.4. Carmichael [20, 21] conjectured that Apmq “ 1 is impossible. Assume that Apmq “ 1 andφpnq “ m.

(a) (Carmichael-Klee) Show that if dś

p|d p|n and q “ 1` d is prime, then q2|n.(b) Show that 223272432|n.(c) Show that either 132|n or 192|n. Hint: consider the two cases 32n and 33|n.

74 KEVIN FORD

7. SMALL GAPS BETWEEN PRIMES

7.1. Introduction. Prior to 2005, there were only weak results know about small gaps between primes. Letpn denote the n-th prime, and set

∆ “ lim infnÑ8

pn`1 ´ pnlog n

.

The Prime Number Theorem implies ∆ ď 1. Prior to 2005, it was not known that ∆ “ 0, which is itself avery weak bound in the direction of the Twin Prime Conjecture. Here we summarize the major events:

‚ Hardy-Littlewood, 1926 [73] (unpublished): ∆ ď 23 assuming the Extended Riemann Hypothesisfor Dirichlet L-functions.

‚ Erdos, 1940 [33]: ∆ ă 1 unconditionally.‚ Bombieri and Davenport, 1966 [13] : ∆ ď 2`

?3

8 “ 0.466 . . .

‚ Maier, 1988 [94]: ∆ ď 0.248.

We begin by showing Erdos’ argument from 1940, which incorporated a basic sieve bound.

Theorem 7.1. Suppose that, uniformly for all even h ď 2 log x we have

(7.1) #tx2 ă n ď x : n and n` h are both primeu ď pB ` op1qqChx2

log2 x

where

Ch “ Cź

p|hpą2

p´ 1

p´ 2, C “ 2

ź

pą2

ˆ

1´1

pp´ 1q2

˙

.

Then ∆ ď 1´ 12B .

Basic upper bound sieves, such as Theorem 2.5, show that (7.1) holds for some finite B, while Theorem3.5 implies that B “ 4 is admissible.

Proof. The basic idea is that the Prime Number Theorem implies that the average gap between primes up tox is „ log x, but (7.1) implies that there are not many gaps that are extremely close to log x.

Let x be large and let pn`1, . . . , pn`m`1 be the primes in px2, xs. Put dj “ pj`1 ´ pj for all j. Fix1

3B ă ε ă 12B and let

I ““

p1´ εq log x, p1` εq log x‰

.

Assume that dj ą p1´ εq log x for all n` 1 ď j ď n`m. For each even k P I , let

Nk “ #tn` 1 ď j ď n`m : dj “ ku,

so that by (7.1), we have

(7.2) Nk ď pB ` op1qqCkx2

log2 x.

SIEVE METHODS LECTURE NOTES, SPRING 2020 75

Now

x

n`mÿ

j“n`1

dj “ÿ

kąp1´εq log x

kNk

ěÿ

kPI

kNk ` p1` εq log x

ˆ

m´ÿ

kPI

Nk

˙

“ p1` εqm log x´ÿ

kPI

Nk pp1` εq log x´ kq .

The Prime Number Theorem gives m „x2log x . Hence, by (7.2),

(7.3)x

ˆ

1` ε

2` op1q

˙

x´pB2` op1qqx

log2 x

ÿ

kPI

Ck pp1` εq log x´ kq .

We claim that

(7.4)ÿ

kďy

Ck “ y `Oplog2 yq.

Assuming the claim, partial summation givesÿ

kPI

kCk „ 2ε log2 x,

and we conclude from (7.3) that

0 ěε

2´ pB2q

`

2εp1` εq ´ 2ε˘

` op1q “ε

2´Bε2 ` op1q.

This is a contradiction if ε ă 12B , and proves the theorem.

Now we prove the claim (7.4). Write Ck “ Cř

d|k gpdq, where g is multiplicative, supported on square-free integers, gp2q “ 0 and gppq “ 1

p´2 for primes p ą 2. Thus,

gpdq !1

d

ˆ

d

φpdq

˙2

!plog2 dq

2

d!

log d

d.

We then computeÿ

kďy

Ck “ Cÿ

dďyd odd

gpdqÿ

kďyp2dq|k

1 “ Cÿ

dďyd odd

gpdqY y

2d

]

“Cy

2

ÿ

d

gpdq

d`O

ˆ

yÿ

dąy

gpdq

d`

ÿ

dďy

gpdq

˙

“Cy

2

ź

pą2

ˆ

1`gppq

p

˙

`Oplog2 yq

“ y `Oplog2 yq,

which proves (7.4).

76 KEVIN FORD

7.2. Improved gap detectors: GPY-Zhang-Maynard-Tao. In 2005 (the paper appeared in 2009), Gold-ston, Pintz and Yıldırım[59] showed that ∆ “ 0 using a new type of prime detector. Let ph1, . . . , hkq be anadmissible k-tuple of non-negative integers; that is, the set of linear forms pn`h1, . . . , n`hkq is admissiblein the sense of Definition 1. For some non-negative “weight function” wpnq, consider

(7.5) S “ÿ

Nănď2N

ˆ kÿ

j“1

1n`hj prime ´ 1

˙

wpnq.

If S ą 0 then there is an n P pN, 2N s such that at least two of the forms n` hj are simultaneously prime.The object is to choose wpnq so that

(a) wpnq is small when there are few primes among the n` hj(b) wpnq is large when n` hj is prime ( or nearly prime) for many j;(c) We can find a good upper bound for

ř

Nănď2N wpnq and, for every j, a good lower bound for thesum

ř

Nănď2N wpnq1n`hj prime.

A naive choice iswpnq “ 1n`hj prime @j .

This satisfies (a) and (b) but not (c), because we need something like the Hardy-Littlewood conjectures (Con-jecture 1.3) to get the required lower bounds. Motivated by Selberg’s sieve, Goldston, Pintz and Yıldırımmake the choice

wpnq “

ˆ

ÿ

d|pn`h1q¨¨¨pn`hkq

λd

˙2

, λd “ µpdq

ˆ

logpzdq

log z

˙k``

, ` ě 0.

Elaborating on the ideas in [59], they proved in [60] that

lim infnÑ8

pn`1 ´ pn?

log nplog2 nq2ă 8.

More interestingly, they showed that any exponent improvement in the Bombieri-Vinogradov Theoremwould imply that bounded gaps exist infinitely often. More precisely,

Theorem 7.2 (Goldston-Pintz-Yıldırım, 2007). Assume that for some θ ą 12 we have

(7.6) EHpθq : @A ą 0,ÿ

qďxθ

maxpa,qq“1

maxyďx

ˇ

ˇ

ˇ

ˇ

πpy; q, aq ´lipyq

φpqq

ˇ

ˇ

ˇ

ˇ

!Ax

logA x.

Then there is a constant Cpθq such that pn`1 ´ pn ď Cpθq infinitely often. In particular, Cp0.971q “ 16.

Unconditionally, the Bombieri-Vinogradov Theorem (Theorem 2.17) implies EHpθq for all θ ă 12,while Elliott and Halberstam [30] conjectured EHpθq for all θ ă 1.

Conjecture 7.3 (Elliott-Halberstam Conjecture). We have EHpθq for every θ ă 1.

Motohashi and Pintz [102] showed in fact that the bounded gaps conclusion would follow from a versionof (7.6) restricted to smooth moduli up to xθ, where θ ą 12, that is moduli with P`pqq ď xδ. YitangZhang [135] then surprised the world in May, 2013 by supplying such a proof of the modified version of(7.6).

Theorem 7.4 (Yitang Zhang, 2013 [135]). For infinitely many n, pn`1 ´ pn ď 70000000.

SIEVE METHODS LECTURE NOTES, SPRING 2020 77

A large on-line collaborative Polymath project [108] refined Zhang’s ideas in the summer of 2013 andsubsequently reduced the bound to about 4600. Then, in October, 2013, James Maynard [97] introduced abetter weight function wpnq, which reduced the bound further to 600 and furthermore showed that boundedgaps could contain arbitrarily many primes. Around the same time, Terence Tao (unpublished) had a similaridea for improving the weitgh function.

Theorem 7.5 (Maynard-Tao). For any m there is a number Cm ! m2e4m such that pn`m ´ pn ď Cminfinitely often. Assuming the Elliott-Halberstam Conjecture, we have C2 ď 12 and Cm ! m2e2m.

A second Polymath project [109] resulted in further numerical improvements, culminating in the boundpn`1 ´ pn ď 246 infinitely often. This is the current world record.

7.3. Bounded gaps between primes. We now prepare the ground for the proof of Theorem 7.5. Themethod is robust enough to handle general linear forms (not only those of type n ` hi), and moreover thebounds can be made uniform in the coefficients of the forms, as in [98], with little additional effort.

Theorem 7.6. For every m P N there is a number Km such that the following holds. Fix k P N withk ě Km. Uniformly over all N ě 100 and every admissible set pa1n` b1, . . . , akn` bkq of linear forms,with 1 ď ai ď plogNq100 and ´aiN2 ď bi ď NplogNq100 for all i, we have

#

"

N ă n ď 2N :kÿ

j“1

1ain`bi prime ě m

*

ěN

plogNqck

for some constant ck depending only on k. Moreover, we have

(a) Km ! me4m for all m ě 2.(b) Assuming the Elliott-Halberstam Conjecture, we have Km ! me2m.

The PolyMath8b project [109] implies5 that K2 “ 50 is admissible. Also, Maynard [97] showed K2 “ 5

is admissible assuming the Elliott-Halberstam conjecture.

Proof of Theorem 7.5 from Theorem 7.6. Let k “ Km. Fix h1 ă . . . ă hk so that n ` h1, . . . , n ` hk isan admissible set of linear forms (we say that the tuple ph1, . . . , hkq is admissible). Apply Theorem 7.6, wesee that

lim infnÑ8

pn`m´1 ´ pn ď hk ´ h1.

When m “ 2, there is an admissble tuple with h50 ´ h1 “ 246, proved in [109]. For general m, leth1, . . . , hk be the k smallest primes greater than k. Then n ` h1, . . . , n ` hk is clearly admissible, and bythe Prime Number Theorem,

hk ´ h1 „ k log k “ Km logKm ! m2e4m.

Assuming the Elliott-Halberstam Conjecture, the above calculation yields Cm ! m2e2m. When m “ 2, wemay take k “ 5, and we apply Theorem 7.6 with the 5-tuple p0, 2, 6, 8, 12q.

5The theorems in [109] are stated only in the case ai “ 1 and bi fixed, however it is clear from the proof that the samequantitative bounds hold in the range of uniformity of Theorem 7.6. The relevant parts of [109] to be adjusted are Theorems 19 (i),20 (i) and 26.

78 KEVIN FORD

We now describe the prime-detector which we will use to prove Theorem 7.6. Let N ě 100, assumeEHpθq for some θ P r13, 1q, and define

(7.7) s “ log2N, R “ Nθ2´ 1s , D “ N1s, z “ D1s “ N1s2 .

For each k P N we will construct a special sequence λpdq (which depends only on N and k) for d “

pd1, . . . , dkq P Nk, which is supported on the set

(7.8) D “ DpNq :“ td P Nk : d1 ¨ ¨ ¨ dk ď R,µ2pd1 ¨ ¨ ¨ dkq “ 1, P´pd1 ¨ ¨ ¨ dkq ą zu.

We will frequently use the fact that D is divisor-closed, that is, if d P D and rj |dj for all j then r P D .Let µ` denote an upper bound sieve which is guaranteed by Theorem 2.19 (with respect to the parameters

z,D). In particular we have

(7.9) |µ`ptq| ď 1 pt P Nq.

Now let pa1n` b1, . . . , akn` bkq be an arbitrary admissible set of linear forms (in particular, ai ‰ 0 andpai, biq “ 1 for all i), with respect to Definition 1. Let

(7.10) E “ Epa,bq “kź

i“1

aiź

iăj

paibj ´ ajbiq, E “ E pa,bq “!

d P Nk : pd1 ¨ ¨ ¨ dk, Eq “ 1)

.

Letρpdq “ #tn mod d : pa1n` b1q ¨ ¨ ¨ pakn` bkq ” 0 pmod dqu,

and note that ρppq ă p for all p (because the set of forms is admissible) and ρppq “ k for all p - E; seeTheorem 2.5. Let

(7.11) V “ź

pďz

ˆ

1´ρppq

p

˙

.

Finally, motivated by Selberg’s sieve and using an idea from Koukoulopulos [92, Ch. 28], let

(7.12) wpnq “

ˆ

ÿ

t|pa1n`b1q¨¨¨pakn`bkq

µ`ptq

˙ˆ

ÿ

dPDXE@j:dj |ajn`bj

λpdq

˙2

.

By Theorem 2.19, wpnq ě 0 for all n. The first factor is a familiar upper bound sieve that we used inTheorem 2.5, for example, and very efficiently sieves out those n for which some ain`bi has a prime factorď z. The second factor is the new ingredient, a kind of k-dimensional version of the Selberg method. Wewill optimize λpdq later, and at this point only impose the normalizing condition

(7.13) |λpdq| ď 1 pd P Dq.

The purpose of imposing d P E is to ensure that d1, . . . , dk are pairwise relatively prime.

Lemma 7.7. Suppose that mj |ajn ` bj for every j and m P E . Then m1, . . . ,mk are pairwise relativeprime, and pmj , ajq “ 1 for all j.

Proof. If p|mi and p|mj then p divides aipajn` bjq´ajpain` biq “ aiaj ´ajai, and so p|E. This provesthe first claim. Since pa1n ` b1, . . . , akn ` bkq is an admissible set, paj , bjq “ 1 for all j. Hence, if p isprime, p|mj |pajn` bjq and p|aj then p|bj , a contradiction. Thus, paj ,mjq “ 1.

SIEVE METHODS LECTURE NOTES, SPRING 2020 79

Notational Convention. Throughout the remainder of this section, constants implied by O and ! sym-bols may depend on k and θ, but not on any other parameter. We also suppose that N is sufficiently large,in terms of k and θ. In particular, our bounds are uniform in the coefficients ai, bi in some range.

Proposition 7.8. Adopt the notation (7.7), (7.8), and let µ` be an upper bound sieve function from Theorem2.19 with parameters z,D. Let λpdq satisfy (7.13) and be supported on D . For r P D define

(7.14) ξprq “ÿ

d

λpr1d1, . . . , rkdkq

d1 ¨ ¨ ¨ dk.

Let pa1n` b1, . . . , akn` bkq be an admissible set of linear forms, with k ě 2 and such that

(7.15) 1 ď |ai| ď N2, |bi| ď N2 p1 ď i ď kq.

Define E,E by (7.10), V by (7.11) and wpnq by (7.12). Thenÿ

Nănď2N

wpnq “ V Nÿ

rPD

ξprq2

r1 ¨ ¨ ¨ rk`O

ˆ

N

plogNq99k

˙

.

Proof. From (7.12), we haveÿ

Nănď2N

wpnq “ÿ

tďD

µ`ptqÿ

d,ePDXE

λpdqλpeqÿ

Nănď2Nt|pa1n`b1q¨¨¨pakn`bkq@j:rdj ,ejs|pajn`bjq

1.

Since d, e P E , by Lemma 7.7 the inner sum is empty unless pdiei, djejq “ 1 for all i ‰ j. In thiscase, the simultaneous conditions rdj , ejs|pajn ` bjq, 1 ď j ď k, define a single residue class n modulośkj“1rdj , ejs. Also, the condition t|pa1n ` b1q ¨ ¨ ¨ pakn ` bkq defines ρptq residue classes modulo t. But

P`ptq ď z ă P´pdjejq for each j, hence n runs over ρptq residue classes modulo trd1, e1s ¨ ¨ ¨ rdk, eks.Hence,

ÿ

Nănď2N

wpnq “ÿ

tďD

µ`ptqÿ

d,ePDXEpdiei,djejq“1 pi‰jq

λpdqλpeq

ˆ

ρptqN

trd1, e1s ¨ ¨ ¨ rdk, eks`Opρptqq

˙

“ NV `B ` T,

(7.16)

where

V ` “ÿ

tďD

µ`ptqρptq

t, B “

ÿ

d,ePDXEpdiei,djejq“1 pi‰jq

λpdqλpeq

rd1, e1s ¨ ¨ ¨ rdk, eks,

and, by (7.13) and (7.9),|T | ! |D |2

ÿ

tďD

ρptq.

We begin with the error terms T . We have

|D | ďÿ

rďRP´prqąz

kωprqµ2prq ď Rÿ

rďRP´prqąz

kωprqµ2prq

r

ď Rź

zăpďR

ˆ

1`k

p

˙2

! Rplog2Nq2k,

80 KEVIN FORD

andÿ

tďD

ρptq ď Dÿ

tďD

ρptq

tď D

ź

pďD

ˆ

1`k

p

˙

! DplogNqk.

Hence,

(7.17) T ! R2DplogNq3k ! N θ.

The function gptq “ ρptqt satisfies (Ω) with κ “ k since ρppq ď k for all p. Therefore, by the FundamentalLemma (Theorem 2.19),

(7.18) V ` “ V`

1`Ope´12s log sq

˘

“ V `O

ˆ

1

plogNq100k

˙

.

We now record a very crude bound for B. For any mi “ rdi, eis, there are at most 3ωpmiq choices for di, ei.Hence, from (7.13),

(7.19)ˇ

ˇ

ˇ

ˇ

ÿ

d,ePD

λpdqλpeq

m1 ¨ ¨ ¨mk

ˇ

ˇ

ˇ

ˇ

ď

i“1

ÿ

miďR2

P´pmiqąz

3ωpmiq

miď

ź

zăpďR2

ˆ

1`3

p

˙k

! s6k ! logN.

To asymptotically bound B, we first remove the conditions d, e P E and pdiei, djejq “ 1. Now from (7.10)and (7.15),

E ! N2k`4pk22q.

Hence there are ! logNlog z ! s2 prime factors of E which are ą z. If d R E or e R E then there is a p|E with

p|mj for some j. Write mj “ pm, then analogously to (7.19) we haveˇ

ˇ

ˇ

ˇ

ÿ

d,ePDdRE or eRE

λpdqλpeq

m1 ¨ ¨ ¨mk

ˇ

ˇ

ˇ

ˇ

ď

kÿ

i“1

ÿ

p|Epąz

ÿ

mďR2

P´pmqąz

3ωpmq`1

mp

ź

j‰i

ÿ

mjďR2

P´pmjqąz

3ωpmjq

mj!s2

zs6k !

logN

z.

Similarly, for each i ‰ j we haveÿ

d,ePDpdiei,djejqą1

λpdqλpeq

m1 ¨ ¨ ¨mkď

ÿ

zăpďR2

1

p2

ź

zăpďR2

ˆ

1`3

p

˙k

!s6k

z log z!

1

z.

Therefore,

(7.20) B “ O

ˆ

logN

z

˙

`B1, B1 “ÿ

d,ePD

λpdqλpeq

rd1, e1s ¨ ¨ ¨ rdk, eks.

Combining (7.16) with (7.17), (7.18) and (7.20), plus the crude bound (7.19), we find thatÿ

Nănď2N

wpnq “ NV B1 ` T `O

ˆ

NV logN

z`

NB1

plogNq100k

˙

“ NV B1 `O

ˆ

N

plogNq99k

˙

.

(7.21)

It remains to bound B1. Write

(7.22)1

rd, es“pd, eq

de“

1

de

ÿ

r|pd,eq

φprq.

SIEVE METHODS LECTURE NOTES, SPRING 2020 81

Then

B1 “ÿ

rPD

φpr1q ¨ ¨ ¨φprkq

ˆ

ÿ

@j:rj |dj

λpdq

d1 ¨ ¨ ¨ dk

˙ˆ

ÿ

@j:rj |ej

λpeq

e1 ¨ ¨ ¨ ek

˙

“ÿ

rPD

φpr1q ¨ ¨ ¨φprkq

r21 ¨ ¨ ¨ r

2k

ξprq2.

For any r ď R, r has at most s2 prime factors ą z. Hence, for all ri,

(7.23)φpriq

ri“

ź

p|ri

p1´ 1pq “ 1`O

ˆ

s2

z

˙

“ 1`

ˆ

logN

z

˙

.

Similar to (7.19) we have

(7.24) ξprq ďź

zăpďR

ˆ

1`1

p

˙k

! s2k ! logN.

Therefore,

B1 “ÿ

rPD

ξprq2

r1 ¨ ¨ ¨ rk`O

ˆ

log3N

z

˙

.

Combining this with (7.21) completes the proof.

Proposition 7.9. Assume EHpθq. Adopt the notation (7.7), (7.8), and let µ` be an upper bound sievefunction from Theorem 2.19 with parameters z,D. Let λpdq satisfy (7.13) and be supported on D . Forr P D and 1 ď m ď k define

(7.25) ζmprq “ 1rm“1

ÿ

dPDdm“1

λpr1d1, . . . , rkdkq

d1 ¨ ¨ ¨ dk.

Let pa1n` b1, . . . , akn` bkq be an admissible set of linear forms, with k ě 2, such that

1 ď am ď plogNq100, ´N

2am ď bm ď N log100N

1 ď |ai| ď N2, |bi| ď N2 pi ‰ mq.(7.26)

Define E,E by (7.10), V by (7.11) and wpnq by (7.12). Then, for 1 ď m ď k we have

ÿ

Nănď2N

wpnq1amn`bm prime “V Ym

ś

pďzp1´ 1pq

ÿ

rPD

ζmprq2

r1 ¨ ¨ ¨ rk`O

ˆ

N

plogNq40k2

˙

,

where

Ym :“lip2amN ` bmq ´ lipamN ` bmq

am„

N

logN.

Proof. We begin with

(7.27)ÿ

Nănď2N

wpnq1amn`bm prime “ÿ

tďD

µ`ptqÿ

d,ePDXE

λpdqλpeqÿ

Nănď2Nt|pa1n`b1q¨¨¨pakn`bkq@j:rdj ,ejs|pajn`bjqamn`bm prime

1.

82 KEVIN FORD

As in the proof of Proposition 7.8, d P E and e P E implies that pdiei, djejq “ 1 for all i ‰ j. Also, sincerdm, ems ď R2 “ N θ´2s, p “ amn` bm is prime and

(7.28) p “ amn` bm ěamN

2ěN

2,

we see that

dm “ em “ 1.

The range of n implies that

amN ` bm ă p ď 2amN ` bm.

For each i ‰ m, the condition rdi, eis|ain` bi is equivalent to

p ” a´1i paibm ´ ambiq pmod rdi, eisq,

Again, d P E and e P E implies that this defines a single residue class modulo rdi, eis, and moreover thisresidue class is coprime to rdi, eis. By (7.28), the condition t|pa1n` b1q ¨ ¨ ¨ pakn` bkq is equivalent to

ź

i‰m

pain` biq ” 0 pmod tq, pamn` bm, tq “ 1.

This defines ρ˚ptq residue classes for n modulo t, where ρ˚ is multiplicative by the Chinese RemainderTheorem, and moreover for primes q we have

(7.29) ρ˚pqq “

#

ρpqq if q|amρpqq ´ 1 if q - am.

To see this, note that when q|am, the congruence amn ` bm ” 0 pmod qq has no solutions, and for any nwe have pamn` bm, qq “ 1 since pam, bmq “ 1. When q - am, there are ρpqq solutions of

pa1n` b1q ¨ ¨ ¨ pakn` bkq ” 0 pmod qq,

including the single solution of amn` bm ” 0 pmod qq, which must be removed.Therefore, there are ρ˚ptq residue classes for p modulo amt. By assumption, 1 ď am ď log100N ă z,

and so amt is coprime to rd1, e1s ¨ ¨ ¨ rdk, eks. Hence, the inner sum in (7.27) defines precisely ρ˚ptq reducedresidue classes for the prime p modulo amtrd1, e1s ¨ ¨ ¨ rdk, eks. Define Epuq by

Epuq “ maxpu,sq“1

ˇ

ˇ

ˇ

ˇ

πp2amN ` bm;u, sq ´ πpamN ` bm;u, sq ´lip2amN ` bmq ´ lipamN ` bmq

φpuq

ˇ

ˇ

ˇ

ˇ

and write u “ amtrd1, e1s ¨ ¨ ¨ rdk, eks. Then, by (7.27),

ÿ

Nănď2N

wpnq1amn`bm prime “ÿ

tďD

µ`ptqÿ

d,ePDXEpdiei,djejq“1 pi‰jq

dm“em“1

λpdqλpeq

ρ˚ptqamYmφpuq

`Opρ˚ptqEpuqq

“ amYmV˚B˚ ` T ˚,

(7.30)

SIEVE METHODS LECTURE NOTES, SPRING 2020 83

where, since P`pamtq ď z ă P´prd1, e1s ¨ ¨ ¨ rdk, eksq,

V ˚ “ÿ

tďD

µ`ptqρ˚ptq

φpamtq,

B˚ “ÿ

d,ePDXEpdiei,djejq“1 pi‰jq

dm“em“1

λpdqλpeq

φprd1, e1s ¨ ¨ ¨ rdk, eksq,

|T ˚| !ÿ

tďDP`ptqďz

ρ˚ptqÿ

d,ePDXEpdiei,djejq“1 pi‰jq

Epuq.

We use Hypothesis EHpθq to handle the error term T ˚. Note that x :“ 2amN ` bm ą N by hypothesis,and since d, e P D , the moduli satisfy

u ď amtd1 ¨ ¨ ¨ dke1 ¨ ¨ ¨ ek ď amDR2 ď N θ ď xθ

if N is large enough. For each squarefree q “ rd1, e1s ¨ ¨ ¨ rdk, eks, there are ď p3kqωpqq ways to choosed1, e1, . . . , dk, ek. Also, ρ˚ptq ď kωptq. Thus, by Cauchy-Schwarz and the trivial boundEpuq ! 2amN`|bm|

u ,

|T ˚| !ÿ

tďDP`ptqďz

µ2ptqkωptqÿ

P´pqqązqďR2

µ2pqqp3kqωpqqEpamtqq

ďÿ

rďDR2

µ2prqp3kqωprqEpamrq

! pN ` |bm|q12

ˆ

ÿ

P`prqďN

µ2prqp3kq2ωprq

r

˙12ˆÿ

rďDR2

Epamrq

˙12

! pN log100Nq12plogNq9k22

ˆ

2amN ` bm

plogNq1000k2

˙12

.

Invoking the bounds on am and bm, we conclude that

(7.31) T ˚ !N

plogNq100k2.

As in the proof of Proposition 7.8, we havemź

i“1

rdi, eis

φprdi, eisq“ 1`O

ˆ

logN

z

˙

.

Hence, by the argument in (7.19),

B˚ “ O

ˆ

log2N

z

˙

`ÿ

d,ePDXEpdiei,djejq“1 pi‰jq

dm“em“1

λpdqλpeq

rd1, e1s ¨ ¨ ¨ rdk, eks.

As in the proof of Proposition 7.8, the “missing terms”, those with d P D , e P D and with eitherpdiei, djejq ą 1, d P E , or e P E , have total Op logN

z q. Using (7.22) and (7.23) again, we get

(7.32) B˚ “ O

ˆ

log2N

z

˙

`ÿ

rPD

ζmprq2

r1 ¨ ¨ ¨ rk.

84 KEVIN FORD

Finally, apply the Fundamental Lemma of the sieve (Theorem 2.19) with the function

gptq “ρ˚ptqφpamq

φpamtq,

where, by (7.29), for primes p we have

gppq “

$

&

%

ρ˚ppqp “

ρppqp if p|am,

ρ˚ppqp´1 “

ρppq´1p´1 if p - am.

Again, gppq ď 2kp for all p, thus (Ω) holds with κ “ 2k. Then, by Theorem 2.19,

V ˚ “1

φpamq

´

1`Ope´12s log sq

¯

ź

pďz

p1´ gppqq “

ˆ

1`O

ˆ

1

plogNq100k2

˙˙

V ˚˚,

where, using (7.29),

V ˚˚ “1

φpamq

ź

p|am

ˆ

1´ρppq

p

˙

ź

pďzp-am

ˆ

1´ρppq ´ 1

p´ 1

˙

“V

φpamq

ź

pďz

ˆ

1´1

p

˙´1ź

p|am

ˆ

1´1

p

˙

“V

am

ź

pďz

ˆ

1´1

p

˙´1

.

Therefore,

(7.33) V ˚ “V

am

ź

pďz

p

p´ 1`O

ˆ

1

plogNq90k2

˙

.

The same argument leading to (7.19) yields B˚ ! logN . Combining (7.30) with (7.31), (7.32) and (7.33)yields the claimed asymptotic.

Next, we prove two relatively easy inversion formulas.

Lemma 7.10. For all r P D and 1 ď m ď k,

ζmprq “ 1rm“1

ÿ

bPN

µpbqξpr1, . . . , rm´1, b, rm`1, . . . , rkq

b.

Proof. Let rm “ 1. By (7.14), the right side equals

“ÿ

b

µpbq

b

ÿ

d

λpr1d1, . . . , rm´1dm´1, dmb, rm`1dm`1, . . .q

d1 ¨ ¨ ¨ dk

“ÿ

di:i‰m

i‰m di

ÿ

`PN

λpr1d1, . . . , rm´1dm´1, `, rm`1dm`1, . . .q

`

ÿ

b|`

µpbq “ ζmprq.

Lemma 7.11. For all d,

λpdq “ 1dPD

ÿ

b

µpb1q ¨ ¨ ¨µpbkqξpb1d1, . . . , bkdkq

b1 ¨ ¨ ¨ bk.

SIEVE METHODS LECTURE NOTES, SPRING 2020 85

Proof. Let d P D . By (7.14), the right side is

“ÿ

b

µpb1q ¨ ¨ ¨µpbkq

b1 ¨ ¨ ¨ bk

ÿ

e

λpb1d1e1, . . . , bkdkekq

e1 ¨ ¨ ¨ ek

“ÿ

l

λpl1d1, . . . , lkdkq

l1 ¨ ¨ ¨ lk

i“1

ÿ

bi|li

µpbiq “ λpdq.

Now we describe how we will construct the functions ξpq and λpq. Let Fk denote the set of functionsF pxq that are continuously differentiable, symmetric and supported on the set

(7.34) Rk “ tx P r0, 1sk : x1 ` ¨ ¨ ¨ ` xk ď 1u,

and such that

(7.35) |F pxq| ď 1 px P Rkq,

and F is not identically zero on Rk. For such an F , we then take

(7.36) ξprq “ 1rPDµpr1q ¨ ¨ ¨µprkqź

zăpďR

p1` kpq´1

loooooooooomoooooooooon

constant

F

ˆ

log r1

logR, . . . ,

log rklogR

˙

.

In this way, by Lemma 7.11, for any d P D we haveˇ

ˇ

ˇλpdq

ź

zăpďR

p1` kpqˇ

ˇ

ˇď

ÿ

bPD

1

b1 ¨ ¨ ¨ bkď

ÿ

P´p`qązP`p`qďR

µ2p`qkωp`q

`“

ź

zăpďR

p1` kpq,

that is, |λpdq| ď 1 for all d P D , as required by (7.35).We next insert the definition (7.36) into Propositions 7.8 and 7.9, thus relating the sums in question to

integrals over F . We first need some general tools, first relating a sum over a 1-variable function to anintegral, and using it to handle multivariate functions.

Lemma 7.12. Suppose g P C1ra, bs, 0 ď a ă b ď 1, with |gptq| ď 1 and |g1ptq| ď logR throughout ra, bs.Suppose that e

?logR ď z ď R and write R “ zu. Then

ÿ

RaănďRb

P´pnqąz

1

ng

ˆ

log n

logR

˙

“ e´γlogR

log z

ˆż b

agptq dt`O

ˆ

log u

u

˙˙

.

Proof. Let δ “ log uu and a1 “ maxpδ, aq. We separate the sum into two parts:

S1 “ÿ

RaănďRa1

P´pnqąz

1

ng

ˆ

log n

logR

˙

, S2 “ÿ

Ra1ănďRb

P´pnqąz

1

ng

ˆ

log n

logR

˙

,

If δ ă a then S1 “ 0, otherwise we have the crude bound

|S1| ďÿ

P`pnqďRδ

P´pnqąz

1

n!

logRδ

log z“ δ

logR

log z.

86 KEVIN FORD

We use partial summation on S2, first writing

S2 :“ÿ

Ra1ănďRb

P´pnqąz

1

ng

ˆ

log n

logR

˙

ż Rb

Ra1

1

tg

ˆ

log t

logR

˙

dΦpt, zq.

By Hypothesis, log tlog z ď

?log t for t ď R. Hence, by Theorem 2.20 (iii),

Φpt, zq “e´γt

log z` Eptq, Eptq “ O

ˆ

t

euδ log z

˙

.

Therefore,

S2 “e´γ

log z

ż Rb

Ra1g

ˆ

log t

logR

˙

dt

t`Eptqgp log t

logRq

t

ˇ

ˇ

ˇ

ˇ

ˇ

Rb

Ra1

´

ż Rb

Ra1Eptq

g1p log tlogRq

t2 logR´gp log t

logRq

t2

dt

“e´γ logR

log z

ż b

a1gpyq dy `O

ˆ

logR

euδ log z

˙

.

Recalling that δ “ log uu and our bound on S1, the lemma follows; if δ ă a then S “ S2 and otherwise we

use thatşa1

a |g| ďşδ0 1 “ δ.

Lemma 7.13. Suppose that f P C1pRkq, |fpxq| ď 1 on Rk, and

maxxPRk

maxi

ˇ

ˇ

ˇ

ˇ

Bf

Bxipxq

ˇ

ˇ

ˇ

ˇ

ď logR.

Let R “ zu, where 3 ď u ď?

logR. then

ÿ

P´pn1¨¨¨nkqązµ2pn1¨¨¨nrq“1

fp logn1

logR , . . . ,lognklogR q

n1 ¨ ¨ ¨nk“

ˆ

e´γlogR

log z

˙k„ ż

Rk

f `Ok

ˆ

log u

u

˙

.

Proof. We first insert “missing” summands corresponding to µ2pn1 ¨ ¨ ¨nkq “ 0. These have total at most

ÿ

P´pn1¨¨¨nkqązµ2pn1¨¨¨nkq“0

1

n1 ¨ ¨ ¨nkď k2

ÿ

pąz

1

p2

ˆ

ÿ

P´pmqązmďR

1

m

˙k

!k1

z

ˆ

logR

log z

˙k

,

which is tiny. Repeated application of Lemma 7.12 (each time with a “ 0) shows that

ÿ

P´pn1¨¨¨nkqąz

fp logn1

logR , . . . ,lognklogR q

n1 ¨ ¨ ¨nk“

ˆ

e´γ logR

log z

˙k „ ż

Rk

f `Ok

ˆ

log u

u

˙

,

which implies the desired conclusion.

Proposition 7.14. Let F P Fk. Define ξ by (7.36).(i) Under the hypotheses of Proposition 7.8, we have

ÿ

Nănď2N

wpnq „ V N

ˆ

e´γlog z

logR

˙k

IpF q pN Ñ8q,

SIEVE METHODS LECTURE NOTES, SPRING 2020 87

where

(7.37) IpF q “

ż

Rk

F 2pxq dx.

(ii) Under the hypotheses of Proposition 7.9, we have

ÿ

Nănď2N

kÿ

m“1

wpnq1amn`bm prime „ V N

ˆ

e´γlog z

logR

˙k kθ

2JpF q pN Ñ8q,

where

(7.38) JpF q “

ż

¨ ¨ ¨

ż

x2,...,xk

ˆż

F pxq dx1

˙2

dx2 ¨ ¨ ¨ dxn.

Proof. From the definitions (7.7), we have R “ zu, where

u “ s2

ˆ

θ

1

s

˙

— s2.

(i) From Proposition 7.8, the definition (7.36) of ξ and Lemma 7.13, we haveÿ

Nănď2N

wpnq “ σ2V N

ˆ

e´γlogR

log z

˙k

IpF q

ˆ

1`O

ˆ

log s

s2

˙˙

`O

ˆ

N

plogNq99k

˙

,

where

σ “ź

zăpďR

p1` kpq´1 „

ˆ

log z

logR

˙k

.

The final error term is negligible since

V σ2 ěź

pď2k

ˆ

1´p´ 1

p

˙

ź

2kăpďR

ˆ

1´k

p

˙3

"k1

plogNq3k.

(ii) From the symmetry of F , we see that ζmprq is independent of m. By Lemma 7.10,

ÿ

r

ζ21 prq

r1 ¨ ¨ ¨ rk“ σ2

ÿ

r2,...,rk

1

r2 ¨ ¨ ¨ rk

˜

ÿ

r1

1

r1F

ˆ

log r1

logR, . . . ,

log rklogR

˙

¸2

.

For each i set xi “ log rilogR . With x2, . . . , xk fixed we have 0 ď x1 ď 1´ px2 ` ¨ ¨ ¨ ` xkq.

By Lemma 7.12, the sum on r1 is equal to

e´γlogR

log z

„ż 1´x2´¨¨¨´xk

0F pxq dx1

looooooooooooomooooooooooooon

fpx2,...,xkq

`OF

ˆ

log s

s2

˙

, xi “log rilogR

p2 ď i ď kq.

Lemma 7.13 then implies thatÿ

r

ζ21 prq

r1 ¨ ¨ ¨ rk„ σ2

ˆ

e´γlogR

log z

˙k`1

JpF q.

Recalling Proposition 7.9, we havekÿ

m“1

ÿ

Nănď2N

wpnq1amn`bm prime „kV N logN

ś

pďzp1´ 1pq

ÿ

rPD

ζ1prq2

r1 ¨ ¨ ¨ rk.

88 KEVIN FORD

Nowś

pďzp1´ 1pq „ e´γ log z by Mertens, and logRlogN „

θ2 , and the desired asymptotic follows.

Armed with Proposition 7.14, we can now apply these results to prime gaps and prime k-tuples.

Theorem 7.15. Fix k P N and m P N, and assume Hypothesis EHpθq. There is a constant ck such that thefollowing holds. Suppose that there is a function F P Fk and such that

MkpF q :“kJpF q

IpF qą

2pm´ 1q

θ,

where IpF q, JpF q are defined in (7.37) and (7.38), respectively. Then, for all sufficiently large N , and alladmissible tuples pa1n` b1, . . . , akn` bkq of linear forms, with

1 ď ai ď log100N, ´aiN2 ă bi ď N log100N p1 ď i ď kq,

there are " NplogNqck integers n P pN, 2N s for which at least m of the numbers a1n` b1, . . . , akn` bkare prime.

In particular, unconditionally the conclusion holds provided that MkpF q ą 4pm´ 1q.

Proof. Let

S “ÿ

Nănď2N

vpnqwpnq, vpnq :“kÿ

j“1

1ajn`bj prime ´ pm´ 1q.

By the two parts of Proposition 7.14, we have

S „ V N

ˆ

e´γlog z

logR

˙k „kJpF qθ

2´ pm´ 1qIpF q

.

By hypothesis, the bracketed expression is positive. From (7.11) we have

V ěź

pďz

ˆ

1´minpk, p´ 1q

p

˙

" plog zq´k,

and thus

S1 :“ÿ

Nănď2Nvpnqě1

wpnq ěÿ

Nănď2N

vpnqwpnq

k“S

k"

N

plogNqk.

It follows that there are many values of n with vpnq ą 0. More precisely, by Cauchy-Schwarz,

pS1q2 ď #tN ă n ď 2N : vpnq ě 1u

ˆ

ÿ

Nănď2N

wpnq2˙

.

Thus,

(7.39) #tN ă n ď 2N : vpnq ě 1u "N2

plogNq2k

ˆ

ÿ

Nănď2N

wpnq2˙´1

By (7.12),

0 ď wpnq ďkź

j“1

τpain` biq3.

SIEVE METHODS LECTURE NOTES, SPRING 2020 89

Hence, by Holder’s inequality and the bound ain` bi ď 3NplogNq100,

ÿ

Nănď2N

wpnq2 ďÿ

Nănď2N

j“1

τpain` biq6

ď

j“1

ˆ

ÿ

Nănď2N

τpajn` bjq6k

˙1k

ďÿ

dď3NplogNq100

τ6kpdq

! NplogNq100`26k´1.

Combined with (7.39), this completes the proof of the first claim, with ck “ 2k ` 100` 26k ´ 1.The final statement follows from the Bombieri-Vinogradov Theorem, which implies Hypothesis EHpθq

for all θ ă 12.

7.4. Bounds on MkpF q.

Definition 6. Let

Mk :“ supFPFk

MkpF q “ supFPFk

kJpF q

IpF q.

We begin with a simple upper bound for Mk from [109].

Theorem 7.16 ([109]). We have Mk ďkk´1 log k “ log k `Op log k

k q.

Proof. Let x2, . . . , xk be given and set y “ 1´ px2 ` ¨ ¨ ¨ ` xkq. The integral over those x with y “ 0 hasmeasure zero and can be discarded. Thus, we may assume that y ą 0. For any A ą 0, by Cauchy-Schwarzwe have

ˆż y

0F pxq dx1

˙2

ď

ż y

0p1`Ax1qF pxq

2 dx1

ż y

0

dx1

1`Ax1

“logp1`Ayq

A

ż y

0p1`Ax1qF pxq

2 dx1.

Put A “ By for some constant B to be determined, then integrate over x2, . . . , xk. We get

JpF q ďlogp1`Bq

B

ż

Rk

p1´ x2 ´ ¨ ¨ ¨ ´ xk `Bx1qF pxq2 dx.

Since F pxq is symmetric, we may interchange x1 and xi. Doing this for each i and summing gives

kJpF q ďlogp1`Bq

B

ż

Rk

pk ´ pk ´ 1qÿ

xi `Bÿ

xiqF pxq2 dx.

Taking B “ k ´ 1, the integral above equals kIpF q and this completes the proof.

Theorem 7.17. We have

Mk ě log k ´ log2 k ´Op1q.

90 KEVIN FORD

Proof. Let δ ą 0, and let g : r0, δs Ñ r0,8q be a function with |gptq| ď 1 for all t. We’ll specialize tofunctions of the type

F pxq “ gpx1q ¨ ¨ ¨ gpxkq.

For short, let

m1 “

ż δ

0gptq dt, m2 “

ż δ

0g2ptq dt.

We interpret IpF q and JpF q probabilistically. Let Z1, . . . , Zk be independent random variables with densityfunction 1

m2g2ptq, 0 ď t ď δ. Then

IpF q “

ż

Rk

g2px1q ¨ ¨ ¨ g2pxkq dx “ mk

2 PpZ1 ` ¨ ¨ ¨ ` Zk ď 1q.

Also,

JpF q ě

ż

¨ ¨ ¨

ż

x2`¨¨¨`xkď1´δ

g2px2q ¨ ¨ ¨ g2pxkq

ˆż δ

0gpx1q dx1

˙2

dx2 ¨ ¨ ¨ dxk

“ m21m

k´12 PpZ2 ` ¨ ¨ ¨ ` Zk ď 1´ δq.

Thus,

(7.40) MkpF q ěkm2

1

m2¨PpZ2 ` ¨ ¨ ¨ ` Zk ď 1´ δq

PpZ1 ` ¨ ¨ ¨ ` Zk ď 1qěkm2

1

m2PpZ2 ` ¨ ¨ ¨ ` Zk ď 1´ δq.

We will choose g so that the probability on the RHS is about 1. If

µ :“ EZi “1

m2

ż δ

0tg2ptq dt,

then we want

(7.41) µ ă1´ δ

k ´ 1

so thatEpZ2 ` ¨ ¨ ¨ ` Zkq “ pk ´ 1qµ ă 1´ δ.

We can bound the probability of a large deviation from the mean using Chebyshev’s inequality and thecalculated variance

σ2 :“ EpZi ´ µq2 “ EZ2i ´ µ

2 “1

m2

ż δ

0t2g2ptq dt´ µ2.

ThenEpZ2 ` ¨ ¨ ¨ ` Zk ´ pk ´ 1qµq2 “ pk ´ 1qσ2.

Thus, under the assumption of (7.41), we have

P pZ2 ` ¨ ¨ ¨ ` Zk ě 1´ δq ď P p|Z2 ` ¨ ¨ ¨ ` Zk ´ pk ´ 1qµ| ě 1´ δ ´ pk ´ 1qµq

ďpk ´ 1qσ2

p1´ δ ´ pk ´ 1qµqq2.

(7.42)

We will choose parameters so that the right side of (7.42) is very small.

SIEVE METHODS LECTURE NOTES, SPRING 2020 91

It then remains to maximize m21m2 subject to µ À 1k. Motivated by the proof of Theorem 7.16, for

any A ą 0 we have

m21 ď

ˆż δ

0p1`Atqg2ptq dt

˙ˆż δ

0

dt

1`At

˙

“ pm2 `Am2µqlogp1`Aδq

A.

Moreover, equality holds only for gptq “ 11`At . That is,

(7.43)m2

1

m2ď min

Aą0

ˆ

1

A` µ

˙

logp1`Aδq.

The minimum occurs whenˆ

1

A` µ

˙

δ

1`Aδ“

logp1`Aδq

A2,

and then taking gptq “ 11`At gives equality in (7.43). With this function gptq and assuming that Aδ is large,

we compute

m1 “logp1`Aδq

A, m2 “

δ

1`Aδ«

1

A,

and

µ “1

m2A2

ˆ

logp1`Aδq ´ 1`1

1`Aδ

˙

«logp1`Aδq

A.

We will take a convenient choice of A, δ satisfying the simpler relation

(7.44) A “ k logp1`Aδq.

Then

µ “1

1

A`

1

kAδand

m21

m2“

1

k2

ˆ

A`1

δ

˙

ąA

k2.

Thus, by (7.40) and (7.42),

(7.45) MkpF q ěA

k

ˆ

1´pk ´ 1qσ2

p1´ δ ´ pk ´ 1qµq2

˙

.

Crudely,

σ2 ď EZ2i ď

1

m2

ˆ

1`Aδ

˙2 ż δ

0

t2 dt

pAtq2“

δ2

1`Aδăδ

A.

Also, using (7.44), we compute (after some algebra)

1´ δ ´ pk ´ 1qµ “ pk ´ eAkq

ˆ

1

1

kpeAk ´ 1q

˙

.

In particular, for this to be positive, we need A ă k log k. Combined with (7.45), we conclude that

MkpF q ěA

k

˜

1´pk ´ 1qpeAk ´ 1q

pk ´ eAkq2p1´ AkpeAk´1q

q2

¸

.

A good choice for A isA “ kplog k ´ log2 kq.

92 KEVIN FORD

(this gives δ „ 1log2 k

). Then eAk “ k log k and we see that

Mk ě plog k ´ log2 kq

ˆ

1´O

ˆ

1

log k

˙˙

“ log k ´ log2 k `Op1q,

as required.

Together with Theorem 7.15, Theorem 7.17 immediately implies Theorem 7.6. To obtain the claimedbounds on Km, notice that by Theorem 7.17 there is a k ! me4m with Mk ą 4pm´ 1q.

The PolyMath8b project provides better bounds on Mk, as well as numerical bounds when k is small.Theorem [109, Theorem 3.9 (vii), (xi)]. We have

(i) M54 ą 4;(ii) Mk “ log k ´Op1q.

Also, Maynard [97] proved that

(7.46) M5 ą 2.

Consequently, assuming the Elliott-Halberstam conjecture, or any admissible 5-tuple, infinitely often at leasttwo of the forms are prime.

7.5. Consecutive integers with large prime factors. One special case of the prime k-tuples conjecture,Conjecture 1.3 states that for infinitely many primes p, p` 1 “ 2q for a prime q. In this direction, we prove

Theorem 7.18 (K. Ford and J. Maynard, 2014; unpublished). There is a constant B so that for infinitelymany n P N, P`pnq ě nB and P`pn` 1q ě pn` 1qB.

Lemma 7.19 (Heath-Brown [79]). For any k there is a set of k positive integers a1, . . . , ak such that

(7.47) ai ´ aj “ pai, ajq pi ą jq.

Examples are

k “ 4 : t6, 8, 9, 12u

k “ 5 : t60, 63, 64, 66, 72u.

The condition (7.47) is equivalent to pai´ ajq|ai for all i ‰ j. Thus, Lemma 7.19 is one of the assertions inLemma 1 of Heath-Brown [79]. As we do not require the other properties of the ai from [79], our proof ismuch shorter.

Proof. By induction. If ta1, . . . , aku satisfies (7.47), then so does the k ` 1 element set

tM,M ´ a1, . . . ,M ´ aku, M “ a1 ¨ ¨ ¨ akź

iăj

|ai ´ aj |.

Proof of Theorem 7.18. By Theorem 7.17, for some k we have Mk ą 4. Thus, by Theorem 7.6, in any setof k admissible linear forms, two are prime infinitely often. Let a1, . . . , ak satisfy (7.47), which exist byLemma 7.19. The set of forms a1n` 1, . . . , akn` 1 is admissible since for any prime p,

ś

pain` 1q ı 0

pmod pq when p|n. By Theorem 7.6, for some pair i ă j, infinitely often ain ` 1 and ajn ` 1 are prime.By (7.47), aj ´ ai “ pai, ajq and hence

ajpai, ajq

pain` 1q andai

pai, ajqpajn` 1q

SIEVE METHODS LECTURE NOTES, SPRING 2020 93

are consecutive integers. Thus the theorem follows with

B “ maxi‰j

aipai, ajq

.

7.6. Locally repeated values of Euler’s function. We partially solve a longstanding conjecture about thesolubility of

(7.48) φpn` kq “ φpnq,

where φ is Euler’s function and k is a fixed positive integer.Hypothesis Sk. The equation (7.48) holds for infinitely many n.

Erdos conjectured in 1945 that for any m, the simultaneous equations

(7.49) φpnq “ φpn` 1q “ ¨ ¨ ¨ “ φpn`m´ 1q

has infinitely many solutions n. If true, this would immediately imply hypothesis Sk for every k. However,there is only one solution of (7.49) known whenm ě 3, namely n “ 5186,m “ 3. In 1956, Sierpinski [125]showed that for any k, (7.48) has at least one solution n (e.g. take n “ pp ´ 1qk, where p is the smallestprime not dividing k). This was extended by Schinzel [117] and by Schinzel and Wakulicz [120], whoshowed that for any k ď 2 ¨ 1058 there are at least two solutions of (7.48). In 1958, Schinzel [117] explicitlyconjectured that Sk is true for every k P N. There is good numerical evidence for Sk, at least when k “ 1

or k is even [63]. Information about solutions for k P t1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12u can also be found inOEIS [104] sequences A001274, A001494, A330251, A179186, A179187, A179188, A179189, A179202,A330429, A276503, A276504 and A217139, respectively. Below 1011 there are very few solutions of (7.48)when k ” 3 pmod 6q [63], e.g. only the two solutions n P t3, 5u for k “ 3 are known. A further search byG. Resta (see [104], sequence A330251) reveals 17 more solutions in r1012, 1015s.

There is a close connection between Hypothesis Sk for even k and generalized prime twins.

Hypothesis Ppa, bq: there are infinitely many n P N such that both an` 1 an bn` 1 are prime.

Hypothesis Ppa, bq is a special case of the Prime k-tuples conjecture, Conjecture 1.3. Schinzel [117]observed that Hypothesis Pp1, 2q implies Sk for every even k. The proof is simple: if n` 1 and 2n` 1 areprime and larger than k, then

φpkp2n` 1qq “ φppn` 1q2kq “ 2nφpkq.

Graham, Holt and Pomerance [63] generalized this idea, showing the following.

Lemma 7.20 ([63, Theorem 1]). For any k and any number j such that j and j ` k have the same primefactors, Hypothesis Pp

jpj,j`kq ,

j`kpj,j`kqq implies Sk.

This also has an easy proof: if jpj,j`kqr ` 1 and j`k

pj,j`kqr ` 1 are both prime, then n “ jp j`kpj,j`kqr ` 1q

satisfies (7.48). Note that for odd k there are no such numbers j, and for each even k there are finitelymany such j (see [63], Section 3). Extending a bound of Erdos, Pomerance and Sarkozy [44] in the casek “ 1, Graham, Holt and Pomerance showed that the solutions of (7.48) not generated from Lemma 7.20are very rare, with counting function Okpx expt´plog xq13uq. Yamada [134] sharpened this bound toOkpx expt´p1

?2` op1qq

?log x log log log xuq. Assuming the Hardy-Littlewood conjectures [72], when

k is even we conclude that there are „ Ckx log2 x solutions n ď x of (7.48), where Ck ą 0.Using the fact that K2 “ 50 is admissible in Theorem 2.5, we will prove the following.

94 KEVIN FORD

Theorem 7.21 (Ford [48], 2020). We have

(a) For any k that is a multiple of 442720643463713815200, Sk is true;(b) There is some even ` ď 3570 such that Sk is true whenever `|k; consequently, the number of k ď x

for which Sk is true is at least x3570.

Under the assumption of the Elliott-Halberstam Conjecture (Conjecture 7.3), Maynard [97] showed thatK2 ď 5, improving the boundK2 ď 6 proved by Goldston, Pintz and Yıldırım[59] under the same hypothe-sis. A generalized version of the Elliot-Halberstam conjecture (in the notation of [109], this is the statementthat GEHrθs holds for all θ ă 1), implies that K2 ď 3 [109, Theorem 16 (xii)]. Improvements to K2 allowus to improve significantly on Theorem 7.21.

Theorem 7.22 (Ford [48], 2020). If K2 ď 5, then Sk is true for all k with 30|k. If K2 ď 4, then Sk is truefor all k with 6|k. In particular, the Elliot-Halberstam conjecture implies Sk for all k with 30|k, and theGeneralized Elliot-Halberstam conjecture implies Sk for all k with 6|k.

Incidentally, the conclusion of Theorem 7.22 whenK2 ď 4 is not improved if we have the stronger boundK2 ď 3.

Using Theorem 7.6, we also make progress toward Erdos’ conjecture that (7.49) has infinitely manysolutions.

Theorem 7.23 (Ford [48], 2020). For any m ě 3 there is a tuple of distinct positive integers h1, . . . , hm sothat for any ` P N, the simultaneous equations

φpn` `h1q “ φpn` `h2q “ ¨ ¨ ¨ “ φpn` `hmq

have infinitely many solutions n.

Very recently, Sungjin Kim [91] proved weaker statements in the direction of Theorem 7.21. He usedTheorem 2.5 to show that Sk holds for some k P tB, 2B, . . . , 50Bu, with B “

ś

pď50 p. He also provedthat the set of k for which Sk holds has counting function " log log x.

Now we get to the proofs. Throughout, 1 ď a ă b are integers. We first show that Ppa, bq implies Skfor certain k, inverting Lemma 7.20. Define

(7.50) κpa, bq “ pb1 ´ a1qź

p|a1b1

p, a1 “a

pa, bq, b1 “

b

pa, bq.

We observe that κpa, bq is always even.

Lemma 7.24. Assume Ppa, bq. Then Sk holds for every k which is a multiple of κpa, bq.

Proof. Define a1 “ apa,bq , b

1 “ bpa,bq and observe that Ppa, bq ñ Ppa1, b1q. Let s “

ś

p|a1b1 p, and supposethat r ą maxpa1, b1q such that a1r ` 1 and b1r ` 1 are both prime. Let ` P N and set

m1 “ b1`spa1r ` 1q, m2 “ a1`spb1r ` 1q.

As all of the prime factors of a1b1 divide `s, we have φpb1`sq “ b1φp`sq and φpa1`sq “ a1φp`sq, and itfollows than φpm1q “ φpm2q. Finally, m1 ´m2 “ pb

1 ´ a1q`s “ `κpa, bq.

Proof of Theorem 7.21. Let

ta1, . . . , a50u “ t1, 2, 4, 5, 6, . . . , 48, 49, 52, 56u,

SIEVE METHODS LECTURE NOTES, SPRING 2020 95

By Theorem 7.6, for some i, j with 1 ď i ă j ď 50, Ppai, ajq is true. We compute

lcmtκpai, ajq : 1 ď i ă j ď 50u “ 442720643463713815200 “ 253352ź

7ďpď47

p,

and thus (a) follows from Lemma 7.24.For part (b), we take

ta1, . . . , a50u “ t15, 20, 30, 36, 40, 45, 60, 72, 75, 80, 90, 96, 100, 108, 120, 135, 144, 150, 180, 192, 200,

216, 225, 240, 250, 270, 288, 300, 320, 324, 360, 375, 384, 400, 405, 450, 480, 500, 540, 600,

720, 750, 810, 900, 960, 1080, 1200, 1440, 1500, 1800u,

numbers that only have prime factors 2, 3, 5. We also compute that

max1ďiăjď50

κpai, ajq “ 3570,

and again invoke Lemma 7.24. This proves (b).

Remarks. For any choice of a1, . . . , a50, 4427206434637138152006 |Lpaq, where

Lpaq “ lcmtκpai, ajq : i ă ju.

Without loss of generality, assume pa1, . . . , a50q “ 1. For a prime 7 ď p ď 47, if p|ai for some i then p - ajfor some j and thus p|κpai, ajq. If p - ai for all i, by the pigeonhole principle, there are two indices withai ” aj pmod pq. Again, p|κpai, ajq. Thus, p|Lpaq. Now we show that 52|Lpaq. Let Sb “ tai : 5baiu

for b ě 0. Then |S0| ě 1. If |Sb| ě 1 for some b ě 2, then there are i, j with 52|ai and 5 - aj , and then52|κpai, ajq. Otherwise, we have |Sb| ě 21 for some b P t0, 1u. By the pigeonhole principle, there is i ‰ j

with 5bai, 5baj and 5b`2|pai ´ ajq. This also implies that 52|κpai, ajq. Simlarly, let Tb “ tai : 3baiu.

Then we have either |Tb| ě 1 for some b ě 2, or |Ti| ě 7 for some i P t0, 1u. Either way, 32|Lpaq. LetUb “ tai : 2baiu. Then either |Ub| ě 1 for some b ě 4 or |Ub| ě 9 for some b P t0, 1, 2, 3u. Eitherway, 24|Lpaq. It is easy to construct a “ pa1, . . . , a50q such that 33 - Lpaq and 25 - Lpaq. However, suchconstructions seem to always produce q|Lpaq for some prime q ą 50.

We believe that 3570 is the smallest number than can be produced for Theorem 7.21 (b). Using numbersdivisible by 4 or more primes always produces some very large κpa, bq, thus we limited our search to setsof numbers composed only of the primes 2,3,5. For a given finite set of integers tb1, . . . , bru, the problemof minimizing maxi,jPI κpbi, bjq over all 50-element subsets I Ă t1, . . . , ru, is equivalent to that of findingthe largest clique in a graph. Take vertex set t1, . . . , ru and draw an edge from i to j if κpbi, bjq ď t. Usingthe Sage routing clique number() with t “ 3569 and tb1, . . . , bru being the smallest 800 numberscomposed only of primes 2,3,5 (the largest being 12754584), we find that the largest clique has size 49.

Proof of Theorem 7.22. Same as the proof of Theorem 7.21 (a), but take ta1, a2, a3, a4, a5u “ t1, 2, 3, 4, 6u

if K2 ď 5 and ta1, . . . , a4u “ t1, 2, 3, 4u if K2 ď 4.

Proof of Theorem 7.23. Let m ě 2, k “ Km and consider any set ta1, a2, . . . , aku of k positive integers.By Theorem 7.6, there are 1 ď i1 ă i2 ă ¨ ¨ ¨ ă im ď k such that for infinitely many r, the m numbersai1r ` 1, . . . , aimr ` 1 are all prime. Let r be such a number. Define

hj “pai1 ¨ ¨ ¨ aimq

2

aijp1 ď j ď mq.

96 KEVIN FORD

Let ` P N and set n “ `pai1 ¨ ¨ ¨ aimq2r. Then, since aij |hj for all j, it follows that for any j,

φpn` `hjq “ φp`hjpaijr ` 1qq “ φp`hjqaijr “ φp`hjaij qr.

7.7. Locally repeated values of σ. One can ask analogous questions about the sum of divisors functionσpnq. As σppq “ p ` 1 vs φppq “ p ´ 1, oftentimes one can port theorems about φ over to σ. This is notthe case here, since our results depend heavily on the existence of solutions of

aφpbq “ bφpaq,

which is true if and only if a and b have the same set of prime factors. The analogous equation

aσpbq “ bσpaq ôσpaq

a“σpbq

b

has more sporadic solutions, e.g. if a, b are both perfect numbers or multiply perfect numbers.

Theorem 7.25 (Ford [48], 2020). For a positive proportion of all k P N, the equation

σpnq “ σpn` kq

has infinitely many solutions n.

As we shall see from the proof, there is a specific number A and a finite set B such that for some elementb P B, the equation σpnq “ σpn`kq has infinitely many solutions for all numbers k “ `b where p`, Aq “ 1.Unfortunately, our methods cannot specify any particular k for which the conclusion holds. Our methodrequires finding, for t “ K2, numbers a1, . . . , at so that

(7.51)σpa1q

a1“ ¨ ¨ ¨ “

σpatq

at“ y.

Such collections of numbers are sometimes referred to as “friends” in the literature, e.g. [107]. Findinglarger collections of ai satisfying (7.51) leads to stronger conclusions.

Theorem 7.26 (Ford [48], 2020). Let m ě 2, let t “ Km and assume that there is a y and positive integersa1, . . . , at satisfying (7.51). Then there are positive integers h1 ă h2 ă ¨ ¨ ¨ ă hm so that for a positiveproportion of integers `, there are infinitely many solutions of

σpn` `h1q “ ¨ ¨ ¨ “ σpn` `hmq.

It is known [103] that for y “ 9, there is a set of 2095 integers satisfying (7.51). The number y “ 9 hasthe largest known multiplicity of σpnqn. Also K2 ď 50 [109], and hence Theorem 7.25 follows from thecase m “ 2 of Theorem 7.26. We cannot make the conclusion unconditional when m ě 3, since the bestknown bounds for K3 is K3 ď 35410 [109, Theorem 3.2 (ii)].

Conjecture 7.27. For any t, there is an y such that σpaqa “ y has at least t solutions. That is, there arearbitrarily large circles of friends.

Clearly, Conjecture 7.27 implies the conclusion of Theorem 7.26 for all m. In [39], Erdos mentionsConjecture A and states that he doesn’t know of any argument that would lead to its resolution. In theopposite direction, Wirsing [132] showed that the number of n ď z with σpnqn “ y is is Opzc log log zq

for some c, uniformly in y. Pollack and Pomerance [107] studied the solutions of (7.51), gathering data onpairs, triples and quadruples of friends, but did not address Conjecture A.

SIEVE METHODS LECTURE NOTES, SPRING 2020 97

Using (7.51) and prime pairs an´ 1 and bn´ 1, one can generate many solutions of σpnq “ σpn` kq,analogous to Lemma 7.20; see Yamada [134, Theorem 1.1]. For example, one can generate solutions withk “ 1 if there is an integer m with σpmqm “ σpm ` 1qpm ` 1q “ y (the ratios need not be integers asclaimed in [134]). Indeed, if r ą m` 1, and rm´ 1 and rpm` 1q ´ 1 are both prime, then

σpmprpm` 1q ´ 1qq “ σpmqrpm` 1q “ rmpm` 1qy,

σppm` 1qpmr ´ 1qq “ σpm` 1qrm “ rmpm` 1qy.

Yamada [134, Theorem 1.2] showed that there are ! x expt´p1?

2` op1qq?

log x log log log xu solutionsn ď x not generated in this way.

Proof of Theorem 7.26. Let t “ Km and a1, . . . , at satisfy (7.51). Put A “ lcmra1, . . . , ats and for each idefine bi “ Aai. By Theorem 7.6 applied to the collection of linear forms bin ´ 1, 1 ď i ď t, there existi1, . . . , im such that for infinitely many r P N, the m numbers bijr ´ 1 are all prime. Let r ą A be such anumber, and let ` P N such that p`, Aq “ 1 (this holds for a positive proportion of all `). Let

tj “ `aij pbijr ´ 1q “ A`r ´ `aij p1 ď j ď mq.

By (7.51), for every j we have

σptjq “ σp`qσpaij qbijr “ σp`qyaijbijr “ yσp`qAr.

98 KEVIN FORD

8. LARGE GAPS BEWTEEN CONSECUTIVE PRIMES

8.1. Introduction. Let pn denote the nth prime, and let

GpXq :“ maxpn`1ďX

ppn`1 ´ pnq

denote the the maximum gap between consecutive primes less than X . It is clear from the prime numbertheorem that

GpXq ě p1` op1qq logX,

as the average gap between the prime numbers which are ď X is „ logX . Explicit gaps of (at least) thissize may be constructed by observing that P pnq`2, P pnq`3, . . . , P pnq`n is a sequence of n´1 compositenumbers, where P pnq is the product of the primes ď n; by the prime number theorem, P pnq “ ep1`op1qqn.

In 1931, Westzynthius [131] proved that infinitely often the gap between consecutive prime numbers canbe an arbitrarily large multiple of the average gap. His bound is6

GpXq "logX log3X

log4X.

In 1934, Ricci [114] slightly improved this to GpXq " logX log3X. In 1935 Erdos [32] made a muchlarger improvement, showing

GpXq "logX log2X

plog3Xq2

and in 1938 Rankin [112] added a quadruple-log, showing

(8.1) GpXq ě pc` op1qqlogX log2X log4X

plog3Xq2

with c “ 13 . The constant c was increased several times [122, 113, 96, 106], ultimately getting to c “ 2eγ

by Pintz [106].It was a well-known open problem (and Erdos prize problem) to show that one could take c Ñ 8. In

August 2014, in two independent papers of Ford-Green-Konyagin-Tao [49] and Maynard [99], it was shownthat c could be taken to be arbitrarily large. The methods of proof in [49] and [99] are quite different. Thearguments in [49] used recent results [66] on the number of solutions to linear equations in primes, whereasthe arguments in [99] instead relied on a multidimensional prime-detecting sieve of the type introducedin [99] (but more complicated). Later, in [50], a quantitative improvement to Rankin’s bound was given,namely

Theorem 8.1 (Ford-Green-Konyagin-Maynard-Tao [50, Theorem 1]). For sufficiently large X , one has

GpXq "logX log2X log4X

log3X.

Here we present a proof of the original theorem from [49] and [99] that the c in (8.1) may be takenarbitrarily large (without a specific rate of growth), which is much simpler than that in either of the twooriginal papers. It is based on a hybrid approach, utilizing ideas worked out in [50], but without the need tomake various estimates quantitative.

Theorem 8.2. The bound (8.1) holds for any real number c ą 0, if x is large enough, depending on c.

6Recall that log2 x “ log log x, log3 x “ log log log x, and so on.

SIEVE METHODS LECTURE NOTES, SPRING 2020 99

FIGURE 1. Gpxq vs. various approximations

Based on a probabilistic model of primes, Cramer [24] conjectured that

lim supXÑ8

GpXq

log2X“ 1.

Granville [64] offered a refinement of Cramer’s model and has conjectured that the lim sup above is in fact atleast 2e´γ “ 1.1229 . . .. Recently, Banks, Ford and Tao [9] made a specific conjecture about the largest gapwhich is dependent on a problem called the interval sieve. These conjectures are well beyond the reach of ourmethods. Numerical evidence is inconclusive, in fact maxXď4¨1018 GpXq log2X « 0.9206, slightly belowthe predictions of Cramer and Granville. This bound is a consequence of the gap of size 1132 following theprime 1693182318746371. See also Figure 1 for a plot of Gpxq versus various approximations.

Unconditional upper bounds for GpXq are far from the conjectured truth, the best being GpXq ! X0.525

and due to Baker, Harman and Pintz [8]. Even the Riemann Hypothesis only7 furnishes the bound GpXq !X12 logX [23].

8.1.1. Notational conventions. Our arguments will rely heavily on probabilistic arguments using discreterandom variables. We will use boldface symbols such as X or a to denote random variables (and non-boldface symbols such as X or a to denote deterministic counterparts of these variables). Vector-valuedrandom variables will be denoted in arrowed boldface, e.g. ~a “ pasqsPS might denote a random tuple ofrandom variables as indexed by some index set S. The letters p and q will always denote primes.

7Some slight improvements are available if one also assumes some form of the pair correlation conjecture; see [78].

100 KEVIN FORD

8.2. Overall plan of the proof. We construct many consecutive integers in pX2, Xs, each of which has a“very small” prime factor. By the Chinese Remainder Theorem, this is equivalent to sieving out an intervalby progressions to small primes.

Definition 7 (Jacobsthal’s function). Let x be a positive integer. Define Y pxq to be the largest gap in theintegers with no prime factor ď x. Equivalently, Y pxq is the largest integer y for which one may selectresidue classes ap mod p, one for each prime p ď x, which together “sieve out” (cover) a whole intervalof the form t1, 2, . . . , yu.

The equivalence of the two definitions of Y pxq is easy by the Chinese remainder theorem. One conse-quence is that pP pxq, 2P pxqs contains Y pxq consecutive numbers that have a prime factor ď x, and thusthese numbers are all composite. We conclude that

(8.2) Gp2P pxqq ě Y pxq.

Since logP pxq „ x by the Prime Number Theorem, this essentially says that

GpXq Á Y plogXq.

All known lower bounds in GpXq are based on lower bounds for Y pxq.Fix a large, positive real number c, let x be a large integer and define

(8.3) y :“

Z

cxlog x log3 x

plog2 xq2

^

,

Also let

(8.4) z :“ xlog3 xp5 log2 xq,

and introduce the three disjoint sets of primes

S :“ ts prime : log20 x ă s ď zu,

P :“ tp prime : x2 ă p ď xu,

Q :“ tq prime : x ă q ď yu.

We will show that Y pxq ě y ´ x by covering px, ys with residue classes modulo primes ď x. NowP pxq “ ep1`op1qx by the prime number theorem, so (8.2) and (8.3) imply that

Gpep1`op1qxq ě p1` op1qqcx log xlog3 x

plog2 xq2.

AS G is monotone, Theorem 8.2 follows upon taking c arbitrarily large.We first reduce the problem to finding residue classes modulo the primes in S Y P which cover most of

the primes in Q. For residue classes ~a “ pas mod sqsPS and~b “ pbp mod pqpPP , define the sifted sets

Sp~aq :“ tn P Z : n ı as pmod sq for all s P Su

and likewiseT p~bq :“ tn P Z : n ı bp pmod pq for all p P Pu.

Theorem 8.3 (Sieving primes). Let c ą 0 be arbitrary, let x be sufficiently large and suppose that y obeys(8.3). Then there are vectors ~a “ pas mod sqsPS and~b “ pbp mod pqpPP , such that

(8.5) #pQX Sp~aq X T p~bqq ď x

5 log x.

SIEVE METHODS LECTURE NOTES, SPRING 2020 101

Proof the Theorem 8.3 implies Theorem 8.2. We will first take

ap “ 0 pp ď log20 x, z ă p ď x4q.

This is a “big gun” and eliminates all numbers from px, ys except primes and a negligible set of z-smoothnumbers. It dates from work of Westzynthius [131], Erdos [32] and Rankin [112]. Let ~a and ~b be as inTheorem 8.3, and consider the sifted set

U :“ px, ys X Sp~aq X T p~bq X V,

whereV “ tn P Z : n ı 0 pmod pq for all p ď log20 x and z ă p ď x4u.

The elements of U , by construction, are not divisible by any prime in p0, log20 xs Y pz, x4s. Thus, eachelement must either be a z-smooth number (i.e., a number with all prime factors at most z), or must consistof a prime greater than x4, possibly multiplied by some additional primes that are all at least log20 x.However, from (8.3) we know that y “ opx log xq. Thus, we see that an element of U is either a z-smoothnumber or a prime in px4, ys. In the second case, the element lies in QX Sp~aq X T p~bq. Conversely, everyelement of QX Sp~aq X T p~bq lies in U . Thus, U only differs from QX Sp~aq X T p~bq by a set R consisting ofz-smooth numbers in r1, ys. Let u :“ log y

log z „ 5 log2 xlog3 x

. By Theorem 4.1 and (8.3),

(8.6) #R ď Ψpy, zq !y

plog xq5`op1q!

x

log2 x.

Thus, we find that

#U ď p1` op1qq x

5 log x.

By matching each of these surviving elements to a distinct prime in px4, x2s and choosing congruenceclasses appropriately, we thus find congruence classes ap mod p for p ď x which cover all of the integersin px, ys. This proves Y pxq ě y ´ x “ p1´ op1qqy, and hence Theorem 8.2.

8.2.1. The Westzynthius-Erdos-Rankin argument giving (8.1) for some c ą 0. It is very easy to show that(8.5) holds for some value of c ą 0. Indeed, by the pigeonhole principle, for any finite set R and prime pthere is a residue class ap so that |R X pap mod pq| ě |R|p. Consequently, there are chocies of as fors P S and bp for p P P such that

QX Sp~aq X T p~bq¯

ď |Q|ź

sPS

ˆ

1´1

s

˙

ź

pPP

ˆ

1´1

p

˙

! |Q| log2 x

log z

!yplog2 xq

2

plog xq2 log3 xď

cx

log x.

Hence, if c is small enough, then (8.5) holds.

8.2.2. Improving the Westzynthius-Erdos-Rankin method. We argue in two stages:

Stage 1. For each prime s P S, we select each as mod s uniformly at random from ZsZ, independentlyfor each s. Let ~a :“ pas mod sqsPS ;

102 KEVIN FORD

Stage 2. For each prime p P P , we select the residue class bp mod p also at random, but in a strategic waywhich is dependent on the choice of ~a; this is done in such a way so that each bp mod p coversmany primes in Q left uncovered by Stage 1.

What we gain in Stage 1 is only what is typical for residue classes for these primes, but the random choicewill be advantagoeus for Stage 2, which is much more complicated. Greatly improving upon arguments fromMaier and Pomerance [96] and Pintz [106], we show in Stage 2 that for any fixed r, there are residue classesbp mod p for p P P which cover an average of at least r numbers left uncovered by Stage 1.

8.3. Concentration of Sp~aq. The sifted set Sp~aq is a random periodic subset of Z, each element survivingwith probability

σ :“ź

sPS

ˆ

1´1

s

˙

“ź

log20 xăsďz

ˆ

1´1

s

˙

.

From Mertens’ bound and (8.4),

(8.7) σ „logplog20 xq

log z“

100plog2 xq2

log x log3 x.

In particular, we have

(8.8) E#pQX Sp~aqq “ÿ

qPQPpq P Sp~aqq “ σ#Q „ 100c

x

log x.

We now show that QX Sp~aq is concentrated about its mean. To accomplish this, we first show that for anyreasonably sized integers n1, . . . , nt, the events ni P Sp~aq are close to being independent.

Lemma 8.4. Let t ď log x, and let n1, . . . , nt be distinct integers in r´x2, x2s. Then

Ppn1, . . . , nt P Sp~aqq “

ˆ

1`O

ˆ

1

log16 x

˙˙

σt.

Proof. For each s P S, the probability that n1, . . . , nt are all in Sp~aq is equal to 1 ´ mpsqt , where mpsq is

the number of distinct residue classes modulo s occupied by n1, . . . , nt. We have mpsq “ t unless s dividesone of the numbers ni ´ nj for 1 ď i ă j ď t. Since |ni ´ nj | ď 2x2, each difference ni ´ nj hasOplog xq prime factors. Therefore, mpsq ă t occurs for at most Opt2 log xq “ Oplog3 xq primes s P S.Byt the independence of the choices as for s P S, the events “tn1, . . . , ntu doesn’t intersect as mod s” are

SIEVE METHODS LECTURE NOTES, SPRING 2020 103

independent. Thus,

Ppn1, . . . , nt P Sp~aqq “ź

sPS

ˆ

1´mpsq

s

˙

“ź

sPS

ˆ

1´t

s

˙

ź

sPSmpsqăt

ˆ

1´t

s

˙´1 ˆ

1´mpsq

s

˙

ˆ

1`O

ˆ

1

log19 x

˙˙Oplog3 xqź

sPS

ˆ

1´t

s

˙

ˆ

1`O

ˆ

1

log16 x

˙˙

σtź

sPS

ˆ

1`O

ˆ

t2

s2

˙˙

ˆ

1`O

ˆ

1

log16 x

˙˙

σt.

Corollary 8.5. With probability ě 1´Op1 log6 xq, we have

(8.9) #pQX Sp~aqq “ˆ

1`O

ˆ

1

log4 x

˙˙

σ#Q „ 100cx

log x.

Proof. From Lemma 8.4, we have

E`

#pQX Sp~aqq˘2“

ÿ

q1,q2PQPpq1, q2 P Sp~aqq

ˆ

1`O

ˆ

1

log16 x

˙˙

`

σ#Qloomoon

q1“q2

`σ2p#Qqp#Q´ 1qloooooooooomoooooooooon

q1‰q2

˘

,

and so by (8.8), (8.3), (8.7),

E`

#pQX Sp~aqq ´ σ#Q˘2“ E#pQX Sp~aqq2 ´ pσ#Qq2 ! x2

log16 x!pσ#Qq2

log14 x.

Combining this last estimate with Chebyshev’s inequality, we conclude that

|#pQX Sp~aqq ´ σ#Q| ě σ#Qlog4 x

˙

!x2 log16 x

pσ#Qq2plog xq´8!

1

log6 x.

8.4. The weight functionwpp, nq. We will also choose the vector~b at random, but in a strategic way whichis dependent on ~a. Each residue class bp mod p must cover many primes in Q (in fact, many primes inQ X Sp~aq), and accomplishing this is the key to success of the whole enterprise. This is done via showingthe existence of a good “weight” function wpp, nq.

Let k be a fixed positive integer, large in terms of the constant c (in fact, k “X

exppc2q\

will do), and letph1, . . . , hkq be a fixed admissible k-tuple of positive integers (that is, for any prime, ph1, . . . , hkq does notcover pZpZq). For instance, p1, 32, 52, . . . , p2k ´ 1q2q.

Theorem 8.6 (Existence of good sieve weight). Let k be a fixed positive integer and ph1, . . . , hkq a fixedadmissible k´tuple. Suppose x is large and y is defined by (8.3). Then there are quantities τ , u satisfying

(8.10) τ “ xop1q, u " log k pxÑ8q

and a non-negative weight function wpp, nq defined on P ˆ pr´y, ys X Zq satisfying

104 KEVIN FORD

‚ Uniformly for every p P P , one has

(8.11)ÿ

nPZwpp, nq „ τ

y

logk x.

‚ Uniformly for every q P Q and i “ 1, . . . , k, one has

(8.12)ÿ

pPPwpp, q ´ hipq „ τ

u

k

x2

logk x.

‚ Uniformly for all p P P and n P Z,

(8.13) wpp, nq ! xop1q pxÑ8q.

Remark 2. One should think of wpp, nq as being a smoothed out indicator function for the event that n `h1p, . . . , n ` hkp are all almost primes in r1, ys. It is thus natural to bring into play the technology fromSection 7.

Proof. We first recall the construction of sieve weights from Section 7. Let

N “ 2y.

Define s,R,D, z by (7.7) where θ “ 13 , define D as in (7.8), and let µ` be an upper bound sieve guaranteed

by the Fundamental Lemma (Theorem 2.19). Fix a prime p P P , and consider the forms

fi,ppmq “ m` phip´ 3yq p1 ď i ď kq,

where 2y “ N ă m ď 2N “ 4y (so that hip ´ y ă fi,ppmq ď hip ` y). Here we write m “ n ` 3y,which maps p´y, yq to pN, 2Nq. Define E,E by (7.10), and define wpp, nq as in (7.12), that is,

wpp, nq “

ˆ

ÿ

t|pn`h1pq¨¨¨pn`hkpq

µ`ptq

˙ˆ

ÿ

@j:dj |n`hjp

λpdq1dPE

˙2

p´y ă n ď yq,

where ξprq is defined by (7.36), and λpdq is defined from Lemma 7.11. Here F is a symmetric, smoothfunction defined on Rk, where Rk is defined in (7.34). Moreover, we choose F so that

MkpF q ě 0.9Mk ě p0.9´ op1qq log k

by Theorem 7.17. Also, since

E “

ˇ

ˇ

ˇ

ˇ

pkpk´1q2ź

iăj

phj ´ hiq

ˇ

ˇ

ˇ

ˇ

,

the hi are bounded and p ą x2 ą R, the factor 1dPE above is superfluous and may be removed.By Proposition 7.14 (i),

ÿ

´yănďy

wpp, nq “ÿ

Nămď2N

wpp,m` 3yq „ V p2yq

ˆ

e´γlog z

logR

˙k

IpF q,

where IpF q is defined in (7.37) and

V “ź

qďz

ˆ

1´ρpqq

q

˙

,

SIEVE METHODS LECTURE NOTES, SPRING 2020 105

where, for prime q ď z,

ρpqq “ #

"

n mod q :kź

j“1

pn` hjpq ” 0 pmod qq

*

“ #

"

n mod q :kź

j“1

pn` hjq ” 0 pmod qq

*

is independent of p (since q ă p). This proves (8.11) with

(8.14) τ “ 2V

ˆ

e´γplog xqlog z

logR

˙k

IpF q “ xop1q.

Next, fix a prime q P Q and an index i P t1, . . . , ku. Then

ÿ

pPPwpp, q ´ hipq “

ÿ

x2ăpďx

1p prime

˜

ÿ

t|ś

j‰ipq`phj´hiqpq

µ`ptq

¸˜

ÿ

dj |q`phj´hiqp @j

λpdq

¸2

.

The asymptotic (8.12) follows from Proposition 7.14 (ii) applied to the linear forms ajn ` bj , 1 ď j ď k,where ai “ 1, bi “ 0 and for j ‰ i, aj “ hj ´ hi and bi “ q. Here we have N “ x2, and technicallythe R,D values used to construct wpp, nq with N “ x2 differ from those defined with N “ 2y by alogarithmic factor. However, the proof of Theorem 7.14 (ii) is robust under this kind of slight tweaking ofR and D. Also, the quantity E has prime factors which are either bounded or ą x and as before, the factor1dPE is superfluous. Also, |aj | ! 1 and q ď y ! x log x ! N logN , which are within the allowable boundsfor Proposition 7.14 (ii). We also note that

u “logR

2 log xMkpF q " log k

by Theorem 7.17. Thus, (8.10) follows. Finally, (8.13) since the definition of wpp, nq implies that wpp, nqis bounded by a divisor function.

8.5. Strategic choice of ~b. Our goal is to choose residue classes bp modulo p P P such that bp mod p

contains many elements of QX Sp~aq.For each p P P , let np denote the random integer with probability density

(8.15) Ppnp “ nq :“wpp, nq

ř

n1PZwpp, n1q

p´y ď n ď yq,

and chosen independently for each p P P . Notice that the random numbers np are chosen independently ofthe vector ~a. Roughly speaking, this gives more weight to n for which many of the numbers n ` hip areprime.

In order to capture the event that bp mod p contains many elements of Sp~aq, for each p P P and fixed(non-random) ~a, we consider the quantity

(8.16) Xpp~aq :“ Ppnp ` hip P Sp~aq for all i “ 1, . . . , kq,

over the random integer n. In light of Lemma 8.4, we expect that Xpp~aq „ σk for most choices of p and ~a,and this will be confirmed below (Lemma 8.8). With this in mind, let Pp~aq denote the set of all the primes

106 KEVIN FORD

p P P such that

(8.17)ˇ

ˇ

ˇXpp~aq ´ σ

ˇ

ˇď

σk

log3 x.

We now define the random variables np. Suppose we are in the event ~a “ ~a. If p P PzPp~aq, weset np “ 0. Otherwise, if p P Pp~aq, we define np to be the random integer with conditional probabilitydistribution

(8.18) Ppnp “ n|~a “ ~aq :“Zpp~a;nq

Xpp~aq,

where, for any ~a, any p P P and any n,

(8.19) Zpp~a;nq “

#

Ppnp “ nq if n` hjp P Sp~aq for j “ 1, . . . , k

0 otherwise,

with the np (p P Pp~aq) jointly independent, conditionally on the event ~a “ ~a. From (8.16) we see that theserandom variables are well defined.

Observe that the support of np is contained in those n for which n`hip P Sp~aq for all i, that is, the residueclass n mod p contains at least k elements of Sp~aq. Also, recalling Remark 1, we see that, conditionallyon ~a “ ~a, np is very likely to be a number for which there are" log k of the numbers n`h1p, . . . , n`hkp

which are prime (and hence in Q). Thus, the residue class np mod p will likely have many elementsof Q X Sp~aq, as desired. Unlike np, the random numbers np are very much dependent on the vector ~a.However, conditional on ~a “ ~a, all of the np (p P P) are independent.

Our main objective is a concentration bound for an average of Zpp~a; q ´ hipq.

Lemma 8.7. Fix c, k, and let u be the value guaranteed by Theorem 8.6. Define Zpp~a;nq by (8.18). Then,as xÑ8, with probability 1´ op1q we have

(8.20) σ´kkÿ

i“1

ÿ

pPPp~aqZpp~a; q ´ hipq „

u

σ

x

2y„

u

200c

for all but at most opx log xq of the primes q P QX Sp~aq.

Proof of Theorem 8.3 from Lemma 8.7. By Corollary 8.5 and Lemma 8.7, there is some vector ~a such that(8.9) holds and also (8.20) holds for almost all q P QXSp~aq. Fix this vector ~a (it is no longer random), andchoose random integers np according to the laws (8.18). Suppose that q P QXSp~aq. Substituting definition(8.18) into the left hand side of of (8.20), using (8.17), and observing that q “ np ` hip is only possible ifp P Pp~aq, we find that

σ´kkÿ

i“1

ÿ

pPPp~aqZpp~a; q ´ hipq “ σ´k

kÿ

i“1

ÿ

pPPp~aqXpp~aqPpnp “ q ´ hip|~a “ ~aq

ˆ

1`O

ˆ

1

log3 x

˙˙ kÿ

i“1

ÿ

pPPp~aqPpnp “ q ´ hip|~a “ ~aq

ˆ

1`O

ˆ

1

log3 x

˙˙

ÿ

pPPPpq P epq,

SIEVE METHODS LECTURE NOTES, SPRING 2020 107

where ep “ tnp ` hip : 1 ď i ď ku XQX Sp~aq. By (8.20), we conclude that

(8.21)ÿ

pPPPpq P epq „

ux

2σy„

u

200c.

Observe that each random set ep is contained in a single arithmetic progression modulo p. Now we setbp “ np mod p for each p P P . Then, for any q P QX Sp~aq, by the independence of the np,

Ppq P T p~bqq “ P pq ı bp pmod pq @p P Pq

“ź

pPPp1´ Ppq ” bp pmod pqqq

ďź

pPPp1´ Ppq P epqq

ď exp!

´ÿ

pPPPpq P epq

)

“ exp!

´ p1` op1qqu

200c

)

.

(8.22)

Hence, by (8.9),

E#pQX Sp~aq X T p~bqq ď 200cx

log xexp

!

´u

300c

)

.

The right hand side is ď x5 log x if k is large enough, thanks to (8.10) which states u " log k. Therefore,

there is some choice of the vector~b so that (8.5) holds, and this completes the proof of Theorem 8.3.

It remains to prove Lemma 8.7. We first confirm that PzPp~aq is small with high probability.

Lemma 8.8. With probability 1 ´ Op1 log3 xq, Pp~aq contains all but Op 1log3 x

xlog xq of the primes p P P .

In particular, E#Pp~aq “ #Pp1`Op1 log3 xqq.

Proof. It suffices to show that for each p P P , we have

(8.23) P pp P Pp~aqq “ 1´O

ˆ

1

log6 x

˙

.

From (8.23), we get

E p#PzPp~aqq “ÿ

pPPP pp R Pp~aqq ! #P

log6 x!

x

log7 x,

and then by Markov’s inequality,

#PzPp~aq ě x

log4 x

˙

ďE p#PzPp~aqqx log4 x

!1

log3 x.

We will prove (8.23) by computing first and second moments of Xpp~aq. Recall that, by (8.16),

Xpp~aq :“ÿ

n

1n`hipPSp~aq @i Ppnp “ nq.

108 KEVIN FORD

The right side is not random (unless we make ~a “ ~a random), since Ppnp “ nq is a deterministic functionof n which is independent of ~a. Using Lemma 8.4,

EXpp~aq “ÿ

n

Ppn` hip P Sp~aq for all i “ 1, . . . , kq Ppnp “ nq

ˆ

1`O

ˆ

1

log16 x

˙˙

σkÿ

n

Ppnp “ nq “

ˆ

1`O

ˆ

1

log16 x

˙˙

σk.(8.24)

Similarly,

EXpp~aq2 “

ÿ

n1,n2

Ppnl ` hip P Sp~aq for 1 ď i ď k; l “ 1, 2qPpnp “ n1qPpnp “ n2q

ˆ

1`O

ˆ

1

log16 x

˙˙

σ2k `O´

ypypqmaxnpPpnp “ nqq2

¯

,

since

#tnl ` hip : i “ 1, . . . , k; l “ 1, 2u “ 2k

unless n1 ” n2 pmod pq and there are Opypypqq such pairs pn1, n2q. From (8.15), (8.11), (8.13), and(8.10) one has Ppnp “ nq ! x´1`op1q for all p P P and n P Z. Also, σ " x´op1q by (8.7), hence

(8.25) EXpp~aq2 “

ˆ

1`O

ˆ

1

log16 x

˙˙

σ2k.

Combining (8.24) and (8.25), we compute

ˇ

ˇXpp~aq ´ σ

ˇ

ˇ

2!

σ2k

log16 x.

By Chebyshev’s inequality, for any p P P ,

P pp R Pp~aqq “ Pˆ

ˇ

ˇXpp~aq ´ σkˇ

ˇ ě1

log3 x

˙

!1

log10 x,

which proves (8.23).

Proof of Lemma 8.7. We first show that replacing Pp~aq with P has negligible effect on the sum, with highprobability. The purpose is to set up an application of (8.12) and to decouple some expressions involving ~a.

Fix i P t1, . . . , ku. By Lemma 8.4 and the definition (8.19) of Zpp~a, nq, we have

Eÿ

n

σ´kÿ

pPPZpp~a;nq “ σ´k

ÿ

pPP

ÿ

n

Ppnp “ nqPpn` hjp P Sp~aq for j “ 1, . . . , kq

ˆ

1`O

ˆ

1

log16 x

˙˙

ÿ

pPP

ÿ

n

Ppnp “ nq

ˆ

1`O

ˆ

1

log16 x

˙˙

#P.

SIEVE METHODS LECTURE NOTES, SPRING 2020 109

Next, by (8.17) and Lemma 8.8 we have

Eÿ

n

σ´kÿ

pPPp~aqZpp~a;nq “ σ´k

ÿ

~a

Pp~a “ ~aqÿ

pPPp~aqXpp~aq

ÿ

n

Ppnp “ n|~a “ ~aq

looooooooooomooooooooooon

equals 1

ˆ

1`O

ˆ

1

log3 x

˙˙

ÿ

~a

Pp~a “ ~aqÿ

pPPp~aq1

ˆ

1`O

ˆ

1

log3 x

˙˙

E #Pp~aq “ˆ

1`O

ˆ

1

log3 x

˙˙

#P.

Subtracting these two expectations, we conclude that

(8.26) Eÿ

n

σ´kÿ

pPPzPp~aqZpp~a;nq !

#Plog3 x

!x

log4 x.

We substitute n “ q ´ hip and find that

Eÿ

qPQXSp~aqσ´k

kÿ

i“1

ÿ

pPPzPp~aqZpp~a; q ´ hipq ď E

ÿ

n

σ´kÿ

pPPzPp~aqZpp~a;nq

!x

log4 x.

By Markov’s inequality, with probability 1´Op1 log xq, we have

ÿ

qPQXSp~aqσ´k

kÿ

i“1

ÿ

pPPzPp~aqZpp~a; q ´ hipq ď

x

log3 x.

Hence, with probability 1´Op1 log xq, we have

σ´kkÿ

i“1

ÿ

pPPzPp~aqZpp~a; q ´ hipq ď

1

log x

for all but Opx log2 xq primes q P Q X Sp~aq. Recalling our goal (8.20), it therefore suffices to show thatwith probability 1´ op1q, for all but at most opx log xq primes q P QX Sp~aq, one has

(8.27) F pq;~aq :“ σ´kkÿ

i“1

ÿ

pPPZpp~a; q ´ hipq „

xu

2σy.

We accomplish this with another first-second moment calculation.First, we note that from Theorem 8.6, (8.11) and (8.12), we have

(8.28)ÿ

pPPPpq “ np ` hipq „

u

k

x

2ypq P Q, 1 ď i ď kq.

110 KEVIN FORD

Hence, combining (8.28) with Lemma 8.4 and (8.15), we get

Eÿ

qPQXSp~aqF pq;~aq “ σ´k

ÿ

qPQ

kÿ

i“1

ÿ

pPPPpq ` phj ´ hiqp P Sp~aq @jqPpnp “ q ´ hipq

ˆ

1`O

ˆ

1

log16 x

˙˙

ÿ

qPQ

kÿ

i“1

ÿ

pPPPpnp “ q ´ hipq

„ σkÿ

qPQ

kÿ

i“1

ux

2ky„

σy

log x

ˆ

xu

2σy

˙

.

This matches what we want, since by corollary (8.5), #pQ X Sp~aqq „ σy log x with high probability.Similarly,

Eÿ

qPQXSp~aqF pq;~aq2 “

ÿ

p1,p2PPqPQ

ÿ

i1,i2

Ppq ` phj ´ hi`qp` P Sp~aq for j “ 1, . . . , k; ` “ 1, 2q

ˆ Ppnp1 “ q ´ hi1p1qPpnp2 “ q ´ hi2p2q

„σy

log x

ˆ

σk´1ux

2y

˙2

,

where in the last step we used the fact that the terms with p1 “ p2 contribute negligibly (the argument issimilar to that leading to (8.25)). Putting the first and second moment bounds together, and using (8.8), weget

Eÿ

qPQXSp~aq

ˆ

F pq;~aq ´xu

2σy

˙2

“ Eÿ

qPQXSp~aqF pq;~aq2 ´ 2

xu

2σyE

ÿ

qPQXSp~aqF pq;~aq `

ˆ

xu

2σy

˙2

E# pQX Sp~aqq

“ o

˜

σy

log x

ˆ

xu

2σy

˙2¸

.

Using Chebyshev’s inequality, we find that with probability 1´op1q, F pq;~aq „ xu2σy for all but opσy log xq

primes q P QX Sp~aq. Now σy log x — x log x, and the lemma follows.

8.6. Remarks: quantitative improvements. The proof described above may be adapted to the case wherek Ñ 8 (x Ñ 8). The relevant estimates needed for the analog of Theorem 8.6 may be found in [98].The error terms corresponding to bounds for primes in progressions from the sum (8.12) need to be of theform xplog xq100k2 , and this is achieved (as in [98]) by a careful analysis of Siegel exceptional zeros. Withk « plog xq15, the analog of Theorem 8.6 will have a factor u " log log x in (8.12). Inserted into the finalestimate (8.22) in the proof of Theorem 2, we find that to succeed we need

u " c log c,

which means that we can improve Y pxq be a factor " u log u (and hence Gpxq improved by a factor"

log ulog log u . In light of (8.21), however, we may expect an improvement of order " u for Y pxq, and of order

" log u for Gpxq. This is achieved by dealing effectively with overlaps among the random sets ep, usingtechniques from hypergraph covering (§4-5 of [50]).

SIEVE METHODS LECTURE NOTES, SPRING 2020 111

REFERENCES

[1] L. M. Adleman and D. R. Heath-Brown, The first case of Fermat’s last theorem. Invent. Math. 79 (1985), no. 2, 409–416.[2] M. Agrawal, N. Kayal and N. Saxena, PRIMES is in P. Ann. of Math. (2) 160 (2004), no. 2, 781–793; errata: Ann. of Math.

(2) 189 (2019), no. 1, 317–318.[3] W. R. Alford, A. Granville and C. Pomerance, There are infinitely many Carmichael numbers. Ann. of Math. 139 (1994),

703–722.[4] A. Balog, p`a without large prime factors. Seminar on number theory, 1983–1984 (Talence, 1983/1984), Exp. No. 31, 5 pp.,

Univ. Bordeaux I, Talence, 1984.[5] Linear equations in primes. Mathematika 39 (1992), no. 2, 367–378.[6] R. C. Baker and G. Harman, The Brun-Titchmarsh theorem on average, Analytic Number Theory (Proceedings in honor of

Heini Halberstam), Birkhauser, Boston, 1996, 39–103.[7] , Shifted primes without large prime factors, Acta Arith. 83 (1998), 331–361.[8] R. C. Baker, G. Harman and J. Pintz, The difference between consecutive primes. II., Proc. London Math. Soc. (3) 83 (2001),

no. 3, 532–562.[9] W. Banks, K. Ford and T. Tao, Large prime gaps and probabilistic models, submitted. Arxiv: 1908.08613

[10] P. T. Bateman and R. A. Horn, Primes represented by irreducible polynomials in one variable, Proc. Sympos. Pure Math.,Vol. VIII, Amer. Math. Soc., Providence, R.I. (1965), 119–132.

[11] P. Billingsly, On the distribution of large prime divisors, Collection of articles dedicated to the memory of Alfred Renyi, I.Period. Math. Hungar. 2 (1972), 283–289.

[12] E. Bombieri, On the large sieve. Mathematika 12 (1965), 201–225.[13] E. Bombieri and H. Davenport, Small differences between prime numbers. Proc. Roy. Soc. London Ser. A 293 (1966), 1–18.[14] E. Bombieri, J. Friedlander and H. Iwaniec, Primes in arithmetic progressions to large moduli. II, Math. Ann. 277 (1987),

361–393.[15] V. Y. Bouniakowsky, Nouveaux theoremes relatifs a la distinction des nombres premiers et a la decomposition des entiers en

facteurs, Mem. Acad. Sci. St. Petersbourg (6) (1857), 305–329.[16] V. Brun, Uber das Goldbachsche Gesetz und die Anzahl der Primzahlpaare, Archiv for Math. og Naturvid. B 34 (1915), no.

8, 19pp.[17] V. Brun, Om fordelingen av primtallene i forskjellige talklasser. En ovre begrænsning, Nyt Tidsskr. f. Math. 27 B (1916),

45–58.[18] V. Brun, La serie 1/5+1/7+1/11+1/13+ 1/17+1/19+1/29+1/31+1/41+1/43+1/59+1/61+... ou les denominateurs sont “nom-

bres premiers jumeaux” est convergente ou finie, Bull. Sci. Math. (2) 43 (1919), 100–104, 124–128.[19] V. Brun, Le crible d’Eratosthene et le theoreme de Goldbach, Skr. Norske Vid.-Akad. Kristiania I. 1920, no. 3, 36 pp.[20] R. D. Carmichael , On Euler’s φ-function , Bull. Amer. Math. Soc. 13 (1907) , 241–243.[21] , Note on Euler’s φ-function , Bull. Amer. Math. Soc. 28 (1922) , 109–110.[22] A. C. Cojocaru and M. Ram Murty. An introduction to sieve methods and their applications. London Mathematical Society

Student Texts, vol. 66. Cambridge University Press, 2006.[23] H. Cramer, Some theorems concerning prime numbers, Ark. Mat. Astr. Fys. 15 (1920), 1–33.[24] H. Cramer, On the order of magnitude of the difference between consecutive prime numbers, Acta Arith. 2 (1936), 396–403.[25] H. Davenport, Multiplicative number theory, 3rd ed., Graduate Texts in Mathematics vol. 74, Springer-Verlag, New York,

2000.[26] H. Diamond, H. Halberstam and W. F. Galway, A Higher-Dimensional Sieve Method: With Procedures for Computing Sieve

Functions, Cambridge Tracts in Mathematics, vol. 177, 2008.[27] L. E. Dickson, A new extension of Dirichlet’s theorem on prime numbers, Messenger Math., 33 (1904), 155–161.[28] P. G. L. Dirichlet, P. G. L. Beweis des Satzes, dass jede unbegrenzte arithmetische Progression, deren erstes Glied und Dif-

ferenz ganze Zahlen ohne gemeinschaftlichen Factor sind, unendlich viele Primzahlen enthalt [Proof of the theorem that everyunbounded arithmetic progression, whose first term and common difference are integers without common factors, containsinfinitely many prime numbers], Abhandlungen der Koniglichen Preußischen Akademie der Wissenschaften zu Berlin, 48 (1837), 45–71.

[29] P. Donnelly and G. Grimmett, On the asymptotic distribution of large prime factors, J. London Math. Soc. (2) 47 (1993),395–404.

[30] P. D. T. A. Elliott and H. Halberstam, A conjecture in prime number theory, Symp. Math. 4 (1968), 59–72.[31] P. Erdos , On the normal number of prime factors of p´ 1 and some related problems concerning Euler’s φ-function , Quart.

J. Math. Oxford 6 (1935), 205–213.[32] , On the difference of consecutive primes , Quart. J. Math. Oxford Ser. 6 (1935), 124–128.

112 KEVIN FORD

[33] , The difference of consecutive primes. Duke Math. J. 6 (1940), 438–441.[34] , Some remarks on Euler’s φ-function and some related problems , Bull. Amer. Math. Soc. 51 (1945), 540–544.[35] , On integers of the form 2k ` p and some related problems, Summa Brasil. Math. 2 (1950). 113–123.[36] , Some remarks on number theory, Riveon Lematematika 9 (1955), 45–48, (Hebrew. English summary).[37] , Some remarks on Euler’s φ-function , Acta Arith. 4 (1958), 10–19.[38] , An asymptotic inequality in the theory of numbers, Vestnik Leningrad. Univ. 15 (1960), no. 13, 41–49, (Russian).[39] , On the distribution of numbers of the form σpnqn and on some related questions, Pacific J. Math. 52 (1974), 59–65.[40] P. Erdos and R.R.Hall , On the values of Euler’s φ-function , Acta Arith. 22 (1973), 201–206.[41] , Distinct values of Euler’s φ-function , Mathematika 23 (1976), 1–3.[42] P. Erdos and M. Kac, The Gaussian law of errors in the theory of additive number theoretic functions. Amer. J. Math. 62

(1940), 738–742.[43] P. Erdos and C. Pomerance, On the normal number of prime factors of φpnq , Rocky Mountain J. of Math. 15 (1985), 343–352.[44] P. Erdos, C. Pomerance, and A. Sarkozy, On locally repeated values of certain arithmetic functions. III. Proc. Amer. Math.

Soc. 101 (1987), no. 1, 1–7.[45] K. Ford, The distribution of totients, Ramanujan J. (Paul Erdos memorial issue) 2 (1998), 67–151.[46] The number of solutions of φpxq “ m, Annals of Math. 150 (1999), 283–311.[47] The distribution of integers with a divisor in a given interval, Ann. Math. (2) 168 (2008), 367–433.[48] , Solutions of φpnq “ φpn` kq and σpnq “ σpn` kq, preprint, March 2020. arXiv:2002.12155[49] K. Ford. B. Green, S. Konyagin, T. Tao, Large gaps between consecutive prime numbers, Ann. Math. 183 (2016), 935–974.[50] K. Ford. B. Green, S. Konyagin, J. Maynard and T. Tao, Long gaps betweenconsecutive prime numbers, J. Amer. Math. Soc.,

31 (2018), no. 1, 65–105.[51] K. Ford and H. Halberstam, The Brun-Hooley sieve, J. Number Th. 81 (2000), 335–350.[52] K. Ford and S. Konyagin, On two conjectures of Sierpinski concerning the arithmetic functions σ and φ, Number Theory in

Progress (Zakopane, Poland, 1997), vol. II, de Gruyter (1999), 795-803.[53] E. Fouvry, Theoreme de Brun-Titchmarsh: application au theoreme de Fermat. (French) [The Brun-Titchmarsh theorem:

application to the Fermat theorem], Invent. Math. 79 (1985), no. 2, 383–407.[54] J. Friedlander, Shifted primes without large prime factors, in Number theory and applications (Banff, AB, 1988) , Kluwer

Acad. Publ., Dorbrecht (1989), 393–401.[55] J. Friedlander and H. Iwaniec, The polynomial X2

` Y 4 captures its primes Ann. of Math. (2), 148 (3) (1998), 945–1040.[56] The asymptotic sieve, Ann. of Math. (2), 148 (3) (1998), 1041–1065.[57] J. Friedlander and H. Iwaniec, Opera de Cribro, American Math. Soc., 2010.[58] M. Goldfeld, On the number of primes p for which p` a has a large prime factor. Mathematika 16 (1969), 23–27.[59] D. Goldston, J. Pintz and C. Yıldırım, Primes in tuples. I, Ann. of Math. 170 (2009), no. 2, 819–862.[60] , Primes in tuples. II. Acta Math. 204 (2010), no. 1, 1–47.[61] D. Goldston, S. Graham, J. Pintz and C. Yıldırım, Small gaps between primes or almost primes, Trans. Amer. Math. Soc. 361

(2009), no. 10, 5285–5330.[62] , Small gaps between products of two primes, Proc. London Math. Soc. (3) 98 (2009), 741–774.[63] S. W. Graham, J. J. Holt and C. Pomerance, On the solutions to φpnq “ φpn ` kq. Number theory in progress, Vol. 2

(Zakopane-Koscielisko, 1997), 867–882, de Gruyter, Berlin, 1999.[64] A. Granville, Harald Cramer and the distribution of prime numbers, Scandanavian Actuarial J. 1 (1995), 12–28.[65] B. J. Green and T. C. Tao, The primes contain arbitrarily long arithmetic progressions, Ann. of Math. 167 (2008), 481–547.[66] , Linear equations in primes, Annals of Math. 171 (2010), no. 3, 1753–1850.[67] , The quantitative behaviour of polynomial orbits on nilmanifolds, Annals of Math. 175 (2012), no. 2, 465–540.[68] B. J. Green and T. C. Tao and T. Ziegler, An inverse theorem for the Gowers U4-norm, Glasg. Math. J. 53 (2011), no. 1, 1–50.[69] , An inverse theorem for the Gowers Us`1

rN s-norm, Annals of Math. 176 (2012), 1231–1372.[70] H. Halberstam and H.-E. Richert, Sieve Methods, Academic Press, London, 1974.[71] R. R. Hall, G. Tenenbaum, Divisors, Cambridge Tracts in mathematics vol. 90, 1988.[72] G. H. Hardy and J. E. Littlewood, Some problems of ‘partitio numerorum’; III: On the expression of a number as a sum of

primes, Acta Math., 114 (3) (1923), 215–273.[73] , Some problems of ‘partitio numerorum’; VII., unpublished.[74] G. H. Hardy and S. Ramanujan, The normal number of prime factors of a number n , Quart. J. Math. 48 (1917), 76–92.[75] G. Harman, On the number of Carmichael numbers up to x. Bull. London Math. Soc. 37 (2005), no. 5, 641–650.[76] , Prime detecting sieves, London Math. Soc. monographs, 2006.[77] , Watt’s mean value theorem and Carmichael numbers. Int. J. Number Theory 4 (2008), no. 2, 241–248.

SIEVE METHODS LECTURE NOTES, SPRING 2020 113

[78] D. R. Heath-Brown, Gaps between primes, and the pair correlation of zeros of the zeta function, Acta Arith. 41 (1982), no. 1,85–99.

[79] , The divisor function at consecutive integers Mathematika 31 (1984), no. 1, 141–149.[80] Artin’s conjecture for primitive roots, Quart. J. Math. Oxford Ser. (2) 37 (1986), no. 145, 27–38.[81] A. Hildebrand and G. Tenenbaum , Integers without large prime factors , J. Theor. Nombres Bordeaux 5 (1993), 411–484.[82] C. Hooley, On Artin’s conjecture, J. Reine Angew. Math. 225 (1967), 209–220.[83] , On the Brun-Titchmarsh theorem. J. Reine Angew. Math. 255 (1972), 60–79.[84] , On the largest prime factor of p` a. Mathematika 20 (1973), 135–143.[85] , On the Brun-Titchmarsh theorem. II. Proc. London Math. Soc. (3) 30 (1975), 114–128.[86] Applications of Sieve Methods to the Theory of Numbers, Cambridge University Press, 1976.[87] On an almost-pure sieve, Acta Arith. LXVI (1994), 359–368.[88] H. Iwaniec, On the error term in the linear sieve. Acta Arith. 19 (1971), 1–30.[89] H. Iwaniec and E. Kowalski, Analytic number theory, Amer. Math. Soc. Colloquium Publications vol. 53, 2004.[90] R. Jajte, On random partitions of the segment, Bull. Acad. Polon. Sci. 19 (1971), 231–233.[91] Sungjin Kim, On the equations φpnq “ φpn` kq and φpp´ 1q “ φpq ´ 1q, preprint.[92] D. Koukoulopoulos, The distribution of prime numbers, Graduate Studies in Math. vol. 203, Amer. Math. Soc., 2019.[93] E. Landau, Neuer Beweis des Primzahlsatzes und Beweis des Primidealsatzes. Mathematische Annalen. 56 (4) (1903), 645–

670.[94] H. Maier, Small differences between prime numbers. Michigan Math. J. 35 (1988), no. 3, 323–344.[95] H. Maier and C. Pomerance , On the number of distinct values of Euler’s φ-function , Acta Arith. 49 (1988), 263–275.[96] , Unusually large gaps between consecutive primes. Trans. Amer. Math. Soc. 322 (1990), no. 1, 201–237.[97] J. Maynard, Small gaps between primes, Annals of Math. 181 (2015), 383–413.[98] J. Maynard, Dense clusters of primes in subsets, Compos. Math. 152 (2016), no. 7, to appear.[99] J. Maynard, Large gaps between primes, Ann. Math. 183 (2016), 915–933.[100] H. L. Montgomery and R. C. Vaughan, On the large sieve, Mathematika 20 (1973), 119–134.[101] Y. Motohashi, A note on the least prime in an arithmetic progression with a prime difference. Acta Arith. 17 (1970), 283–285.[102] Y. Motohashi and J. Pintz, A smoothed GPY sieve, Bull. Lond. Math. Soc. 40 (2008), no. 2, 298–310.[103] The Multiply Perfect Numbers Page, http://wwwhomes.uni-bielefeld.de/achim/mpn.html[104] The On-Line Encyclopedia of Integer Sequences, https://oeis.org/[105] S. Pillai , On some functions connected with φpnq , Bull. Amer. Math. Soc. 35 (1929), 832–836.[106] J. Pintz, Very large gaps between consecutive primes. J. Number Theory 63 (1997), no. 2, 286–301.[107] P. Pollack and C. Pomerance, Some problems of Erdos on the sum-of-divisors function, Trans. Amer. Math. Soc. Ser. B 3

(2016), 1–26.[108] D. H. J. Polymath, New equidistribution estimates of Zhang type, Algebra Number Theory 8 (2014), 2067–2199. See also

http://michaelnielsen.org/polymath1/index.php?title=Bounded_gaps_between_primes[109] D. H. J. Polymath, Variants of the Selberg sieve, and bounded gaps between primes, Research in the Mathematical Sciences

1:12 (2014).[110] C. Pomerance, Popular values of Euler’s function. Mathematika 27 (1980), no. 1, 84–89.[111] , On the distribution of the values of Euler’s function , Acta Arith. 47 (1986), 63–70.[112] R. A. Rankin, The difference between consecutive prime numbers, J. London Math. Soc. 13 (1938), 242–247.[113] R. A. Rankin, The difference between consecutive prime numbers. V, Proc. Edinburgh Math. Soc. (2) 13 (1962/63), 331–332.[114] G. Ricci, Ricerche arithmetiche sui polinomi II (Intorno a una proposizione non vera di Legendre), Rend. Circ. Mat. di

Palermo 58 (1934), 190–208.[115] N. P. Romanoff, Uber einige Satze der additiven Zahlentheorie, Math. Ann. 109 (1934), 668–678.[116] A. Schinzel , Sur l’equation φpxq “ m , Elem. Math. 11 1956, 75–78.[117] , Sur l’equation φpx` kq “ φpxq.. (French) Acta Arith 4 (1958), 181–184.[118] , Remarks of the paper “Sur certaines hypotheses concernant les nombres premiers” , Acta Arith. 7 (1961/62), 1–8.[119] A. Schinzel and W. Sierpinski, Sur certaines hypotheses concernant les nombres premiers, Acta Arith., 4 (1958), 185–208.

erratum, 5 (1959), p. 259.[120] A. Schinzel and A. Wakulicz, Sur l’equation φpx` kq “ φpxq. II. (French) Acta Arith. 5 (1959), 425–426.[121] L. Shnirelmann, Uber additive Eigenschaften von Zahlen, Math. Ann. 107 (1933), 649–690.[122] A. Schonhage, Eine Bemerkung zur Konstruktion grosser Primzahllucken, Arch. Math. 14 (1963), 29–30.[123] A. Selberg, The general sieve-method and its place in prime number theory. Proceedings of the International Congress of

Mathematicians, Cambridge, Mass., 1950, vol. 1, pp. 286–292. Amer. Math. Soc., Providence, R. I., 1952.[124] A. Selberg, Lectures on sieves, A. Selberg’s collected papers, vol. II, Springer-Verlag, 1991, pp. 65–247.

114 KEVIN FORD

[125] W. Sierpinski, Sur une propriete de la fonction φpnq. (French) Publ. Math. Debrecen 4 (1956), 184–185.[126] T. Oliveira e Silva, S. Herzog, S. Pardi, Empirical verification of the even Goldbach conjecture and computation of prime

gaps up to 4ˆ 1018, Math. Comp. 83 (2014), 2033–2060.[127] G. Tenenbaum, Introduction to Analytic and Probabilistic Number Theory, 3rd ed., Amer. Math Soc., 2015[128] N. M. Timofeev, Hardy-Ramanujan and Halasz type inequalities for shifted prime numbers, Math. Notes 57 (1995), 522–

535.[129] E. C. Titchmarsh, A divisor problem, Rend. Circ. Mat. Palermo 54 (1930), 414–429.[130] Christian Tudesq. Majoration de la loi locale de certaines fonctions additives. Arch. Math. (Basel), 67(6):465–472, 1996.[131] E. Westzynthius, Uber die Verteilung der Zahlen, die zu den n ersten Primzahlen teilerfremd sind, Commentationes Physico–

Mathematicae, Societas Scientarium Fennica, Helsingfors 5, no. 25, (1931) 1–37.[132] E. Wirsing, Bemerkung zu der Arbeit uber vollkommene Zahlen. (German) Math. Ann. 137 (1959), 316–318.[133] K. Wooldridge, Values taken many times by Euler’s phi-function. Proc. Amer. Math. Soc. 76 (1979), no. 2, 229–234.[134] T. Yamada, On equations σpnq “ σpn` kq and φpnq “ φpn` kq. J. Comb. Number Theory 9 (2017), no. 1, 15–21.[135] Yitang Zhang, Bounded gaps between primes. Annals of Mathematics 179 (2014), 1121–1174.

DEPARTMENT OF MATHEMATICS, 1409 WEST GREEN STREET, UNIVERSITY OF ILLINOIS AT URBANA-CHAMPAIGN,URBANA, IL 61801, USA

Email address: [email protected]