comparison src/zorn.agda @ 1018:c63f1fadd27f

sa<b
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Thu, 24 Nov 2022 11:18:46 +0900
parents ffdfd8d1303a
children eb2d0fb19b67
comparison
equal deleted inserted replaced
1017:ffdfd8d1303a 1018:c63f1fadd27f
429 field 429 field
430 supf : Ordinal → Ordinal 430 supf : Ordinal → Ordinal
431 sup=u : {b : Ordinal} → (ab : odef A b) → b o≤ z 431 sup=u : {b : Ordinal} → (ab : odef A b) → b o≤ z
432 → IsSUP A (UnionCF A f mf ay supf b) ab ∧ (¬ HasPrev A (UnionCF A f mf ay supf b) f b ) → supf b ≡ b 432 → IsSUP A (UnionCF A f mf ay supf b) ab ∧ (¬ HasPrev A (UnionCF A f mf ay supf b) f b ) → supf b ≡ b
433 cfcs : (mf< : <-monotonic-f A f) 433 cfcs : (mf< : <-monotonic-f A f)
434 {a b w : Ordinal } → a o< b → b o≤ z → supf a o< z → FClosure A f (supf a) w → odef (UnionCF A f mf ay supf z) w 434 {a b w : Ordinal } → a o< b → b o≤ z → supf a o< b → FClosure A f (supf a) w → odef (UnionCF A f mf ay supf b) w
435 435
436 asupf : {x : Ordinal } → odef A (supf x) 436 asupf : {x : Ordinal } → odef A (supf x)
437 supf-mono : {x y : Ordinal } → x o≤ y → supf x o≤ supf y 437 supf-mono : {x y : Ordinal } → x o≤ y → supf x o≤ supf y
438 supf-< : {x y : Ordinal } → supf x o< supf y → supf x << supf y 438 supf-< : {x y : Ordinal } → supf x o< supf y → supf x << supf y
439 supfmax : {x : Ordinal } → z o< x → supf x ≡ supf z 439 supfmax : {x : Ordinal } → z o< x → supf x ≡ supf z
527 supf-idem mf< {b} b≤z sfb≤x = z52 where 527 supf-idem mf< {b} b≤z sfb≤x = z52 where
528 z54 : {w : Ordinal} → odef (UnionCF A f mf ay supf (supf b)) w → (w ≡ supf b) ∨ (w << supf b) 528 z54 : {w : Ordinal} → odef (UnionCF A f mf ay supf (supf b)) w → (w ≡ supf b) ∨ (w << supf b)
529 z54 {w} ⟪ aw , ch-init fc ⟫ = fcy<sup b≤z fc 529 z54 {w} ⟪ aw , ch-init fc ⟫ = fcy<sup b≤z fc
530 z54 {w} ⟪ aw , ch-is-sup u u<x is-sup fc ⟫ = subst (λ k → (w ≡ k) ∨ (w << k )) 530 z54 {w} ⟪ aw , ch-is-sup u u<x is-sup fc ⟫ = subst (λ k → (w ≡ k) ∨ (w << k ))
531 (sym (supf-is-minsup b≤z)) 531 (sym (supf-is-minsup b≤z))
532 (MinSUP.x≤sup (minsup b≤z) ?) where 532 (MinSUP.x≤sup (minsup b≤z) (cfcs mf< u<b b≤z ? fc )) where
533 u<b : u o< b 533 u<b : u o< b
534 u<b = supf-inject ( subst (λ k → k o< supf b) (sym (ChainP.supu=u is-sup)) u<x ) 534 u<b = supf-inject ( subst (λ k → k o< supf b) (sym (ChainP.supu=u is-sup)) u<x )
535 su<z : supf u o< z 535 su<z : supf u o< z
536 su<z = subst (λ k → k o< z ) (sym (ChainP.supu=u is-sup)) ( ordtrans<-≤ u<b b≤z ) 536 su<z = subst (λ k → k o< z ) (sym (ChainP.supu=u is-sup)) ( ordtrans<-≤ u<b b≤z )
537 z52 : supf (supf b) ≡ supf b 537 z52 : supf (supf b) ≡ supf b
857 m10 : f (supf b) ≡ supf b 857 m10 : f (supf b) ≡ supf b
858 m10 = fc-stop A f mf (ZChain.asupf zc) m11 sb=sx where 858 m10 = fc-stop A f mf (ZChain.asupf zc) m11 sb=sx where
859 m11 : {z : Ordinal} → FClosure A f (supf b) z → (z ≡ ZChain.supf zc x) ∨ (z << ZChain.supf zc x) 859 m11 : {z : Ordinal} → FClosure A f (supf b) z → (z ≡ ZChain.supf zc x) ∨ (z << ZChain.supf zc x)
860 m11 {z} fc = subst (λ k → (z ≡ k) ∨ (z << k)) (sym m18) ( MinSUP.x≤sup m17 m13 ) where 860 m11 {z} fc = subst (λ k → (z ≡ k) ∨ (z << k)) (sym m18) ( MinSUP.x≤sup m17 m13 ) where
861 m13 : odef (UnionCF A f mf ay supf x) z 861 m13 : odef (UnionCF A f mf ay supf x) z
862 m13 = ? -- ZChain.cfcs zc mf< b<x x≤A (ZChain.supf<A zc) fc 862 m13 = ZChain.cfcs zc mf< b<x x≤A ? fc
863 863
864 ... | no lim = record { is-max = is-max ; order = order } where 864 ... | no lim = record { is-max = is-max ; order = order } where
865 is-max : {a : Ordinal} {b : Ordinal} → odef (UnionCF A f mf ay supf x) a → 865 is-max : {a : Ordinal} {b : Ordinal} → odef (UnionCF A f mf ay supf x) a →
866 b o< x → (ab : odef A b) → 866 b o< x → (ab : odef A b) →
867 HasPrev A (UnionCF A f mf ay supf x) f b ∨ IsSUP A (UnionCF A f mf ay supf b) ab → 867 HasPrev A (UnionCF A f mf ay supf x) f b ∨ IsSUP A (UnionCF A f mf ay supf b) ab →
895 m10 : f (supf b) ≡ supf b 895 m10 : f (supf b) ≡ supf b
896 m10 = fc-stop A f mf (ZChain.asupf zc) m11 sb=sx where 896 m10 = fc-stop A f mf (ZChain.asupf zc) m11 sb=sx where
897 m11 : {z : Ordinal} → FClosure A f (supf b) z → (z ≡ ZChain.supf zc x) ∨ (z << ZChain.supf zc x) 897 m11 : {z : Ordinal} → FClosure A f (supf b) z → (z ≡ ZChain.supf zc x) ∨ (z << ZChain.supf zc x)
898 m11 {z} fc = subst (λ k → (z ≡ k) ∨ (z << k)) (sym m18) ( MinSUP.x≤sup m17 m13 ) where 898 m11 {z} fc = subst (λ k → (z ≡ k) ∨ (z << k)) (sym m18) ( MinSUP.x≤sup m17 m13 ) where
899 m13 : odef (UnionCF A f mf ay supf x) z 899 m13 : odef (UnionCF A f mf ay supf x) z
900 m13 = ? -- ZChain.cfcs zc mf< b<x x≤A (ZChain.supf<A zc) fc 900 m13 = ZChain.cfcs zc mf< b<x x≤A ? fc
901 901
902 uchain : ( f : Ordinal → Ordinal ) → (mf : ≤-monotonic-f A f ) {y : Ordinal} (ay : odef A y) → HOD 902 uchain : ( f : Ordinal → Ordinal ) → (mf : ≤-monotonic-f A f ) {y : Ordinal} (ay : odef A y) → HOD
903 uchain f mf {y} ay = record { od = record { def = λ x → FClosure A f y x } ; odmax = & A ; <odmax = 903 uchain f mf {y} ay = record { od = record { def = λ x → FClosure A f y x } ; odmax = & A ; <odmax =
904 λ {z} cz → subst (λ k → k o< & A) &iso ( c<→o< (subst (λ k → odef A k ) (sym &iso ) (A∋fc y f mf cz ))) } 904 λ {z} cz → subst (λ k → k o< & A) &iso ( c<→o< (subst (λ k → odef A k ) (sym &iso ) (A∋fc y f mf cz ))) }
905 905
1097 fcpu {u} {z} fc u≤px = subst (λ k → FClosure A f k z ) (sym (sf1=sf0 u≤px)) fc 1097 fcpu {u} {z} fc u≤px = subst (λ k → FClosure A f k z ) (sym (sf1=sf0 u≤px)) fc
1098 1098
1099 -- this is a kind of maximality, so we cannot prove this without <-monotonicity 1099 -- this is a kind of maximality, so we cannot prove this without <-monotonicity
1100 -- 1100 --
1101 cfcs : (mf< : <-monotonic-f A f) {a b w : Ordinal } 1101 cfcs : (mf< : <-monotonic-f A f) {a b w : Ordinal }
1102 → a o< b → b o≤ x → supf1 a o< x → FClosure A f (supf1 a) w → odef (UnionCF A f mf ay supf1 x) w 1102 → a o< b → b o≤ x → supf1 a o< b → FClosure A f (supf1 a) w → odef (UnionCF A f mf ay supf1 b) w
1103 cfcs mf< {a} {b} {w} a<b b≤x sa<x fc with zc43 (supf0 a) px 1103 cfcs mf< {a} {b} {w} a<b b≤x sa<b fc with zc43 (supf0 a) px
1104 ... | case2 px≤sa = z50 where 1104 ... | case2 px≤sa = z50 where
1105 a≤px : a o≤ px 1105 a≤px : a o≤ px
1106 a≤px = subst (λ k → a o< k) (sym (Oprev.oprev=x op)) (ordtrans<-≤ a<b b≤x) 1106 a≤px = subst (λ k → a o< k) (sym (Oprev.oprev=x op)) (ordtrans<-≤ a<b b≤x)
1107 -- supf0 a ≡ px we cannot use previous cfcs, it is in the chain because 1107 -- supf0 a ≡ px we cannot use previous cfcs, it is in the chain because
1108 -- supf0 a ≡ supf0 (supf0 a) ≡ supf0 px o< x 1108 -- supf0 a ≡ supf0 (supf0 a) ≡ supf0 px o< x
1109 z50 : odef (UnionCF A f mf ay supf1 x) w 1109 z50 : odef (UnionCF A f mf ay supf1 b) w
1110 z50 with osuc-≡< px≤sa 1110 z50 with osuc-≡< px≤sa
1111 ... | case1 px=sa = ⟪ A∋fc {A} _ f mf fc , ch-is-sup (supf0 px) ? ? (subst (λ k → FClosure A f k w) ? fc) ⟫ 1111 ... | case1 px=sa = ⟪ A∋fc {A} _ f mf fc , ch-is-sup (supf0 px) ? ? (subst (λ k → FClosure A f k w) ? fc) ⟫
1112 ... | case2 px<sa = ⊥-elim ( ¬p<x<op ⟪ px<sa , subst₂ (λ j k → j o< k ) (sf1=sf0 a≤px) (sym (Oprev.oprev=x op)) sa<x ⟫ ) 1112 ... | case2 px<sa = ⊥-elim ( ¬p<x<op ⟪ px<sa , subst₂ (λ j k → j o< k ) (sf1=sf0 a≤px) (sym (Oprev.oprev=x op)) ? ⟫ )
1113 ... | case1 sa<px with trio< a px 1113 ... | case1 sa<px with trio< a px
1114 ... | tri< a<px ¬b ¬c = z50 where 1114 ... | tri< a<px ¬b ¬c = z50 where
1115 z50 : odef (UnionCF A f mf ay supf1 x) w 1115 z50 : odef (UnionCF A f mf ay supf1 b) w
1116 z50 with osuc-≡< b≤x 1116 z50 with osuc-≡< b≤x
1117 ... | case2 lt with ZChain.cfcs zc mf< a<b (subst (λ k → b o< k) (sym (Oprev.oprev=x op)) lt) sa<px fc 1117 ... | case2 lt with ZChain.cfcs zc mf< a<b (subst (λ k → b o< k) (sym (Oprev.oprev=x op)) lt) ? fc
1118 ... | ⟪ az , ch-init fc ⟫ = ⟪ az , ch-init fc ⟫ 1118 ... | ⟪ az , ch-init fc ⟫ = ⟪ az , ch-init fc ⟫
1119 ... | ⟪ az , ch-is-sup u u<b is-sup fc ⟫ = ⟪ az , ch-is-sup u ? cp1 (fcpu fc u≤px ) ⟫ where -- u o< px → u o< b ? 1119 ... | ⟪ az , ch-is-sup u u<b is-sup fc ⟫ = ⟪ az , ch-is-sup u u<b cp1 (fcpu fc u≤px ) ⟫ where -- u o< px → u o< b ?
1120 u≤px : u o≤ px 1120 u≤px : u o≤ px
1121 u≤px = subst (λ k → u o< k) (sym (Oprev.oprev=x op)) (ordtrans<-≤ u<b ? ) 1121 u≤px = subst (λ k → u o< k) (sym (Oprev.oprev=x op)) (ordtrans<-≤ u<b b≤x )
1122 u<x : u o< x 1122 u<x : u o< x
1123 u<x = ordtrans<-≤ u<b ? --b≤x 1123 u<x = ordtrans<-≤ u<b b≤x
1124 cp1 : ChainP A f mf ay supf1 u 1124 cp1 : ChainP A f mf ay supf1 u
1125 cp1 = record { fcy<sup = λ {z} fc → subst (λ k → (z ≡ k) ∨ ( z << k ) ) (sf=eq u<x) (ChainP.fcy<sup is-sup fc ) 1125 cp1 = record { fcy<sup = λ {z} fc → subst (λ k → (z ≡ k) ∨ ( z << k ) ) (sf=eq u<x) (ChainP.fcy<sup is-sup fc )
1126 ; order = λ {s} {z} s<u fc → subst (λ k → (z ≡ k) ∨ ( z << k ) ) (sf=eq u<x) 1126 ; order = λ {s} {z} s<u fc → subst (λ k → (z ≡ k) ∨ ( z << k ) ) (sf=eq u<x)
1127 (ChainP.order is-sup (subst₂ (λ j k → j o< k ) (sym (sf=eq (ordtrans (supf-inject0 supf1-mono s<u) u<x) )) 1127 (ChainP.order is-sup (subst₂ (λ j k → j o< k ) (sym (sf=eq (ordtrans (supf-inject0 supf1-mono s<u) u<x) ))
1128 (sym (sf=eq u<x)) s<u) 1128 (sym (sf=eq u<x)) s<u)
1129 (subst (λ k → FClosure A f k z ) (sym (sf=eq (ordtrans (supf-inject0 supf1-mono s<u) u<x) )) fc )) 1129 (subst (λ k → FClosure A f k z ) (sym (sf=eq (ordtrans (supf-inject0 supf1-mono s<u) u<x) )) fc ))
1130 ; supu=u = trans (sym (sf=eq u<x)) (ChainP.supu=u is-sup) } 1130 ; supu=u = trans (sym (sf=eq u<x)) (ChainP.supu=u is-sup) }
1131 z50 | case1 eq with ZChain.cfcs zc mf< a<px o≤-refl sa<px fc 1131 z50 | case1 eq with ZChain.cfcs zc mf< a<px o≤-refl sa<px fc
1132 ... | ⟪ az , ch-init fc ⟫ = ⟪ az , ch-init fc ⟫ 1132 ... | ⟪ az , ch-init fc ⟫ = ⟪ az , ch-init fc ⟫
1133 ... | ⟪ az , ch-is-sup u u<px is-sup fc ⟫ = ⟪ az , ch-is-sup u ? cp1 (fcpu fc (o<→≤ u<px)) ⟫ where -- u o< px → u o< b ? 1133 ... | ⟪ az , ch-is-sup u u<px is-sup fc ⟫ = ⟪ az , ch-is-sup u u<b cp1 (fcpu fc (o<→≤ u<px)) ⟫ where -- u o< px → u o< b ?
1134 u<b : u o< b 1134 u<b : u o< b
1135 u<b = subst (λ k → u o< k ) (trans (Oprev.oprev=x op) (sym eq) ) (ordtrans u<px <-osuc ) 1135 u<b = subst (λ k → u o< k ) (trans (Oprev.oprev=x op) (sym eq) ) (ordtrans u<px <-osuc )
1136 u<x : u o< x 1136 u<x : u o< x
1137 u<x = subst (λ k → u o< k ) (Oprev.oprev=x op) ( ordtrans u<px <-osuc ) 1137 u<x = subst (λ k → u o< k ) (Oprev.oprev=x op) ( ordtrans u<px <-osuc )
1138 cp1 : ChainP A f mf ay supf1 u 1138 cp1 : ChainP A f mf ay supf1 u
1153 ... | tri> ¬a ¬b c = ⊥-elim ( o≤> b≤x c ) -- x o< b 1153 ... | tri> ¬a ¬b c = ⊥-elim ( o≤> b≤x c ) -- x o< b
1154 z51 : FClosure A f (supf1 px) w 1154 z51 : FClosure A f (supf1 px) w
1155 z51 = subst (λ k → FClosure A f k w) (sym (trans (cong supf1 (sym a=px)) (sf1=sf0 (o≤-refl0 a=px) ))) fc 1155 z51 = subst (λ k → FClosure A f k w) (sym (trans (cong supf1 (sym a=px)) (sf1=sf0 (o≤-refl0 a=px) ))) fc
1156 z53 : odef A w 1156 z53 : odef A w
1157 z53 = A∋fc {A} _ f mf fc 1157 z53 = A∋fc {A} _ f mf fc
1158 csupf1 : odef (UnionCF A f mf ay supf1 x) w 1158 csupf1 : odef (UnionCF A f mf ay supf1 b) w
1159 csupf1 with trio< (supf0 px) x 1159 csupf1 with trio< (supf0 px) x
1160 ... | tri< sfpx<x ¬b ¬c = ⟪ z53 , ch-is-sup spx ? cp1 fc1 ⟫ where 1160 ... | tri< sfpx<x ¬b ¬c = ⟪ z53 , ch-is-sup spx (subst (λ k → spx o< k) (sym b=x) sfpx<x) cp1 fc1 ⟫ where
1161 spx = supf0 px 1161 spx = supf0 px
1162 spx≤px : supf0 px o≤ px 1162 spx≤px : supf0 px o≤ px
1163 spx≤px = zc-b<x _ sfpx<x 1163 spx≤px = zc-b<x _ sfpx<x
1164 z52 : supf1 (supf0 px) ≡ supf0 px 1164 z52 : supf1 (supf0 px) ≡ supf0 px
1165 z52 = trans (sf1=sf0 (zc-b<x _ sfpx<x)) ( ZChain.supf-idem zc mf< o≤-refl (zc-b<x _ sfpx<x ) ) 1165 z52 = trans (sf1=sf0 (zc-b<x _ sfpx<x)) ( ZChain.supf-idem zc mf< o≤-refl (zc-b<x _ sfpx<x ) )
1166 fc1 : FClosure A f (supf1 spx) w 1166 fc1 : FClosure A f (supf1 spx) w
1167 fc1 = subst (λ k → FClosure A f k w ) (trans (cong supf0 a=px) (sym z52) ) fc 1167 fc1 = subst (λ k → FClosure A f k w ) (trans (cong supf0 a=px) (sym z52) ) fc
1168 order : {s z1 : Ordinal} → supf1 s o< supf1 spx → FClosure A f (supf1 s) z1 → (z1 ≡ supf1 spx) ∨ (z1 << supf1 spx) 1168 order : {s z1 : Ordinal} → supf1 s o< supf1 spx → FClosure A f (supf1 s) z1 → (z1 ≡ supf1 spx) ∨ (z1 << supf1 spx)
1169 order {s} {z1} ss<spx fcs = subst (λ k → (z1 ≡ k) ∨ (z1 << k )) 1169 order {s} {z1} ss<spx fcs = subst (λ k → (z1 ≡ k) ∨ (z1 << k ))
1170 (trans (sym (ZChain.supf-is-minsup zc spx≤px )) (sym (sf1=sf0 spx≤px) ) ) 1170 (trans (sym (ZChain.supf-is-minsup zc spx≤px )) (sym (sf1=sf0 spx≤px) ) )
1171 (MinSUP.x≤sup (ZChain.minsup zc spx≤px) ? ) where 1171 (MinSUP.x≤sup (ZChain.minsup zc spx≤px) (ZChain.cfcs zc mf< (supf-inject0 supf1-mono ss<spx)
1172 -- (ZChain.cfcs zc mf< (supf-inject0 supf1-mono ss<spx) 1172 spx≤px ? (fcup fcs (ordtrans (supf-inject0 supf1-mono ss<spx) spx≤px ) ))) where
1173 -- spx≤px ss<px (fcup fcs (ordtrans (supf-inject0 supf1-mono ss<spx) spx≤px ) ))) where
1174 ss<px : supf0 s o< px 1173 ss<px : supf0 s o< px
1175 ss<px = osucprev ( begin 1174 ss<px = osucprev ( begin
1176 osuc (supf0 s) ≡⟨ cong osuc (sym (sf1=sf0 ( begin 1175 osuc (supf0 s) ≡⟨ cong osuc (sym (sf1=sf0 ( begin
1177 s <⟨ supf-inject0 supf1-mono ss<spx ⟩ 1176 s <⟨ supf-inject0 supf1-mono ss<spx ⟩
1178 supf0 px ≤⟨ spx≤px ⟩ 1177 supf0 px ≤⟨ spx≤px ⟩
1266 1265
1267 -- supf0 px not is included by the chain 1266 -- supf0 px not is included by the chain
1268 -- supf1 x ≡ supf0 px because of supfmax 1267 -- supf1 x ≡ supf0 px because of supfmax
1269 1268
1270 cfcs : (mf< : <-monotonic-f A f) {a b w : Ordinal } 1269 cfcs : (mf< : <-monotonic-f A f) {a b w : Ordinal }
1271 → a o< b → b o≤ x → supf0 a o< x → FClosure A f (supf0 a) w → odef (UnionCF A f mf ay supf0 x) w 1270 → a o< b → b o≤ x → supf0 a o< b → FClosure A f (supf0 a) w → odef (UnionCF A f mf ay supf0 b) w
1272 cfcs mf< {a} {b} {w} a<b b≤x sa<x fc with trio< b px 1271 cfcs mf< {a} {b} {w} a<b b≤x sa<b fc with trio< b px
1273 ... | tri< a ¬b ¬c = ? -- ZChain.cfcs zc mf< a<b (o<→≤ a) ? fc 1272 ... | tri< a ¬b ¬c = ZChain.cfcs zc mf< a<b (o<→≤ a) ? fc
1274 ... | tri≈ ¬a refl ¬c = ? -- ZChain.cfcs zc mf< a<b o≤-refl ? fc 1273 ... | tri≈ ¬a refl ¬c = ZChain.cfcs zc mf< a<b o≤-refl ? fc
1275 ... | tri> ¬a ¬b px<b with trio< a px 1274 ... | tri> ¬a ¬b px<b with trio< a px
1276 ... | tri< a ¬b ¬c = ? -- chain-mono f mf ay (ZChain.supf zc) (ZChain.supf-mono zc) (o<→≤ px<b) ( ZChain.cfcs zc mf< a o≤-refl ? fc ) 1275 ... | tri< a ¬b ¬c = chain-mono f mf ay (ZChain.supf zc) (ZChain.supf-mono zc) (o<→≤ px<b) ( ZChain.cfcs zc mf< a o≤-refl ? fc )
1277 ... | tri> ¬a ¬b c = ⊥-elim ( o≤> ? c ) 1276 ... | tri> ¬a ¬b c = ⊥-elim ( o≤> ? c )
1278 ... | tri≈ ¬a refl ¬c = ? -- supf0 px o< x → odef (UnionCF A f mf ay supf0 x) (supf0 px) 1277 ... | tri≈ ¬a refl ¬c = ? -- supf0 px o< x → odef (UnionCF A f mf ay supf0 x) (supf0 px)
1279 -- x o≤ supf0 px o≤ sp → 1278 -- x o≤ supf0 px o≤ sp →
1280 1279
1281 zc17 : {z : Ordinal } → supf0 z o≤ supf0 px 1280 zc17 : {z : Ordinal } → supf0 z o≤ supf0 px
1421 ... | tri< a ¬b ¬c = ? 1420 ... | tri< a ¬b ¬c = ?
1422 ... | tri≈ ¬a b ¬c = ? 1421 ... | tri≈ ¬a b ¬c = ?
1423 ... | tri> ¬a ¬b c = ? 1422 ... | tri> ¬a ¬b c = ?
1424 1423
1425 cfcs : (mf< : <-monotonic-f A f) {a b w : Ordinal } 1424 cfcs : (mf< : <-monotonic-f A f) {a b w : Ordinal }
1426 → a o< b → b o≤ x → supf1 a o< x → FClosure A f (supf1 a) w → odef (UnionCF A f mf ay supf1 x) w 1425 → a o< b → b o≤ x → supf1 a o< b → FClosure A f (supf1 a) w → odef (UnionCF A f mf ay supf1 b) w
1427 cfcs mf< {a} {b} {w} a<b b≤x sa<x fc with osuc-≡< b≤x 1426 cfcs mf< {a} {b} {w} a<b b≤x sa<b fc with osuc-≡< b≤x
1428 ... | case1 b=x with trio< a x 1427 ... | case1 b=x with trio< a x
1429 ... | tri< a<x ¬b ¬c = zc40 where 1428 ... | tri< a<x ¬b ¬c = zc40 where
1430 sa = ZChain.supf (pzc (ob<x lim a<x)) a 1429 sa = ZChain.supf (pzc (ob<x lim a<x)) a
1431 m = omax a sa 1430 m = omax a sa
1432 m<x : m o< x 1431 m<x : m o< x
1433 m<x with trio< a sa | inspect (omax a) sa 1432 m<x with trio< a sa | inspect (omax a) sa
1434 ... | tri< a<sa ¬b ¬c | record { eq = eq } = ob<x lim sa<x 1433 ... | tri< a<sa ¬b ¬c | record { eq = eq } = ob<x lim ?
1435 ... | tri≈ ¬a a=sa ¬c | record { eq = eq } = subst (λ k → k o< x) eq zc41 where 1434 ... | tri≈ ¬a a=sa ¬c | record { eq = eq } = subst (λ k → k o< x) eq zc41 where
1436 zc41 : omax a sa o< x 1435 zc41 : omax a sa o< x
1437 zc41 = osucprev ( begin 1436 zc41 = osucprev ( begin
1438 osuc ( omax a sa ) ≡⟨ cong (λ k → osuc (omax a k)) (sym a=sa) ⟩ 1437 osuc ( omax a sa ) ≡⟨ cong (λ k → osuc (omax a k)) (sym a=sa) ⟩
1439 osuc ( omax a a ) ≡⟨ cong osuc (omxx _) ⟩ 1438 osuc ( omax a a ) ≡⟨ cong osuc (omxx _) ⟩
1447 sam<m = subst (λ k → k o< m ) (supf-unique A f mf ay zc42 (pzc (ob<x lim a<x)) (pzc (ob<x lim m<x)) (o<→≤ <-osuc)) ( omax-y _ _ ) 1446 sam<m = subst (λ k → k o< m ) (supf-unique A f mf ay zc42 (pzc (ob<x lim a<x)) (pzc (ob<x lim m<x)) (o<→≤ <-osuc)) ( omax-y _ _ )
1448 fcm : FClosure A f (ZChain.supf (pzc (ob<x lim m<x)) a) w 1447 fcm : FClosure A f (ZChain.supf (pzc (ob<x lim m<x)) a) w
1449 fcm = subst (λ k → FClosure A f k w ) (zeq (ob<x lim a<x) (ob<x lim m<x) zc42 (o<→≤ <-osuc) ) fc 1448 fcm = subst (λ k → FClosure A f k w ) (zeq (ob<x lim a<x) (ob<x lim m<x) zc42 (o<→≤ <-osuc) ) fc
1450 zcm : odef (UnionCF A f mf ay (ZChain.supf (pzc (ob<x lim m<x))) (osuc (omax a sa))) w 1449 zcm : odef (UnionCF A f mf ay (ZChain.supf (pzc (ob<x lim m<x))) (osuc (omax a sa))) w
1451 zcm = ZChain.cfcs (pzc (ob<x lim m<x)) mf< (o<→≤ (omax-x _ _)) o≤-refl (o<→≤ sam<m) fcm 1450 zcm = ZChain.cfcs (pzc (ob<x lim m<x)) mf< (o<→≤ (omax-x _ _)) o≤-refl (o<→≤ sam<m) fcm
1452 zc40 : odef (UnionCF A f mf ay supf1 x) w 1451 zc40 : odef (UnionCF A f mf ay supf1 b) w
1453 zc40 with ZChain.cfcs (pzc (ob<x lim m<x)) mf< (o<→≤ (omax-x _ _)) o≤-refl (o<→≤ sam<m) fcm 1452 zc40 with ZChain.cfcs (pzc (ob<x lim m<x)) mf< (o<→≤ (omax-x _ _)) o≤-refl (o<→≤ sam<m) fcm
1454 ... | ⟪ az , ch-init fc ⟫ = ⟪ az , ch-init fc ⟫ 1453 ... | ⟪ az , ch-init fc ⟫ = ⟪ az , ch-init fc ⟫
1455 ... | ⟪ az , ch-is-sup u u<x is-sup fc1 ⟫ = ⟪ az , ch-is-sup u ? ? fc2 ⟫ where -- u o< px → u o< b ? 1454 ... | ⟪ az , ch-is-sup u u<x is-sup fc1 ⟫ = ⟪ az , ch-is-sup u u<b ? fc2 ⟫ where -- u o< px → u o< b ?
1456 zc55 : u o< osuc m 1455 zc55 : u o< osuc m
1457 zc55 = u<x 1456 zc55 = u<x
1458 u<b : u o< b -- b o≤ u → b o≤ a -- u ≡ supf1 a 1457 u<b : u o< b -- b o≤ u → b o≤ a -- u ≡ supf1 a
1459 u<b = subst (λ k → u o< k ) (sym b=x) ( ordtrans u<x (ob<x lim m<x)) 1458 u<b = subst (λ k → u o< k ) (sym b=x) ( ordtrans u<x (ob<x lim m<x))
1460 fc1m : FClosure A f (ZChain.supf (pzc (ob<x lim m<x)) u) w 1459 fc1m : FClosure A f (ZChain.supf (pzc (ob<x lim m<x)) u) w
1465 fc2 = subst (λ k → FClosure A f k w) (trans (sym (zeq _ _ zc57 (o<→≤ <-osuc))) (sym (sf1=sf (ordtrans≤-< u<x m<x))) ) fc1 where 1464 fc2 = subst (λ k → FClosure A f k w) (trans (sym (zeq _ _ zc57 (o<→≤ <-osuc))) (sym (sf1=sf (ordtrans≤-< u<x m<x))) ) fc1 where
1466 zc57 : osuc u o≤ osuc m 1465 zc57 : osuc u o≤ osuc m
1467 zc57 = osucc u<x 1466 zc57 = osucc u<x
1468 ... | tri≈ ¬a b ¬c = ⊥-elim ( ¬a (ordtrans<-≤ a<b b≤x)) 1467 ... | tri≈ ¬a b ¬c = ⊥-elim ( ¬a (ordtrans<-≤ a<b b≤x))
1469 ... | tri> ¬a ¬b c = ⊥-elim ( ¬a (ordtrans<-≤ a<b b≤x)) 1468 ... | tri> ¬a ¬b c = ⊥-elim ( ¬a (ordtrans<-≤ a<b b≤x))
1470 cfcs mf< {a} {b} {w} a<b b≤x sa<x fc | case2 b<x = zc40 where 1469 cfcs mf< {a} {b} {w} a<b b≤x sa<b fc | case2 b<x = zc40 where
1471 supfb = ZChain.supf (pzc (ob<x lim b<x)) 1470 supfb = ZChain.supf (pzc (ob<x lim b<x))
1472 fcb : FClosure A f (supfb a) w 1471 fcb : FClosure A f (supfb a) w
1473 fcb = ? 1472 fcb = ?
1474 -- supfb a o≤ supfb b 1473 -- supfb a o≤ supfb b
1475 -- supfb (supfb a) o≤ supfb b
1476 sa<b : supfb a o< osuc b 1474 sa<b : supfb a o< osuc b
1477 sa<b = ? 1475 sa<b = ?
1478 zcb : odef (UnionCF A f mf ay supfb x) w 1476 zcb : odef (UnionCF A f mf ay supfb b) w
1479 zcb = ? -- ZChain.cfcs (pzc (ob<x lim b<x)) mf< a<b (o<→≤ <-osuc) sa<b fcb 1477 zcb = ZChain.cfcs (pzc (ob<x lim b<x)) mf< a<b (o<→≤ <-osuc) ? fcb
1480 zc40 : odef (UnionCF A f mf ay supf1 x) w 1478 zc40 : odef (UnionCF A f mf ay supf1 b) w
1481 zc40 with zcb 1479 zc40 with zcb
1482 ... | ⟪ az , ch-init fc ⟫ = ⟪ az , ch-init fc ⟫ 1480 ... | ⟪ az , ch-init fc ⟫ = ⟪ az , ch-init fc ⟫
1483 ... | ⟪ az , ch-is-sup u u<x is-sup fc1 ⟫ = ⟪ az , ch-is-sup u u<x ? ? ⟫ 1481 ... | ⟪ az , ch-is-sup u u<x is-sup fc1 ⟫ = ⟪ az , ch-is-sup u u<x ? ? ⟫
1484 1482
1485 --- 1483 ---