The even-N upper bound (Erdős 865, §4) #
Strong induction on N proving even_bound: every triple-free A ⊆ [1, 2e] satisfies the
5/8 counting bound, split into the cases even_bound_case1 and even_bound_case2.
theorem
Erdos865.even_bound_case1
{H p q : ℕ}
{A : Finset ℕ}
(hsub : A ⊆ Finset.Icc 1 (2 * H))
(hA : IsTripleFree A)
(hq : q ∈ A)
(hqlo : H ≤ q)
(hqhi : q ≤ 2 * H)
(hqmin : ∀ a ∈ A, H ≤ a → q ≤ a)
(_hp : p ∈ A)
(_hplo : 1 ≤ p)
(hphi : p ≤ H)
(hpmax : ∀ a ∈ A, a ≤ H → a ≤ p)
(hcase : q - H ≤ 4 * (H - p))
:
A subset of a triple-free set is triple-free.
theorem
Erdos865.even_bound_case2
{H p q : ℕ}
{A : Finset ℕ}
(hsub : A ⊆ Finset.Icc 1 (2 * H))
(hA : IsTripleFree A)
(hqlo : H ≤ q)
(hqhi : q ≤ 2 * H)
(hqmin : ∀ a ∈ A, H ≤ a → q ≤ a)
(hp : p ∈ A)
(hplo : 1 ≤ p)
(hphi : p ≤ H)
(hpmax : ∀ a ∈ A, a ≤ H → a ≤ p)
(hcase : 4 * (H - p) < q - H)
(IH : ∀ (H' : ℕ) (A' : Finset ℕ), H' < H → A' ⊆ Finset.Icc 1 (2 * H') → IsTripleFree A' → 4 * A'.card ≤ 5 * H' + 24)
:
theorem
Erdos865.even_bound
(H : ℕ)
(A : Finset ℕ)
(hsub : A ⊆ Finset.Icc 1 (2 * H))
(hA : IsTripleFree A)
: