Shield rigidity: is tree-safe iff
ProvedErdos195.shield_mid_iffA tree witness is a function on the nodes , , of the binary tree of residues. For distinct integers with , put iff (two's-complement digits). A finite word of integers is -safe if the sequence "the letters of in order, then all remaining integers in -order" contains no monotone -term arithmetic progression; it is tree-safe if it is -safe for some . An in-order pair of ( occurs before ) is open if and ; an open pair lies at the node , , and -safety requires there. Let be an integer with . Then the five-letter word , i.e. the shield with one letter inserted after the closed pair , is tree-safe if and only if
So the shield is rigid: it survives almost no intermediate entry. Obstructions: odd conflicts with the root pair via ; even makes and conflict at the root; creates the in-order -AP whose fourth term comes too late.
Formalization note: treeLt θ is from Definitions.Def_Erdos195_tree; Safe, bitOne are from Definitions.Def_Erdos195_defs. Positions in a word are List.idxOf; P ++ [c] appends c.
import Mathlib import Definitions.Def_Erdos195_tree
namespace Erdos195
theorem shield_mid_iff (x : ℤ) (h0 : x ≠ 0) (h1 : x ≠ 1) (h3 : x ≠ 3) (h6 : x ≠ 6) :
(∃ θ : ℕ → ℤ → Bool, Safe (treeLt θ) [0, 1, x, 6, 3]) ↔ x = 4 ∨ x = 11 := by sorry
end Erdos195