AFTD Auto-Formalizing Theoretical Domains

CleanHandshakeSeq

inductive

Inductive predicate stating that a sequence of handshakes is clean when executed starting from an initial contamination map $t$.

Statement

inductive CleanHandshakeSeq {V : Type*} {Γ : Type*} [DecidableEq Γ] : List (Handshake V Γ) → (Γ × Bool → Set V) → Prop
Defined in
scout/2610-17602-clean-handshake-sequences.md:222
Verified
18 Oct 2026
Axioms
none listed
Built on 3
  • HandshakeA handshake between vertices in $V$ using gloves from $\Gamma$, which is either single-gloved (one vertex wears a glove side inside, the…
  • handshake_is_cleanA handshake is clean with respect to a contamination map $t : \Gamma \times \mathrm{Bool} \to \mathrm{Set}(V)$ if no player directly…
  • handshake_update_contamThe updated contamination map after a handshake: players add their germs to the glove sides they touch directly, and in a double handshake…
Used by 9

Read back from the Lean

An inductive predicate CleanHandshakeSeq parameterized by types V and Γ (with [DecidableEq Γ]), taking a sequence of handshakes seq : List (Handshake V Γ) and a contamination map t : Γ × Bool → Set V. It asserts that the sequence of handshakes can be executed cleanly without cross-contamination starting from state t: 1. nil: For any initial contamination state t, the empty sequence [] is clean. 2. cons: A non-empty sequence h :: seq is clean from state t if: - handshake_is_clean h t holds for the first handshake h, and - CleanHandshakeSeq seq (handshake_update_contam h t) holds for the remaining handshakes under the contamination state updated by h.

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

/-- Predicate asserting a sequence of handshakes is clean starting from a contamination state. -/
inductive CleanHandshakeSeq {V : Type*} {Γ : Type*} [DecidableEq Γ] : List (Handshake V Γ) → (Γ × Bool → Set V) → Prop where
  | nil (t : Γ × Bool → Set V) : CleanHandshakeSeq [] t
  | cons (h : Handshake V Γ) (seq : List (Handshake V Γ)) (t : Γ × Bool → Set V) :
      handshake_is_clean h t → CleanHandshakeSeq seq (handshake_update_contam h t) →
        CleanHandshakeSeq (h :: seq) t
See it in the graphDiscuss this resultChallenge it