2014-08-01 00:48:51 +00:00
|
|
|
-- Copyright (c) 2014 Microsoft Corporation. All rights reserved.
|
|
|
|
-- Released under Apache 2.0 license as described in the file LICENSE.
|
|
|
|
-- Authors: Leonardo de Moura, Jeremy Avigad
|
2014-08-28 00:46:07 +00:00
|
|
|
|
2014-10-02 21:27:33 +00:00
|
|
|
import general_notation type
|
2014-08-28 00:46:07 +00:00
|
|
|
|
|
|
|
-- implication
|
|
|
|
-- -----------
|
|
|
|
|
2014-09-17 21:39:05 +00:00
|
|
|
definition imp (a b : Prop) : Prop := a → b
|
2014-08-28 00:46:07 +00:00
|
|
|
|
|
|
|
|
|
|
|
-- true and false
|
|
|
|
-- --------------
|
|
|
|
|
|
|
|
inductive false : Prop
|
|
|
|
|
2014-11-09 01:54:17 +00:00
|
|
|
-- make c explicit and rename to false.elim
|
2014-09-02 02:44:04 +00:00
|
|
|
theorem false_elim {c : Prop} (H : false) : c :=
|
2014-09-04 22:03:59 +00:00
|
|
|
false.rec c H
|
2014-08-28 00:46:07 +00:00
|
|
|
|
|
|
|
inductive true : Prop :=
|
2014-09-04 23:36:06 +00:00
|
|
|
intro : true
|
|
|
|
|
2014-09-17 21:39:05 +00:00
|
|
|
definition trivial := true.intro
|
2014-08-28 00:46:07 +00:00
|
|
|
|
2014-09-17 21:39:05 +00:00
|
|
|
definition not (a : Prop) := a → false
|
2014-08-28 00:46:07 +00:00
|
|
|
prefix `¬` := not
|
|
|
|
|
|
|
|
|
|
|
|
-- not
|
|
|
|
-- ---
|
|
|
|
|
2014-11-09 01:54:17 +00:00
|
|
|
--rename to not.intro or neg.intro
|
2014-08-28 00:46:07 +00:00
|
|
|
theorem not_intro {a : Prop} (H : a → false) : ¬a := H
|
|
|
|
|
2014-11-09 01:54:17 +00:00
|
|
|
--rename to not.elim or neg.elim
|
2014-08-28 00:46:07 +00:00
|
|
|
theorem not_elim {a : Prop} (H1 : ¬a) (H2 : a) : false := H1 H2
|
|
|
|
|
2014-11-22 03:39:16 +00:00
|
|
|
definition absurd {a : Prop} {b : Type} (H1 : a) (H2 : ¬a) : b :=
|
|
|
|
false.rec b (H2 H1)
|
2014-08-28 00:46:07 +00:00
|
|
|
|
|
|
|
theorem not_not_intro {a : Prop} (Ha : a) : ¬¬a :=
|
|
|
|
assume Hna : ¬a, absurd Ha Hna
|
|
|
|
|
|
|
|
theorem mt {a b : Prop} (H1 : a → b) (H2 : ¬b) : ¬a :=
|
|
|
|
assume Ha : a, absurd (H1 Ha) H2
|
|
|
|
|
|
|
|
theorem not_false_trivial : ¬false :=
|
|
|
|
assume H : false, H
|
|
|
|
|
|
|
|
theorem not_implies_left {a b : Prop} (H : ¬(a → b)) : ¬¬a :=
|
2014-08-28 01:34:09 +00:00
|
|
|
assume Hna : ¬a, absurd (assume Ha : a, absurd Ha Hna) H
|
2014-08-28 00:46:07 +00:00
|
|
|
|
|
|
|
theorem not_implies_right {a b : Prop} (H : ¬(a → b)) : ¬b :=
|
|
|
|
assume Hb : b, absurd (assume Ha : a, Hb) H
|