11{- Eilenberg-MacLane Spaces: https://anders.groupoid.space/mathematics/homotopy/KGn/
22
3- Implemented using primitives:
3+ Implemented using strict primitives:
44 - W-types (via nat-ind) for space indexing.
55 - Coequalizers (via KG1 and suspension) for group and loop structure.
6- - Hub and Spoke Disc (via truncation ) for homotopy level control.
6+ - Hub and Spoke Disc (via truncationw ) for homotopy level control.
77
88 Copyright (c) Groupoid Infinity, 2014-2026. -}
99
@@ -12,65 +12,65 @@ import library/foundations/mltt/natw
1212import library/mathematics/algebra/algebra
1313import library/mathematics/homotopy/KG1
1414import library/mathematics/homotopy/suspension
15- import library/mathematics/homotopy/truncation
15+ import library/mathematics/homotopy/truncationw
16+ import library/mathematics/homotopy/Snw
1617import library/mathematics/homotopy/loop
1718
1819-- Pointed type helper
1920def Pointed : U := summa (Ak : U), Ak
2021
21- -- Pointed loop space tower
22- def OmegaRefl (A : U) (a : A) : nat → Pointed
23- := nat-ind (λ (k : nat), Pointed) (A, a) (λ (k : nat) (prev : Pointed), (Path prev.1 prev.2 prev.2, <_> prev.2))
22+ -- Pointed loop space tower using nat-iter for cleaner normalization
23+ def OmegaRefl (A : U) (a : A) : natw → Pointed
24+ := nat-iter Pointed (A, a) (λ (prev : Pointed), (Path prev.1 prev.2 prev.2, <_> prev.2))
2425
25- def Ωⁿ (A : U) (a : A) (n : nat ) : U := (OmegaRefl A a n).1
26- def reflⁿ (A : U) (a : A) (n : nat ) : Ωⁿ A a n := (OmegaRefl A a n).2
26+ def Ωⁿ (A : U) (a : A) (n : natw ) : U := (OmegaRefl A a n).1
27+ def reflⁿ (A : U) (a : A) (n : natw ) : Ωⁿ A a n := (OmegaRefl A a n).2
2728
28- -- Optimized recursive steps to avoid nested nat-ind blowup
29- def K-next (G : abgroup) (k : nat ) : U
30- := nat-ind (λ (m : nat), U) (K1 (G.1, G.2.1)) (λ (m : nat) ( pm : U), trunc (𝚺 pm) (succ (succ m ))) k
29+ -- Optimized recursive steps using nat-iter
30+ def K-next (G : abgroup) (k : natw ) : U
31+ := nat-iter U (K1 (G.1, G.2.1)) (λ (pm : U), truncw (𝚺 pm) (succw (succw zerow ))) k
3132
32- def K-point-next (G : abgroup) (k : nat) : K-next G k
33- := nat-ind (λ (m : nat), K-next G m) (K1-point (G.1, G.2.1)) (λ (m : nat) (pm : K-next G m), trunc₁ (𝚺 (K-next G m)) (succ (succ m)) (𝜎₁ (K-next G m))) k
33+ -- Note: We use a simplified K-point-next that maintains judgmental stability
34+ def K-point-next (G : abgroup) (k : natw) : K-next G k
35+ := nat-iter (K-next G k) (K1-point (G.1, G.2.1)) (λ (pm : K-next G k), trunc₁w (𝚺 (K-next G k)) (succw (succw zerow)) (𝜎₁ (K-next G k))) k
3436
3537-- K(G, n) definition
36- def Kn (G : abgroup) : nat → U
37- := nat-ind (λ (k : nat ), U) (discreteTopology G) (λ (k : nat ) (prev : U), K-next G k)
38+ def Kn (G : abgroup) : natw → U
39+ := nat-ind (λ (k : natw ), U) (discreteTopology G) (λ (k : natw ) (prev : U), K-next G k)
3840
39- def K (G : abgroup) (n : nat ) : U := Kn G n
41+ def K (G : abgroup) (n : natw ) : U := Kn G n
4042
4143-- Base point
42- def K-point (G : abgroup) (n : nat ) : K G n
43- := nat-ind (K G) (G.2.1.1.2.2.1) (λ (k : nat ) (pk : K G k), K-point-next G k) n
44+ def K-point (G : abgroup) (n : natw ) : K G n
45+ := nat-ind (K G) (G.2.1.1.2.2.1) (λ (k : natw ) (pk : K G k), K-point-next G k) n
4446
4547-- Functorial Loop Suspension to increase dimension
46- -- With 'natw' and 'irrelevance true', transport workarounds are no longer required .
47- def susp-Ω (A : U) (a : A) (n : nat ) (p : Ωⁿ A a n) : Ωⁿ (𝚺 A) (𝜎₁ A) (succ n)
48- := nat-ind (λ (k : nat ), Ωⁿ A a k → Ωⁿ (𝚺 A) (𝜎₁ A) (succ k))
49- (λ (x : A), <i> hcomp (𝚺 A) (∂ i) (λ (k : I), [ (i = 0) -> reflⁿ (𝚺 A) ( 𝜎₁ A) one @ 0 , (i = 1) -> reflⁿ (𝚺 A) ( 𝜎₁ A) one @ 0 ])
48+ -- With nat-iter, the recursive step boundaries unify judgmentally .
49+ def susp-Ω (A : U) (a : A) (n : natw ) (p : Ωⁿ A a n) : Ωⁿ (𝚺 A) (𝜎₁ A) (succw n)
50+ := nat-ind (λ (k : natw ), Ωⁿ A a k → Ωⁿ (𝚺 A) (𝜎₁ A) (succw k))
51+ (λ (x : A), <i> hcomp (𝚺 A) (∂ i) (λ (k : I), [ (i = 0) -> 𝜎₁ A, (i = 1) -> 𝜎₁ A ])
5052 (comp-Path (𝚺 A) (𝜎₁ A) (𝜎₂ A) (𝜎₁ A) (𝜎₃ A x) (<j> 𝜎₃ A a @ -j) @ i))
51- (λ (k : nat) (prev : Ωⁿ A a k → Ωⁿ (𝚺 A) (𝜎₁ A) (succ k)) (pk : Ωⁿ A a (succ k)),
52- <j> hcomp (Ωⁿ (𝚺 A) (𝜎₁ A) (succ k)) (∂ j)
53- (λ (l : I), [ (j = 0) -> reflⁿ (𝚺 A) (𝜎₁ A) (succ k), (j = 1) -> reflⁿ (𝚺 A) (𝜎₁ A) (succ k) ])
54- (prev (pk @ j)))
53+ (λ (k : natw) (prev : Ωⁿ A a k → Ωⁿ (𝚺 A) (𝜎₁ A) (succw k)) (pk : Ωⁿ A a (succw k)),
54+ <j> prev (pk @ j))
5555 n p
5656
57- -- Final K-loop definition using recursive dimension increase
58- def K-loop (G : abgroup) (n : nat ) (g : G.1.1) : Ωⁿ (K G n) (K-point G n) n
59- := nat-ind (λ (k : nat ), Ωⁿ (K G k) (K-point G k) k)
57+ -- Final K-loop definition
58+ def K-loop (G : abgroup) (n : natw ) (g : G.1.1) : Ωⁿ (K G n) (K-point G n) n
59+ := nat-ind (λ (k : natw ), Ωⁿ (K G k) (K-point G k) k)
6060 (g)
61- (λ (k : nat ) (prev : Ωⁿ (K G k) (K-point G k) k),
62- <i> trunc₁ (𝚺 (K G k)) (succ (succ k )) (susp-Ω (K G k) (K-point G k) k prev @ i))
61+ (λ (k : natw ) (prev : Ωⁿ (K G k) (K-point G k) k),
62+ <i> trunc₁w (𝚺 (K G k)) (succw (succw zerow )) (susp-Ω (K G k) (K-point G k) k prev @ i))
6363 n
6464
6565-- Induction Principle
66- def K-ind-succ (G : abgroup) (n : nat ) (P : K G (succ n) → U)
67- (nNorth : P (K-point G (succ n)))
68- (nSouth : P (trunc₁ (𝚺 (K G n)) (succ (succ n )) (𝜎₂ (K G n))))
69- (nMerid : Π (x : K G n), PathP (<i> P (trunc₁ (𝚺 (K G n)) (succ (succ n )) (𝜎₃ (K G n) x @ i))) nNorth nSouth)
70- (nHub : Π (f : sphere (succ (succ n )) → K G (succ n)) (nF : Π (s : sphere (succ (succ n ))), P (f s)), P (trunc₂ (K G (succ n)) (succ (succ n )) f))
71- (nSpoke : Π (f : sphere (succ (succ n )) → K G (succ n)) (nF : Π (s : sphere (succ (succ n ))), P (f s)) (s : sphere (succ (succ n ))),
72- PathP (<i> P (trunc₃ (K G (succ n)) (succ (succ n )) f s @ i)) (nHub f nF) (nF s))
73- (z : K G (succ n)) : P z
74- := trunc-ind (𝚺 (K G n)) (succ (succ n )) P
75- (𝚺-ind (K G n) (λ (s : 𝚺 (K G n)), P (trunc₁ (𝚺 (K G n)) (succ (succ n )) s)) nNorth nSouth nMerid)
66+ def K-ind-succ (G : abgroup) (n : natw ) (P : K G (succw n) → U)
67+ (nNorth : P (K-point G (succw n)))
68+ (nSouth : P (trunc₁w (𝚺 (K G n)) (succw (succw zerow )) (𝜎₂ (K G n))))
69+ (nMerid : Π (x : K G n), PathP (<i> P (trunc₁w (𝚺 (K G n)) (succw (succw zerow )) (𝜎₃ (K G n) x @ i))) nNorth nSouth)
70+ (nHub : Π (f : spherew (succw (succw zerow )) → K G (succw n)) (nF : Π (s : spherew (succw (succw zerow ))), P (f s)), P (trunc₂w (K G (succw n)) (succw (succw zerow )) f))
71+ (nSpoke : Π (f : spherew (succw (succw zerow )) → K G (succw n)) (nF : Π (s : spherew (succw (succw zerow ))), P (f s)) (s : spherew (succw (succw zerow ))),
72+ PathP (<i> P (trunc₃w (K G (succw n)) (succw (succw zerow )) f s @ i)) (nHub f nF) (nF s))
73+ (z : K G (succw n)) : P z
74+ := trunc-indw (𝚺 (K G n)) (succw (succw zerow )) P
75+ (𝚺-ind (K G n) (λ (s : 𝚺 (K G n)), P (trunc₁w (𝚺 (K G n)) (succw (succw zerow )) s)) nNorth nSouth nMerid)
7676 nHub nSpoke z
0 commit comments