Mercurial > hg > Members > kono > Proof > ZF-in-agda
comparison src/zorn.agda @ 976:8fe873f0c88e
is-max condition have to be b o< x
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Tue, 08 Nov 2022 18:29:35 +0900 |
parents | 1e88cce74699 |
children | f0d2666fe3b2 |
comparison
equal
deleted
inserted
replaced
975:1e88cce74699 | 976:8fe873f0c88e |
---|---|
522 | 522 |
523 record ZChain1 ( A : HOD ) ( f : Ordinal → Ordinal ) (mf : ≤-monotonic-f A f) | 523 record ZChain1 ( A : HOD ) ( f : Ordinal → Ordinal ) (mf : ≤-monotonic-f A f) |
524 {y : Ordinal} (ay : odef A y) (zc : ZChain A f mf ay (& A)) ( z : Ordinal ) : Set (Level.suc n) where | 524 {y : Ordinal} (ay : odef A y) (zc : ZChain A f mf ay (& A)) ( z : Ordinal ) : Set (Level.suc n) where |
525 supf = ZChain.supf zc | 525 supf = ZChain.supf zc |
526 field | 526 field |
527 is-max : {a b : Ordinal } → (ca : odef (UnionCF A f mf ay supf z) a ) → supf b o< supf z → (ab : odef A b) | 527 is-max : {a b : Ordinal } → (ca : odef (UnionCF A f mf ay supf z) a ) → b o< z → (ab : odef A b) |
528 → HasPrev A (UnionCF A f mf ay supf z) f b ∨ IsSUP A (UnionCF A f mf ay supf b) ab | 528 → HasPrev A (UnionCF A f mf ay supf z) f b ∨ IsSUP A (UnionCF A f mf ay supf b) ab |
529 → * a < * b → odef ((UnionCF A f mf ay supf z)) b | 529 → * a < * b → odef ((UnionCF A f mf ay supf z)) b |
530 order : {b s z1 : Ordinal} → b o< & A → supf s o< supf b → FClosure A f (supf s) z1 → (z1 ≡ supf b) ∨ (z1 << supf b) | 530 order : {b s z1 : Ordinal} → b o< & A → supf s o< supf b → FClosure A f (supf s) z1 → (z1 ≡ supf b) ∨ (z1 << supf b) |
531 | 531 |
532 record Maximal ( A : HOD ) : Set (Level.suc n) where | 532 record Maximal ( A : HOD ) : Set (Level.suc n) where |
697 ... | yes op = record { is-max = is-max ; order = order } where | 697 ... | yes op = record { is-max = is-max ; order = order } where |
698 px = Oprev.oprev op | 698 px = Oprev.oprev op |
699 zc-b<x : {b : Ordinal } → ZChain.supf zc b o< ZChain.supf zc x → b o< osuc px | 699 zc-b<x : {b : Ordinal } → ZChain.supf zc b o< ZChain.supf zc x → b o< osuc px |
700 zc-b<x {b} lt = subst (λ k → b o< k ) (sym (Oprev.oprev=x op)) (ZChain.supf-inject zc lt ) | 700 zc-b<x {b} lt = subst (λ k → b o< k ) (sym (Oprev.oprev=x op)) (ZChain.supf-inject zc lt ) |
701 is-max : {a : Ordinal} {b : Ordinal} → odef (UnionCF A f mf ay supf x) a → | 701 is-max : {a : Ordinal} {b : Ordinal} → odef (UnionCF A f mf ay supf x) a → |
702 ZChain.supf zc b o< ZChain.supf zc x → (ab : odef A b) → | 702 b o< x → (ab : odef A b) → |
703 HasPrev A (UnionCF A f mf ay supf x) f b ∨ IsSUP A (UnionCF A f mf ay supf b) ab → | 703 HasPrev A (UnionCF A f mf ay supf x) f b ∨ IsSUP A (UnionCF A f mf ay supf b) ab → |
704 * a < * b → odef (UnionCF A f mf ay supf x) b | 704 * a < * b → odef (UnionCF A f mf ay supf x) b |
705 is-max {a} {b} ua b<x ab P a<b with ODC.or-exclude O P | 705 is-max {a} {b} ua b<x ab P a<b with ODC.or-exclude O P |
706 is-max {a} {b} ua b<x ab P a<b | case1 has-prev = is-max-hp x {a} {b} ua ab has-prev a<b | 706 is-max {a} {b} ua b<x ab P a<b | case1 has-prev = is-max-hp x {a} {b} ua ab has-prev a<b |
707 is-max {a} {b} ua sb<sx ab P a<b | case2 is-sup | 707 is-max {a} {b} ua b<x ab P a<b | case2 is-sup |
708 = ⟪ ab , ch-is-sup b sb<sx m06 (subst (λ k → FClosure A f k b) (sym m05) (init ab refl)) ⟫ where | 708 = ⟪ ab , ch-is-sup b sb<sx m06 (subst (λ k → FClosure A f k b) (sym m05) (init ab refl)) ⟫ where |
709 b<A : b o< & A | 709 b<A : b o< & A |
710 b<A = z09 ab | 710 b<A = z09 ab |
711 b<x : b o< x | 711 sb<sx : supf b o< supf x |
712 b<x = ZChain.supf-inject zc sb<sx | 712 sb<sx = ? |
713 m04 : ¬ HasPrev A (UnionCF A f mf ay supf b) f b | 713 m04 : ¬ HasPrev A (UnionCF A f mf ay supf b) f b |
714 m04 nhp = proj1 is-sup ( record { ax = HasPrev.ax nhp ; y = HasPrev.y nhp ; ay = | 714 m04 nhp = proj1 is-sup ( record { ax = HasPrev.ax nhp ; y = HasPrev.y nhp ; ay = |
715 chain-mono1 (o<→≤ b<x) (HasPrev.ay nhp) ; x=fy = HasPrev.x=fy nhp } ) | 715 chain-mono1 (o<→≤ b<x) (HasPrev.ay nhp) ; x=fy = HasPrev.x=fy nhp } ) |
716 m05 : ZChain.supf zc b ≡ b | 716 m05 : ZChain.supf zc b ≡ b |
717 m05 = ZChain.sup=u zc ab (o<→≤ (z09 ab) ) ⟪ record { x≤sup = λ {z} uz → IsSUP.x≤sup (proj2 is-sup) uz } , m04 ⟫ | 717 m05 = ZChain.sup=u zc ab (o<→≤ (z09 ab) ) ⟪ record { x≤sup = λ {z} uz → IsSUP.x≤sup (proj2 is-sup) uz } , m04 ⟫ |
722 m09 {s} {z} s<b fcz = order b<A s<b fcz | 722 m09 {s} {z} s<b fcz = order b<A s<b fcz |
723 m06 : ChainP A f mf ay supf b | 723 m06 : ChainP A f mf ay supf b |
724 m06 = record { fcy<sup = m08 ; order = m09 ; supu=u = m05 } | 724 m06 = record { fcy<sup = m08 ; order = m09 ; supu=u = m05 } |
725 ... | no lim = record { is-max = is-max ; order = order } where | 725 ... | no lim = record { is-max = is-max ; order = order } where |
726 is-max : {a : Ordinal} {b : Ordinal} → odef (UnionCF A f mf ay supf x) a → | 726 is-max : {a : Ordinal} {b : Ordinal} → odef (UnionCF A f mf ay supf x) a → |
727 ZChain.supf zc b o< ZChain.supf zc x → (ab : odef A b) → | 727 b o< x → (ab : odef A b) → |
728 HasPrev A (UnionCF A f mf ay supf x) f b ∨ IsSUP A (UnionCF A f mf ay supf b) ab → | 728 HasPrev A (UnionCF A f mf ay supf x) f b ∨ IsSUP A (UnionCF A f mf ay supf b) ab → |
729 * a < * b → odef (UnionCF A f mf ay supf x) b | 729 * a < * b → odef (UnionCF A f mf ay supf x) b |
730 is-max {a} {b} ua sb<sx ab P a<b with ODC.or-exclude O P | 730 is-max {a} {b} ua sb<sx ab P a<b with ODC.or-exclude O P |
731 is-max {a} {b} ua sb<sx ab P a<b | case1 has-prev = is-max-hp x {a} {b} ua ab has-prev a<b | 731 is-max {a} {b} ua sb<sx ab P a<b | case1 has-prev = is-max-hp x {a} {b} ua ab has-prev a<b |
732 is-max {a} {b} ua sb<sx ab P a<b | case2 is-sup with IsSUP.x≤sup (proj2 is-sup) (init-uchain A f mf ay ) | 732 is-max {a} {b} ua sb<sx ab P a<b | case2 is-sup with IsSUP.x≤sup (proj2 is-sup) (init-uchain A f mf ay ) |
733 ... | case1 b=y = ⟪ subst (λ k → odef A k ) b=y ay , ch-init (subst (λ k → FClosure A f y k ) b=y (init ay refl )) ⟫ | 733 ... | case1 b=y = ⟪ subst (λ k → odef A k ) b=y ay , ch-init (subst (λ k → FClosure A f y k ) b=y (init ay refl )) ⟫ |
734 ... | case2 y<b = ⟪ ab , ch-is-sup b sb<sx m06 (subst (λ k → FClosure A f k b) (sym m05) (init ab refl)) ⟫ where | 734 ... | case2 y<b = ⟪ ab , ch-is-sup b ? m06 (subst (λ k → FClosure A f k b) (sym m05) (init ab refl)) ⟫ where |
735 m09 : b o< & A | 735 m09 : b o< & A |
736 m09 = subst (λ k → k o< & A) &iso ( c<→o< (subst (λ k → odef A k ) (sym &iso ) ab)) | 736 m09 = subst (λ k → k o< & A) &iso ( c<→o< (subst (λ k → odef A k ) (sym &iso ) ab)) |
737 b<x : b o< x | 737 b<x : b o< x |
738 b<x = ZChain.supf-inject zc sb<sx | 738 b<x = ZChain.supf-inject zc ? |
739 m07 : {z : Ordinal} → FClosure A f y z → z <= ZChain.supf zc b | 739 m07 : {z : Ordinal} → FClosure A f y z → z <= ZChain.supf zc b |
740 m07 {z} fc = ZChain.fcy<sup zc (o<→≤ m09) fc | 740 m07 {z} fc = ZChain.fcy<sup zc (o<→≤ m09) fc |
741 m08 : {s z1 : Ordinal} → ZChain.supf zc s o< ZChain.supf zc b | 741 m08 : {s z1 : Ordinal} → ZChain.supf zc s o< ZChain.supf zc b |
742 → FClosure A f (ZChain.supf zc s) z1 → z1 <= ZChain.supf zc b | 742 → FClosure A f (ZChain.supf zc s) z1 → z1 <= ZChain.supf zc b |
743 m08 {s} {z1} s<b fc = order m09 s<b fc | 743 m08 {s} {z1} s<b fc = order m09 s<b fc |
1475 → MinSUP A (UnionCF A f mf ay (ZChain.supf zc) x) | 1475 → MinSUP A (UnionCF A f mf ay (ZChain.supf zc) x) |
1476 msp0 f mf {x} ay zc = minsupP (UnionCF A f mf ay (ZChain.supf zc) x) (ZChain.chain⊆A zc) (ZChain.f-total zc) | 1476 msp0 f mf {x} ay zc = minsupP (UnionCF A f mf ay (ZChain.supf zc) x) (ZChain.chain⊆A zc) (ZChain.f-total zc) |
1477 | 1477 |
1478 fixpoint : ( f : Ordinal → Ordinal ) → (mf : ≤-monotonic-f A f ) (zc : ZChain A f mf as0 (& A) ) | 1478 fixpoint : ( f : Ordinal → Ordinal ) → (mf : ≤-monotonic-f A f ) (zc : ZChain A f mf as0 (& A) ) |
1479 → (sp1 : MinSUP A (ZChain.chain zc)) | 1479 → (sp1 : MinSUP A (ZChain.chain zc)) |
1480 → (ssp<as : ZChain.supf zc (MinSUP.sup sp1) o< ZChain.supf zc (& A)) | |
1481 → f (MinSUP.sup sp1) ≡ MinSUP.sup sp1 | 1480 → f (MinSUP.sup sp1) ≡ MinSUP.sup sp1 |
1482 fixpoint f mf zc sp1 ssp<as = z14 where | 1481 fixpoint f mf zc sp1 = z14 where |
1483 chain = ZChain.chain zc | 1482 chain = ZChain.chain zc |
1484 supf = ZChain.supf zc | 1483 supf = ZChain.supf zc |
1485 sp : Ordinal | 1484 sp : Ordinal |
1486 sp = MinSUP.sup sp1 | 1485 sp = MinSUP.sup sp1 |
1487 asp : odef A sp | 1486 asp : odef A sp |
1488 asp = MinSUP.asm sp1 | 1487 asp = MinSUP.asm sp1 |
1489 z10 : {a b : Ordinal } → (ca : odef chain a ) → supf b o< supf (& A) → (ab : odef A b ) | 1488 z10 : {a b : Ordinal } → (ca : odef chain a ) → b o< & A → (ab : odef A b ) |
1490 → HasPrev A chain f b ∨ IsSUP A (UnionCF A f mf as0 (ZChain.supf zc) b) ab | 1489 → HasPrev A chain f b ∨ IsSUP A (UnionCF A f mf as0 (ZChain.supf zc) b) ab |
1491 → * a < * b → odef chain b | 1490 → * a < * b → odef chain b |
1492 z10 = ZChain1.is-max (SZ1 f mf as0 zc (& A) ) | 1491 z10 = ZChain1.is-max (SZ1 f mf as0 zc (& A) ) |
1493 z22 : sp o< & A | 1492 z22 : sp o< & A |
1494 z22 = z09 asp | 1493 z22 = z09 asp |
1495 z12 : odef chain sp | 1494 z12 : odef chain sp |
1496 z12 with o≡? (& s) sp | 1495 z12 with o≡? (& s) sp |
1497 ... | yes eq = subst (λ k → odef chain k) eq ( ZChain.chain∋init zc ) | 1496 ... | yes eq = subst (λ k → odef chain k) eq ( ZChain.chain∋init zc ) |
1498 ... | no ne = ZChain1.is-max (SZ1 f mf as0 zc (& A)) {& s} {sp} ( ZChain.chain∋init zc ) ssp<as asp (case2 z19 ) z13 where | 1497 ... | no ne = ZChain1.is-max (SZ1 f mf as0 zc (& A)) {& s} {sp} ( ZChain.chain∋init zc ) z22 asp (case2 z19 ) z13 where |
1499 z13 : * (& s) < * sp | 1498 z13 : * (& s) < * sp |
1500 z13 with MinSUP.x≤sup sp1 ( ZChain.chain∋init zc ) | 1499 z13 with MinSUP.x≤sup sp1 ( ZChain.chain∋init zc ) |
1501 ... | case1 eq = ⊥-elim ( ne eq ) | 1500 ... | case1 eq = ⊥-elim ( ne eq ) |
1502 ... | case2 lt = lt | 1501 ... | case2 lt = lt |
1503 z19 : IsSUP A (UnionCF A f mf as0 (ZChain.supf zc) sp) asp | 1502 z19 : IsSUP A (UnionCF A f mf as0 (ZChain.supf zc) sp) asp |
1542 | 1541 |
1543 z04 : (nmx : ¬ Maximal A ) → (zc : ZChain A (cf nmx) (cf-is-≤-monotonic nmx) as0 (& A)) → ⊥ | 1542 z04 : (nmx : ¬ Maximal A ) → (zc : ZChain A (cf nmx) (cf-is-≤-monotonic nmx) as0 (& A)) → ⊥ |
1544 z04 nmx zc = <-irr0 {* (cf nmx a)} {* a} | 1543 z04 nmx zc = <-irr0 {* (cf nmx a)} {* a} |
1545 (subst (λ k → odef A k ) (sym &iso) (proj1 (is-cf nmx (MinSUP.asm asup )))) | 1544 (subst (λ k → odef A k ) (sym &iso) (proj1 (is-cf nmx (MinSUP.asm asup )))) |
1546 (subst (λ k → odef A k) (sym &iso) (MinSUP.asm asup) ) | 1545 (subst (λ k → odef A k) (sym &iso) (MinSUP.asm asup) ) |
1547 (case1 ( cong (*)( fixpoint (cf nmx) (cf-is-≤-monotonic nmx ) zc asup sa<sa ))) -- x ≡ f x ̄ | 1546 (case1 ( cong (*)( fixpoint (cf nmx) (cf-is-≤-monotonic nmx ) zc asup ))) -- x ≡ f x ̄ |
1548 (proj1 (cf-is-<-monotonic nmx a (MinSUP.asm asup ))) where -- x < f x | 1547 (proj1 (cf-is-<-monotonic nmx a (MinSUP.asm asup ))) where -- x < f x |
1549 | 1548 |
1550 supf = ZChain.supf zc | 1549 supf = ZChain.supf zc |
1551 asup : MinSUP A (ZChain.chain zc) | 1550 asup : MinSUP A (ZChain.chain zc) |
1552 asup = msp0 (cf nmx) (cf-is-≤-monotonic nmx) as0 zc | 1551 asup = msp0 (cf nmx) (cf-is-≤-monotonic nmx) as0 zc |
1553 a : Ordinal | 1552 a : Ordinal |
1554 a = MinSUP.sup asup | 1553 a = MinSUP.sup asup |
1555 a<A : a o< & A | 1554 a<A : a o< & A |
1556 a<A = ∈∧P→o< ⟪ MinSUP.asm asup , lift true ⟫ | 1555 a<A = ∈∧P→o< ⟪ MinSUP.asm asup , lift true ⟫ |
1557 | |
1558 csup : MinSUP A (UnionCF A (cf nmx) (cf-is-≤-monotonic nmx) as0 supf a) | |
1559 csup = ZChain.minsup zc (o<→≤ a<A) | |
1560 c : Ordinal | |
1561 c = MinSUP.sup csup | |
1562 ac : odef A c | |
1563 ac = ? | |
1564 sfc=c : supf a ≡ c | |
1565 sfc=c = ZChain.supf-is-minsup zc (o<→≤ a<A) | |
1566 c<A : c o< & A | |
1567 c<A = ∈∧P→o< ⟪ MinSUP.asm csup , lift true ⟫ | |
1568 | |
1569 dsup : MinSUP A (UnionCF A (cf nmx) (cf-is-≤-monotonic nmx) as0 supf c) | |
1570 dsup = ZChain.minsup zc (o<→≤ c<A) | |
1571 d : Ordinal | |
1572 d = MinSUP.sup dsup | |
1573 ad : odef A d | |
1574 ad = ? | |
1575 sfc=d : supf c ≡ d | |
1576 sfc=d = ZChain.supf-is-minsup zc (o<→≤ c<A) | |
1577 d<A : d o< & A | |
1578 d<A = ∈∧P→o< ⟪ MinSUP.asm dsup , lift true ⟫ | |
1579 | |
1580 zc40 : uchain (cf nmx) (cf-is-≤-monotonic nmx) ac ⊆' UnionCF A (cf nmx) (cf-is-≤-monotonic nmx) as0 supf d | |
1581 zc40 = ? | |
1582 | |
1583 sc<<d : {mc : Ordinal } → (asc : odef A (supf mc)) → (spd : MinSUP A (uchain (cf nmx) (cf-is-≤-monotonic nmx) asc )) | |
1584 → supf mc << MinSUP.sup spd | |
1585 sc<<d {mc} asc spd = z25 where | |
1586 d1 : Ordinal | |
1587 d1 = MinSUP.sup spd -- supf d1 ≡ d | |
1588 z24 : (supf mc ≡ d1) ∨ ( supf mc << d1 ) | |
1589 z24 = MinSUP.x≤sup spd (init asc refl) | |
1590 -- | |
1591 -- f ( f .. ( supf mc ) <= d1 | |
1592 -- f d1 <= d1 | |
1593 -- | |
1594 z25 : supf mc << d1 | |
1595 z25 with z24 | |
1596 ... | case2 lt = lt | |
1597 ... | case1 eq = ⊥-elim ( <-irr z29 (proj1 (cf-is-<-monotonic nmx d1 (MinSUP.asm spd)) ) ) where | |
1598 -- supf mc ≡ d1 | |
1599 z32 : ((cf nmx (supf mc)) ≡ d1) ∨ ( (cf nmx (supf mc)) << d1 ) | |
1600 z32 = MinSUP.x≤sup spd (fsuc _ (init asc refl)) | |
1601 z29 : (* (cf nmx d1) ≡ * d1) ∨ (* (cf nmx d1) < * d1) | |
1602 z29 with z32 | |
1603 ... | case1 eq1 = case1 (cong (*) (trans (cong (cf nmx) (sym eq)) eq1) ) | |
1604 ... | case2 lt = case2 (subst (λ k → * k < * d1 ) (cong (cf nmx) eq) lt) | |
1605 | |
1606 -- supf a ≡ c o< d ≡ supf c o≤ supf (& A) | |
1607 | |
1608 sa<sa : supf a o< supf (& A) | |
1609 sa<sa = ? | |
1610 | 1556 |
1611 zorn00 : Maximal A | 1557 zorn00 : Maximal A |
1612 zorn00 with is-o∅ ( & HasMaximal ) -- we have no Level (suc n) LEM | 1558 zorn00 with is-o∅ ( & HasMaximal ) -- we have no Level (suc n) LEM |
1613 ... | no not = record { maximal = ODC.minimal O HasMaximal (λ eq → not (=od∅→≡o∅ eq)) ; as = zorn01 ; ¬maximal<x = zorn02 } where | 1559 ... | no not = record { maximal = ODC.minimal O HasMaximal (λ eq → not (=od∅→≡o∅ eq)) ; as = zorn01 ; ¬maximal<x = zorn02 } where |
1614 -- yes we have the maximal | 1560 -- yes we have the maximal |