Other Agda modules in this section (18)
- ElementaryYoneda
- Everything
- HomCalculus.ExpressionCancellation
- HomCalculus.FramedFiberImages
- HomCalculus.HomCompositionNaturality
- HomCalculus.HomFamilyPostcomposition
- HomCalculus.HomFiberPostcomposition
- HomCalculus.HomNormalization
- HomCalculus.HomOperations
- HomCalculus.HomPoints
- HomCalculus.HomPostcomposition
- HomCalculus.HomRestriction
- HomCalculus.PullbackEndpointFrames
- HomCalculus.PullbackFamilies
- HomCalculus.PullbackHomMaps
- HomComposition
- HomCompositionDetection
- HomCompositionEquivalences
Complete compiler-highlighted source. Follow a symbol to its declaration.
Explanation (AI-generated): Hom expressions and restriction
# Hom functors and their endpoint coordinates An identification in a hom category retains both endpoint equations. Conversely, an endpoint-preserving identification of expressions gives an identification between the corresponding hom functors. ```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 module SCT.VolumeI.Chapter02.Section06.HomCalculus.HomCoordinates {c m a : Level} (π― : Theory c m a) (M : Mapping.MappingAnimae π―) (β± : Categories.FunctorCategories π― M) (P : Laws.PullbackStructure π―) (I : Walking.WalkingMorphism π―) where open import SCT.VolumeI.Chapter02.Section01.HomAndSlices π― M β± P I public open import SCT.VolumeI.Chapter01.Section06.PullbackSquares π― P import SCT.VolumeI.Chapter01.Section03.Equivalences as TerminalComparisons open TerminalComparisons.TerminalTargets vocabulary terminal products productLaws composition using (terminal-Isoβ) import SCT.VolumeI.Chapter01.Section03.ProductCalculus.PairingCoherence as PC import SCT.VolumeI.Chapter01.Section03.ProductCalculus.PairingNaturality as PN import SCT.VolumeI.Chapter01.Section03.IdentificationCalculus.Structural as Structural open PC vocabulary terminal products productLaws composition vertical whiskering using (pair-cong-comp; pair-cong-Isoβ) open PN vocabulary terminal products productLaws composition vertical whiskering using (pair-pre-natural-substitution; substitution-square-projection) open Structural vocabulary terminal products productLaws composition whiskering using (postWhisker-comp-at) module EncodeComparison {Ξ B C : CAT} (u v : MAP B C) (y : MAP Ξ B) {f g : MorphismExpression (u β y) (v β y)} (Ξ¦ : ExpressionIso f g) where private module F = MorphismExpression f module G = MorphismExpression g Ξ΄ = ExpressionIso.comparison Ξ¦ p = pair-cong F.source-frame F.target-frame q = pair-cong G.source-frame G.target-frame before = pair-pre evβ evβ F.arrow after = pair-pre evβ evβ G.arrow r = (pair-pre u v y) β»ΒΉ d = pair-cong (evβ β Ξ΄) (evβ β Ξ΄) e = endpoints β Ξ΄ paired : (q β d) =β p paired = pair-cong-Isoβ (ExpressionIso.source-compatible Ξ¦) (ExpressionIso.target-compatible Ξ¦) β (pair-cong-comp G.source-frame (evβ β Ξ΄) G.target-frame (evβ β Ξ΄)) β»ΒΉ matching : ((r β (q β after)) β e) =β (r β (p β before)) matching = isoComp-cong (idIso r) (isoComp-cong paired (idIso before)) β (isoComp-cong (idIso r) ((isoComp-assoc-at q d before) β»ΒΉ) β (isoComp-cong (idIso r) (isoComp-cong (idIso q) ((pair-pre-natural-substitution evβ evβ Ξ΄) β»ΒΉ)) β (isoComp-cong (idIso r) (isoComp-assoc-at q after e) β isoComp-assoc-at r (q β after) e))) comparison : ConeIso (EndpointFiber.cone u v y f) (EndpointFiber.cone u v y g) comparison = record { leftIso = Ξ΄ ; rightIso = idIso y ; compatible = (isoComp-unitΛ‘-at (r β (p β before)) β isoComp-cong (postWhisker-idIso (pair u v) y) (idIso (r β (p β before)))) β»ΒΉ β matching } hom-cong : {Ξ C : CAT} {x y : Obj-abs C} {f g : MorphismExpression (const {P = Ξ} x) (const y)} β ExpressionIso f g β hom-intro f =β hom-intro g hom-cong {Ξ} {x = x} {y} Ξ¦ = pullbackLift-cong (EncodeComparison.comparison x y (terminate Ξ) Ξ¦) module ConstantBase {Ξ A C : CAT} (b : MAP A One) (x : Obj-abs C) {h k : MAP Ξ A} (Ξ± : h =β k) where th = terminal-iso (b β h) (terminate Ξ) tk = terminal-iso (b β k) (terminate Ξ) at-h = (x β th) β comp-assoc h b x at-k = (x β tk) β comp-assoc k b x natural : (at-k β ((x β b) β Ξ±)) =β at-h natural = isoComp-cong ((postWhisker x β terminal-Isoβ (tk β (b β Ξ±)) th) β (postWhisker-isoComp-at x tk (b β Ξ±)) β»ΒΉ) (idIso (comp-assoc h b x)) β ((isoComp-assoc-at (x β tk) (x β (b β Ξ±)) (comp-assoc h b x)) β»ΒΉ β (isoComp-cong (idIso (x β tk)) (postWhisker-comp-at Ξ± b x) β isoComp-assoc-at (x β tk) (comp-assoc k b x) ((x β b) β Ξ±))) module HomIdentification {Ξ C : CAT} {x y : Obj-abs C} {h k : MAP Ξ (Hom C x y)} (Ξ± : h =β k) where module H = EndpointFiber x y endpoint : (Ο : MAP (Ar C) C) (z : Obj-abs C) (frame : (Ο β H.arrow) =β (z β H.base)) β (((z β terminal-iso (H.base β k) (terminate Ξ)) β (comp-assoc k H.base z β ((frame β· k) β (comp-assoc k H.arrow Ο) β»ΒΉ))) β (Ο β (H.arrow β Ξ±))) =β ((z β terminal-iso (H.base β h) (terminate Ξ)) β (comp-assoc h H.base z β ((frame β· h) β (comp-assoc h H.arrow Ο) β»ΒΉ))) endpoint Ο z frame = isoComp-assoc-at nh Ah bh β (isoComp-cong (ConstantBase.natural H.base z Ξ±) (idIso bh) β ((isoComp-assoc-at (nk β Ak) ((z β H.base) β Ξ±) bh) β»ΒΉ β (isoComp-cong (idIso (nk β Ak)) (substitution-square-projection Ο H.arrow (z β H.base) frame Ξ±) β (isoComp-assoc-at (nk β Ak) bk (Ο β (H.arrow β Ξ±)) β isoComp-cong ((isoComp-assoc-at nk Ak bk) β»ΒΉ) (idIso (Ο β (H.arrow β Ξ±))))))) where nh = z β terminal-iso (H.base β h) (terminate Ξ) nk = z β terminal-iso (H.base β k) (terminate Ξ) Ah = comp-assoc h H.base z Ak = comp-assoc k H.base z bh = (frame β· h) β (comp-assoc h H.arrow Ο) β»ΒΉ bk = (frame β· k) β (comp-assoc k H.arrow Ο) β»ΒΉ comparison : ExpressionIso (hom-expression h) (hom-expression k) comparison = record { comparison = H.arrow β Ξ± ; source-compatible = endpoint evβ x H.source-frame ; target-compatible = endpoint evβ y H.target-frame } hom-expression-cong : {Ξ C : CAT} {x y : Obj-abs C} {h k : MAP Ξ (Hom C x y)} β h =β k β ExpressionIso (hom-expression h) (hom-expression k) hom-expression-cong = HomIdentification.comparison ```