TheoremmissingDen_spec
Statement
theorem missingDen_spec {kind : Nat} {ds : List Den} {d : Den} (hk : kind = 0 ∨ kind = 1 ∨ kind = 2)
(h : missingDen kind ds = some d) : d ∉ ds ∧ d.kind = kind ∧ d.inRange = trueProof
by
unfold missingDen at h
have hm := List.mem_of_find?_eq_some h
have hp := List.find?_some h
obtain ⟨i, _, hi⟩ := List.mem_filterMap.mp hm
refine ⟨fun hd => ?_, litCandidate_spec hk hi⟩
simp at hp
exact hp hdProved with tactics, which Lean expands into a proof term that its kernel checks.
Theorems it uses
Used by
In StandardElmMech/Stat/PatternsProof.lean: The pattern decider is correct: every type is inhabited (inhabited), useful_spec, exhDec_sound, irrDec_sound.
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.