diff options
author | filliatr <filliatr@85f007b7-540e-0410-9357-904b9bb8a0f7> | 2000-03-16 22:45:07 +0000 |
---|---|---|
committer | filliatr <filliatr@85f007b7-540e-0410-9357-904b9bb8a0f7> | 2000-03-16 22:45:07 +0000 |
commit | 93da0ad0e56bf54f1be8913d0a5832868fc6be7c (patch) | |
tree | 966b7f847b5c8ffef75723fa6f44f8c9e574d56f /theories/Bool/Sumbool.v | |
parent | 629ac006253938d252529edb56dd2442e8e6b76f (diff) |
mise sous CVS
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/coq/trunk@318 85f007b7-540e-0410-9357-904b9bb8a0f7
Diffstat (limited to 'theories/Bool/Sumbool.v')
-rw-r--r-- | theories/Bool/Sumbool.v | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/theories/Bool/Sumbool.v b/theories/Bool/Sumbool.v new file mode 100644 index 000000000..a7d600289 --- /dev/null +++ b/theories/Bool/Sumbool.v @@ -0,0 +1,48 @@ + +(* $Id$ *) + +(* Here are collected some results about the type sumbool (see INIT/Specif.v) + * + * (sumbool A B), which is written {A}+{B}, is the informative + * disjunction "A or B", where A and B are logical propositions. + * Its extraction is isomorphic to the type of booleans. + *) + +(* A boolean is either true or false, and this is decidable *) + +Lemma sumbool_of_bool : (b:bool) {b=true}+{b=false}. +Proof. + Induction b; Auto. +Save. + +Hints Resolve sumbool_of_bool : bool. + +(* pourquoi ce machin-la est dans BOOL et pas dans LOGIC ? Papageno *) + +(* Logic connectives on type sumbool *) + +Section connectives. + +Variables A,B,C,D : Prop. + +Hypothesis H1 : {A}+{B}. +Hypothesis H2 : {C}+{D}. + +Lemma sumbool_and : {A/\C}+{B\/D}. +Proof. +Case H1; Case H2; Auto. +Save. + +Lemma sumbool_or : {A\/C}+{B/\D}. +Proof. +Case H1; Case H2; Auto. +Save. + +Lemma sumbool_not : {B}+{A}. +Proof. +Case H1; Auto. +Save. + +End connectives. + +Hints Resolve sumbool_and sumbool_or sumbool_not : core. |