Theoremreach_closed
Statement
theorem reach_closed {n : Nat} {r : Nat → Nat → Bool} {s : List Nat} (hc : Closed n r s) :
∀ {a b}, Plus n r a b → a ∈ s → b ∈ sProof
by
intro a b h
induction h with
| step _ hj hr => exact fun ha => hc _ ha _ hj hr
| trans _ _ ih1 ih2 => exact fun ha => ih2 (ih1 ha)Proved with tactics, which Lean expands into a proof term that its kernel checks.
Used by
In StandardElmMech/Src/Graph.lean: Reachability on graphs over 0 .. n-1 (Plus, Reach) and its decider, proved correct (plusB_iff, reachB_iff).
A Standard Definition of Elm? (Draft version 0.4) © Rupert Smith. The text is licensed under CC BY 4.0: share and adapt it freely, with credit and a link to the licence.