~ubuntu-branches/ubuntu/hardy/coq-doc/hardy

« back to all changes in this revision

Viewing changes to library/Coq.Logic.ClassicalDescription.html

  • Committer: Bazaar Package Importer
  • Author(s): Samuel Mimram
  • Date: 2004-09-18 13:28:22 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20040918132822-ees5mb8qmzd6a0fw
Tags: 8.0pl1.0-1
* Added the Coq faq, moved the tutorial to the root directory and added
  doc-base files for both, closes: #272204.
* Set dh_compat to level 4.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<html xmlns="http://www.w3.org/1999/xhtml">
 
2
<head>
 
3
<meta http-equiv="Content-Type" content="text/html; charset="><link rel="stylesheet" href="style.css" type="text/css"><title>Coq.Logic.ClassicalDescription</title>
 
4
</head>
 
5
 
 
6
<body>
 
7
 
 
8
<h1>Library Coq.Logic.ClassicalDescription</h1>
 
9
 
 
10
<code>
 
11
</code>
 
12
 
 
13
<table width="100%"><tr class="doc"><td>
 
14
This file provides classical logic and definite description 
 
15
</td></tr></table>
 
16
<code>
 
17
 
 
18
<br/>
 
19
</code>
 
20
 
 
21
<table width="100%"><tr class="doc"><td>
 
22
Classical logic and definite description, as shown in <code>1</code>,
 
23
    implies the double-negation of excluded-middle in Set, hence it
 
24
    implies a strongly classical world. Especially it conflicts with
 
25
    impredicativity of Set, knowing that true&lt;&gt;false in Set.
 
26
 
 
27
<br/><br/>
 
28
    <code>1</code> Laurent Chicli, Lo�c Pottier, Carlos Simpson, Mathematical
 
29
    Quotients and Quotient Types in Coq, Proceedings of TYPES 2002,
 
30
    Lecture Notes in Computer Science 2646, Springer Verlag.
 
31
 
 
32
</td></tr></table>
 
33
<code>
 
34
 
 
35
<br/>
 
36
<code class="keyword">Require</code> <code class="keyword">Export</code> <a href="Coq.Logic.Classical.html">Classical</a>.<br/>
 
37
 
 
38
<br/>
 
39
<code class="keyword">Axiom</code><br/>
 
40
&nbsp;&nbsp;<a name="dependent_description"></a>dependent_description :<br/>
 
41
&nbsp;&nbsp;&nbsp;&nbsp;forall (A:Type) (B:A -&gt; Type) (R:forall x:A, B x -&gt; Prop),<br/>
 
42
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(forall x:A,<br/>
 
43
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;exists y : B x, R x y /\ (forall y':B x, R x y' -&gt; y = y')) -&gt;<br/>
 
44
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;exists f : forall x:A, B x, (forall x:A, R x (f x)).<br/>
 
45
 
 
46
<br/>
 
47
</code>
 
48
 
 
49
<table width="100%"><tr class="doc"><td>
 
50
Principle of definite descriptions (aka axiom of unique choice) 
 
51
</td></tr></table>
 
52
<code>
 
53
 
 
54
<br/>
 
55
<code class="keyword">Theorem</code> <a name="description"></a>description :<br/>
 
56
&nbsp;forall (A B:Type) (R:A -&gt; B -&gt; Prop),<br/>
 
57
&nbsp;&nbsp;&nbsp;(forall x:A,  exists y : B, R x y /\ (forall y':B, R x y' -&gt; y = y')) -&gt;<br/>
 
58
&nbsp;&nbsp;&nbsp;&nbsp;exists f : A -&gt; B, (forall x:A, R x (f x)).<br/>
 
59
<code class="keyword">Proof</code>.<br/>
 
60
intros A B.<br/>
 
61
apply (<a href="Coq.Logic.ClassicalDescription.html#dependent_description">dependent_description</a> A (fun _ =&gt; B)).<br/>
 
62
<code class="keyword">Qed</code>.<br/>
 
63
 
 
64
<br/>
 
65
</code>
 
66
 
 
67
<table width="100%"><tr class="doc"><td>
 
68
The followig proof comes from <code>1</code> 
 
69
</td></tr></table>
 
70
<code>
 
71
 
 
72
<br/>
 
73
<code class="keyword">Theorem</code> <a name="classic_set"></a>classic_set : ((forall P:Prop, {P} + {~ P}) -&gt; <a href="Coq.Init.Logic.html#False">False</a>) -&gt; <a href="Coq.Init.Logic.html#False">False</a>.<br/>
 
74
<code class="keyword">Proof</code>.<br/>
 
75
intro HnotEM.<br/>
 
76
set (R:= fun A b =&gt; A /\ <a href="Coq.Init.Datatypes.html#true">true</a> = b \/ ~ A /\ <a href="Coq.Init.Datatypes.html#false">false</a> = b).<br/>
 
77
assert (H :  exists f : Prop -&gt; <a href="Coq.Init.Datatypes.html#bool">bool</a>, (forall A:Prop, R A (f A))).<br/>
 
78
apply <a href="Coq.Logic.ClassicalDescription.html#description">description</a>.<br/>
 
79
intro A.<br/>
 
80
destruct (<a href="Coq.Logic.Classical_Prop.html#classic">classic</a> A) as [Ha| Hnota].<br/>
 
81
&nbsp;&nbsp;exists <a href="Coq.Init.Datatypes.html#true">true</a>; split.<br/>
 
82
&nbsp;&nbsp;&nbsp;&nbsp;left; split; [ assumption | reflexivity ].<br/>
 
83
&nbsp;&nbsp;&nbsp;&nbsp;intros y [[_ Hy]| [Hna _]].<br/>
 
84
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;assumption.<br/>
 
85
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;contradiction.<br/>
 
86
&nbsp;&nbsp;exists <a href="Coq.Init.Datatypes.html#false">false</a>; split.<br/>
 
87
&nbsp;&nbsp;&nbsp;&nbsp;right; split; [ assumption | reflexivity ].<br/>
 
88
&nbsp;&nbsp;&nbsp;&nbsp;intros y [[Ha _]| [_ Hy]].<br/>
 
89
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;contradiction.<br/>
 
90
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;assumption.<br/>
 
91
destruct H as [f Hf].<br/>
 
92
apply HnotEM.<br/>
 
93
intro P.<br/>
 
94
assert (HfP:= Hf P).<br/>
 
95
destruct (f P).<br/>
 
96
&nbsp;&nbsp;left.<br/>
 
97
&nbsp;&nbsp;destruct HfP as [[Ha _]| [_ Hfalse]].<br/>
 
98
&nbsp;&nbsp;&nbsp;&nbsp;assumption.<br/>
 
99
&nbsp;&nbsp;&nbsp;&nbsp;discriminate.<br/>
 
100
&nbsp;&nbsp;right.<br/>
 
101
&nbsp;&nbsp;destruct HfP as [[_ Hfalse]| [Hna _]].<br/>
 
102
&nbsp;&nbsp;&nbsp;&nbsp;discriminate.<br/>
 
103
&nbsp;&nbsp;&nbsp;&nbsp;assumption.<br/>
 
104
<code class="keyword">Qed</code>.<br/>
 
105
&nbsp;<br/>
 
106
</code>
 
107
<hr/><a href="index.html">Index</a><hr/><font size="-1">This page has been generated by <a href="http://www.lri.fr/~filliatr/coqdoc/">coqdoc</a></font>
 
108
</body>
 
109
</html>
 
 
b'\\ No newline at end of file'