Other Agda modules in this section (43)

Complete compiler-highlighted source. Follow a symbol to its declaration.

# Inverse witnesses from triangles with constant long edge

Move the constant long edge to the displayed endpoint of the given
morphism. The other corners then determine the endpoint frames of its
inverse. Constant-boundary naturality verifies the remaining corner.
This construction needs neither Segal nor Rezk.

```agda
{-# OPTIONS --safe --without-K #-}
open import Agda.Primitive using (Level)
open import SCT.VolumeI.Chapter01.Theory using (Theory)
import SCT.VolumeI.Chapter01.Section04.MappingAnimae as Mapping
import SCT.VolumeI.Chapter01.Section07.FunctorCategories as Categories
import SCT.VolumeI.Chapter01.Section06.PullbackLaws as Laws
import SCT.VolumeI.Chapter02.Section01.WalkingMorphism as Walking
import SCT.VolumeI.Chapter02.Section01.IntervalEndpoints as Endpoints

module SCT.VolumeI.Chapter02.Section03.InverseCalculus.AbsoluteInverseTriangles
  {c m a : Level} (𝒯 : Theory c m a) (M : Mapping.MappingAnimae 𝒯)
  (β„± : Categories.FunctorCategories 𝒯 M) (P : Laws.PullbackStructure 𝒯)
  (I : Walking.WalkingMorphism 𝒯) (E : Endpoints.IntervalEndpoints 𝒯 M β„± P I) where

open import SCT.VolumeI.Chapter02.Section03.Isomorphisms 𝒯 M β„± P I E public
open import SCT.VolumeI.Chapter02.Section01.DiagramCalculus.VertexTransport 𝒯 M β„± P I E
  using (module ConstantBoundary)
open import SCT.VolumeI.Chapter02.Section01.DiagramCalculus.DegenerateCocones 𝒯 M β„± P I E
  using (triangle-edges; triangle-source; upper-edges)
open import SCT.VolumeI.Chapter01.Section04.ProductCalculus.ProductAssociativity 𝒯 M using (cancel-inverse-tail)
import SCT.VolumeI.Chapter01.Section03.ProductCalculus.PairingNaturality as PN
open PN vocabulary terminal products productLaws composition vertical whiskering using (cancel-left)

vertex-equation : {C : CAT} {u v p q z : Obj-abs C}
  (Ξ± : p =₁ z) (Ξ² : q =₁ z) (L : u =₁ p) (R : v =₁ q) (Ξ΄ : u =₁ v) β†’
  (Ξ± βˆ™ L) =β‚‚ (Ξ² βˆ™ (R βˆ™ Ξ΄)) β†’ ((Ξ² ⁻¹ βˆ™ Ξ±) βˆ™ L) =β‚‚ (R βˆ™ Ξ΄)
vertex-equation Ξ± Ξ² L R Ξ΄ Ξ΅ = cancel-left Ξ² (R βˆ™ Ξ΄) βˆ™
  (isoComp-cong (idIso (Ξ² ⁻¹)) Ξ΅ βˆ™ isoComp-assoc-at (Ξ² ⁻¹) Ξ± L)

module MoveConstant {C : CAT} {h : Mor C} {z y : Obj-abs C}
  (long : h =₁ const z) (ρ : z =₁ y) where
  comparison : h =₁ const y
  comparison = (ρ β–· terminate [1]) βˆ™ long

  endpoint : (i : Obj-abs [1]) β†’
    (constant-boundary i y βˆ™ (comparison β–· i)) =β‚‚
      (ρ βˆ™ (constant-boundary i z βˆ™ (long β–· i)))
  endpoint i = isoComp-assoc-at ρ (constant-boundary i z) (long β–· i) βˆ™
    (isoComp-cong (ConstantBoundary.natural ρ i) (idIso (long β–· i)) βˆ™
      ((isoComp-assoc-at (constant-boundary i y) ((ρ β–· terminate [1]) β–· i) (long β–· i)) ⁻¹ βˆ™
        isoComp-cong (idIso (constant-boundary i y))
          (preWhisker-isoComp-at (ρ β–· terminate [1]) long i)))

module Right {C : CAT} {x y z : Obj-abs C} (f : Morphism x y)
  (Οƒ : Triangle C) (Ξ² : (Οƒ ∘ dβ‚€) =₁ Morphism.diagram f)
  (long : (Οƒ ∘ d₁) =₁ const z) where
  private
    module F = Morphism f
    middle = Cocone.match (coconePost Οƒ triangle-edges)
    source-corner = Cocone.match (coconePost Οƒ triangle-source)
    target-corner = Cocone.match (coconePost Οƒ upper-edges)
    target-value = (F.target-identification βˆ™ (Ξ² β–· one)) βˆ™ target-corner ⁻¹
    long-target = constant-boundary one z βˆ™ (long β–· one)
    module Moved = MoveConstant long (target-value βˆ™ long-target ⁻¹)
    source-value = constant-boundary zero y βˆ™ (Moved.comparison β–· zero)
    inverse-source = source-value βˆ™ source-corner ⁻¹
    inverse-target = F.source-identification βˆ™ ((Ξ² β–· zero) βˆ™ middle)

  inverse : Morphism y x
  inverse = record { diagram = Οƒ ∘ dβ‚‚
    ; source-identification = inverse-source ; target-identification = inverse-target }

  private
    middle-equation : (inverse-target βˆ™ (idIso (Οƒ ∘ dβ‚‚) β–· one)) =β‚‚
      (F.source-identification βˆ™ ((Ξ² β–· zero) βˆ™ middle))
    middle-equation = isoComp-unitΚ³-at inverse-target βˆ™
      isoComp-cong (idIso inverse-target) (preWhisker-idIso (Οƒ ∘ dβ‚‚) one)

    source-equation : (constant-boundary zero y βˆ™ (Moved.comparison β–· zero)) =β‚‚
      (inverse-source βˆ™ ((idIso (Οƒ ∘ dβ‚‚) β–· zero) βˆ™ source-corner))
    source-equation = (cancel-inverse-tail source-value source-corner βˆ™
      isoComp-cong (idIso inverse-source) (isoComp-unitΛ‘-at source-corner βˆ™
        isoComp-cong (preWhisker-idIso (Οƒ ∘ dβ‚‚) zero) (idIso source-corner))) ⁻¹

    moved-target : (constant-boundary one y βˆ™ (Moved.comparison β–· one)) =β‚‚ target-value
    moved-target = cancel-inverse-tail target-value long-target βˆ™ Moved.endpoint one

    target-equation : (F.target-identification βˆ™ (Ξ² β–· one)) =β‚‚
      (constant-boundary one y βˆ™ ((Moved.comparison β–· one) βˆ™ target-corner))
    target-equation = (cancel-inverse-tail (F.target-identification βˆ™ (Ξ² β–· one)) target-corner βˆ™
      (isoComp-cong moved-target (idIso target-corner) βˆ™
        (isoComp-assoc-at (constant-boundary one y) (Moved.comparison β–· one) target-corner) ⁻¹)) ⁻¹

  witness : CompositeWitness inverse f (identity-morphism y)
  witness = record
    { triangle = Οƒ ; first-edge = idIso (Οƒ ∘ dβ‚‚) ; second-edge = Ξ² ; long-edge = Moved.comparison
    ; middle-vertex = vertex-equation inverse-target F.source-identification _ _ middle middle-equation
    ; source-vertex = vertex-equation (constant-boundary zero y) inverse-source _ _ source-corner source-equation
    ; target-vertex = vertex-equation F.target-identification (constant-boundary one y) _ _ target-corner target-equation }

module Left {C : CAT} {x y z : Obj-abs C} (f : Morphism x y)
  (Οƒ : Triangle C) (Ξ± : (Οƒ ∘ dβ‚‚) =₁ Morphism.diagram f)
  (long : (Οƒ ∘ d₁) =₁ const z) where
  private
    module F = Morphism f
    middle = Cocone.match (coconePost Οƒ triangle-edges)
    source-corner = Cocone.match (coconePost Οƒ triangle-source)
    target-corner = Cocone.match (coconePost Οƒ upper-edges)
    source-value = (F.source-identification βˆ™ (Ξ± β–· zero)) βˆ™ source-corner
    long-source = constant-boundary zero z βˆ™ (long β–· zero)
    module Moved = MoveConstant long (source-value βˆ™ long-source ⁻¹)
    target-value = constant-boundary one x βˆ™ (Moved.comparison β–· one)
    inverse-source = (F.target-identification βˆ™ (Ξ± β–· one)) βˆ™ middle ⁻¹
    inverse-target = target-value βˆ™ target-corner

  inverse : Morphism y x
  inverse = record { diagram = Οƒ ∘ dβ‚€
    ; source-identification = inverse-source ; target-identification = inverse-target }

  private
    middle-equation : (F.target-identification βˆ™ (Ξ± β–· one)) =β‚‚
      (inverse-source βˆ™ ((idIso (Οƒ ∘ dβ‚€) β–· zero) βˆ™ middle))
    middle-equation = (cancel-inverse-tail (F.target-identification βˆ™ (Ξ± β–· one)) middle βˆ™
      isoComp-cong (idIso inverse-source) (isoComp-unitΛ‘-at middle βˆ™
        isoComp-cong (preWhisker-idIso (Οƒ ∘ dβ‚€) zero) (idIso middle))) ⁻¹

    source-equation : (constant-boundary zero x βˆ™ (Moved.comparison β–· zero)) =β‚‚
      (F.source-identification βˆ™ ((Ξ± β–· zero) βˆ™ source-corner))
    source-equation = isoComp-assoc-at F.source-identification (Ξ± β–· zero) source-corner βˆ™
      (cancel-inverse-tail source-value long-source βˆ™ Moved.endpoint zero)

    target-equation : (inverse-target βˆ™ (idIso (Οƒ ∘ dβ‚€) β–· one)) =β‚‚
      (constant-boundary one x βˆ™ ((Moved.comparison β–· one) βˆ™ target-corner))
    target-equation = isoComp-assoc-at (constant-boundary one x) (Moved.comparison β–· one) target-corner βˆ™
      (isoComp-unitΚ³-at inverse-target βˆ™
        isoComp-cong (idIso inverse-target) (preWhisker-idIso (Οƒ ∘ dβ‚€) one))

  witness : CompositeWitness f inverse (identity-morphism x)
  witness = record
    { triangle = Οƒ ; first-edge = Ξ± ; second-edge = idIso (Οƒ ∘ dβ‚€) ; long-edge = Moved.comparison
    ; middle-vertex = vertex-equation F.target-identification inverse-source _ _ middle middle-equation
    ; source-vertex = vertex-equation (constant-boundary zero x) F.source-identification _ _ source-corner source-equation
    ; target-vertex = vertex-equation inverse-target (constant-boundary one x) _ _ target-corner target-equation }
```