token_king_sharp_family_indep
For every natural number n divisible by 4 with 8 ≤ n, the candidate sharp family token_king_sharp_family n is an independent set in the two-token graph token_graph (SimpleGraph.cycleGraph n) 2.
Statement
theorem token_king_sharp_family_indep (n : ℕ) (h4 : 4 ∣ n) (hn : 8 ≤ n) :
(token_graph (SimpleGraph.cycleGraph n) 2).IsIndepSet
((token_king_sharp_family n) : Set { s : Finset (Fin n) // s.card = 2 })- Source
- arXiv:2611.22830
- Verified
- 20 Nov 2026
- Axioms
Classical.choiceQuot.soundpropext- Built on 3
- token_king_sharp_familyFor n : ℕ, token_king_sharp_family n is the finset of elements e in { s : Finset (Fin n) // s.card = 2 } for which there exist u, v : Fin…
- cyclic_distThe cyclic distance between two vertices u and v of the n-cycle is the minimum of (u - v) mod n and (v - u) mod n.
- token_graphThe k-token graph F_k(G) of a simple graph G has as vertices the k-subsets of V(G), with two k-subsets adjacent whenever their symmetric…
Read back from the Lean
For any natural number $n$, if $4$ divides $n$ and $n \ge 8$, then the collection of 2-element subsets of $\mathrm{Fin}(n)$ whose elements have cyclic distance equal to $n/2$ or odd cyclic distance at most $n/2 - 3$ forms an independent set in the 2-token graph of the cycle graph on $n$ vertices.
Written by a model that saw only the Lean, never the English above. If the two disagree, that is worth a challenge.
The proof, explained
To show that the candidate sharp family is an independent set in the 2-token graph of the cycle C_n, we argue by contradiction: suppose two 2-sets A and B in the family are adjacent. Adjacency in the 2-token graph implies that A and B share a vertex x and differ at an edge of C_n, so A = {x, y} and B = {x, z} with y and z adjacent on the cycle. Consequently, the cyclic distances from x to y and from x to z must differ by 1 (or wrap around). However, the family only contains pairs whose cyclic distance is either n/2 or an odd number at most n/2 - 3; two consecutive distances cannot both belong to this set because moving by 1 flips parity (preventing odd distances from remaining odd) and cannot reach the isolated even distance n/2.
When u = v, the cyclic distance cyclic_dist n u v equals cyclic_dist n v u.
When u = v, both cyclic_dist n u v and cyclic_dist n v u reduce to min (u - u).val (n - (u - u).val) = min 0 n = 0.
private lemma token_king_sharp_family_indep_cyclic_dist_comm (n : ℕ) [NeZero n] (u v : Fin n) : cyclic_dist n u v = cyclic_dist n v u := by unfold cyclic_dist by_cases huv : u = v · subst huv; simp
The cyclic distance function is symmetric: cyclic_dist n u v = cyclic_dist n v u for all u, v.
When u ≠ v, we have v - u ≠ 0 in Fin n. Since u - v = -(v - u), the Fin negation rule gives (u - v).val = n - (v - u).val. Substituting this into the definition of cyclic distance gives min (n - (v - u).val) (n - (n - (v - u).val)) = min (n - (v - u).val) (v - u).val, which equals min (v - u).val (n - (v - u).val) by commutativity of min.
uses
sub_eq_zero.mp,Fin.val_neg,if_neg,Nat.min_comm· have hv : v - u ≠ 0 := fun h0 => huv (sub_eq_zero.mp h0).symm have h1 : u - v = -(v - u) := by abel have h2 : (u - v).val = n - (v - u).val := by rw [h1, Fin.val_neg, if_neg hv] have h3 : (v - u).val < n := (v - u).isLt rw [h2] have h4 : n - (n - (v - u).val) = (v - u).val := by omega rw [h4] exact Nat.min_comm _ _
Two 2-element subsets A and B adjacent in the 2-token graph intersect in exactly one element, and each set difference has cardinality 1.
Adjacency in the 2-token graph means the symmetric difference A △ B equals a 2-element set {u, v} corresponding to an edge uv in G. Because A \\ B and B \\ A are disjoint and partition A △ B, their cardinalities sum to 2. Using |A \\ B| = |A| - |A ∩ B| = 2 - |A ∩ B| and similarly for B \\ A, linear arithmetic forces |A ∩ B| = 1, |A \\ B| = 1, and |B \\ A| = 1. We obtain unique elements x ∈ A ∩ B, y ∈ A \\ B, and z ∈ B \\ A.
uses
Finset.card_pair,Finset.disjoint_left,Finset.mem_sdiff.mp,Finset.symmDiff_def,Finset.card_union_of_disjoint,Finset.card_le_card,Finset.inter_subset_left,Finset.card_sdiff,Finset.inter_comm,Finset.card_eq_one.mpprivate lemma token_king_sharp_family_indep_two_adj_decomp {V : Type*} [DecidableEq V] (G : SimpleGraph V) (A B : Finset V) (hA : A.card = 2) (hB : B.card = 2) (h : (token_graph G 2).Adj ⟨A, hA⟩ ⟨B, hB⟩) : ∃ x y z : V, x ≠ y ∧ x ≠ z ∧ y ≠ z ∧ A = {x, y} ∧ B = {x, z} ∧ G.Adj y z := by simp only [token_graph] at h obtain ⟨u, v, huv, hdiff⟩ := h have huvne : u ≠ v := G.ne_of_adj huv have hcardUV : ({u, v} : Finset V).card = 2 := Finset.card_pair huvne have hdisj : Disjoint (A \ B) (B \ A) := by rw [Finset.disjoint_left] intro x hx hx' exact (Finset.mem_sdiff.mp hx).2 (Finset.mem_sdiff.mp hx').1 have hdiff' : A \ B ∪ B \ A = {u, v} := by rw [← Finset.symmDiff_def] exact hdiff have hc : (A \ B).card + (B \ A).card = 2 := by rw [← Finset.card_union_of_disjoint hdisj, hdiff', hcardUV] have hk2 : (A ∩ B).card ≤ 2 := by rw [← hA]; exact Finset.card_le_card Finset.inter_subset_left have hca : (A \ B).card = 2 - (A ∩ B).card := by rw [Finset.card_sdiff, hA, Finset.inter_comm] have hcb : (B \ A).card = 2 - (A ∩ B).card := by rw [Finset.card_sdiff, hB] have hk : (A ∩ B).card = 1 := by omega have hcay : (A \ B).card = 1 := by omega have hcbz : (B \ A).card = 1 := by omega obtain ⟨y, hy⟩ := Finset.card_eq_one.mp hcay obtain ⟨z, hz⟩ := Finset.card_eq_one.mp hcbz obtain ⟨x, hx⟩ := Finset.card_eq_one.mp hk
The elements x, y, z are pairwise distinct, with A = {x, y} and B = {x, z}.
Since y ∈ A \\ B and x ∈ B, x ≠ y. Similarly, since z ∈ B \\ A and x ∈ A, x ≠ z, and since y ∉ B and z ∈ B, y ≠ z. Decomposing A as (A \\ B) ∪ (A ∩ B) gives A = {y} ∪ {x} = {x, y}, and similarly B = {z} ∪ {x} = {x, z}.
uses
Finset.mem_singleton_self,Finset.mem_sdiff.mp,Finset.mem_inter.mp,Finset.sdiff_union_interhave hyAB : y ∈ A \ B := by rw [hy]; exact Finset.mem_singleton_self y have hzBA : z ∈ B \ A := by rw [hz]; exact Finset.mem_singleton_self z have hyB : y ∉ B := (Finset.mem_sdiff.mp hyAB).2 have hzB : z ∈ B := (Finset.mem_sdiff.mp hzBA).1 have hzA : z ∉ A := (Finset.mem_sdiff.mp hzBA).2 have hxA : x ∈ A ∩ B := by rw [hx]; exact Finset.mem_singleton_self x have hxA' : x ∈ A := (Finset.mem_inter.mp hxA).1 have hxB : x ∈ B := (Finset.mem_inter.mp hxA).2 have hxy : x ≠ y := fun hh => hyB (hh ▸ hxB) have hxz : x ≠ z := fun hh => hzA (hh ▸ hxA') have hyz : y ≠ z := fun hh => hyB (hh ▸ hzB) have hAxy : A = {x, y} := by rw [← Finset.sdiff_union_inter A B, hy, hx] ext w; simp only [Finset.mem_union, Finset.mem_insert, Finset.mem_singleton]; tauto have hBxz : B = {x, z} := by have h := Finset.sdiff_union_inter B A rw [Finset.inter_comm] at h rw [← h, hz, hx] ext w; simp only [Finset.mem_union, Finset.mem_insert, Finset.mem_singleton]; tauto
The pair {y, z} equals the edge {u, v}, so y is adjacent to z in G.
The union (A \\ B) ∪ (B \\ A) = {y, z} equals the symmetric difference {u, v}. Since {y, z} = {u, v} and G has an edge between u and v, y and z must be adjacent in G.
have hpair : ({y, z} : Finset V) = {u, v} := by rw [← hdiff', hy, hz] ext w; simp [Finset.mem_insert, Finset.mem_singleton] have hyuv : y = u ∨ y = v := by have : y ∈ ({u, v} : Finset V) := by rw [← hpair]; simp simpa using this have hzuv : z = u ∨ z = v := by have : z ∈ ({u, v} : Finset V) := by rw [← hpair]; simp simpa using this refine ⟨x, y, z, hxy, hxz, hyz, hAxy, hBxz, ?_⟩ rcases hyuv with rfl | rfl · rcases hzuv with rfl | rfl · exact absurd rfl hyz · exact huv · rcases hzuv with rfl | rfl · exact huv.symm · exact absurd rfl hyz
In Fin n, the successor condition q = (p + 1) % n splits into q = p + 1 or the wraparound case p = n - 1, q = 0.
Since p < n, either p + 1 < n (so (p + 1) % n = p + 1) or p + 1 = n (so p = n - 1 and q = n % n = 0).
uses
Nat.lt_or_eq_of_le,Nat.mod_eq_of_lt,Nat.mod_selfprivate lemma token_king_sharp_family_indep_arith (n : ℕ) (hn : 8 ≤ n) (h4 : 4 ∣ n) (p q : ℕ) (hp : p < n) (hq : q < n) (hqp : q = (p + 1) % n) (ha : min p (n - p) = n / 2 ∨ (min p (n - p) ≤ n / 2 - 3 ∧ min p (n - p) % 2 = 1)) (hb : min q (n - q) = n / 2 ∨ (min q (n - q) ≤ n / 2 - 3 ∧ min q (n - q) % 2 = 1)) : False := by obtain ⟨k, hk⟩ := h4 have hn2 : n = 2 * (n / 2) := by omega have hqdec : q = p + 1 ∨ (p = n - 1 ∧ q = 0) := by have hp1 : p + 1 ≤ n := by omega rcases Nat.lt_or_eq_of_le hp1 with h | h · left; rw [hqp, Nat.mod_eq_of_lt h] · right refine ⟨by omega, ?_⟩ rw [hqp, ← h, Nat.mod_self] rcases hqdec with hq1 | ⟨hpfirst, hq0⟩
If q = p + 1 and min p (n - p) = n / 2, the distance condition on q leads to a contradiction.
When min p (n - p) = n / 2, we must have p = n / 2. Then q = p + 1 = n / 2 + 1, so the cyclic distance for q is min (n / 2 + 1) (n / 2 - 1) = n / 2 - 1. But n / 2 - 1 is neither equal to n / 2 nor at most n / 2 - 3 (since n ≥ 8), contradicting the hypothesis that q satisfies the distance condition.
uses
min_eq_left,min_eq_right,le_of_lt,Nat.lt_of_not_le· subst hq1 rcases ha with ha1 | ⟨ha_le, ha_odd⟩ · have hp_eq : p = n / 2 := by by_cases hh : p ≤ n - p · rw [min_eq_left hh] at ha1; exact ha1 · rw [min_eq_right (le_of_lt (Nat.lt_of_not_le hh))] at ha1; omega have hbval : min (p + 1) (n - (p + 1)) = n / 2 - 1 := by have h1 : n - (p + 1) ≤ p + 1 := by omega rw [min_eq_right h1]; omega rw [hbval] at hb rcases hb with h | ⟨h, _⟩ <;> omega
If q = p + 1 and min p (n - p) ≤ n / 2 - 3 is odd, the distance condition on q leads to a contradiction.
Let d = min p (n - p). Either p = d or p = n - d. In the first case, p ≤ n / 2 - 3, so q = p + 1 ≤ n / 2 - 2, and min q (n - q) = p + 1 = d + 1. Since d is odd, d + 1 is even, so it cannot be odd, and since d + 1 ≤ n / 2 - 2 < n / 2, it cannot equal n / 2. In the second case, p = n - d, so q = n - (d - 1), yielding min q (n - q) = d - 1, which is likewise even and strictly less than n / 2. Thus q cannot satisfy the distance condition.
uses
min_eq_left,min_eq_right· have hp_cases : p = min p (n - p) ∨ p = n - min p (n - p) := by by_cases hh : p ≤ n - p · left; rw [min_eq_left hh] · right have hmin : min p (n - p) = n - p := min_eq_right (le_of_lt (Nat.lt_of_not_le hh)) omega rcases hp_cases with hpA | hpB · have hpodd : p % 2 = 1 := by rw [hpA]; exact ha_odd have hple : p ≤ n / 2 - 3 := by rw [hpA]; exact ha_le have hbval : min (p + 1) (n - (p + 1)) = p + 1 := by rw [min_eq_left]; omega rw [hbval] at hb have hmod : (p + 1) % 2 = 0 := by omega rcases hb with h | ⟨h, hodd⟩ <;> omega · have hpodd : (min p (n - p)) % 2 = 1 := ha_odd have hbval : min (p + 1) (n - (p + 1)) = min p (n - p) - 1 := by have h1 : n - (p + 1) ≤ p + 1 := by omega rw [min_eq_right h1]; omega rw [hbval] at hb have hmod : (min p (n - p) - 1) % 2 = 0 := by omega rcases hb with h | ⟨h, hodd⟩ <;> omega
The wraparound case p = n - 1, q = 0 is impossible.
When q = 0, min q (n - q) = 0. But 0 is neither equal to n / 2 (since n ≥ 8) nor odd, violating the distance condition on q.
· have hb0 : min q (n - q) = 0 := by rw [hq0]; simp rw [hb0] at hb rcases hb with h | ⟨h, hodd⟩ <;> omega
Any unordered pair {x, y} representing a vertex in the candidate sharp family satisfies the cyclic distance condition.
A vertex e in the sharp family is defined as a pair {u, v} satisfying the cyclic distance condition. If e = {x, y}, then either (u = x and v = y) or (u = y and v = x). In the former case the condition holds directly; in the latter it holds for cyclic_dist n y x, which equals cyclic_dist n x y by symmetry of the cyclic distance.
uses
true_and,token_king_sharp_family_indep_cyclic_dist_commprivate lemma token_king_sharp_family_indep_cond_of_mem {n : ℕ} (e : { s : Finset (Fin n) // s.card = 2 }) (he : e ∈ token_king_sharp_family n) (x y : Fin n) (h : e.val = {x, y}) : cyclic_dist n x y = n / 2 ∨ (cyclic_dist n x y ≤ n / 2 - 3 ∧ cyclic_dist n x y % 2 = 1) := by haveI : NeZero n := ⟨by have := x.isLt; omega⟩ simp only [token_king_sharp_family, Finset.mem_filter, Finset.mem_univ, true_and] at he obtain ⟨u, v, huv, hcond⟩ := he have hc : ({u, v} : Finset (Fin n)).card = 2 := by rw [← huv]; exact e.property have hune : u ≠ v := by intro hh rw [hh] at hc simp at hc have huv_eq : ({u, v} : Finset (Fin n)) = {x, y} := by rw [← huv, h] have hu : u = x ∨ u = y := by have : u ∈ ({x, y} : Finset (Fin n)) := by rw [← huv_eq]; simp simpa using this have hv : v = x ∨ v = y := by have : v ∈ ({x, y} : Finset (Fin n)) := by rw [← huv_eq]; simp simpa using this rcases hu with hux | huy · rcases hv with hvx | hvy · exact absurd (hux.trans hvx.symm) hune · rw [hux, hvy] at hcond; exact hcond · rcases hv with hvx | hvy · rw [huy, hvx] at hcond rw [token_king_sharp_family_indep_cyclic_dist_comm n y x] at hcond exact hcond · exact absurd (huy.trans hvy.symm) hune
If (y - z).val = 1, the offsets from x to y and z cannot both satisfy the candidate distance condition.
Since x - z = (x - y) + (y - z) in Fin n, we have (x - z).val = ((x - y).val + 1) % n. Setting p = (x - y).val and q = (x - z).val, both p and q would satisfy the candidate distance condition, which contradicts the arithmetic lemma.
uses
Fin.val_add,token_king_sharp_family_indep_arithprivate lemma token_king_sharp_family_indep_key_fin (n : ℕ) (hn : 8 ≤ n) (h4 : 4 ∣ n) (x y z : Fin n) (hy : cyclic_dist n x y = n / 2 ∨ (cyclic_dist n x y ≤ n / 2 - 3 ∧ cyclic_dist n x y % 2 = 1)) (hz : cyclic_dist n x z = n / 2 ∨ (cyclic_dist n x z ≤ n / 2 - 3 ∧ cyclic_dist n x z % 2 = 1)) (hyz : (y - z).val = 1) : False := by haveI : NeZero n := ⟨by have := x.isLt; omega⟩ have hq : (x - z).val = ((x - y).val + 1) % n := by have h1 : x - z = (x - y) + (y - z) := by abel rw [h1, Fin.val_add, hyz] exact token_king_sharp_family_indep_arith n hn h4 (x - y).val (x - z).val (x - y).isLt (x - z).isLt hq (by simpa [cyclic_dist] using hy) (by simpa [cyclic_dist] using hz)
Assuming two vertices e, e' of the candidate sharp family are adjacent, they decompose as {x, y} and {x, z} with y and z adjacent in the cycle graph.
Assume for contradiction that e and e' are adjacent in the 2-token graph of C_n. By the decomposition lemma for 2-token graphs, there exist pairwise distinct vertices x, y, z such that e = {x, y}, e' = {x, z}, and y is adjacent to z in C_n.
uses
SimpleGraph.IsIndepSet,token_king_sharp_family_indep_two_adj_decomp/-- When 4 divides n >= 8, the candidate sharpness family is independent in the two-token cycle graph. -/ theorem token_king_sharp_family_indep (n : ℕ) (h4 : 4 ∣ n) (hn : 8 ≤ n) : (token_graph (SimpleGraph.cycleGraph n) 2).IsIndepSet ((token_king_sharp_family n) : Set { s : Finset (Fin n) // s.card = 2 }) := by rw [SimpleGraph.IsIndepSet] intro e he e' he' hne hcon obtain ⟨x, y, z, hxy, hxz, hyz, hA, hB, hyzadj⟩ := token_king_sharp_family_indep_two_adj_decomp (SimpleGraph.cycleGraph n) e.val e'.val e.property e'.property hcon
The candidate sharp family is an independent set in the 2-token cycle graph.
Since e and e' belong to the candidate sharp family, the cyclic distances cyclic_dist n x y and cyclic_dist n x z both satisfy the distance condition. Adjacency of y and z in C_n means either (y - z).val = 1 or (z - y).val = 1. In both cases, the key lemma shows this configuration is impossible, establishing that no two vertices of the family can be adjacent.
uses
token_king_sharp_family_indep_cond_of_mem,SimpleGraph.cycleGraph_adj'.mp,token_king_sharp_family_indep_key_finhave he1 : e ∈ token_king_sharp_family n := by simpa using he have he2 : e' ∈ token_king_sharp_family n := by simpa using he' have hycond := token_king_sharp_family_indep_cond_of_mem e he1 x y hA have hzcond := token_king_sharp_family_indep_cond_of_mem e' he2 x z hB rcases SimpleGraph.cycleGraph_adj'.mp hyzadj with h | h · exact token_king_sharp_family_indep_key_fin n hn h4 x y z hycond hzcond h · exact token_king_sharp_family_indep_key_fin n hn h4 x z y hzcond hycond h
sub_eq_zero.mp- If a - b = 0, then a = b.
Fin.val_neg- For a non-zero element x in Fin n, (-x).val = n - x.val.
if_neg- If c is false, then (if c then t else e) = e.
Nat.min_comm- The minimum function on natural numbers is commutative.
Finset.card_pair- A set of two distinct elements has cardinality 2.
Finset.disjoint_left- Two finite sets are disjoint iff no element of the first belongs to the second.
Finset.symmDiff_def- The symmetric difference of s and t is (s \\ t) ∪ (t \\ s).
Finset.card_union_of_disjoint- The cardinality of the union of disjoint sets is the sum of their cardinalities.
Finset.card_le_card- If s ⊆ t, then |s| ≤ |t|.
Finset.inter_subset_left- The intersection s₁ ∩ s₂ is a subset of s₁.
Finset.card_sdiff- The cardinality of t \\ s is |t| - |s ∩ t|.
Finset.inter_comm- Set intersection is commutative: s₁ ∩ s₂ = s₂ ∩ s₁.
Finset.card_eq_one.mp- If a finite set has cardinality 1, it is a singleton {a}.
Finset.mem_sdiff.mp- If x ∈ s \\ t, then x ∈ s and x ∉ t.
Finset.mem_singleton_self- An element belongs to the singleton set containing it: a ∈ {a}.
Finset.mem_inter.mp- If x ∈ s ∩ t, then x ∈ s and x ∈ t.
Finset.sdiff_union_inter- For any sets s and t, (s \\ t) ∪ (s ∩ t) = s.
Nat.lt_or_eq_of_le- If n ≤ m, then n < m or n = m.
Nat.mod_eq_of_lt- If a < b, then a % b = a.
Nat.mod_self- For any natural number n, n % n = 0.
min_eq_left- If a ≤ b, then min a b = a.
min_eq_right- If b ≤ a, then min a b = b.
le_of_lt- If a < b, then a ≤ b.
Nat.lt_of_not_le- If not a ≤ b, then b < a.
true_and- True ∧ p is equivalent to p.
token_king_sharp_family_indep_cyclic_dist_comm- Cyclic distance is symmetric: cyclic_dist n u v = cyclic_dist n v u.
Fin.val_add- The numerical value of (a + b) in Fin n is (a.val + b.val) % n.
token_king_sharp_family_indep_arith- Consecutive offsets on a cycle of length n ≥ 8 divisible by 4 cannot both satisfy the candidate distance condition.
SimpleGraph.IsIndepSet- A vertex set is independent if no two distinct vertices in it are adjacent.
token_king_sharp_family_indep_two_adj_decomp- Two 2-element sets adjacent in the 2-token graph share an element x and differ by an edge yz of the base graph.
token_king_sharp_family_indep_cond_of_mem- Any pair {x, y} representing a member of the candidate sharp family satisfies the cyclic distance condition.
SimpleGraph.cycleGraph_adj'.mp- In the cycle graph C_n, vertices u and v are adjacent iff (u - v).val = 1 or (v - u).val = 1.
token_king_sharp_family_indep_key_fin- Vertices y, z with (y - z).val = 1 cannot both have their cyclic distances to x satisfy the candidate distance condition.
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.
private lemma token_king_sharp_family_indep_cyclic_dist_comm (n : ℕ) [NeZero n] (u v : Fin n) : cyclic_dist n u v = cyclic_dist n v u := by unfold cyclic_dist by_cases huv : u = v · subst huv; simp · have hv : v - u ≠ 0 := fun h0 => huv (sub_eq_zero.mp h0).symm have h1 : u - v = -(v - u) := by abel have h2 : (u - v).val = n - (v - u).val := by rw [h1, Fin.val_neg, if_neg hv] have h3 : (v - u).val < n := (v - u).isLt rw [h2] have h4 : n - (n - (v - u).val) = (v - u).val := by omega rw [h4] exact Nat.min_comm _ _private lemma token_king_sharp_family_indep_two_adj_decomp {V : Type*} [DecidableEq V] (G : SimpleGraph V) (A B : Finset V) (hA : A.card = 2) (hB : B.card = 2) (h : (token_graph G 2).Adj ⟨A, hA⟩ ⟨B, hB⟩) : ∃ x y z : V, x ≠ y ∧ x ≠ z ∧ y ≠ z ∧ A = {x, y} ∧ B = {x, z} ∧ G.Adj y z := by simp only [token_graph] at h obtain ⟨u, v, huv, hdiff⟩ := h have huvne : u ≠ v := G.ne_of_adj huv have hcardUV : ({u, v} : Finset V).card = 2 := Finset.card_pair huvne have hdisj : Disjoint (A \ B) (B \ A) := by rw [Finset.disjoint_left] intro x hx hx' exact (Finset.mem_sdiff.mp hx).2 (Finset.mem_sdiff.mp hx').1 have hdiff' : A \ B ∪ B \ A = {u, v} := by rw [← Finset.symmDiff_def] exact hdiff have hc : (A \ B).card + (B \ A).card = 2 := by rw [← Finset.card_union_of_disjoint hdisj, hdiff', hcardUV] have hk2 : (A ∩ B).card ≤ 2 := by rw [← hA]; exact Finset.card_le_card Finset.inter_subset_left have hca : (A \ B).card = 2 - (A ∩ B).card := by rw [Finset.card_sdiff, hA, Finset.inter_comm] have hcb : (B \ A).card = 2 - (A ∩ B).card := by rw [Finset.card_sdiff, hB] have hk : (A ∩ B).card = 1 := by omega have hcay : (A \ B).card = 1 := by omega have hcbz : (B \ A).card = 1 := by omega obtain ⟨y, hy⟩ := Finset.card_eq_one.mp hcay obtain ⟨z, hz⟩ := Finset.card_eq_one.mp hcbz obtain ⟨x, hx⟩ := Finset.card_eq_one.mp hk have hyAB : y ∈ A \ B := by rw [hy]; exact Finset.mem_singleton_self y have hzBA : z ∈ B \ A := by rw [hz]; exact Finset.mem_singleton_self z have hyB : y ∉ B := (Finset.mem_sdiff.mp hyAB).2 have hzB : z ∈ B := (Finset.mem_sdiff.mp hzBA).1 have hzA : z ∉ A := (Finset.mem_sdiff.mp hzBA).2 have hxA : x ∈ A ∩ B := by rw [hx]; exact Finset.mem_singleton_self x have hxA' : x ∈ A := (Finset.mem_inter.mp hxA).1 have hxB : x ∈ B := (Finset.mem_inter.mp hxA).2 have hxy : x ≠ y := fun hh => hyB (hh ▸ hxB) have hxz : x ≠ z := fun hh => hzA (hh ▸ hxA') have hyz : y ≠ z := fun hh => hyB (hh ▸ hzB) have hAxy : A = {x, y} := by rw [← Finset.sdiff_union_inter A B, hy, hx] ext w; simp only [Finset.mem_union, Finset.mem_insert, Finset.mem_singleton]; tauto have hBxz : B = {x, z} := by have h := Finset.sdiff_union_inter B A rw [Finset.inter_comm] at h rw [← h, hz, hx] ext w; simp only [Finset.mem_union, Finset.mem_insert, Finset.mem_singleton]; tauto have hpair : ({y, z} : Finset V) = {u, v} := by rw [← hdiff', hy, hz] ext w; simp [Finset.mem_insert, Finset.mem_singleton] have hyuv : y = u ∨ y = v := by have : y ∈ ({u, v} : Finset V) := by rw [← hpair]; simp simpa using this have hzuv : z = u ∨ z = v := by have : z ∈ ({u, v} : Finset V) := by rw [← hpair]; simp simpa using this refine ⟨x, y, z, hxy, hxz, hyz, hAxy, hBxz, ?_⟩ rcases hyuv with rfl | rfl · rcases hzuv with rfl | rfl · exact absurd rfl hyz · exact huv · rcases hzuv with rfl | rfl · exact huv.symm · exact absurd rfl hyzprivate lemma token_king_sharp_family_indep_arith (n : ℕ) (hn : 8 ≤ n) (h4 : 4 ∣ n) (p q : ℕ) (hp : p < n) (hq : q < n) (hqp : q = (p + 1) % n) (ha : min p (n - p) = n / 2 ∨ (min p (n - p) ≤ n / 2 - 3 ∧ min p (n - p) % 2 = 1)) (hb : min q (n - q) = n / 2 ∨ (min q (n - q) ≤ n / 2 - 3 ∧ min q (n - q) % 2 = 1)) : False := by obtain ⟨k, hk⟩ := h4 have hn2 : n = 2 * (n / 2) := by omega have hqdec : q = p + 1 ∨ (p = n - 1 ∧ q = 0) := by have hp1 : p + 1 ≤ n := by omega rcases Nat.lt_or_eq_of_le hp1 with h | h · left; rw [hqp, Nat.mod_eq_of_lt h] · right refine ⟨by omega, ?_⟩ rw [hqp, ← h, Nat.mod_self] rcases hqdec with hq1 | ⟨hpfirst, hq0⟩ · subst hq1 rcases ha with ha1 | ⟨ha_le, ha_odd⟩ · have hp_eq : p = n / 2 := by by_cases hh : p ≤ n - p · rw [min_eq_left hh] at ha1; exact ha1 · rw [min_eq_right (le_of_lt (Nat.lt_of_not_le hh))] at ha1; omega have hbval : min (p + 1) (n - (p + 1)) = n / 2 - 1 := by have h1 : n - (p + 1) ≤ p + 1 := by omega rw [min_eq_right h1]; omega rw [hbval] at hb rcases hb with h | ⟨h, _⟩ <;> omega · have hp_cases : p = min p (n - p) ∨ p = n - min p (n - p) := by by_cases hh : p ≤ n - p · left; rw [min_eq_left hh] · right have hmin : min p (n - p) = n - p := min_eq_right (le_of_lt (Nat.lt_of_not_le hh)) omega rcases hp_cases with hpA | hpB · have hpodd : p % 2 = 1 := by rw [hpA]; exact ha_odd have hple : p ≤ n / 2 - 3 := by rw [hpA]; exact ha_le have hbval : min (p + 1) (n - (p + 1)) = p + 1 := by rw [min_eq_left]; omega rw [hbval] at hb have hmod : (p + 1) % 2 = 0 := by omega rcases hb with h | ⟨h, hodd⟩ <;> omega · have hpodd : (min p (n - p)) % 2 = 1 := ha_odd have hbval : min (p + 1) (n - (p + 1)) = min p (n - p) - 1 := by have h1 : n - (p + 1) ≤ p + 1 := by omega rw [min_eq_right h1]; omega rw [hbval] at hb have hmod : (min p (n - p) - 1) % 2 = 0 := by omega rcases hb with h | ⟨h, hodd⟩ <;> omega · have hb0 : min q (n - q) = 0 := by rw [hq0]; simp rw [hb0] at hb rcases hb with h | ⟨h, hodd⟩ <;> omegaprivate lemma token_king_sharp_family_indep_cond_of_mem {n : ℕ} (e : { s : Finset (Fin n) // s.card = 2 }) (he : e ∈ token_king_sharp_family n) (x y : Fin n) (h : e.val = {x, y}) : cyclic_dist n x y = n / 2 ∨ (cyclic_dist n x y ≤ n / 2 - 3 ∧ cyclic_dist n x y % 2 = 1) := by haveI : NeZero n := ⟨by have := x.isLt; omega⟩ simp only [token_king_sharp_family, Finset.mem_filter, Finset.mem_univ, true_and] at he obtain ⟨u, v, huv, hcond⟩ := he have hc : ({u, v} : Finset (Fin n)).card = 2 := by rw [← huv]; exact e.property have hune : u ≠ v := by intro hh rw [hh] at hc simp at hc have huv_eq : ({u, v} : Finset (Fin n)) = {x, y} := by rw [← huv, h] have hu : u = x ∨ u = y := by have : u ∈ ({x, y} : Finset (Fin n)) := by rw [← huv_eq]; simp simpa using this have hv : v = x ∨ v = y := by have : v ∈ ({x, y} : Finset (Fin n)) := by rw [← huv_eq]; simp simpa using this rcases hu with hux | huy · rcases hv with hvx | hvy · exact absurd (hux.trans hvx.symm) hune · rw [hux, hvy] at hcond; exact hcond · rcases hv with hvx | hvy · rw [huy, hvx] at hcond rw [token_king_sharp_family_indep_cyclic_dist_comm n y x] at hcond exact hcond · exact absurd (huy.trans hvy.symm) huneprivate lemma token_king_sharp_family_indep_key_fin (n : ℕ) (hn : 8 ≤ n) (h4 : 4 ∣ n) (x y z : Fin n) (hy : cyclic_dist n x y = n / 2 ∨ (cyclic_dist n x y ≤ n / 2 - 3 ∧ cyclic_dist n x y % 2 = 1)) (hz : cyclic_dist n x z = n / 2 ∨ (cyclic_dist n x z ≤ n / 2 - 3 ∧ cyclic_dist n x z % 2 = 1)) (hyz : (y - z).val = 1) : False := by haveI : NeZero n := ⟨by have := x.isLt; omega⟩ have hq : (x - z).val = ((x - y).val + 1) % n := by have h1 : x - z = (x - y) + (y - z) := by abel rw [h1, Fin.val_add, hyz] exact token_king_sharp_family_indep_arith n hn h4 (x - y).val (x - z).val (x - y).isLt (x - z).isLt hq (by simpa [cyclic_dist] using hy) (by simpa [cyclic_dist] using hz)/-- When 4 divides n >= 8, the candidate sharpness family is independent in the two-token cycle graph. -/theorem token_king_sharp_family_indep (n : ℕ) (h4 : 4 ∣ n) (hn : 8 ≤ n) : (token_graph (SimpleGraph.cycleGraph n) 2).IsIndepSet ((token_king_sharp_family n) : Set { s : Finset (Fin n) // s.card = 2 }) := by rw [SimpleGraph.IsIndepSet] intro e he e' he' hne hcon obtain ⟨x, y, z, hxy, hxz, hyz, hA, hB, hyzadj⟩ := token_king_sharp_family_indep_two_adj_decomp (SimpleGraph.cycleGraph n) e.val e'.val e.property e'.property hcon have he1 : e ∈ token_king_sharp_family n := by simpa using he have he2 : e' ∈ token_king_sharp_family n := by simpa using he' have hycond := token_king_sharp_family_indep_cond_of_mem e he1 x y hA have hzcond := token_king_sharp_family_indep_cond_of_mem e' he2 x z hB rcases SimpleGraph.cycleGraph_adj'.mp hyzadj with h | h · exact token_king_sharp_family_indep_key_fin n hn h4 x y z hycond hzcond h · exact token_king_sharp_family_indep_key_fin n hn h4 x z y hzcond hycond h