mathlib3 documentation

combinatorics.additive.behrend

Behrend's bound on Roth numbers #

THIS FILE IS SYNCHRONIZED WITH MATHLIB4. Any changes to this file require a corresponding PR to mathlib4.

This file proves Behrend's lower bound on Roth numbers. This says that we can find a subset of {1, ..., n} of size n / exp (O (sqrt (log n))) which does not contain arithmetic progressions of length 3.

The idea is that the sphere (in the n dimensional Euclidean space) doesn't contain arithmetic progressions (literally) because the corresponding ball is strictly convex. Thus we can take integer points on that sphere and map them onto ℕ in a way that preserves arithmetic progressions (behrend.map).

Main declarations #

References #

Tags #

Salem-Spencer, Behrend construction, arithmetic progression, sphere, strictly convex

Turning the sphere into a Salem-Spencer set #

We define behrend.sphere, the intersection of the $$L^2$$ sphere with the positive quadrant of integer points. Because the $$L^2$$ closed ball is strictly convex, the $$L^2$$ sphere and behrend.sphere are Salem-Spencer (add_salem_spencer_sphere). Then we can turn this set in fin n → ℕ into a set in ℕ using behrend.map, which preserves add_salem_spencer because it is an additive monoid homomorphism.

def behrend.box (n d : ℕ) :

The box {0, ..., d - 1}^n as a finset.

Equations
theorem behrend.mem_box {n d : ℕ} {x : fin n → ℕ} :
x ∈ behrend.box n d ↔ ∀ (i : fin n), x i < d
@[simp]
theorem behrend.card_box {n d : ℕ} :
(behrend.box n d).card = d ^ n
@[simp]
theorem behrend.box_zero {n : ℕ} :
behrend.box (n + 1) 0 = ∅
def behrend.sphere (n d k : ℕ) :

The intersection of the sphere of radius sqrt k with the integer points in the positive quadrant.

Equations
@[simp]
theorem behrend.sphere_zero_right (n k : ℕ) :
behrend.sphere (n + 1) 0 k = ∅
theorem behrend.norm_of_mem_sphere {n d k : ℕ} {x : fin n → ℕ} (hx : x ∈ behrend.sphere n d k) :
‖⇑((pi_Lp.equiv 2 (λ (ᾰ : fin n), ℝ)).symm) (coe ∘ x)‖ = √ ↑k
theorem behrend.sphere_subset_preimage_metric_sphere {n d k : ℕ} :
↑(behrend.sphere n d k) ⊆ (λ (x : fin n → ℕ), ⇑((pi_Lp.equiv 2 (λ (ᾰ : fin n), ℝ)).symm) (coe ∘ x)) ⁻¹' metric.sphere 0 (√ ↑k)
@[simp]
theorem behrend.map_apply {n : ℕ} (d : ℕ) (a : fin n → ℕ) :
⇑(behrend.map d) a = finset.univ.sum (λ (i : fin n), a i * d ^ ↑i)
def behrend.map {n : ℕ} (d : ℕ) :

The map that appears in Behrend's bound on Roth numbers.

Equations
@[simp]
theorem behrend.map_zero (d : ℕ) (a : fin 0 → ℕ) :
theorem behrend.map_succ {n d : ℕ} (a : fin (n + 1) → ℕ) :
⇑(behrend.map d) a = a 0 + finset.univ.sum (λ (x : fin n), a x.succ * d ^ ↑x) * d
theorem behrend.map_succ' {n d : ℕ} (a : fin (n + 1) → ℕ) :
theorem behrend.map_mod {n d : ℕ} (a : fin n.succ → ℕ) :
⇑(behrend.map d) a % d = a 0 % d
theorem behrend.map_eq_iff {n d : ℕ} {x₁ x₂ : fin n.succ → ℕ} (hx₁ : ∀ (i : fin n.succ), x₁ i < d) (hx₂ : ∀ (i : fin n.succ), x₂ i < d) :
⇑(behrend.map d) x₁ = ⇑(behrend.map d) x₂ ↔ x₁ 0 = x₂ 0 ∧ ⇑(behrend.map d) (x₁ ∘ fin.succ) = ⇑(behrend.map d) (x₂ ∘ fin.succ)
theorem behrend.map_inj_on {n d : ℕ} :
set.inj_on ⇑(behrend.map d) {x : fin n → ℕ | ∀ (i : fin n), x i < d}
theorem behrend.map_le_of_mem_box {n d : ℕ} {x : fin n → ℕ} (hx : x ∈ behrend.box n d) :
⇑(behrend.map (2 * d - 1)) x ≤ finset.univ.sum (λ (i : fin n), (d - 1) * (2 * d - 1) ^ ↑i)
theorem behrend.sum_sq_le_of_mem_box {n d : ℕ} {x : fin n → ℕ} (hx : x ∈ behrend.box n d) :
finset.univ.sum (λ (i : fin n), x i ^ 2) ≤ n * (d - 1) ^ 2
theorem behrend.sum_eq {n d : ℕ} :
finset.univ.sum (λ (i : fin n), d * (2 * d + 1) ^ ↑i) = ((2 * d + 1) ^ n - 1) / 2
theorem behrend.sum_lt {n d : ℕ} :
finset.univ.sum (λ (i : fin n), d * (2 * d + 1) ^ ↑i) < (2 * d + 1) ^ n

Optimization #

Now that we know how to turn the integer points of any sphere into a Salem-Spencer set, we find a sphere containing many integer points by the pigeonhole principle. This gives us an implicit bound that we then optimize by tweaking the parameters. The (almost) optimal parameters are behrend.n_value and behrend.d_value.

theorem behrend.exists_large_sphere_aux (n d : ℕ) :
∃ (k : ℕ) (H : k ∈ finset.range (n * (d - 1) ^ 2 + 1)), ↑(d ^ n) / (↑(n * (d - 1) ^ 2) + 1) ≤ ↑((behrend.sphere n d k).card)
theorem behrend.exists_large_sphere (n d : ℕ) :
∃ (k : ℕ), ↑d ^ n / ↑(n * d ^ 2) ≤ ↑((behrend.sphere n d k).card)
theorem behrend.bound_aux' (n d : ℕ) :
↑d ^ n / ↑(n * d ^ 2) ≤ ↑(⇑roth_number_nat ((2 * d - 1) ^ n))
theorem behrend.bound_aux {n d : ℕ} (hd : d ≠ 0) (hn : 2 ≤ n) :
↑d ^ (n - 2) / ↑n ≤ ↑(⇑roth_number_nat ((2 * d - 1) ^ n))
theorem behrend.le_sqrt_log {N : ℕ} (hN : 4096 ≤ N) :
real.log (2 / (1 - 2 / rexp 1)) * (69 / 50) ≤ √ (real.log ↑N)
theorem behrend.exp_neg_two_mul_le {x : ℝ} (hx : 0 < x) :
theorem behrend.div_lt_floor {x : ℝ} (hx : 2 / (1 - 2 / rexp 1) ≤ x) :
theorem behrend.ceil_lt_mul {x : ℝ} (hx : 50 / 19 ≤ x) :
↑⌈x⌉₊ < 69 / 50 * x
noncomputable def behrend.n_value (N : ℕ) :

The (almost) optimal value of n in behrend.bound_aux.

Equations
noncomputable def behrend.d_value (N : ℕ) :

The (almost) optimal value of d in behrend.bound_aux.

Equations
theorem behrend.n_value_pos {N : ℕ} (hN : 2 ≤ N) :
theorem behrend.two_le_n_value {N : ℕ} (hN : 3 ≤ N) :
theorem behrend.three_le_n_value {N : ℕ} (hN : 64 ≤ N) :
theorem behrend.d_value_pos {N : ℕ} (hN₃ : 8 ≤ N) :
theorem behrend.le_N {N : ℕ} (hN : 2 ≤ N) :
theorem behrend.bound {N : ℕ} (hN : 4096 ≤ N) :
theorem behrend.roth_lower_bound_explicit {N : ℕ} (hN : 4096 ≤ N) :
theorem behrend.exp_four_lt  :
rexp 4 < 64
theorem behrend.lower_bound_le_one' {N : ℕ} (hN : 2 ≤ N) (hN' : N ≤ 4096) :
↑N * rexp ((-4) * √ (real.log ↑N)) ≤ 1
theorem behrend.lower_bound_le_one {N : ℕ} (hN : 1 ≤ N) (hN' : N ≤ 4096) :
↑N * rexp ((-4) * √ (real.log ↑N)) ≤ 1