AFTD Auto-Formalizing Theoretical Domains

petersen_strip_boundary

def

For a natural number k and a finite vertex set S : Finset PetersenStripVertex, petersen_strip_boundary k S is the Finset PetersenStripVertex defined by (S.biUnion N) \ S, where N (u i) = {u (i + 1), u (i - 1), v i} and N (v i) = if k = 0 then {u i} else {u i, v (i + k), v (i - k)}.

Statement

def petersen_strip_boundary (k : ℕ) (S : Finset PetersenStripVertex) : Finset PetersenStripVertex
Defined in
scout/2610-24059-sharp-zero-forcing-numbers-for-the-generalized-petersen-gra.md:191
Verified
27 Oct 2026
Axioms
none listed
Built on 1
  • PetersenStripVertexThe vertex set of the infinite generalized Petersen strip, consisting of outer vertices u_i and inner vertices v_i indexed by integers i…
Used by 4

Read back from the Lean

petersen_strip_boundary k S defines the outer boundary of a finite vertex set S in the Petersen strip graph with jump parameter k : ℕ. The vertices of the graph are given by PetersenStripVertex, which has two infinite rows: u i and v i for integers i : ℤ. The function returns the finite set of vertices outside S that are adjacent to at least one vertex in S, where the adjacency/neighborhood function is defined as: - For u i: the set {u (i + 1), u (i - 1), v i}. - For v i: - If k = 0: the singleton {u i}. - If k ≠ 0: the set {u i, v (i + k), v (i - k)}. The boundary is computed as the union over all vertices in S of their neighbor sets, minus S itself.

Written by a model that saw only the Lean, never the English above. If the two disagree, that is worth a challenge.

Lean source view module on GitHub

/-- The external vertex boundary of a finite vertex set S in the generalized Petersen strip H_k. -/
def petersen_strip_boundary (k : ℕ) (S : Finset PetersenStripVertex) : Finset PetersenStripVertex :=
  (S.biUnion fun
    | .u i => { .u (i + 1), .u (i - 1), .v i }
    | .v i => if k = 0 then { .u i } else { .u i, .v (i + (k : ℤ)), .v (i - (k : ℤ)) }) \ S
See it in the graphDiscuss this resultChallenge it