Sumfree sets, the Schur degree , block sums and the number of Eliahou–Revuelta
DefinitionClassicalSchurBasicThis bundle fixes the objects of Eliahou and Revuelta's study of the Schur degree of block-sum sets. It was written for the formalization of cited in the source field, whose main theorems use all of its definitions. Other theorems can use only some of them, for example only the sumfree sets and covers of items 1 and 2.
Throughout, and , and a sequence is a finite list of natural numbers, of length .
- A set is sumfree (Lean
SumFree) if for all . The case is included, so the condition is . - A set is covered by sumfree sets (Lean
CoveredBySumFree X n) if there are sumfree sets with . The sets need not be disjoint and need not lie in . - The Schur degree of (Lean
sdeg) is the least such that is covered by sumfree sets, and if there is no such . - A block of is a nonempty run of consecutive entries, . The set of block sums of (Lean
blockSums A) is . - The average of (Lean
average A) is the rational number . - For , the property (Lean
ERProperty n L) states: every sequence of positive integers with and satisfies . - The number (Lean
erL n) is the least positive integer such that holds.
In display form, the two central quantities are
with , and
Eliahou and Revuelta prove for (Proposition 5.3), where is the Schur number, the largest such that can be partitioned into sumfree sets, and is the multicolour Ramsey number of triangles, and they conjecture (Conjecture 5.6).
Formalization Note (1) The ambient set is , while the paper works in an abelian group (for , in the integers). For the least number of sumfree sets that cover does not depend on this choice: a sumfree subset of meets in a sumfree set, and a sumfree subset of is sumfree in . (2) takes values in the extended naturals ℕ∞, where is ⊤; it is the infimum of the set of admissible , and the infimum of the empty set is ⊤. (3) Sequences are lists of natural numbers, and blocks are nonempty contiguous sublists (List.IsInfix); positivity of the entries is a hypothesis of , not part of the definition of . (4) The average is computed in , and the empty sequence has average by Lean's convention for division by zero; the paper does not define of the empty sequence, and only uses lengths . (5) is defined for every as an infimum in , where the empty infimum would be . For every the set is nonempty (by the form of Theorem 4.1 of the paper proved in the formalization of cited in the source field), so is its least element, and for it is the of the paper, which the paper defines only for .
-- Generated from lean/ClassicalSchur/Basic.lean by skeleton
-- subtraction: every declaration except the def-material below is deleted,
-- and project imports are rewritten to their platform Definitions bundles.
import Mathlib
namespace ClassicalSchur
/-- A set of naturals is sumfree when it has no `x, y, z` with `x + y = z`;
`x = y` is allowed (ER §2.3: `(S + S) ∩ S = ∅`). -/
def SumFree (S : Set ℕ) : Prop := ∀ x ∈ S, ∀ y ∈ S, x + y ∉ S
/-- `X` is covered by `n` sumfree sets (ER Definition 2.1). -/
def CoveredBySumFree (X : Set ℕ) (n : ℕ) : Prop :=
∃ C : Fin n → Set ℕ, (∀ i, SumFree (C i)) ∧ X ⊆ ⋃ i, C i
/-- The Schur degree (ER Definition 2.1): the least `n ≥ 1` such that `X` is
covered by `n` sumfree sets, and `⊤` when there is no such `n`. -/
noncomputable def sdeg (X : Set ℕ) : ℕ∞ :=
sInf ((fun n : ℕ => (n : ℕ∞)) '' {n | 1 ≤ n ∧ CoveredBySumFree X n})
/-- The block sums `Â` of a sequence `A` (ER Notation 2.2): the sums of the
nonempty runs of consecutive entries of `A`. -/
def blockSums (A : List ℕ) : Set ℕ :=
{s | ∃ B : List ℕ, B <:+: A ∧ B ≠ [] ∧ B.sum = s}
/-- The average `μ(A)` of a sequence. -/
def average (A : List ℕ) : ℚ := (A.sum : ℚ) / A.length
/-- The property of ER Definition 5.1 at length `L`: every sequence of
positive integers of length `L` and average at most `n` has
`sdeg(Â) ≥ n`. -/
def ERProperty (n L : ℕ) : Prop :=
∀ A : List ℕ, A.length = L → (∀ a ∈ A, 0 < a) → average A ≤ n →
(n : ℕ∞) ≤ sdeg (blockSums A)
/-- `L(n)` of ER Definition 5.1: the least positive integer `L` with
`ERProperty n L`. -/
noncomputable def erL (n : ℕ) : ℕ := sInf {L | 0 < L ∧ ERProperty n L}
end ClassicalSchur