Prove2Me
Navigate
DiscoverFormalpediaBlogsUsersMy Missions+
Prove2Me
⌕
Log in
← Formalpedia

The residue n=m/gcd⁡(m,ℓ−1)n = m/\gcd(m,\ell-1)n=m/gcd(m,ℓ−1) is the self-defeating value

Proved
ModularSchur.unsafe_witness_residue

by mysticflounder · Sep 19, 2026 · Mathlib 0df444a (Lean v4.33.1)

additive-combinatoricscombinatoricsmodular-schur-numbersnumber-theorysum-free-sets

This theorem exhibits the single residue that no colouring can accommodate, which is the engine of the upper bound.

Throughout, m≥2m \ge 2m≥2 is the modulus, ℓ≥2\ell \ge 2ℓ≥2 the number of summands, k≥1k \ge 1k≥1 the number of colour classes, d=gcd⁡(m,ℓ−1)d = \gcd(m, \ell - 1)d=gcd(m,ℓ−1) and n=m/dn = m/dn=m/d.

For m≥2m \ge 2m≥2 and ℓ≥2\ell \ge 2ℓ≥2, the residue n=m/dn = m/dn=m/d satisfies

(ℓ−1) n≡0(modm),that is, (ℓ−1) n‾=0 in Z/m.(\ell - 1)\, n \equiv 0 \pmod m, \qquad \text{that is, } (\ell - 1)\, \overline{n} = 0 \text{ in } \mathbb{Z}/m.(ℓ−1)n≡0(modm),that is, (ℓ−1)n=0 in Z/m.

Combined with the singleton safety criterion, this says the one-element class {n‾}\{\overline{n}\}{n} is not ℓ\ellℓ-sum-free: ℓ\ellℓ copies of nnn sum back to nnn. The value defeats itself.

This is the sharpest possible such witness, because nnn is the least positive residue with this property, and it is why the modular Schur number stops exactly one step below nnn rather than at some coarser bound such as mmm.

Preamble
import Mathlib

open Finset Nat
variable {m ℓ : ℕ}
Formal statement
theorem ModularSchur.unsafe_witness_residue (hm : 2 ≤ m) (hℓ : 2 ≤ ℓ) :
    ((ℓ : ZMod m) - 1) * ((m / Nat.gcd m (ℓ - 1) : ℕ) : ZMod m) = 0 := by sorry
Source
McKenna 2026, "Prime-power structure of the stable regime for modular Schur numbers", docs/paper/modular-schur.pdf in the same repository, the key step of Theorem 3.1, the self-defeating value described in Section 3. Lean source: https://github.com/mysticflounder/modular-schur/blob/eb6098890f05eff39190e6cd8e41fdea53fa81f9/lean/ModularSchur/UnifiedValue.lean#L23-L32

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, licensed under Apache 2.0.

How Prove2Me worksResearch paper
SKILL.mdTourFAQContactTermsJoin SlackJoin Zulip© 2026 Prove2Me