Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactoring of retractions, sections, and equivalences, and adding the 6-for-2 property of equivalences #903

Merged
merged 34 commits into from
Nov 9, 2023
Merged
Show file tree
Hide file tree
Changes from 31 commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
0a52700
typecheck
EgbertRijke Nov 6, 2023
acff8c4
integrating the retracts of maps file
EgbertRijke Nov 6, 2023
c079888
minor edits
EgbertRijke Nov 6, 2023
b497b50
fix link
EgbertRijke Nov 6, 2023
b782af7
make pre-commit
EgbertRijke Nov 6, 2023
9c10a1a
fixing prose
EgbertRijke Nov 6, 2023
5d3b912
make pre-commit
EgbertRijke Nov 6, 2023
1df5297
fix preleft-map-traingle
EgbertRijke Nov 6, 2023
284e2e2
sixth equivalence in 6-for-2
EgbertRijke Nov 6, 2023
c50def6
adding link to nlab
EgbertRijke Nov 6, 2023
96f1f25
further streamlining of the 6-for-2 argument
EgbertRijke Nov 6, 2023
92b6035
fix postleft-map-triangle
EgbertRijke Nov 6, 2023
e4795a0
Merge branch 'master' of github.com:UniMath/agda-unimath into 6-for-2
EgbertRijke Nov 6, 2023
1f3583b
merge
EgbertRijke Nov 6, 2023
e36b1bf
Merge branch 'master' of github.com:UniMath/agda-unimath into 6-for-2
EgbertRijke Nov 6, 2023
c428148
Update src/foundation/retracts-of-maps.lagda.md
EgbertRijke Nov 6, 2023
c9d52d3
Update src/foundation/retracts-of-maps.lagda.md
EgbertRijke Nov 6, 2023
69e7f95
Update src/foundation/retracts-of-maps.lagda.md
EgbertRijke Nov 6, 2023
5530580
Update src/foundation/retracts-of-maps.lagda.md
EgbertRijke Nov 6, 2023
6de63cc
Update src/foundation/retracts-of-maps.lagda.md
EgbertRijke Nov 6, 2023
05b9643
simplification of the proof that retracts of equivalences are equival…
EgbertRijke Nov 6, 2023
21dea0a
make pre-commit
EgbertRijke Nov 6, 2023
b1b31fa
Merge branch 'master' of github.com:UniMath/agda-unimath into 6-for-2
EgbertRijke Nov 6, 2023
ba6e902
small edit
EgbertRijke Nov 6, 2023
bdab6b2
morphisms of arrows
EgbertRijke Nov 7, 2023
2f2c25f
progress on functoriality of fibers
EgbertRijke Nov 8, 2023
59d6786
finished the functorial proof
EgbertRijke Nov 9, 2023
b644bd9
fix
EgbertRijke Nov 9, 2023
db88311
Merge branch 'master' of github.com:UniMath/agda-unimath into 6-for-2
EgbertRijke Nov 9, 2023
24c6ff0
fix link
EgbertRijke Nov 9, 2023
57ac05f
fix fs and gs
EgbertRijke Nov 9, 2023
9a12ea6
Apply suggestions from code review
fredrik-bakke Nov 9, 2023
94a33e0
pre-commit
fredrik-bakke Nov 9, 2023
68954bd
Merge branch 'master' into 6-for-2
fredrik-bakke Nov 9, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
109 changes: 109 additions & 0 deletions src/foundation-core/commuting-squares-of-maps.lagda.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,13 @@ module foundation-core.commuting-squares-of-maps where
<details><summary>Imports</summary>

```agda
open import foundation.action-on-identifications-functions
open import foundation.universe-levels

open import foundation-core.commuting-triangles-of-maps
open import foundation-core.function-types
open import foundation-core.homotopies
open import foundation-core.identity-types
open import foundation-core.whiskering-homotopies
```

Expand Down Expand Up @@ -113,3 +115,110 @@ module _
( pasting-vertical-coherence-square-maps sq-top sq-bottom)) ∙h
( inv-htpy (K ·r top))
```

### Associativity of horizontal pasting

**Proof:** Consider a commuting diagram of the form

```text
α₀ β₀ γ₀
A -----> X -----> U -----> K
| | | |
f | α g | β h | γ | i
V V V V
B -----> Y -----> V -----> L.
α₁ β₁ γ₁
```

Then we can make the following calculation, in which we write `□` for horizontal
pasting of squares:

```text
(α □ β) □ γ
= (γ₁ ·l ((β₁ ·l α) ∙h (β ·r α₀))) ∙h (γ ·r (β₀ ∘ α₀))
= ((γ₁ ·l (β₁ ·l α)) ∙h (γ₁ ·l (β ·r α₀))) ∙h (γ ·r (β₀ ∘ α₀))
= ((γ₁ ∘ β₁) ·l α) ∙h (((γ₁ ·l β) ·r α₀) ∙h ((γ ·r β₀) ·r α₀))
= ((γ₁ ∘ β₁) ·l α) ∙h (((γ₁ ·l β) ∙h (γ ·r β₀)) ·r α₀)
= α □ (β □ γ)
```

```agda
module _
{l1 l2 l3 l4 l5 l6 l7 l8 : Level}
{A : UU l1} {B : UU l2} {X : UU l3} {Y : UU l4} {U : UU l5} {V : UU l6}
{K : UU l7} {L : UU l8}
(α₀ : A → X) (β₀ : X → U) (γ₀ : U → K)
(f : A → B) (g : X → Y) (h : U → V) (i : K → L)
(α₁ : B → Y) (β₁ : Y → V) (γ₁ : V → L)
(α : coherence-square-maps α₀ f g α₁)
(β : coherence-square-maps β₀ g h β₁)
(γ : coherence-square-maps γ₀ h i γ₁)
where

assoc-pasting-horizontal-coherence-square-maps :
pasting-horizontal-coherence-square-maps
( β₀ ∘ α₀)
( γ₀)
( f)
( h)
( i)
( β₁ ∘ α₁)
( γ₁)
( pasting-horizontal-coherence-square-maps α₀ β₀ f g h α₁ β₁ α β)
( γ) ~
pasting-horizontal-coherence-square-maps
( α₀)
( γ₀ ∘ β₀)
( f)
( g)
( i)
( α₁)
( γ₁ ∘ β₁)
( α)
( pasting-horizontal-coherence-square-maps β₀ γ₀ g h i β₁ γ₁ β γ)
assoc-pasting-horizontal-coherence-square-maps a =
( ap
( _∙ _)
( ( ap-concat γ₁ (ap β₁ (α a)) (β (α₀ a))) ∙
( inv (ap (_∙ _) (ap-comp γ₁ β₁ (α a)))))) ∙
( assoc (ap (γ₁ ∘ β₁) (α a)) (ap γ₁ (β (α₀ a))) (γ (β₀ (α₀ a))))
```

### The unit laws for horizontal pasting of commuting squares of maps

#### The left unit law

```agda
module _
{l1 l2 l3 l4 : Level} {A : UU l1} {B : UU l2} {X : UU l3} {Y : UU l4}
(i : A → X) (f : A → B) (g : X → Y) (j : B → Y)
(α : coherence-square-maps i f g j)
where

left-unit-law-pasting-horizontal-coherence-square-maps :
pasting-horizontal-coherence-square-maps id i f f g id j refl-htpy α ~ α
left-unit-law-pasting-horizontal-coherence-square-maps = refl-htpy
```

### The right unit law

```agda
module _
{l1 l2 l3 l4 : Level} {A : UU l1} {B : UU l2} {X : UU l3} {Y : UU l4}
(i : A → X) (f : A → B) (g : X → Y) (j : B → Y)
(α : coherence-square-maps i f g j)
where

right-unit-law-pasting-horizontal-coherence-square-maps :
pasting-horizontal-coherence-square-maps i id f g g j id α refl-htpy ~ α
right-unit-law-pasting-horizontal-coherence-square-maps a =
right-unit ∙ ap-id (α a)
```

## See also

Several structures make essential use of commuting squares of maps:

- [Cones over cospans](foundation.cones-over-cospans.md)
- [Cocones under spans](synthetic-homotopy-theory.cocones-under-spans.md)
- [Morphisms of arrows](foundation.morphisms-arrows.md)
125 changes: 84 additions & 41 deletions src/foundation-core/commuting-triangles-of-maps.lagda.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,9 @@ module foundation-core.commuting-triangles-of-maps where
open import foundation.universe-levels

open import foundation-core.function-types
open import foundation-core.functoriality-function-types
open import foundation-core.homotopies
open import foundation-core.retractions
open import foundation-core.sections
open import foundation-core.whiskering-homotopies
```

Expand All @@ -22,16 +23,16 @@ open import foundation-core.whiskering-homotopies
A triangle of maps

```text
top
A ----> B
\ /
left \ / right
V V
X
top
A ----> B
\ /
left \ / right
V V
X
```

is said to commute if there is a homotopy between the map on the left and the
composite map
is said to **commute** if there is a [homotopy](foundation-core.homotopies.md)
between the map on the left and the composite of the top and right maps:

```text
left ~ right ∘ top.
Expand Down Expand Up @@ -71,46 +72,88 @@ module _
H ∙h (K ·r i)
```

### Any commuting triangle of maps induces a commuting triangle of function spaces
### Coherences of commuting triangles of maps with fixed vertices

This or its opposite should be the coherence in the characterization of
identifications of commuting triangles of maps with fixed end vertices.

```agda
module _
{ l1 l2 l3 l4 : Level} {X : UU l1} {A : UU l2} {B : UU l3}
( left : A → X) (right : B → X) (top : A → B)
{l1 l2 l3 : Level} {X : UU l1} {A : UU l2} {B : UU l3}
(left : A → X) (right : B → X) (top : A → B)
(left' : A → X) (right' : B → X) (top' : A → B)
(c : coherence-triangle-maps left right top)
(c' : coherence-triangle-maps left' right' top')
where

precomp-coherence-triangle-maps :
coherence-triangle-maps left right top →
( W : UU l4) →
coherence-triangle-maps
( precomp left W)
( precomp top W)
( precomp right W)
precomp-coherence-triangle-maps H W = htpy-precomp H W

precomp-coherence-triangle-maps' :
coherence-triangle-maps' left right top →
( W : UU l4) →
coherence-triangle-maps'
( precomp left W)
( precomp top W)
( precomp right W)
precomp-coherence-triangle-maps' H W = htpy-precomp H W
coherence-htpy-triangle-maps :
left ~ left' → right ~ right' → top ~ top' → UU (l1 ⊔ l2)
coherence-htpy-triangle-maps L R T =
c ∙h htpy-comp-horizontal T R ~ L ∙h c'
```

### Coherences of commuting triangles of maps with fixed vertices
## Properties

This or its opposite should be the coherence in the characterization of
identifications of commuting triangles of maps with fixed end vertices.
### If the top map has a section, then the reversed triangle with the section on top commutes

If `t : B → A` is a [section](foundation-core.sections.md) of the top map `h`,
then the triangle

```text
t
B ------> A
\ /
g\ /f
\ /
V V
X,
fredrik-bakke marked this conversation as resolved.
Show resolved Hide resolved
```

commutes.

```agda
coherence-htpy-triangle-maps :
{l1 l2 l3 : Level} {X : UU l1} {A : UU l2} {B : UU l3}
(left : A → X) (right : B → X) (top : A → B)
(left' : A → X) (right' : B → X) (top' : A → B) →
coherence-triangle-maps left right top →
coherence-triangle-maps left' right' top' →
left ~ left' → right ~ right' → top ~ top' → UU (l1 ⊔ l2)
coherence-htpy-triangle-maps left right top left' right' top' c c' L R T =
c ∙h htpy-comp-horizontal T R ~ L ∙h c'
module _
{l1 l2 l3 : Level} {A : UU l1} {B : UU l2} {X : UU l3}
(f : A → X) (g : B → X) (h : A → B) (H : coherence-triangle-maps f g h)
(t : section h)
where

inv-triangle-section : coherence-triangle-maps' g f (map-section h t)
inv-triangle-section =
(H ·r map-section h t) ∙h (g ·l is-section-map-section h t)

triangle-section : coherence-triangle-maps g f (map-section h t)
triangle-section = inv-htpy inv-triangle-section
```

### If the right map has a retraction, then the reversed triangle with the retraction on the right commutes

If `r : X → B` is a retraction of the right map `g` in a triangle `f ~ g ∘ h`,
then the triangle

```text
f
A ------> X
\ /
h\ /r
\ /
V V
B,
fredrik-bakke marked this conversation as resolved.
Show resolved Hide resolved
```

commutes.

```agda
module _
{l1 l2 l3 : Level} {A : UU l1} {B : UU l2} {X : UU l3}
(f : A → X) (g : B → X) (h : A → B) (H : coherence-triangle-maps f g h)
(r : retraction g)
where

inv-triangle-retraction : coherence-triangle-maps' h (map-retraction g r) f
inv-triangle-retraction =
(map-retraction g r ·l H) ∙h (is-retraction-map-retraction g r ·r h)

triangle-retraction : coherence-triangle-maps h (map-retraction g r) f
triangle-retraction = inv-htpy inv-triangle-retraction
```
1 change: 1 addition & 0 deletions src/foundation-core/contractible-types.lagda.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ open import foundation.dependent-pair-types
open import foundation.equality-cartesian-product-types
open import foundation.function-extensionality
open import foundation.implicit-function-types
open import foundation.retracts-of-types
open import foundation.universe-levels

open import foundation-core.cartesian-product-types
Expand Down
Loading