op861_no_local_source_rule_counterexample
Six explicit five-vertex acyclic directed graphs refute every ordered-triple source rule: whichever source choice is made for each possible induced ordered triple, one graph uses every vertex as a tail.
Statement
theorem op861_no_local_source_rule_counterexample :
(∀ i x y, localSourceEdges i x y = true → localSourceRank i x < localSourceRank i y) ∧
(∀ a : Fin 3, ∀ b c d e f g : Bool,
(∀ i j z, localSourceEdges i (localSourceTriple j z) (localSourceTail a b c d e f g i j) = false) ∧
∃ i : Fin 6, ∀ v : Fin 5, ∃ j : Fin 10, localSourceTail a b c d e f g i j = v)- Source
- Finite local-rule synthesis in experiments 30758, 30759, and 30768; compared with the four-vertex longest-path construction in https://korandi.org/docs/domination-3tournaments.pdf.
- Verified
- 18 Nov 2026
- Axioms
Classical.choiceQuot.soundpropext
The proof, explained
The theorem is proved by exhaustive finite computation on six explicit 5-vertex directed graphs. First, all six graphs are verified to be acyclic by exhibiting a topological rank function that strictly increases along every directed edge. Second, the finite parameter space of 192 possible local source selection rules is exhaustively checked: every rule is verified to pick an in-degree zero vertex in every induced triple, and for every rule at least one of the six graphs uses all five vertices as tails.
The goal reduces to two independent assertions: verifying that each of the six candidate graphs is acyclic, and verifying that every possible local source selection rule yields full vertex coverage on at least one of the graphs.
The main theorem is a conjunction of an acyclicity condition and a counterexample condition, so applying the constructor separates it into two subgoals.
constructorAll six candidate graphs are directed acyclic graphs. automation
A directed graph is acyclic if there exists a ranking function on its vertices that strictly increases along every directed edge. For each of the six 5-vertex graphs, the preassigned ranking localSourceRank satisfies rank(x) < rank(y) for every directed edge x → y. Because this involves only six graphs and a finite number of vertex pairs, the claim is verified by finite computational evaluation via decide.
· decideEvery valid local source selection rule selects an in-degree zero vertex in each induced triple, yet for each rule at least one of the six graphs uses all five vertices as tails. automation
A local source rule assigns a source vertex to each 3-vertex induced subgraph pattern. With unique sources fixed, the remaining choices are parameterized by a ∈ Fin 3 and six boolean variables b, c, d, e, f, g ∈ Bool, yielding 3 × 2⁶ = 192 candidate rules. The proof introduces the first two parameters a and b, splits them into their 3 × 2 = 6 concrete values, and dispatches each of the six cases using decide. For each case, the evaluator exhaustively checks all combinations of c, d, e, f, g, confirming both that every selected tail has no incoming edge in its triple and that there is a graph index i ∈ {0, ..., 5} whose ten triples select every vertex v ∈ {0, ..., 4} as a tail.
· intro a b fin_cases a <;> cases b <;> decide
- The case split on parameters a and b (fin_cases a <;> cases b) before invoking decide is a performance optimization that keeps Lean's kernel within recursion depth and heartbeat limits; mathematically, the entire search space of 192 rules is finite and decidable at once.
- The ternary encoding localSourcePattern maps each induced 3-vertex subgraph to an integer in [0, 26] based on the directed edges between its vertices. The function localSourceRule hardcodes the unique source vertex for every pattern where only one in-degree zero vertex exists, leaving exactly seven patterns as free parameters (a in Fin 3 and b, c, d, e, f, g in Bool).
Written by a model (gemini-3.8-flash) from the Lean proof and the goal states Lean reported at each step. Lean verified the proof; this explanation is a reading aid and is not itself machine-checked.
Lean source view module on GitHub
Choose a tactic — a marked line — to see the goals Lean had before and after it, as in Lean’s infoview. Step with ← → or j k.
set_option maxRecDepth 32768set_option maxHeartbeats 12000000def localSourceEdges (i : Fin 6) (x y : Fin 5) : Bool := match i.val with | 0 => (x == 1 && y == 3) || (x == 3 && y == 2) || (x == 4 && y == 1) | 1 => (x == 0 && y == 4) || (x == 1 && y == 4) | 2 => (x == 0 && y == 4) || (x == 4 && y == 2) | 3 => (x == 3 && y == 2) || (x == 4 && y == 1) | 4 => (x == 2 && y == 4) || (x == 3 && y == 2) || (x == 4 && y == 1) | _ => (x == 2 && y == 4) || (x == 3 && y == 4) || (x == 4 && y == 1)def localSourceRank : Fin 6 → Fin 5 → ℕ := ![![0,1,3,2,0], ![0,0,0,0,1], ![0,0,2,0,1], ![0,1,1,0,0], ![0,3,1,0,2], ![0,2,0,0,1]]def localSourceTriple : Fin 10 → Fin 3 → Fin 5 := ![![0,1,2], ![0,1,3], ![0,1,4], ![0,2,3], ![0,2,4], ![0,3,4], ![1,2,3], ![1,2,4], ![1,3,4], ![2,3,4]]def localSourceEdgeCode (i : Fin 6) (u v : Fin 5) : ℕ := if localSourceEdges i u v then 1 else if localSourceEdges i v u then 2 else 0def localSourcePattern (i : Fin 6) (j : Fin 10) : ℕ := localSourceEdgeCode i (localSourceTriple j 0) (localSourceTriple j 1) + 3 * localSourceEdgeCode i (localSourceTriple j 0) (localSourceTriple j 2) + 9 * localSourceEdgeCode i (localSourceTriple j 1) (localSourceTriple j 2)def localSourceRule (a : Fin 3) (b c d e f g : Bool) (p : ℕ) : Fin 3 := if p = 0 then a else if p = 9 then if b then 0 else 1 else if p = 18 then if c then 0 else 2 else if p = 3 then if d then 0 else 1 else if p = 12 then if e then 0 else 1 else if p = 6 then if f then 1 else 2 else if p = 2 then if g then 1 else 2 else if p = 21 then 0 else if p = 15 then 1 else if p = 7 then 2 else if p = 5 then 1 else 0def localSourceTail (a : Fin 3) (b c d e f g : Bool) (i : Fin 6) (j : Fin 10) : Fin 5 := localSourceTriple j (localSourceRule a b c d e f g (localSourcePattern i j))theorem op861_no_local_source_rule_counterexample : (∀ i x y, localSourceEdges i x y = true → localSourceRank i x < localSourceRank i y) ∧ (∀ a : Fin 3, ∀ b c d e f g : Bool, (∀ i j z, localSourceEdges i (localSourceTriple j z) (localSourceTail a b c d e f g i j) = false) ∧ ∃ i : Fin 6, ∀ v : Fin 5, ∃ j : Fin 10, localSourceTail a b c d e f g i j = v) := by constructor · decide · intro a b fin_cases a <;> cases b <;> decide