Elm Exactly

TheoremevForces_next_ge

StandardElmMech/Mod/Complete.lean:73, nostuck · term proof

Statement

theorem evForces_next_ge (o : Oracle) (n : Nat) (E : Env) : ∀ ys k, k ≤ (evForces o n E ys k).next
  | [], k => by simp [evForces]
  | y :: ys, k => by
    simp only [evForces]
    rcases h1 : evExp o n E (forceExp y) k with ⟨out1, l1, k1⟩
    have e1

Proof

evExp_next h1
    simp only at e1
    cases out1 with
    | value v =>
      dsimp only
      rcases h2 : evForces o n E ys k1 with ⟨out2, l2, k2⟩
      have e2 := evForces_next_ge o n E ys k1
      rw [h2] at e2; simp only at e2
      cases out2 <;> simp <;> omega
    | stuck => simp; omega
    | outOfFuel => simp; omega

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

Theorems it uses

Used by

In StandardElmMech/Mod/Complete.lean: The functional parts' converses, nostuck for modules and programs, noMeaning_of_stuck, evProgram_unique_l, completeness (evProgram_complete, noMeaning_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.