Prove2Me
Navigate
DiscoverCollectionsFormalpediaBlogsUsersMomentumMy Missions+
Prove2Me
⌕
Log in
← Formalpedia

Target-last absorption of 222 after (0,1,−1)(0,1,-1)(0,1,−1) forces a released word

Proved
Erdos195.target_last_released

by Ethan Cheung Wang · Oct 23, 2026 · Mathlib 0df444a (Lean v4.33.1)

arithmetic-progressionscombinatoricserdos-problems

A tree witness is a function θ(k,r)∈{0,1}\theta(k,r)\in\{0,1\}θ(k,r)∈{0,1} on the nodes (k,r)(k,r)(k,r), 0≤r<2k0\le r<2^k0≤r<2k, of the binary tree of residues. For distinct integers x,yx,yx,y with k=ν2(y−x)k=\nu_2(y-x)k=ν2​(y−x), put x≺θyx\prec_\theta yx≺θ​y iff bitk(x)=θ(k, x mod 2k)\mathrm{bit}_k(x)=\theta(k,\,x\bmod 2^k)bitk​(x)=θ(k,xmod2k). A finite word QQQ of integers is θ\thetaθ-safe if the sequence "the letters of QQQ in order, then all remaining integers in ≺θ\prec_\theta≺θ​-order" contains no monotone 444-term arithmetic progression. For letters aaa before bbb in QQQ, the pair (a,b)(a,b)(a,b) is OPEN if neither 2b−a2b-a2b−a nor 3b−2a3b-2a3b−2a occurs in QQQ. Let θ\thetaθ be any tree witness and let A=(0,1,−1,r1,…,rm,2)A=(0,1,-1,r_1,\dots,r_m,2)A=(0,1,−1,r1​,…,rm​,2) be a word with 2∉{r1,…,rm}2\notin\{r_1,\dots,r_m\}2∈/{r1​,…,rm​}. If AAA is θ\thetaθ-safe, then θ(0,0)=0\theta(0,0)=0θ(0,0)=0, and AAA is RELEASED:

every OPEN pair (a,b) of A with b−a odd has b even.\text{every OPEN pair }(a,b)\text{ of }A\text{ with }b-a\text{ odd has }b\text{ even.}every OPEN pair (a,b) of A with b−a odd has b even.

So absorbing the target 222 as the last letter after the prefix (0,1,−1)(0,1,-1)(0,1,−1) is only possible by a released word. The proof (following GPT Astra) compares the extremes of AAA via the extremal-parity lemma, applied to AAA and to its normalized odd half.

Formalization note: treeLt θ is from Definitions.Def_Erdos195_tree, and Safe is from Definitions.Def_Erdos195_defs. Positions are List.idxOf; the word is written (0 :: 1 :: -1 :: rest) ++ [2], and the hypothesis 2∉rest2\notin\mathrm{rest}2∈/rest makes 222 the last letter and its only occurrence.

Preamble
import Mathlib
import Definitions.Def_Erdos195_tree
Formal statement
namespace Erdos195

theorem target_last_released (θ : ℕ → ℤ → Bool) (A rest : List ℤ)
    (hA : A = (0 :: 1 :: -1 :: rest) ++ [2]) (h2 : (2 : ℤ) ∉ rest)
    (hS : Safe (treeLt θ) A) :
    θ 0 0 = false ∧
    ∀ a b : ℤ, a ∈ A → b ∈ A → A.idxOf a < A.idxOf b → (b - a) % 2 = 1 →
      2 * b - a ∉ A → 3 * b - 2 * a ∉ A → b % 2 = 0 := by sorry

end Erdos195
Source
Erdős Problem 195 (https://www.erdosproblems.com/195); tree-witness framework; argument by GPT Astra, Lean-verified by Grok Bot for Ethan Cheung (Oct 23 2026)

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, with reuse governed by our licensing terms.

How Prove2Me worksResearch paper
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me