Mercurial > hg > Members > kono > Proof > ZF-in-agda
comparison src/zorn.agda @ 754:db177d911091
...
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Sat, 23 Jul 2022 18:40:35 +0900 |
parents | b96491f7c775 |
children | b22327e78b03 |
comparison
equal
deleted
inserted
replaced
750:b96491f7c775 | 754:db177d911091 |
---|---|
291 chain⊆A : chain ⊆' A | 291 chain⊆A : chain ⊆' A |
292 chain∋init : odef chain init | 292 chain∋init : odef chain init |
293 initial : {y : Ordinal } → odef chain y → * init ≤ * y | 293 initial : {y : Ordinal } → odef chain y → * init ≤ * y |
294 f-next : {a : Ordinal } → odef chain a → odef chain (f a) | 294 f-next : {a : Ordinal } → odef chain a → odef chain (f a) |
295 f-total : IsTotalOrderSet chain | 295 f-total : IsTotalOrderSet chain |
296 sup=u : {b : Ordinal} → {ab : odef A b} → b o< z → IsSup A chain ab → supf b ≡ b | 296 csupf : {z : Ordinal } → odef chain (supf z) |
297 order : {b sup1 z1 : Ordinal} → b o< z → sup1 o< b → FClosure A f (supf sup1) z1 → z1 << supf b | |
298 | 297 |
299 record ZChain1 ( A : HOD ) ( f : Ordinal → Ordinal ) (mf : ≤-monotonic-f A f) | 298 record ZChain1 ( A : HOD ) ( f : Ordinal → Ordinal ) (mf : ≤-monotonic-f A f) |
300 {init : Ordinal} (ay : odef A init) (zc : ZChain A f mf ay (& A)) ( z : Ordinal ) : Set (Level.suc n) where | 299 {init : Ordinal} (ay : odef A init) (zc : ZChain A f mf ay (& A)) ( z : Ordinal ) : Set (Level.suc n) where |
301 field | 300 field |
302 chain-mono2 : { a b c : Ordinal } → | 301 chain-mono2 : { a b c : Ordinal } → |
451 zc1 x prev with Oprev-p x | 450 zc1 x prev with Oprev-p x |
452 ... | yes op = record { is-max = is-max ; chain-mono2 = chain-mono2 x ; fcy<sup = ? ; sup=u = ? ; order = ? } where | 451 ... | yes op = record { is-max = is-max ; chain-mono2 = chain-mono2 x ; fcy<sup = ? ; sup=u = ? ; order = ? } where |
453 px = Oprev.oprev op | 452 px = Oprev.oprev op |
454 zc-b<x : (b : Ordinal ) → b o< x → b o< osuc px | 453 zc-b<x : (b : Ordinal ) → b o< x → b o< osuc px |
455 zc-b<x b lt = subst (λ k → b o< k ) (sym (Oprev.oprev=x op)) lt | 454 zc-b<x b lt = subst (λ k → b o< k ) (sym (Oprev.oprev=x op)) lt |
455 fcy<sup : {u w : Ordinal} → u o< x → FClosure A f y w → w << ZChain.supf zc u | |
456 fcy<sup {u} {w} u<x fc = ? | |
456 is-max : {a : Ordinal} {b : Ordinal} → odef (UnionCF A f mf ay (ZChain.supf zc) x) a → | 457 is-max : {a : Ordinal} {b : Ordinal} → odef (UnionCF A f mf ay (ZChain.supf zc) x) a → |
457 b o< x → (ab : odef A b) → | 458 b o< x → (ab : odef A b) → |
458 HasPrev A (UnionCF A f mf ay (ZChain.supf zc) x) ab f ∨ IsSup A (UnionCF A f mf ay (ZChain.supf zc) x) ab → | 459 HasPrev A (UnionCF A f mf ay (ZChain.supf zc) x) ab f ∨ IsSup A (UnionCF A f mf ay (ZChain.supf zc) x) ab → |
459 * a < * b → odef (UnionCF A f mf ay (ZChain.supf zc) x) b | 460 * a < * b → odef (UnionCF A f mf ay (ZChain.supf zc) x) b |
460 is-max {a} {b} ua b<x ab (case1 has-prev) a<b = is-max-hp x {a} {b} ua b<x ab has-prev a<b | 461 is-max {a} {b} ua b<x ab (case1 has-prev) a<b = is-max-hp x {a} {b} ua b<x ab has-prev a<b |
575 sp1 : SUP A (ZChain.chain zc) | 576 sp1 : SUP A (ZChain.chain zc) |
576 sp1 = sp0 (cf nmx) (cf-is-≤-monotonic nmx) zc total | 577 sp1 = sp0 (cf nmx) (cf-is-≤-monotonic nmx) zc total |
577 c = & (SUP.sup sp1) | 578 c = & (SUP.sup sp1) |
578 | 579 |
579 inititalChain : ( f : Ordinal → Ordinal ) → (mf : ≤-monotonic-f A f ) {y : Ordinal} (ay : odef A y) → ZChain A f mf ay o∅ | 580 inititalChain : ( f : Ordinal → Ordinal ) → (mf : ≤-monotonic-f A f ) {y : Ordinal} (ay : odef A y) → ZChain A f mf ay o∅ |
580 inititalChain f mf {y} ay = record { supf = isupf ; chain⊆A = λ lt → proj1 lt ; chain∋init = cy | 581 inititalChain f mf {y} ay = record { supf = isupf ; chain⊆A = λ lt → proj1 lt ; chain∋init = cy ; csupf = ? |
581 ; initial = isy ; f-next = inext ; f-total = itotal ; sup=u = λ b<0 → ⊥-elim (¬x<0 b<0) ; order = λ b<0 → ⊥-elim (¬x<0 b<0) } where | 582 ; initial = isy ; f-next = inext ; f-total = itotal ; sup=u = λ b<0 → ⊥-elim (¬x<0 b<0) ; order = λ b<0 → ⊥-elim (¬x<0 b<0) } where |
582 isupf : Ordinal → Ordinal | 583 isupf : Ordinal → Ordinal |
583 isupf z = y | 584 isupf z = y |
584 cy : odef (UnionCF A f mf ay isupf o∅) y | 585 cy : odef (UnionCF A f mf ay isupf o∅) y |
585 cy = ⟪ ay , ch-init (init ay) ⟫ | 586 cy = ⟪ ay , ch-init (init ay) ⟫ |
639 zc7 : y << (ZChain.supf zc) u | 640 zc7 : y << (ZChain.supf zc) u |
640 zc7 = ChainP.fcy<sup is-sup (init ay) | 641 zc7 = ChainP.fcy<sup is-sup (init ay) |
641 pcy : odef pchain y | 642 pcy : odef pchain y |
642 pcy = ⟪ ay , ch-init (init ay) ⟫ | 643 pcy = ⟪ ay , ch-init (init ay) ⟫ |
643 | 644 |
644 supf0 = ZChain.supf (prev px (subst (λ k → px o< k) (Oprev.oprev=x op) <-osuc )) | 645 supf0 = ZChain.supf zc |
646 | |
647 csupf : {z : Ordinal} → odef (UnionCF A f mf ay supf0 x) (supf0 z) | |
648 csupf {z} with ZChain.csupf zc {z} | |
649 ... | ⟪ az , ch-init fc ⟫ = ⟪ az , ch-init fc ⟫ | |
650 ... | ⟪ az , ch-is-sup u u<px is-sup fc ⟫ = ⟪ az , ch-is-sup u (ordtrans u<px px<x ) is-sup fc ⟫ | |
645 | 651 |
646 -- if previous chain satisfies maximality, we caan reuse it | 652 -- if previous chain satisfies maximality, we caan reuse it |
647 -- | 653 -- |
648 no-extension : ZChain A f mf ay x | 654 no-extension : ZChain A f mf ay x |
649 no-extension = record { supf = supf0 | 655 no-extension = record { supf = supf0 |
650 ; initial = pinit ; chain∋init = pcy ; sup=u = sup=u | 656 ; initial = pinit ; chain∋init = pcy ; csupf = csupf |
651 ; chain⊆A = pchain⊆A ; f-next = pnext ; f-total = ptotal ; order = order } where | 657 ; chain⊆A = pchain⊆A ; f-next = pnext ; f-total = ptotal } |
652 sup=u : {b : Ordinal} {ab : odef A b} → b o< x | |
653 → IsSup A (UnionCF A f mf ay supf0 x) ab | |
654 → supf0 b ≡ b | |
655 sup=u {b} {ab} b<x is-sup with trio< b px | |
656 ... | tri< a ¬b ¬c = ZChain.sup=u zc {b} {ab} a record { x<sup = pc20 } where | |
657 pc20 : {z : Ordinal} → odef (UnionCF A f mf ay (ZChain.supf zc) (Oprev.oprev op)) z → (z ≡ b) ∨ (z << b) | |
658 pc20 {z} ⟪ az , ch-init fc ⟫ = | |
659 IsSup.x<sup is-sup ⟪ az , ch-init fc ⟫ | |
660 pc20 {z} ⟪ az , ch-is-sup u u<x is-sup-c fc ⟫ = IsSup.x<sup is-sup | |
661 ⟪ az , ch-is-sup u (subst (λ k → u o< k) (Oprev.oprev=x op) (ordtrans u<x <-osuc)) is-sup-c fc ⟫ | |
662 ... | tri≈ ¬a refl ¬c = ? | |
663 ... | tri> ¬a ¬b c = ⊥-elim ( ¬p<x<op ⟪ c , subst (λ k → b o< k ) (sym (Oprev.oprev=x op)) b<x ⟫ ) | |
664 order : {b sup1 z1 : Ordinal} → b o< x → sup1 o< b → FClosure A f (supf0 sup1) z1 → z1 << supf0 b | |
665 order {b} {s} {z1} b<x s<b fc with trio< b px | |
666 ... | tri< a ¬b ¬c = ZChain.order zc a s<b fc | |
667 ... | tri≈ ¬a refl ¬c = ? | |
668 ... | tri> ¬a ¬b c = ⊥-elim ( ¬p<x<op ⟪ c , subst (λ k → b o< k ) (sym (Oprev.oprev=x op)) b<x ⟫ ) | |
669 | 658 |
670 zc4 : ZChain A f mf ay x | 659 zc4 : ZChain A f mf ay x |
671 zc4 with ODC.∋-p O A (* px) | 660 zc4 with ODC.∋-p O A (* px) |
672 ... | no noapx = no-extension -- ¬ A ∋ p, just skip | 661 ... | no noapx = no-extension -- ¬ A ∋ p, just skip |
673 ... | yes apx with ODC.p∨¬p O ( HasPrev A (ZChain.chain zc ) apx f ) | 662 ... | yes apx with ODC.p∨¬p O ( HasPrev A (ZChain.chain zc ) apx f ) |
674 -- we have to check adding x preserve is-max ZChain A y f mf x | 663 -- we have to check adding x preserve is-max ZChain A y f mf x |
675 ... | case1 pr = no-extension -- we have previous A ∋ z < x , f z ≡ x, so chain ∋ f z ≡ x because of f-next | 664 ... | case1 pr = no-extension -- we have previous A ∋ z < x , f z ≡ x, so chain ∋ f z ≡ x because of f-next |
676 ... | case2 ¬fy<x with ODC.p∨¬p O (IsSup A (ZChain.chain zc ) apx ) | 665 ... | case2 ¬fy<x with ODC.p∨¬p O (IsSup A (ZChain.chain zc ) apx ) |
677 ... | case1 is-sup = -- x is a sup of zc | 666 ... | case1 is-sup = -- x is a sup of zc |
678 record { supf = psupf1 ; chain⊆A = ? ; f-next = ? ; f-total = ? | 667 record { supf = psupf1 ; chain⊆A = ? ; f-next = ? ; f-total = ? ; csupf = ? |
679 ; initial = ? ; chain∋init = ? ; sup=u = ? ; order = ? } where | 668 ; initial = ? ; chain∋init = ? } where |
680 psupf1 : Ordinal → Ordinal | 669 psupf1 : Ordinal → Ordinal |
681 psupf1 z with trio< z x | 670 psupf1 z with trio< z x |
682 ... | tri< a ¬b ¬c = ZChain.supf zc z | 671 ... | tri< a ¬b ¬c = ZChain.supf zc z |
683 ... | tri≈ ¬a b ¬c = x | 672 ... | tri≈ ¬a b ¬c = x |
684 ... | tri> ¬a ¬b c = x | 673 ... | tri> ¬a ¬b c = x |
721 zc7 : y << psupf0 ? | 710 zc7 : y << psupf0 ? |
722 zc7 = ChainP.fcy<sup is-sup (init ay) | 711 zc7 = ChainP.fcy<sup is-sup (init ay) |
723 pcy : odef pchain y | 712 pcy : odef pchain y |
724 pcy = ⟪ ay , ch-init (init ay) ⟫ | 713 pcy = ⟪ ay , ch-init (init ay) ⟫ |
725 | 714 |
726 no-extension : ZChain A f mf ay x | |
727 no-extension = record { initial = pinit ; chain∋init = pcy ; supf = psupf0 | |
728 ; chain⊆A = pchain⊆A ; f-next = pnext ; f-total = ptotal ; sup=u = ? ; order = ? } | |
729 | |
730 usup : SUP A pchain | 715 usup : SUP A pchain |
731 usup = supP pchain (λ lt → proj1 lt) ptotal | 716 usup = supP pchain (λ lt → proj1 lt) ptotal |
732 spu = & (SUP.sup usup) | 717 spu = & (SUP.sup usup) |
733 psupf : Ordinal → Ordinal | 718 psupf : Ordinal → Ordinal |
734 psupf z with trio< z x | 719 psupf z with trio< z x |
735 ... | tri< a ¬b ¬c = ZChain.supf (pzc z a) z | 720 ... | tri< a ¬b ¬c = ZChain.supf (pzc z a) z |
736 ... | tri≈ ¬a b ¬c = spu | 721 ... | tri≈ ¬a b ¬c = spu |
737 ... | tri> ¬a ¬b c = spu | 722 ... | tri> ¬a ¬b c = spu |
738 | 723 |
724 | |
725 csupf :{z : Ordinal} → odef (UnionCF A f mf ay psupf x) (psupf z) | |
726 csupf {z} with trio< z x | |
727 ... | tri< a ¬b ¬c = zc11 where | |
728 zc11 : odef A (ZChain.supf (pzc z a) z) ∧ UChain A f mf ay psupf x (ZChain.supf (pzc z a) z) | |
729 zc11 with ZChain.csupf (pzc z a) {z} | |
730 ... | ⟪ az , ch-init fc ⟫ = ⟪ az , ch-init fc ⟫ | |
731 ... | ⟪ az , ch-is-sup u u<z is-sup fc ⟫ = ⟪ az , ch-is-sup u (ordtrans u<z a) ? (pfc a fc) ⟫ | |
732 ... | tri≈ ¬a b ¬c = ? | |
733 ... | tri> ¬a ¬b c = ? | |
734 | |
735 no-extension : ZChain A f mf ay x | |
736 no-extension = record { initial = ? ; chain∋init = ? ; supf = psupf ; csupf = ? | |
737 ; chain⊆A = ? ; f-next = ? ; f-total = ? } | |
738 | |
739 | |
739 zc5 : ZChain A f mf ay x | 740 zc5 : ZChain A f mf ay x |
740 zc5 with ODC.∋-p O A (* x) | 741 zc5 with ODC.∋-p O A (* x) |
741 ... | no noax = no-extension -- ¬ A ∋ p, just skip | 742 ... | no noax = no-extension -- ¬ A ∋ p, just skip |
742 ... | yes ax with ODC.p∨¬p O ( HasPrev A pchain ax f ) | 743 ... | yes ax with ODC.p∨¬p O ( HasPrev A pchain ax f ) |
743 -- we have to check adding x preserve is-max ZChain A y f mf x | 744 -- we have to check adding x preserve is-max ZChain A y f mf x |
744 ... | case1 pr = no-extension | 745 ... | case1 pr = no-extension |
745 ... | case2 ¬fy<x with ODC.p∨¬p O (IsSup A pchain ax ) | 746 ... | case2 ¬fy<x with ODC.p∨¬p O (IsSup A pchain ax ) |
746 ... | case1 is-sup = record { initial = {!!} ; chain∋init = {!!} ; supf = psupf1 ; sup=u = ? ; order = ? | 747 ... | case1 is-sup = record { initial = {!!} ; chain∋init = {!!} ; supf = psupf1 ; csupf = ? |
747 ; chain⊆A = {!!} ; f-next = {!!} ; f-total = ? } where -- x is a sup of (zc ?) | 748 ; chain⊆A = {!!} ; f-next = {!!} ; f-total = ? } where -- x is a sup of (zc ?) |
748 psupf1 : Ordinal → Ordinal | 749 psupf1 : Ordinal → Ordinal |
749 psupf1 z with trio< z x | 750 psupf1 z with trio< z x |
750 ... | tri< a ¬b ¬c = ZChain.supf (pzc z a) z | 751 ... | tri< a ¬b ¬c = ZChain.supf (pzc z a) z |
751 ... | tri≈ ¬a b ¬c = x | 752 ... | tri≈ ¬a b ¬c = x |