Skip to content

Commit e49f84f

Browse files
committed
make implicit + rename isExact so the names are more descriptive
1 parent 6363fa4 commit e49f84f

File tree

2 files changed

+22
-27
lines changed

2 files changed

+22
-27
lines changed

Cubical/Algebra/Group/Exact.agda

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -30,17 +30,17 @@ private
3030
variable
3131
ℓ ℓ' : Level
3232

33-
-- Exactness except the intersecting Group is only propositionally equal
34-
isWeakExactAt : {A B B' C : Group ℓ} (f : GroupHom A B) (g : GroupHom B' C) (p : B ≡ B') Type ℓ
35-
isWeakExactAt {ℓ = ℓ} {B = B} {B' = B'} f g p = (b : ⟨ B ⟩) (isInKer g (tr b) isInIm f b) × (isInIm f b isInKer g (tr b)) where
36-
tr = λ (b : ⟨ B ⟩) subst (λ (a : Σ (Type ℓ) GroupStr) fst a) p b
37-
38-
isExactAt : {A B C : Group ℓ} (f : GroupHom A B) (g : GroupHom B C) Type ℓ
39-
isExactAt {B = B} f g = (b : ⟨ B ⟩) (isInKer g b isInIm f b) × (isInIm f b isInKer g b)
33+
record IsExactAt {ℓ ℓ' ℓ'' : Level}
34+
{A : Group ℓ} {B : Group ℓ'} {C : Group ℓ''}
35+
(f : GroupHom A B) (g : GroupHom B C) (b : ⟨ B ⟩)
36+
: Type (ℓ-max ℓ (ℓ-max ℓ' ℓ'')) where
37+
field
38+
im∈ker : isInIm f b isInKer g b
39+
ker∈im : isInKer g b isInIm f b
40+
open IsExactAt public
4041

41-
isWeakExactAtRefl : {A B C : Group ℓ} (f : GroupHom A B) (g : GroupHom B C)
42-
isWeakExactAt f g refl ≡ isExactAt f g
43-
isWeakExactAtRefl {ℓ = ℓ} {B = B} f g i = (b : ⟨ B ⟩) (isInKer g (transportRefl b i) isInIm f b) × (isInIm f b isInKer g (transportRefl b i))
42+
IsExact : {A B C : Group ℓ} (f : GroupHom A B) (g : GroupHom B C) Type ℓ
43+
IsExact {B = B} f g = (b : ⟨ B ⟩) IsExactAt f g b
4444

4545
SES→isEquiv : {L R : Group ℓ-zero}
4646
{G : Group ℓ} {H : Group ℓ'}

Cubical/Algebra/Group/Five.agda

Lines changed: 12 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -29,12 +29,12 @@ private
2929
ℓ ℓ' : Level
3030

3131
module _
32-
(A B C D E A' B' C' D' E' : Group ℓ)
33-
(f : GroupHom A B) (g : GroupHom B C) (h : GroupHom C D) (j : GroupHom D E)
34-
(l : GroupHom A A') (m : BijectionIso B B') (n : GroupHom C C') (p : BijectionIso D D') (q : GroupHom E E')
35-
(r : GroupHom A' B') (s : GroupHom B' C') (t : GroupHom C' D') (u : GroupHom D' E')
36-
(fg : isExactAt f g) (gh : isExactAt g h) (hj : isExactAt h j)
37-
(rs : isExactAt r s) (st : isExactAt s t) (tu : isExactAt t u)
32+
{A B C D E A' B' C' D' E' : Group ℓ}
33+
{f : GroupHom A B} {g : GroupHom B C} {h : GroupHom C D} {j : GroupHom D E}
34+
{l : GroupHom A A'} {m : BijectionIso B B'} {n : GroupHom C C'} {p : BijectionIso D D'} {q : GroupHom E E'}
35+
{r : GroupHom A' B'} {s : GroupHom B' C'} {t : GroupHom C' D'} {u : GroupHom D' E'}
36+
(fg : IsExact f g) (gh : IsExact g h) (hj : IsExact h j)
37+
(rs : IsExact r s) (st : IsExact s t) (tu : IsExact t u)
3838
(lSurj : isSurjective l)
3939
(qInj : isInjective q)
4040
(sq1 : (a : fst A) r .fst (l .fst a) ≡ m .fun .fst (f .fst a))
@@ -65,7 +65,7 @@ module _
6565
c-in-ker[h] = h[c]≡0
6666

6767
c-in-im[g] : isInIm g c
68-
c-in-im[g] = gh c .fst c-in-ker[h]
68+
c-in-im[g] = gh c .ker∈im c-in-ker[h]
6969

7070
rest : (b : ⟨ B ⟩) (g .fst b ≡ c) goalTy
7171

@@ -89,7 +89,7 @@ module _
8989
m[b]-in-ker[s] = s[m[b]]≡0
9090

9191
m[b]-in-im[r] : isInIm r m[b]
92-
m[b]-in-im[r] = rs m[b] .fst m[b]-in-ker[s]
92+
m[b]-in-im[r] = rs m[b] .ker∈im m[b]-in-ker[s]
9393

9494
rest2 : (a' : ⟨ A' ⟩) (r .fst a' ≡ m[b]) (a : ⟨ A ⟩) l .fst a ≡ a' goalTy
9595

@@ -118,7 +118,7 @@ module _
118118
f[a]-in-im[f] = ∣ a , refl ∣₁
119119

120120
f[a]-in-ker[g] : isInKer g (f .fst a)
121-
f[a]-in-ker[g] = fg (f .fst a) .snd f[a]-in-im[f]
121+
f[a]-in-ker[g] = fg (f .fst a) .im∈ker f[a]-in-im[f]
122122

123123
g[f[a]]≡0 : g .fst (f .fst a) ≡ C .snd .GroupStr.1g
124124
g[f[a]]≡0 = f[a]-in-ker[g]
@@ -158,8 +158,7 @@ module _
158158
u[p[d]]≡q[j[d]] = sq4 d
159159

160160
d'-in-ker[u] : isInKer u d'
161-
d'-in-ker[u] = let im[t]→ker[u] = tu d' .snd in
162-
im[t]→ker[u] ∣ (c' , refl) ∣₁
161+
d'-in-ker[u] = tu d' .im∈ker ∣ (c' , refl) ∣₁
163162

164163
u[p[d]]≡0 : u[p[d]] ≡ E' .snd .GroupStr.1g
165164
u[p[d]]≡0 = cong (u .fst) p[d]≡t[c'] ∙ d'-in-ker[u]
@@ -174,9 +173,7 @@ module _
174173
d-in-ker[j] = j[d]≡0
175174

176175
d-in-im[h] : isInIm h d
177-
d-in-im[h] =
178-
let ker[j]→im[h] = hj d .fst in
179-
ker[j]→im[h] d-in-ker[j]
176+
d-in-im[h] = hj d .ker∈im d-in-ker[j]
180177

181178
rest : (c : ⟨ C ⟩) h .fst c ≡ d goalTy
182179

@@ -216,9 +213,7 @@ module _
216213
[c'-n[c]]-in-ker[t] = t[c'-n[c]]≡0
217214

218215
[c'-n[c]]-in-im[s] : isInIm s c'-n[c]
219-
[c'-n[c]]-in-im[s] =
220-
let ker[t]→im[s] = st c'-n[c] .fst in
221-
ker[t]→im[s] [c'-n[c]]-in-ker[t]
216+
[c'-n[c]]-in-im[s] = st c'-n[c] .ker∈im [c'-n[c]]-in-ker[t]
222217

223218
rest2 : (b' : ⟨ B' ⟩) s .fst b' ≡ c'-n[c] goalTy
224219

0 commit comments

Comments
 (0)