]> matita.cs.unibo.it Git - helm.git/blobdiff - helm/matita/library/logic/connectives.ma
New version of the library, a bit more structured.
[helm.git] / helm / matita / library / logic / connectives.ma
diff --git a/helm/matita/library/logic/connectives.ma b/helm/matita/library/logic/connectives.ma
new file mode 100644 (file)
index 0000000..835bb68
--- /dev/null
@@ -0,0 +1,56 @@
+(**************************************************************************)
+(*       ___                                                               *)
+(*      ||M||                                                             *)
+(*      ||A||       A project by Andrea Asperti                           *)
+(*      ||T||                                                             *)
+(*      ||I||       Developers:                                           *)
+(*      ||T||       A.Asperti, C.Sacerdoti Coen,                          *)
+(*      ||A||       E.Tassi, S.Zacchiroli                                 *)
+(*      \   /                                                             *)
+(*       \ /        This file is distributed under the terms of the       *)
+(*        v         GNU Lesser General Public License Version 2.1         *)
+(*                                                                        *)
+(**************************************************************************)
+
+set "baseuri" "cic:/matita/connectives/".
+
+inductive True: Prop \def
+I : True.
+
+default "true" cic:/matita/logic/True.ind.
+
+inductive False: Prop \def .
+
+default "false" cic:/matita/logic/False.ind.
+
+definition Not: Prop \to Prop \def
+\lambda A. (A \to False).
+
+theorem absurd : \forall A,C:Prop. A \to Not A \to C.
+intros. elim (H1 H).
+qed.
+
+default "absurd" cic:/matita/logic/absurd.ind.
+
+inductive And (A,B:Prop) : Prop \def
+    conj : A \to B \to (And A B).
+
+theorem proj1: \forall A,B:Prop. (And A B) \to A.
+intros. elim H. assumption.
+qed.
+
+theorem proj2: \forall A,B:Prop. (And A B) \to B.
+intros. elim H. assumption.
+qed.
+
+inductive Or (A,B:Prop) : Prop \def
+     or_introl : A \to (Or A B)
+   | or_intror : B \to (Or A B).
+   
+definition decidable : Prop \to Prop \def \lambda A:Prop. Or A (Not A).
+
+inductive ex (A:Type) (P:A \to Prop) : Prop \def
+    ex_intro: \forall x:A. P x \to ex A P.
+
+inductive ex2 (A:Type) (P,Q:A \to Prop) : Prop \def
+    ex_intro2: \forall x:A. P x \to Q x \to ex2 A P Q.