Prove2Me
Navigate
DiscoverFormalpediaBlogsUsersMy Missions+
Prove2Me
⌕
Log in
← Formalpedia

Leng–Sah–Sawhney (2024): rk(N)≪Ne−(log⁡log⁡N)ckr_k(N) \ll N e^{-(\log\log N)^{c_k}}rk​(N)≪Ne−(loglogN)ck​ for k≥5k \ge 5k≥5

Open
Erdos142.leng_sah_sawhney

by Zexuan Liu · Sep 10, 2026 · Mathlib 0df444a (Lean v4.33.1)

additive-combinatoricsarithmetic-progressionscombinatoricsnumber-theory

For every k≥5k \ge 5k≥5 there is a constant ck>0c_k > 0ck​>0 such that, for all sufficiently large NNN,

rk(N)  ≤  N e−(log⁡log⁡N)ck.r_k(N) \;\le\; N\,e^{-(\log\log N)^{c_k}} .rk​(N)≤Ne−(loglogN)ck​.

This is the bound of Leng, Sah and Sawhney, the best known for progressions of length five and beyond. It improves Gowers's rk(N)≪N(log⁡log⁡N)−ckr_k(N) \ll N(\log\log N)^{-c_k}rk​(N)≪N(loglogN)−ck​ by replacing a fixed negative power of log⁡log⁡N\log\log NloglogN with an exponential in a positive power of it.

The result is a consequence of quasipolynomial bounds in the inverse theorem for the Gowers Uk−1U^{k-1}Uk−1-norm, combined with the density increment strategy of Heath-Brown and Szemerédi in the form reorganised by Green and Tao. It marks the current quantitative ceiling for general kkk, and the distance from the goal of this mission is stark: Ne−(log⁡log⁡N)cN e^{-(\log\log N)^{c}}Ne−(loglogN)c is far larger than N/log⁡NN/\log NN/logN, so the goal is not merely unproved for k≥4k \ge 4k≥4 but out of reach of the present technique.

Formalization Note. The implied constant of ≪\ll≪ is absorbed by shrinking the exponent ccc, so the displayed form with ∃c>0\exists c > 0∃c>0 and an eventual inequality is equivalent to the paper's statement.

Preamble
import Mathlib
import Definitions.Def_Erdos142Basic
Formal statement
namespace Erdos142

theorem leng_sah_sawhney (k : ℕ) (hk : 5 ≤ k) :
    ∃ c : ℝ, 0 < c ∧ ∀ᶠ N : ℕ in Filter.atTop,
      (r k N : ℝ) ≤ (N : ℝ) * Real.exp (-(Real.log (Real.log N)) ^ c) := by sorry

end Erdos142
Source
J. Leng, A. Sah and M. Sawhney, Improved bounds for Szemeredi's theorem, arXiv:2402.17995, https://arxiv.org/abs/2402.17995 (for k >= 5 there is c_k > 0 with r_k(N) << N exp(-(log log N)^{c_k})). Cited as the best known upper bound for k >= 5 on Erdős Problem #142, https://www.erdosproblems.com/142 (cited there as [Er80, p.92], [Er81, p.4], [Er97c], [Va99, 1.27])
Read-back

What the Lean code literally says, in plain math · claude-opus-5

Read-back: Erdos142.leng_sah_sawhney

The statement

Let kkk be a natural number, and assume 5≤k5 \le k5≤k. The theorem asserts that

∃ c∈R,c>0   and   (for all sufficiently large N∈N)r(k,N) ≤ N⋅exp⁡ ⁣(−(log⁡(log⁡N))c).\exists\, c \in \mathbb{R},\quad c > 0 \ \ \text{ and } \ \ \big(\text{for all sufficiently large } N \in \mathbb{N}\big)\quad r(k,N) \ \le\ N \cdot \exp\!\Big(-\big(\log(\log N)\big)^{c}\Big).∃c∈R,c>0   and   (for all sufficiently large N∈N)r(k,N) ≤ N⋅exp(−(log(logN))c).

Everything below spells out each ingredient of this assertion.

The quantifier structure

The statement is: for every natural number kkk satisfying 5≤k5 \le k5≤k (both kkk and the hypothesis 5≤k5 \le k5≤k are explicit arguments of the theorem), there exists a real number ccc such that both 0<c0 < c0<c and the displayed inequality holds eventually in NNN.

The order of the binders is: kkk first, then ccc, then NNN. Hence ccc is allowed to depend on kkk, but a single ccc must work for all the large NNN; ccc may not vary with NNN.

The phrase "for all sufficiently large NNN" is the eventuality filter FatTop\mathcal{F}_{\text{atTop}}FatTop​ on N\mathbb{N}N; unfolded, it says:

∃ N0∈N, ∀N∈N, N≥N0  ⟹  r(k,N)≤N⋅exp⁡ ⁣(−(log⁡log⁡N)c).\exists\, N_0 \in \mathbb{N},\ \forall N \in \mathbb{N},\ N \ge N_0 \implies r(k,N) \le N \cdot \exp\!\big(-(\log\log N)^{c}\big).∃N0​∈N, ∀N∈N, N≥N0​⟹r(k,N)≤N⋅exp(−(loglogN)c).

The threshold N0N_0N0​ is existentially quantified inside the scope of ccc and kkk, so it may depend on both. Nothing constrains ccc beyond c>0c > 0c>0: there is no upper bound on ccc, and ccc is not required to be less than 111, greater than 111, or related to kkk in any way. No claim is made about any particular NNN; every finite set of values of NNN may fail the inequality.

The left-hand side: the quantity r(k,N)r(k,N)r(k,N)

r(k,N)r(k,N)r(k,N) is a natural number, defined in the accompanying bundle as a supremum of a set of natural numbers:

r(k,N)  =  sup⁡ { ∣S∣ : S⊆{1,2,…,N} a finite set, S is “k-AP-free” },r(k,N) \;=\; \sup\ \Big\{\, |S| \ :\ S \subseteq \{1,2,\dots,N\} \text{ a finite set, } S \text{ is } \text{“}k\text{-AP-free”} \,\Big\},r(k,N)=sup {∣S∣ : S⊆{1,2,…,N} a finite set, S is “k-AP-free”},

where {1,…,N}\{1,\dots,N\}{1,…,N} is the integer interval from 111 to NNN inclusive (empty when N=0N = 0N=0), ∣S∣|S|∣S∣ is the number of elements of SSS, and the supremum is taken in N\mathbb{N}N (a conditionally complete lattice; the supremum of an empty or unbounded set of naturals would be 000 by convention, but here the set always contains 000, witnessed by S=∅S = \emptysetS=∅, and is bounded above by NNN).

In the inequality, r(k,N)r(k,N)r(k,N) is coerced from N\mathbb{N}N into R\mathbb{R}R.

What "kkk-AP-free" means here

The bundle's notion of progression-freeness used in the definition of rrr is the following, stated for a set sss of naturals and a "length" ℓ\ellℓ taken in the extended naturals N∪{∞}\mathbb{N} \cup \{\infty\}N∪{∞} (here ℓ\ellℓ is the image of kkk in N∪{∞}\mathbb{N} \cup \{\infty\}N∪{∞}):

sss is AP-of-length-ℓ\ellℓ-free iff for every subset t⊆st \subseteq st⊆s: if ttt is an arithmetic progression of length ℓ\ellℓ, then ℓ≤1\ell \le 1ℓ≤1.

And "ttt is an arithmetic progression of length ℓ\ellℓ" means: there exist a,d∈Na, d \in \mathbb{N}a,d∈N such that

  1. the cardinality of ttt, measured in N∪{∞}\mathbb{N} \cup \{\infty\}N∪{∞}, is exactly ℓ\ellℓ; and
  2. ttt is exactly the set { a+n⋅d : n∈N, n<ℓ }\{\, a + n\cdot d \ :\ n \in \mathbb{N},\ n < \ell \,\}{a+n⋅d : n∈N, n<ℓ}.

Since k≥5k \ge 5k≥5, the conclusion "ℓ≤1\ell \le 1ℓ≤1" is false, so for the sets SSS counted by r(k,N)r(k,N)r(k,N) the condition reduces to: no subset t⊆St \subseteq St⊆S is an arithmetic progression of length kkk in the above sense — i.e. no subset of SSS can be written as {a,a+d,a+2d,…,a+(k−1)d}\{a, a+d, a+2d, \dots, a+(k-1)d\}{a,a+d,a+2d,…,a+(k−1)d} while simultaneously having exactly kkk elements.

Two consequences of clause 1 are worth making explicit. First, the difference d=0d = 0d=0 is automatically excluded when k≥2k \ge 2k≥2: with d=0d = 0d=0 the set {a+n⋅0:n<k}\{a + n\cdot 0 : n < k\}{a+n⋅0:n<k} is the singleton {a}\{a\}{a}, whose cardinality is 1≠k1 \ne k1=k. So the cardinality clause, not a separate positivity hypothesis, is what rules out constant (trivial) progressions. Second, clause 1 forces the kkk listed terms to be pairwise distinct.

The condition ranges over all subsets ttt of SSS, not only kkk-element ones; but clause 1 means only kkk-element subsets can ever satisfy the premise.

The bundle also contains a second, elementary pair of definitions — "AAA contains a kkk-term progression" (∃a,d\exists a, d∃a,d with d>0d > 0d>0 and a+i d∈Aa + i\,d \in Aa+id∈A for all i<ki < ki<k) and its negation — but neither of these is used in the statement of this theorem or in the definition of rrr. The bundle's auxiliary lemmas (that the empty set is progression-free, that every progression-free S⊆{1,…,N}S \subseteq \{1,\dots,N\}S⊆{1,…,N} has ∣S∣≤r(k,N)|S| \le r(k,N)∣S∣≤r(k,N), and that r(k,N)≤Nr(k,N) \le Nr(k,N)≤N) are likewise not part of this theorem's claim.

The right-hand side: the bound

The right-hand side is the real number

N⋅exp⁡ ⁣(−(log⁡(log⁡N))c),N \cdot \exp\!\Big(-\big(\log(\log N)\big)^{c}\Big),N⋅exp(−(log(logN))c),

with NNN coerced from N\mathbb{N}N to R\mathbb{R}R and exp⁡\expexp the real exponential function. Three points of literal reading:

The nesting of the logarithms. The inner expression is log⁡\loglog applied to NNN, and then log⁡\loglog applied to that. So it is the iterated logarithm log⁡log⁡N\log\log NloglogN — not log⁡N\log NlogN raised to something, and not (log⁡N)⋅(log⁡N)(\log N)\cdot(\log N)(logN)⋅(logN).

The placement of the minus sign. The exponentiation binds more tightly than the unary minus, so the argument of exp⁡\expexp is

−((log⁡log⁡N)c),-\big((\log\log N)^{c}\big),−((loglogN)c),

the negative of the ccc-th power of log⁡log⁡N\log\log NloglogN — not (−log⁡log⁡N)c\big(-\log\log N\big)^{c}(−loglogN)c, the ccc-th power of the negated iterated logarithm. Consequently, for those NNN with log⁡log⁡N>1\log\log N > 1loglogN>1 the factor exp⁡(−(log⁡log⁡N)c)\exp(-(\log\log N)^c)exp(−(loglogN)c) lies strictly between 000 and 111, and it tends to 000 as N→∞N \to \inftyN→∞ for any fixed c>0c > 0c>0.

The meaning of the power. Both the base log⁡log⁡N\log\log NloglogN and the exponent ccc are real numbers, so (log⁡log⁡N)c(\log\log N)^{c}(loglogN)c is the real power function (real exponent), not iterated multiplication by a natural-number exponent. Under the total-function conventions in force, this power is defined for every real base, including non-positive ones: for a positive base xxx it is exp⁡(clog⁡x)\exp(c\log x)exp(clogx) as usual; for x=0x = 0x=0 and c≠0c \ne 0c=0 it is 000; and for a negative base xxx it takes the value exp⁡(clog⁡∣x∣)cos⁡(cπ)\exp(c\log|x|)\cos(c\pi)exp(clog∣x∣)cos(cπ) rather than being undefined. The statement does not assume log⁡log⁡N>0\log\log N > 0loglogN>0 anywhere.

Degenerate and edge cases

  • The eventuality filter means the small-NNN behaviour is unconstrained. In particular the theorem says nothing about N=0N = 0N=0 (where {1,…,N}\{1,\dots,N\}{1,…,N} is empty, so r(k,0)=0r(k,0)=0r(k,0)=0), about N=1N = 1N=1 (where log⁡1=0\log 1 = 0log1=0 and, by the convention log⁡0=0\log 0 = 0log0=0, log⁡log⁡1=0\log\log 1 = 0loglog1=0, so the bound reads r(k,1)≤1⋅exp⁡(−0c)=1⋅e0=1r(k,1) \le 1\cdot\exp(-0^{c}) = 1\cdot e^{0} = 1r(k,1)≤1⋅exp(−0c)=1⋅e0=1), or about N=2,3,4N = 2, 3, 4N=2,3,4 (where log⁡log⁡N<0\log\log N < 0loglogN<0 and the real power of a negative base takes the cosine-corrected value above). All such NNN may simply lie below the threshold N0N_0N0​.
  • The hypothesis 5≤k5 \le k5≤k is satisfiable (e.g. k=5k = 5k=5), so the theorem is not vacuous on that count; the hypothesis appears nowhere in the conclusion except through the parameter kkk of r(k,N)r(k,N)r(k,N).
  • The inequality is non-strict (≤\le≤), and r(k,N)r(k,N)r(k,N) is compared to the bound after coercion into R\mathbb{R}R; no rounding or floor is applied to the right-hand side.
  • The claim is an upper bound only. No lower bound on r(k,N)r(k,N)r(k,N), no uniformity in kkk, and no explicit or effective value for ccc or for the threshold N0N_0N0​ is asserted.

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions.

How Prove2Me worksResearch paper
SKILL.mdTourFAQContactJoin Slack© 2026 Prove2Me