lean2/tests/lean/tst6.lean.expected.out
Leonardo de Moura 7a3aab60c6 chore(builtin/kernel): remove \bowtie as notation for transitivity
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
2014-01-18 21:11:12 -08:00

67 lines
3 KiB
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
Assumed: N
Assumed: h
Proved: congrH
Set: lean::pp::implicit
variable h : N → N → N
theorem congrH {a1 a2 b1 b2 : N} (H1 : @eq N a1 b1) (H2 : @eq N a2 b2) : @eq N (h a1 a2) (h b1 b2) :=
@congr N N (h a1) (h b1) a2 b2 (@congr N (N → N) h h a1 b1 (@refl (N → N → N) h) H1) H2
Set: lean::pp::implicit
variable h : N → N → N
theorem congrH {a1 a2 b1 b2 : N} (H1 : a1 = b1) (H2 : a2 = b2) : h a1 a2 = h b1 b2 := congr (congr (refl h) H1) H2
Proved: Example1
Set: lean::pp::implicit
theorem Example1 (a b c d : N) (H : @eq N a b ∧ @eq N b c @eq N a d ∧ @eq N d c) : @eq N (h a b) (h c b) :=
@or_elim (@eq N a b ∧ @eq N b c)
(@eq N a d ∧ @eq N d c)
(@eq N (h a b) (h c b))
H
(λ H1 : @eq N a b ∧ @eq N b c,
@congrH a
b
c
b
(@trans N a b c (@and_eliml (@eq N a b) (@eq N b c) H1) (@and_elimr (@eq N a b) (@eq N b c) H1))
(@refl N b))
(λ H1 : @eq N a d ∧ @eq N d c,
@congrH a
b
c
b
(@trans N a d c (@and_eliml (@eq N a d) (@eq N d c) H1) (@and_elimr (@eq N a d) (@eq N d c) H1))
(@refl N b))
Proved: Example2
Set: lean::pp::implicit
theorem Example2 (a b c d : N) (H : @eq N a b ∧ @eq N b c @eq N a d ∧ @eq N d c) : @eq N (h a b) (h c b) :=
@or_elim (@eq N a b ∧ @eq N b c)
(@eq N a d ∧ @eq N d c)
(@eq N (h a b) (h c b))
H
(λ H1 : @eq N a b ∧ @eq N b c,
@congrH a
b
c
b
(@trans N a b c (@and_eliml (@eq N a b) (@eq N b c) H1) (@and_elimr (@eq N a b) (@eq N b c) H1))
(@refl N b))
(λ H1 : @eq N a d ∧ @eq N d c,
@congrH a
b
c
b
(@trans N a d c (@and_eliml (@eq N a d) (@eq N d c) H1) (@and_elimr (@eq N a d) (@eq N d c) H1))
(@refl N b))
Proved: Example3
Set: lean::pp::implicit
theorem Example3 (a b c d e : N) (H : a = b ∧ b = e ∧ b = c a = d ∧ d = c) : h a b = h c b :=
or_elim H
(λ H1 : a = b ∧ b = e ∧ b = c, congrH (trans (and_eliml H1) (and_elimr (and_elimr H1))) (refl b))
(λ H1 : a = d ∧ d = c, congrH (trans (and_eliml H1) (and_elimr H1)) (refl b))
Proved: Example4
Set: lean::pp::implicit
theorem Example4 (a b c d e : N) (H : a = b ∧ b = e ∧ b = c a = d ∧ d = c) : h a c = h c a :=
or_elim H
(λ H1 : a = b ∧ b = e ∧ b = c,
let AeqC := trans (and_eliml H1) (and_elimr (and_elimr H1)) in congrH AeqC (symm AeqC))
(λ H1 : a = d ∧ d = c, let AeqC := trans (and_eliml H1) (and_elimr H1) in congrH AeqC (symm AeqC))