]> matita.cs.unibo.it Git - helm.git/blob - helm/software/matita/nlibrary/topology/cantor.ma
some more work
[helm.git] / helm / software / matita / nlibrary / topology / cantor.ma
1
2
3 include "topology/igft.ma".
4
5 ntheorem axiom_cond: âˆ€A:Ax.∀a:A.∀i:𝐈 a.a â—ƒ đ‚ a i.
6 #A; #a; #i; @2 i; #x; #H; @; napply H;
7 nqed.
8
9 nlemma hint_auto1 : âˆ€A,U,V. (∀x.x âˆˆ U â†’ x â—ƒ V) â†’ cover_set cover A U V.
10 nnormalize; nauto.
11 nqed.
12
13 alias symbol "covers" (instance 1) = "covers".
14 alias symbol "covers" (instance 2) = "covers set".
15 alias symbol "covers" (instance 3) = "covers".
16 ntheorem transitivity: âˆ€A:Ax.∀a:A.∀U,V. a â—ƒ U â†’ U â—ƒ V â†’ a â—ƒ V.
17 #A; #a; #U; #V; #aU; #UV;
18 nelim aU;
19 ##[ #c; #H; nauto; 
20 ##| #c; #i; #HCU; #H; @2 i; nauto; 
21 ##]
22 nqed.
23
24 ndefinition emptyset: âˆ€A.Ί^A â‰ ÎťA.{x | False}.
25
26 notation "∅" non associative with precedence 90 for @{ 'empty }.
27 interpretation "empty" 'empty = (emptyset ?).
28
29 naxiom EM : âˆ€A:Ax.∀a:A.∀i_star.(a âˆˆ đ‚ a i_star) âˆ¨ ÂŹ( a âˆˆ đ‚ a i_star).
30
31 ntheorem th2_3 :
32   âˆ€A:Ax.∀a:A. a â—ƒ âˆ… â†’ âˆƒi. ÂŹ a âˆˆ đ‚ a i.
33 #A; #a; #H; nelim H;
34 ##[ #n; *;
35 ##| #b; #i_star; #IH1; #IH2;
36     ncases (EM â€Ś b i_star);
37     ##[##2: (* nauto; *) #W; @i_star; napply W;
38     ##| nauto;
39     ##]
40 ##] 
41 nqed.
42
43 ninductive eq1 (A : Type[0]) : Type[0] â†’ CProp[0] â‰ 
44 | refl1 : eq1 A A.
45
46 notation "hvbox( a break âˆź b)" non associative with precedence 40 
47 for @{ 'eqT $a $b }.
48
49 interpretation "eq between types" 'eqT a b = (eq1 a b).
50
51 ninductive unit : Type[0] â‰ one : unit.
52
53 nrecord uAx : Type[1] â‰ {
54   uax_ : Ax;
55   with_ : âˆ€a:uax_.𝐈 a âˆź unit
56 }.
57
58 ndefinition uax : uAx â†’ Ax.
59 #A; @ (uax_ A) (Îťx.unit); #a; #_; napply (𝐂 a ?);  nlapply one; ncases (with_ A a); nauto; 
60 nqed.
61
62 ncoercion uax : âˆ€u:uAx. Ax â‰ uax on _u : uAx to Ax.
63
64 naxiom A: Type[0].
65 naxiom S: A â†’ ÎŠ^A.
66
67 ndefinition axs: uAx.
68 @; ##[ @ A (Îť_.unit) (Îťa,x.S a); ##| #_; @; ##]
69 nqed.
70  
71 alias id "S" = "cic:/matita/ng/topology/igft/S.fix(0,0,1)".
72 unification hint 0 â‰” ;
73          x â‰Ÿ axs  
74   (* -------------- *) âŠ˘
75          S x â‰Ą A. 
76
77
78 ntheorem col2_4 :
79   âˆ€A:uAx.∀a:A. a â—ƒ âˆ… â†’ ÂŹ a âˆˆ đ‚ a ?. ##[ (* bug *) ##2: nnormalize; napply one; ##]
80 #A; #a; #H; nelim H;
81 ##[ #n; *;
82 ##| #b; #i_star; #IH1; #IH2; #H3; nlapply (IH2 â€Ś H3); #H4; nauto;
83 ##] 
84 nqed.
85
86 ndefinition Z : ÎŠ^axs â‰ { x | x â—ƒ âˆ… }.
87
88 ntheorem cover_monotone: âˆ€A:Ax.∀a:A.∀U,V.U âŠ† V â†’ a â—ƒ U â†’ a â—ƒ V.
89 #A; #a; #U; #V; #HUV; #H; nelim H;
90 ##[ nauto;
91 ##| #b; #i; #HCU; #W; @2 i; #x; nauto; ##]
92 nqed.
93
94 ntheorem th3_1: ÂŹâˆƒa:axs.Z âŠ† S a âˆ§ S a âŠ† Z.
95 *; #a; *; #ZSa; #SaZ; 
96 ncut (a â—ƒ Z); ##[
97   nlapply (axiom_cond â€Ś a one); #AxCon; nchange in AxCon with (a â—ƒ S a);
98   (* nauto; *) napply (cover_monotone â€Ś AxCon); nassumption; ##] #H; 
99 ncut (a â—ƒ âˆ…); ##[ napply (transitivity â€Ś H); #x; #E; napply E; ##] #H1;
100 ncut (ÂŹ a âˆˆ S a); ##[ napply (col2_4 â€Ś H1); ##] #H2;
101 ncut (a âˆˆ S a); ##[ napply ZSa; napply H1; ##] #H3;
102 nauto;
103 nqed.
104
105 include "nat/nat.ma".
106
107 naxiom phi : nat â†’ nat â†’ nat.
108
109 notation > "ϕ" non associative with precedence 90 for @{ 'phi }.
110 interpretation "phi" 'phi = phi.
111  
112 notation < "ϕ a i" non associative with precedence 90 for @{ 'phi2 $a $i}.
113 interpretation "phi2" 'phi2 a i = (phi a i). 
114 notation < "ϕ a" non associative with precedence 90 for @{ 'phi1 $a }.
115 interpretation "phi2" 'phi1 a = (phi a). 
116
117 ndefinition caxs : uAx. 
118 @; ##[ @ nat (Îť_.unit); #a; #_; napply { x | Ď• a x = O } ##| #_; @; ##]
119 nqed.
120
121
122 alias id "S" = "cic:/matita/ng/topology/igft/S.fix(0,0,1)".
123 unification hint 0 â‰” ;
124          x â‰Ÿ caxs  
125   (* -------------- *) âŠ˘
126          S x â‰Ą nat. 
127
128 naxiom h : nat â†’ nat. 
129
130 alias symbol "eq" = "leibnitz's equality".
131 alias symbol "eq" = "setoid1 eq".
132 alias symbol "covers" = "covers".
133 naxiom Ph :  âˆ€x.h x = O \liff  x â—ƒ âˆ….
134
135 nlemma replace_char:
136   âˆ€A:Ax.∀U,V.U âŠ† V â†’ V âŠ† U â†’ âˆ€a:A.a â—ƒ U â†’ a â—ƒ V.
137 #A; #U; #V;  #a; #H1; #H2; #E; nelim E;
138 ##[ #b; #Hb; @; nauto;
139 ##| #b; #i; #H3; #H4; @2 i; #c; #Hc; nauto; ##]
140 nqed.
141
142 ntheorem th_ch3: ÂŹâˆƒa:caxs.∀x.ϕ a x = h x.
143 *; #a; #H;
144 ncut (a â—ƒ { x | x â—ƒ âˆ…}); ##[
145   napply (replace_char â€Ś { x | h x = O }); ##[ ##1,2: #x; ncases (Ph x);
146      (* nauto; *) #H1; #H2; #H3; nauto; (* ??? *) ##]
147   napply (replace_char â€Ś { x | Ď• a x = O }); ##[##1,2: #x; nrewrite > (H x);
148      (* nauto; *) #E; napply E; ##]
149   napply (axiom_cond â€Ś a one); ##] #H1;
150 ncut (a â—ƒ âˆ…); ##[ napply (transitivity â€Ś H1); #x; nauto; ##] #H2;
151 nlapply (col2_4 â€ŚH2); #H3;
152 ncut (a âˆˆ đ‚ a one); ##[
153   nnormalize; ncases (Ph a); nrewrite > (H a); nauto; ##] #H4;
154 nauto;
155 nqed.
156
157