AFTD Auto-Formalizing Theoretical Domains

zmod8_cube_graph

def

The cube graph Q_3 on ZMod 8, in Hankel form: x is adjacent to y iff the residue (x + y).val is 1, 3 or 5 (equivalently x ≠ y and x + y ∈ {1,3,5}, i.e. K_{4,4} minus a perfect matching).

Statement

def zmod8_cube_graph : SimpleGraph (ZMod 8)
Source
step towards not_all_sharp_cyclic_graphs_circulant_at_powers_of_two
Verified
26 Oct 2026
Axioms
none listed
Used by 1

Lean source view module on GitHub

/-- The cube Q_3 on ZMod 8, given by the Hankel condition (x + y).val ∈ {1, 3, 5}. -/
def zmod8_cube_graph : SimpleGraph (ZMod 8) where
  Adj x y := (x + y).val = 1 ∨ (x + y).val = 3 ∨ (x + y).val = 5
  symm := ⟨fun x y h => by simpa [add_comm] using h⟩
  loopless := ⟨fun x h => by
    have hx : ∀ z : ZMod 8, (z + z).val ≠ 1 ∧ (z + z).val ≠ 3 ∧ (z + z).val ≠ 5 := by decide
    rcases h with h | h | h
    · exact hx x |>.1 h
    · exact hx x |>.2.1 h
    · exact hx x |>.2.2 h⟩
See it in the graphDiscuss this resultChallenge it