annotate cardinal.agda @ 238:a8c6239176db

ZFProduct
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Mon, 19 Aug 2019 11:39:46 +0900
parents 521290e85527
children b6d80eec5f9e
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
16
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 15
diff changeset
1 open import Level
224
afc864169325 recover ε-induction
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 219
diff changeset
2 open import Ordinals
afc864169325 recover ε-induction
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 219
diff changeset
3 module cardinal {n : Level } (O : Ordinals {n}) where
3
e7990ff544bf reocrd ZF
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents:
diff changeset
4
14
e11e95d5ddee separete constructible set
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 11
diff changeset
5 open import zf
219
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
6 open import logic
224
afc864169325 recover ε-induction
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 219
diff changeset
7 import OD
23
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 22
diff changeset
8 open import Data.Nat renaming ( zero to Zero ; suc to Suc ; ℕ to Nat ; _⊔_ to _n⊔_ )
224
afc864169325 recover ε-induction
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 219
diff changeset
9 open import Relation.Binary.PropositionalEquality
14
e11e95d5ddee separete constructible set
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 11
diff changeset
10 open import Data.Nat.Properties
6
d9b704508281 isEquiv and isZF
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 4
diff changeset
11 open import Data.Empty
d9b704508281 isEquiv and isZF
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 4
diff changeset
12 open import Relation.Nullary
d9b704508281 isEquiv and isZF
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 4
diff changeset
13 open import Relation.Binary
d9b704508281 isEquiv and isZF
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 4
diff changeset
14 open import Relation.Binary.Core
d9b704508281 isEquiv and isZF
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 4
diff changeset
15
224
afc864169325 recover ε-induction
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 219
diff changeset
16 open inOrdinal O
afc864169325 recover ε-induction
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 219
diff changeset
17 open OD O
219
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
18 open OD.OD
29
fce60b99dc55 posturate OD is isomorphic to Ordinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 28
diff changeset
19
120
ac214eab1c3c inifinite done
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 119
diff changeset
20 open _∧_
213
22d435172d1a separate logic and nat
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 210
diff changeset
21 open _∨_
22d435172d1a separate logic and nat
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 210
diff changeset
22 open Bool
44
fcac01485f32 od→lv : {n : Level} → OD {n} → Nat
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 43
diff changeset
23
230
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
24 -- we have to work on Ordinal to keep OD Level n
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
25 -- since we use p∨¬p which works only on Level n
225
5f48299929ac does not work
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 224
diff changeset
26
233
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
27 <_,_> : (x y : OD) → OD
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
28 < x , y > = (x , x ) , (x , y )
226
176ff97547b4 set theortic function definition using sup
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 225
diff changeset
29
238
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
30 data ord-pair : (p : Ordinal) → Set n where
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
31 pair : (x y : Ordinal ) → ord-pair ( od→ord ( < ord→od x , ord→od y > ) )
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
32
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
33 ZFProduct : OD
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
34 ZFProduct = record { def = λ x → ord-pair x }
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
35
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
36 π1' : { p : OD } → ZFProduct ∋ p → OD
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
37 π1' lt = ord→od (pi1 lt) where
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
38 pi1 : { p : Ordinal } → ord-pair p → Ordinal
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
39 pi1 ( pair x y ) = x
237
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 236
diff changeset
40
238
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
41 π2' : { p : OD } → ZFProduct ∋ p → OD
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
42 π2' lt = ord→od (pi2 lt) where
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
43 pi2 : { p : Ordinal } → ord-pair p → Ordinal
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
44 pi2 ( pair x y ) = y
237
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 236
diff changeset
45
238
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
46 p-cons : { x y : OD } → ZFProduct ∋ < x , y >
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
47 p-cons {x} {y} = def-subst {_} {_} {ZFProduct} {od→ord (< x , y >)} (pair (od→ord x) ( od→ord y )) refl (
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
48 let open ≡-Reasoning in begin
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
49 od→ord < ord→od (od→ord x) , ord→od (od→ord y) >
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
50 ≡⟨ cong₂ (λ j k → od→ord < j , k >) oiso oiso ⟩
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
51 od→ord < x , y >
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
52 ∎ )
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
53
a8c6239176db ZFProduct
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
54
237
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 236
diff changeset
55
236
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
56 record SetProduct ( A B : OD ) : Set n where
226
176ff97547b4 set theortic function definition using sup
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 225
diff changeset
57 field
176ff97547b4 set theortic function definition using sup
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 225
diff changeset
58 π1 : Ordinal
176ff97547b4 set theortic function definition using sup
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 225
diff changeset
59 π2 : Ordinal
233
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
60 A∋π1 : def A π1
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
61 B∋π2 : def B π2
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
62 -- opair : x ≡ od→ord (Ord ( omax (omax π1 π1) (omax π1 π2) )) -- < π1 , π2 >
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
63
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
64 open SetProduct
226
176ff97547b4 set theortic function definition using sup
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 225
diff changeset
65
234
e06b76e5b682 ac from LEM in abstract ordinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 233
diff changeset
66 ∋-p : (A x : OD ) → Dec ( A ∋ x )
e06b76e5b682 ac from LEM in abstract ordinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 233
diff changeset
67 ∋-p A x with p∨¬p ( A ∋ x )
e06b76e5b682 ac from LEM in abstract ordinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 233
diff changeset
68 ∋-p A x | case1 t = yes t
e06b76e5b682 ac from LEM in abstract ordinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 233
diff changeset
69 ∋-p A x | case2 t = no t
e06b76e5b682 ac from LEM in abstract ordinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 233
diff changeset
70
233
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
71 _⊗_ : (A B : OD) → OD
236
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
72 A ⊗ B = record { def = λ x → SetProduct A B }
233
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
73 -- A ⊗ B = record { def = λ x → (y z : Ordinal) → def A y ∧ def B z ∧ ( x ≡ od→ord (< ord→od y , ord→od z >) ) }
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
74
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
75 -- Power (Power ( A ∪ B )) ∋ ( A ⊗ B )
225
5f48299929ac does not work
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 224
diff changeset
76
233
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
77 Func : ( A B : OD ) → OD
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
78 Func A B = record { def = λ x → def (Power (A ⊗ B)) x }
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
79
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
80 -- power→ : ( A t : OD) → Power A ∋ t → {x : OD} → t ∋ x → ¬ ¬ (A ∋ x)
226
176ff97547b4 set theortic function definition using sup
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 225
diff changeset
81
234
e06b76e5b682 ac from LEM in abstract ordinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 233
diff changeset
82 func←od : { dom cod : OD } → {f : Ordinal } → def (Func dom cod ) f → (Ordinal → Ordinal )
233
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
83 func←od {dom} {cod} {f} lt x = sup-o ( λ y → lemma y ) where
226
176ff97547b4 set theortic function definition using sup
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 225
diff changeset
84 lemma : Ordinal → Ordinal
235
846e0926bb89 fix cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 234
diff changeset
85 lemma y with IsZF.power→ isZF (dom ⊗ cod) (ord→od f) (subst (λ k → def (Power (dom ⊗ cod)) k ) (sym diso) lt ) | ∋-p (ord→od f) (ord→od y)
234
e06b76e5b682 ac from LEM in abstract ordinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 233
diff changeset
86 lemma y | p | no n = o∅
e06b76e5b682 ac from LEM in abstract ordinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 233
diff changeset
87 lemma y | p | yes f∋y with double-neg-eilm ( p {ord→od y} f∋y ) -- p : {x : OD} → f ∋ x → ¬ ¬ (dom ⊗ cod ∋ x)
e06b76e5b682 ac from LEM in abstract ordinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 233
diff changeset
88 ... | t with decp ( x ≡ π1 t )
e06b76e5b682 ac from LEM in abstract ordinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 233
diff changeset
89 ... | yes _ = π2 t
e06b76e5b682 ac from LEM in abstract ordinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 233
diff changeset
90 ... | no _ = o∅
233
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
91
236
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
92
233
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
93 func→od : (f : Ordinal → Ordinal ) → ( dom : OD ) → OD
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
94 func→od f dom = Replace dom ( λ x → < x , ord→od (f (od→ord x)) > )
af60c40298a4 function continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 230
diff changeset
95
236
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
96 record Func←cd { dom cod : OD } {f : Ordinal } (f<F : def (Func dom cod ) f) : Set n where
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
97 field
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
98 func-1 : Ordinal → Ordinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
99 func→od∈Func-1 : (Func dom (Ord (sup-o (λ x → func-1 x)) )) ∋ func→od func-1 dom
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
100
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
101 func←od1 : { dom cod : OD } → {f : Ordinal } → (f<F : def (Func dom cod ) f ) → Func←cd {dom} {cod} {f} f<F
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
102 func←od1 {dom} {cod} {f} lt = record { func-1 = λ x → sup-o ( λ y → lemma x y ) ; func→od∈Func-1 = {!!} } where
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
103 lemma : Ordinal → Ordinal → Ordinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
104 lemma x y with IsZF.power→ isZF (dom ⊗ cod) (ord→od f) (subst (λ k → def (Power (dom ⊗ cod)) k ) (sym diso) lt ) | ∋-p (ord→od f) (ord→od y)
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
105 lemma x y | p | no n = o∅
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
106 lemma x y | p | yes f∋y with double-neg-eilm ( p {ord→od y} f∋y ) -- p : {x : OD} → f ∋ x → ¬ ¬ (dom ⊗ cod ∋ x)
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
107 ... | t with decp ( x ≡ π1 t )
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
108 ... | yes _ = π2 t
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
109 ... | no _ = o∅
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
110
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
111 func→od∈Func : (f : Ordinal → Ordinal ) ( dom : OD ) → (Func dom (Ord (sup-o (λ x → f x)) )) ∋ func→od f dom
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 235
diff changeset
112 func→od∈Func f dom = record { proj1 = {!!} ; proj2 = {!!} }
225
5f48299929ac does not work
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 224
diff changeset
113
227
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 226
diff changeset
114 -- contra position of sup-o<
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 226
diff changeset
115 --
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 226
diff changeset
116
235
846e0926bb89 fix cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 234
diff changeset
117 -- postulate
846e0926bb89 fix cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 234
diff changeset
118 -- -- contra-position of mimimulity of supermum required in Cardinal
846e0926bb89 fix cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 234
diff changeset
119 -- sup-x : ( Ordinal → Ordinal ) → Ordinal
846e0926bb89 fix cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 234
diff changeset
120 -- sup-lb : { ψ : Ordinal → Ordinal } → {z : Ordinal } → z o< sup-o ψ → z o< osuc (ψ (sup-x ψ))
227
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 226
diff changeset
121
219
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
122 ------------
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
123 --
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
124 -- Onto map
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
125 -- def X x -> xmap
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
126 -- X ---------------------------> Y
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
127 -- ymap <- def Y y
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
128 --
224
afc864169325 recover ε-induction
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 219
diff changeset
129 record Onto (X Y : OD ) : Set n where
219
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
130 field
226
176ff97547b4 set theortic function definition using sup
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 225
diff changeset
131 xmap : Ordinal
176ff97547b4 set theortic function definition using sup
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 225
diff changeset
132 ymap : Ordinal
176ff97547b4 set theortic function definition using sup
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 225
diff changeset
133 xfunc : def (Func X Y) xmap
176ff97547b4 set theortic function definition using sup
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 225
diff changeset
134 yfunc : def (Func Y X) ymap
234
e06b76e5b682 ac from LEM in abstract ordinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 233
diff changeset
135 onto-iso : {y : Ordinal } → (lty : def Y y ) →
e06b76e5b682 ac from LEM in abstract ordinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 233
diff changeset
136 func←od {X} {Y} {xmap} xfunc ( func←od yfunc y ) ≡ y
230
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
137
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
138 open Onto
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
139
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
140 onto-restrict : {X Y Z : OD} → Onto X Y → ({x : OD} → _⊆_ Z Y {x}) → Onto X Z
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
141 onto-restrict {X} {Y} {Z} onto Z⊆Y = record {
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
142 xmap = xmap1
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
143 ; ymap = zmap
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
144 ; xfunc = xfunc1
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
145 ; yfunc = zfunc
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
146 ; onto-iso = onto-iso1
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
147 } where
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
148 xmap1 : Ordinal
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
149 xmap1 = od→ord (Select (ord→od (xmap onto)) {!!} )
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
150 zmap : Ordinal
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
151 zmap = {!!}
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
152 xfunc1 : def (Func X Z) xmap1
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
153 xfunc1 = {!!}
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
154 zfunc : def (Func Z X) zmap
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
155 zfunc = {!!}
234
e06b76e5b682 ac from LEM in abstract ordinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 233
diff changeset
156 onto-iso1 : {z : Ordinal } → (ltz : def Z z ) → func←od xfunc1 ( func←od zfunc z ) ≡ z
230
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
157 onto-iso1 = {!!}
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
158
51
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 50
diff changeset
159
224
afc864169325 recover ε-induction
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 219
diff changeset
160 record Cardinal (X : OD ) : Set n where
219
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
161 field
224
afc864169325 recover ε-induction
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 219
diff changeset
162 cardinal : Ordinal
230
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
163 conto : Onto X (Ord cardinal)
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
164 cmax : ( y : Ordinal ) → cardinal o< y → ¬ Onto X (Ord y)
151
b5a337fb7a6d recovering...
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 150
diff changeset
165
224
afc864169325 recover ε-induction
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 219
diff changeset
166 cardinal : (X : OD ) → Cardinal X
afc864169325 recover ε-induction
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 219
diff changeset
167 cardinal X = record {
219
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
168 cardinal = sup-o ( λ x → proj1 ( cardinal-p x) )
226
176ff97547b4 set theortic function definition using sup
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 225
diff changeset
169 ; conto = onto
219
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
170 ; cmax = cmax
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
171 } where
230
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
172 cardinal-p : (x : Ordinal ) → ( Ordinal ∧ Dec (Onto X (Ord x) ) )
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
173 cardinal-p x with p∨¬p ( Onto X (Ord x) )
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
174 cardinal-p x | case1 True = record { proj1 = x ; proj2 = yes True }
219
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
175 cardinal-p x | case2 False = record { proj1 = o∅ ; proj2 = no False }
229
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 228
diff changeset
176 S = sup-o (λ x → proj1 (cardinal-p x))
230
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
177 lemma1 : (x : Ordinal) → ((y : Ordinal) → y o< x → Lift (suc n) (y o< (osuc S) → Onto X (Ord y))) →
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
178 Lift (suc n) (x o< (osuc S) → Onto X (Ord x) )
229
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 228
diff changeset
179 lemma1 x prev with trio< x (osuc S)
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 228
diff changeset
180 lemma1 x prev | tri< a ¬b ¬c with osuc-≡< a
230
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
181 lemma1 x prev | tri< a ¬b ¬c | case1 x=S = lift ( λ lt → {!!} )
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
182 lemma1 x prev | tri< a ¬b ¬c | case2 x<S = lift ( λ lt → lemma2 ) where
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
183 lemma2 : Onto X (Ord x)
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
184 lemma2 with prev {!!} {!!}
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
185 ... | lift t = t {!!}
229
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 228
diff changeset
186 lemma1 x prev | tri≈ ¬a b ¬c = lift ( λ lt → ⊥-elim ( o<¬≡ b lt ))
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 228
diff changeset
187 lemma1 x prev | tri> ¬a ¬b c = lift ( λ lt → ⊥-elim ( o<> c lt ))
230
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
188 onto : Onto X (Ord S)
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
189 onto with TransFinite {λ x → Lift (suc n) ( x o< osuc S → Onto X (Ord x) ) } lemma1 S
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
190 ... | lift t = t <-osuc
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
191 cmax : (y : Ordinal) → S o< y → ¬ Onto X (Ord y)
229
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 228
diff changeset
192 cmax y lt ontoy = o<> lt (o<-subst {_} {_} {y} {S}
224
afc864169325 recover ε-induction
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 219
diff changeset
193 (sup-o< {λ x → proj1 ( cardinal-p x)}{y} ) lemma refl ) where
219
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
194 lemma : proj1 (cardinal-p y) ≡ y
230
1b1620e2053c we need ordered pair
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 229
diff changeset
195 lemma with p∨¬p ( Onto X (Ord y) )
219
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
196 lemma | case1 x = refl
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
197 lemma | case2 not = ⊥-elim ( not ontoy )
217
d5668179ee69 cardinal continue
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 216
diff changeset
198
226
176ff97547b4 set theortic function definition using sup
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 225
diff changeset
199
176ff97547b4 set theortic function definition using sup
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 225
diff changeset
200 -----
219
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
201 -- All cardinal is ℵ0, since we are working on Countable Ordinal,
43021d2b8756 separate cardinal
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 218
diff changeset
202 -- Power ω is larger than ℵ0, so it has no cardinal.
218
eee983e4b402 try func
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 217
diff changeset
203
eee983e4b402 try func
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 217
diff changeset
204
eee983e4b402 try func
Shinji KONO <kono@ie.u-ryukyu.ac.jp>
parents: 217
diff changeset
205