Elm Exactly

TheoremaReadyList_get

StandardElmMech/Src/AliasOrderProof.lean:183 · term proof

Statement

theorem aReadyList_get : ∀ (P os : List AliasD), AReadyList all P os →
    ∀ (k : Nat) (hk : k < os.length), aReady all (P ++ os.take k) os[k] = true
  | _, [], _, k, hk => by simp at hk
  | P, a :: os, ⟨h1, _⟩, 0, _ => by simpa using h1
  | P, a :: os, ⟨_, h2⟩, k + 1, hk => by
    have

Proof

aReadyList_get (P ++ [a]) os h2 k (by simp at hk; omega)
    simpa using this

Proved by a term, which Lean's kernel checks directly.

Used by

In StandardElmMech/Src/AliasOrderProof.lean: aliasOrder_valid: the canonical order of aliases is one the book allows.

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.