Mathematics / Formalization Note / Combinatorics & Graph Theory

Erdős Problem 360 in Lean 4: The Last Open Leaf, a Deshouillers-Freiman-Type Small-Doubling Theorem in Z/mZ

Proof of the leaf Erdos360.erdos_360.R1.H4.R1.H4.R1.H1 (PR #74359, accepted by the Left to Solve Lean checker) of the reduction R1.H4.R1.H4.R1 written by KevinBigham. According to the PR body and the Left to Solve records it was the last open leaf; the root Erdos360.erdos_360 was recorded as solved at the same timestamp and credited to the reduction author green-notes (contributors OrangeHeadz, green-notes). The reduction tree and all other leaves are other participants' work. The Kneser addition theorem module in the file is adapted from Mantas Baksys and Yael Dillies (YaelDillies/misc-yd, Apache-2.0).

Author
Ali Uyar
DOI
10.5281/zenodo.24765164
Scope
Modular suite
Status
Merged on Left to Solve
Original theorem
Erdos Problem 360 (Erdos and Graham): how fast does the minimal number f(n) of classes partitioning {1, ..., n-1}, with n not a sum of distinct elements of one class, grow? Conlon, Fox and Pham (arXiv:2104.14766, Theorem 1.5) determined f(n) up to a constant factor: f(n) is of order n^(1/3) (n/phi(n)) / ((log n)^(1/3) (log log n)^(2/3)). The leaf proved here is of the type studied by Deshouillers and Freiman (Proc. LMS 86, 2003) and is proved via a special case of Lev's Z x F inverse theorem (SIAM J. Discrete Math. 36, 2022).
Statement source
Left to Solve (FormalConjectures / OMA statements)
Source
github.com/aliuyar1234/lean4-landmark-formalizations/tree/main/26-erdos-360-totient-partition

Machine-checked in Lean 4 ✓ Accepted and merged on Left to Solve.

Summary

A 4,293-line Lean 4 file (4,090 code lines plus 203 lines of Apache-2.0 license text) proves the leaf R1.H4.R1.H4.R1.H1 of the Left to Solve reduction tree for Erdős Problem 360: a small-doubling inverse theorem of Deshouillers-Freiman type for subsets of Z/mZ with doubling at most 2.04 and density at most an explicit xi ≈ 6.5e-129 (the leaf asks for some xi < 1/100), so it covers very sparse sets. The proof combines character moments, Freiman-style semicircle rectification, stabilizer quotients, Kneser's theorem (about 945 lines adapted from Baksys and Dillies) and a proof of the restricted case of Lev's Z x F inverse theorem used here. It was accepted by the Left to Solve Lean checker as PR #74359 and, according to the Left to Solve records, was the last open leaf: the root, Conlon, Fox and Pham's determination of f(n) up to a constant factor, was then recorded as solved under the reduction author green-notes. The reduction tree and the other leaves are other participants' work, and the mathematics of the leaf is known.

Context

A Lean 4 proof of a cyclic-group inverse theorem above the 3/2 doubling threshold (at 2.04, for very sparse sets), built from Freiman-style rectification, a restricted case of Lev's Z x F theorem and an adapted formalization of Kneser's theorem. It supplied the last missing piece of a collaborative formal proof of Erdős 360.

Root problems on Left to Solve

  • LTS Erdos360.erdos_360 closed by @green-notes

Credits

Mathematics: Erdos and Graham (problem); Conlon, Fox and Pham (order of growth of f(n)); Deshouillers and Freiman (2.04 small-doubling structure theorem in Z/nZ); Lev (Z x F inverse theorem, restricted case formalized). Reduction tree on Left to Solve: green-notes (R1, R1.H4.R1), steveDOTdigital (R1.H4.R1.H3.R1), KevinBigham (R1.H4.R1.H4.R1, which states this leaf); other leaves by OrangeHeadz, green-notes, KevinBigham, marcusbuffett, smurali12, steveDOTdigital and LordMike. Root solution credited to green-notes (contributors OrangeHeadz, green-notes). Adapted Lean code: Kneser module, header 'Copyright (c) 2023 Mantas Baksys, Yael Dillies ... Adapted from YaelDillies/misc-yd at f2f1d413b681dfd7a0f0e8481aee3ab7e0bae7ba', Apache-2.0. PR body: 'Formalizes Lev's product inverse theorem (ProductInverse, doubling < 2.4 in Z x F), Freiman's integer 3k - 4 theorem, Kneser's theorem (with Apache 2.0 attribution to Baksys & Dillies), and the small-doubling cyclic-group reduction to H1.' ProductInverse is only the restricted case, and the submitted file contains no standalone Freiman 3k-4 theorem. No other contributors recorded.

Pull request ledger (1)

  • #74359 Erdos360.erdos_360.R1.H4.R1.H4.R1.H1 merged

Cite

@misc{uyar2026_erdos_360_totient_partition_lean4,
  author    = {Uyar, Ali},
  title     = {Erdős Problem 360 in Lean 4: The Last Open Leaf, a Deshouillers-Freiman-Type Small-Doubling Theorem in Z/mZ},
  year      = {2026},
  publisher = {Zenodo},
  doi       = {10.5281/zenodo.24765164},
  url       = {https://doi.org/10.5281/zenodo.24765164},
  note      = {Lean 4 formalization technical note (Erdos Problem 360 (Erdos and Graham): how fast does the minimal number f(n) of classes partitioning {1, ..., n-1}, with n not a sum of distinct elements of one class, grow? Conlon, Fox and Pham (arXiv:2104.14766, Theorem 1.5) determined f(n) up to a constant factor: f(n) is of order n^(1/3) (n/phi(n)) / ((log n)^(1/3) (log log n)^(2/3)). The leaf proved here is of the type studied by Deshouillers and Freiman (Proc. LMS 86, 2003) and is proved via a special case of Lev's Z x F inverse theorem (SIAM J. Discrete Math. 36, 2022).). Code: https://github.com/aliuyar1234/lean4-landmark-formalizations/tree/main/26-erdos-360-totient-partition}
}