lean2/tests/lean/add_assoc.lean.expected.out
Leonardo de Moura ba9a8f9d98 feat(frontends/lean): add 'show' expression syntax sugar
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-02-06 07:50:22 -08:00

17 lines
829 B
Text
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

Set: pp::colors
Set: pp::unicode
Imported 'tactic'
Using: Nat
Proved: add_assoc
Nat::add_zerol : ∀ a : , 0 + a = a
Nat::add_succl : ∀ a b : , a + 1 + b = a + b + 1
@eq_id : ∀ (A : (Type U)) (a : A), a = a ↔
theorem add_assoc (a b c : ) : a + (b + c) = a + b + c :=
Nat::induction_on
a
(eqt_elim (trans (congr (congr2 eq (Nat::add_zerol (b + c))) (congr1 c (congr2 Nat::add (Nat::add_zerol b))))
(eq_id (b + c))))
(λ (n : ) (iH : n + (b + c) = n + b + c),
eqt_elim (trans (congr (congr2 eq (trans (Nat::add_succl n (b + c)) (congr1 1 (congr2 Nat::add iH))))
(trans (congr1 c (congr2 Nat::add (Nat::add_succl n b))) (Nat::add_succl (n + b) c)))
(eq_id (n + b + c + 1))))