Other Agda modules in this section (47)
- AbsoluteMorphisms
- CommutativeSquareAxiom
- CoreCoproducts
- DiagramCalculus.CoconeAssociativity
- DiagramCalculus.CompositeWitnesses
- DiagramCalculus.DegenerateCocones
- DiagramCalculus.DiagramComparisons
- DiagramCalculus.ExpressionComparisons
- DiagramCalculus.FramedCocones
- DiagramCalculus.IdentityBoundaries
- DiagramCalculus.IdentityComposites
- DiagramCalculus.IdentityPreservation
- DiagramCalculus.JunctionCalculus
- DiagramCalculus.MiddleVertex
- DiagramCalculus.MorphismComparisons
- DiagramCalculus.OuterVertices
- DiagramCalculus.SliceFibers
- DiagramCalculus.TriangleCorners
- DiagramCalculus.UniversalComparisons
- DiagramCalculus.VertexTransport
- EvaluationCalculus.ConstantConeComparison
- EvaluationCalculus.ConstantConeFrames
- EvaluationCalculus.ConstantConeNaturality
- EvaluationCalculus.ConstantDiagramEvaluation
- EvaluationCalculus.ConstantDiagramNaturality
- EvaluationCalculus.CoreInclusions
- EvaluationCalculus.EndpointEvaluation
- EvaluationCalculus.EndpointFibers
- EvaluationCalculus.EndpointNaturality
- Everything
- HomAndSlices
- IntervalCore
- IntervalEndpoints
- Lattice
- SquareCalculus.FourPoints
- SquareCalculus.LatticePullbacks
- SquareCalculus.LatticeUniqueness
- SquareCalculus.SquareCalculus
- SquareCalculus.SquareFamilies
- SquareCalculus.SquareRetractions
- SquareCalculus.SquareShape
- SquareGluing
- TriangleCore
- TrianglesAndComposites
- UniversalArrows
- WalkingMorphism
- WalkingTriangle
Complete compiler-highlighted source. Follow a symbol to its declaration.
Corresponding book passages
- Morphisms and their endpoints
- Natural transformations
- Arrow categories and hom categories
- Morphism expressions with endpoint comparisons
- From primitive identifications to morphisms
- A morphism is an interval diagram
- Source of a morphism
- Target of a morphism
- A morphism with fixed endpoints
- Source and target functors
- Natural transformations as morphisms
- The uncurried transformation diagram
- The arrow category
- Identifications between morphism expressions
- Identity morphisms
- The underlying arrow of the identity isomorphism
# Morphisms, natural transformations, and the arrow category Three declarations describe different aspects of `def:Morphisms`. `Ar C = Fun [1] C` is the internal arrow category. `Mor C = MAP [1] C` is the external type of absolute interval diagrams. `Morphism x y` equips such a diagram with identifications of its source and target with the specified objects `x` and `y`. `NatTrans C D` is a morphism of `Fun C D`; its two endpoint functors are determined by the diagram. `MorphismExpression`, below, uses the arrow category to describe a family with specified endpoints. No property of the interval beyond its two objects is used in these definitions. ```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.Chapter02.Section01.WalkingMorphism as Walking module SCT.VolumeI.Chapter02.Section01.Morphisms {c m a : Level} (π― : Theory c m a) (M : Mapping.MappingAnimae π―) (β± : Categories.FunctorCategories π― M) (I : Walking.WalkingMorphism π―) where open import SCT.VolumeI.Chapter02.Section01.EvaluationCalculus.EndpointEvaluation π― M β± public open import SCT.VolumeI.Chapter01.Section07.EvaluationCalculus.IsomorphismLifting π― M β± using (funIsoReflect) open Walking.WalkingMorphism I public Ar : CAT β CAT Ar C = Fun [1] C Mor : CAT β Set m Mor C = MAP [1] C source target : {C : CAT} β Mor C β Obj-abs C source f = f β zero target f = f β one evβ evβ : {C : CAT} β MAP (Ar C) C evβ = evaluate zero evβ = evaluate one record Morphism {C : CAT} (x y : Obj-abs C) : Set m where field diagram : Mor C source-identification : (source diagram) =β x target-identification : (target diagram) =β y NatTrans : (C D : CAT) β Set m NatTrans C D = Mor (Fun C D) transformation-diagram : {C D : CAT} β NatTrans C D β MAP ([1] Γ C) D transformation-diagram = funUncurry diagram-transformation : {C D : CAT} β MAP ([1] Γ C) D β NatTrans C D diagram-transformation = funCurry transformation-Ξ² : {C D : CAT} (H : MAP ([1] Γ C) D) β (transformation-diagram (diagram-transformation H)) =β H transformation-Ξ² = funCurry-Ξ² transformation-Ξ· : {C D : CAT} (Ξ± : NatTrans C D) β (diagram-transformation (transformation-diagram Ξ±)) =β Ξ± transformation-Ξ· = funCurry-Ξ· ``` The following record is `con:Morphism_Expressions`. Its comparisons retain compatibility with the displayed source and target, not just the interval diagram. Currying and the endpoint evaluation comparison relate it to the book's presentation by a functor `Ξ Γ [1] β C`. ```agda record MorphismExpression {Ξ C : CAT} (f g : MAP Ξ C) : Set m where field arrow : MAP Ξ (Ar C) source-frame : (evβ β arrow) =β f target-frame : (evβ β arrow) =β g record ExpressionIso {Ξ C : CAT} {f g : MAP Ξ C} (Ξ± Ξ² : MorphismExpression f g) : Set m where field comparison : (MorphismExpression.arrow Ξ±) =β (MorphismExpression.arrow Ξ²) source-compatible : (MorphismExpression.source-frame Ξ² β (evβ β comparison)) =β (MorphismExpression.source-frame Ξ±) target-compatible : (MorphismExpression.target-frame Ξ² β (evβ β comparison)) =β (MorphismExpression.target-frame Ξ±) expression : {Ξ C : CAT} {f g : MAP Ξ C} (H : MAP (Ξ Γ [1]) C) β (H β insert zero) =β f β (H β insert one) =β g β MorphismExpression f g expression H Ξ± Ξ² = record { arrow = funCurry H ; source-frame = Ξ± β evaluate-curry zero H ; target-frame = Ξ² β evaluate-curry one H } restrict-expression : {Ξ Ξ C : CAT} {f g : MAP Ξ C} β MorphismExpression f g β (r : MAP Ξ Ξ) β MorphismExpression (f β r) (g β r) restrict-expression Ξ± r = record { arrow = MorphismExpression.arrow Ξ± β r ; source-frame = (MorphismExpression.source-frame Ξ± β· r) β (comp-assoc r (MorphismExpression.arrow Ξ±) evβ) β»ΒΉ ; target-frame = (MorphismExpression.target-frame Ξ± β· r) β (comp-assoc r (MorphismExpression.arrow Ξ±) evβ) β»ΒΉ } retarget-expression : {Ξ C : CAT} {f g fβ² gβ² : MAP Ξ C} β MorphismExpression f g β f =β fβ² β g =β gβ² β MorphismExpression fβ² gβ² retarget-expression Ξ± p q = record { arrow = MorphismExpression.arrow Ξ± ; source-frame = p β MorphismExpression.source-frame Ξ± ; target-frame = q β MorphismExpression.target-frame Ξ± } identityArrow : {C : CAT} β MAP C (Ar C) identityArrow {C} = constantDiagram [1] C identity-source : {C : CAT} β (evβ β identityArrow) =β (id C) identity-source = evaluate-constant zero identity-target : {C : CAT} β (evβ β identityArrow) =β (id C) identity-target = evaluate-constant one identity-boundary : {Ξ C : CAT} (x : Obj-abs [1]) (f : MAP Ξ C) β ((f β prβ) β insert x) =β f identity-boundary x f = comp-unitΚ³ f β ((f β pair-Ξ²β _ _) β comp-assoc (insert x) prβ f) constant-boundary : {C : CAT} (y : Obj-abs [1]) (x : Obj-abs C) β (const x β y) =β x constant-boundary y x = comp-unitΚ³ x β ((x β terminal-iso (terminate [1] β y) (id One)) β comp-assoc y (terminate [1]) x) identity-expression : {Ξ C : CAT} (f : MAP Ξ C) β MorphismExpression f f identity-expression f = expression (f β prβ) (identity-boundary zero f) (identity-boundary one f) isomorphism-expression : {Ξ C : CAT} {f g : MAP Ξ C} β f =β g β MorphismExpression f g isomorphism-expression {f = f} Ξ± = record { arrow = MorphismExpression.arrow (identity-expression f) ; source-frame = MorphismExpression.source-frame (identity-expression f) ; target-frame = Ξ± β MorphismExpression.target-frame (identity-expression f) } post-boundary : {Ξ C D : CAT} (x : Obj-abs [1]) (F : MAP C D) (h : MAP Ξ (Ar C)) {f : MAP Ξ C} β (evaluate x β h) =β f β (evaluate x β (funPost F β h)) =β (F β f) post-boundary x F h p = (F β (p β (evaluate-uncurry x h) β»ΒΉ)) β (comp-assoc (insert x) (funUncurry h) F β ((funPost-uncurry F h β· insert x) β evaluate-uncurry x (funPost F β h))) post-expression : {Ξ C D : CAT} (F : MAP C D) {f g : MAP Ξ C} β MorphismExpression f g β MorphismExpression (F β f) (F β g) post-expression F Ξ± = record { arrow = funPost F β MorphismExpression.arrow Ξ± ; source-frame = post-boundary zero F (MorphismExpression.arrow Ξ±) (MorphismExpression.source-frame Ξ±) ; target-frame = post-boundary one F (MorphismExpression.arrow Ξ±) (MorphismExpression.target-frame Ξ±) } post-identity-arrow : {Ξ C D : CAT} (F : MAP C D) (f : MAP Ξ C) β (MorphismExpression.arrow (post-expression F (identity-expression f))) =β (MorphismExpression.arrow (identity-expression (F β f))) post-identity-arrow F f = funIsoReflect _ _ ((funCurry-Ξ² ((F β f) β prβ)) β»ΒΉ β ((comp-assoc prβ f F) β»ΒΉ β ((F β funCurry-Ξ² (f β prβ)) β funPost-uncurry F (funCurry (f β prβ))))) ```