1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
|
(************************************************************************)
(* v * The Coq Proof Assistant / The Coq Development Team *)
(* <O___,, * INRIA - CNRS - LIX - LRI - PPS - Copyright 1999-2010 *)
(* \VV/ **************************************************************)
(* // * This file is distributed under the terms of the *)
(* * GNU Lesser General Public License Version 2.1 *)
(************************************************************************)
(*i $Id: Epsilon.v 13323 2010-07-24 15:57:30Z herbelin $ i*)
(** This file provides indefinite description under the form of
Hilbert's epsilon operator; it does not assume classical logic. *)
Require Import ChoiceFacts.
Set Implicit Arguments.
(** Hilbert's epsilon: operator and specification in one statement *)
Axiom epsilon_statement :
forall (A : Type) (P : A->Prop), inhabited A ->
{ x : A | (exists x, P x) -> P x }.
Lemma constructive_indefinite_description :
forall (A : Type) (P : A->Prop),
(exists x, P x) -> { x : A | P x }.
Proof.
apply epsilon_imp_constructive_indefinite_description.
exact epsilon_statement.
Qed.
Lemma small_drinkers'_paradox :
forall (A:Type) (P:A -> Prop), inhabited A ->
exists x, (exists x, P x) -> P x.
Proof.
apply epsilon_imp_small_drinker.
exact epsilon_statement.
Qed.
Theorem iota_statement :
forall (A : Type) (P : A->Prop), inhabited A ->
{ x : A | (exists! x : A, P x) -> P x }.
Proof.
intros; destruct epsilon_statement with (P:=P); firstorder.
Qed.
Lemma constructive_definite_description :
forall (A : Type) (P : A->Prop),
(exists! x, P x) -> { x : A | P x }.
Proof.
apply iota_imp_constructive_definite_description.
exact iota_statement.
Qed.
(** Hilbert's epsilon operator and its specification *)
Definition epsilon (A : Type) (i:inhabited A) (P : A->Prop) : A
:= proj1_sig (epsilon_statement P i).
Definition epsilon_spec (A : Type) (i:inhabited A) (P : A->Prop) :
(exists x, P x) -> P (epsilon i P)
:= proj2_sig (epsilon_statement P i).
(** Church's iota operator and its specification *)
Definition iota (A : Type) (i:inhabited A) (P : A->Prop) : A
:= proj1_sig (iota_statement P i).
Definition iota_spec (A : Type) (i:inhabited A) (P : A->Prop) :
(exists! x:A, P x) -> P (iota i P)
:= proj2_sig (iota_statement P i).
|