module Cat.Functor.Algebra.Limits where

Limits in categories of F-algebrasπŸ”—

This short note details the construction of limits in categories of F-algebras from limits in the underlying category.

Let be an endofunctor, and be a diagram of If has a limit of then is the limit of in

  Forget-algebra-lift-limit : Limit (Ο€αΆ  (F-Algebras F) F∘ K) β†’ Limit K
  Forget-algebra-lift-limit L = to-limit (to-is-limit L') where
    module L = Limit L
    open make-is-limit

As noted earlier, the underlying object of the limit is The algebra is constructed via the universal property of to give a map it suffices to give maps for every which we can construct by composing the projection with the algebra

    apex : FAlg.Ob F
    apex .fst = L.apex
    apex .snd = L.universal (Ξ» j β†’ K.β‚€ j .snd ∘ F.₁ (L.ψ j)) comm where abstract
      comm
        : βˆ€ {i j : J.Ob} (f : J.Hom i j)
        β†’ K.₁ f .fst ∘ K.β‚€ i .snd ∘ F.₁ (L.ψ i) ≑ K.β‚€ j .snd ∘ F.₁ (L.ψ j)
      comm {i} {j} f =
        K.₁ f .fst ∘ K.β‚€ i .snd ∘ F.₁ (L.ψ i)         β‰‘βŸ¨ pulll (K.₁ f .snd) βŸ©β‰‘
        (K.β‚€ j .snd ∘ F.₁ (K.₁ f .fst)) ∘ F.₁ (L.ψ i) β‰‘βŸ¨ F.pullr (L.commutes f) βŸ©β‰‘
        K.β‚€ j .snd ∘ F.₁ (L.ψ j)                      ∎

A short series of calculations shows that the projections and universal map associated to are homomorphisms.

    L' : make-is-limit K apex
    L' .ψ j .fst = L.ψ j
    L' .ψ j .snd = L.factors _ _
    L' .universal eps p .fst =
      L.universal (Ξ» j β†’ eps j .fst) (Ξ» f β†’ ap fst (p f))
    L' .universal eps p .snd =
      L.uniqueβ‚‚ (Ξ» j β†’ K.Fβ‚€ j .snd ∘ F.₁ (eps j .fst))
        (Ξ» f β†’ pulll (K.₁ f .snd) βˆ™ F.pullr (ap fst (p f)))
        (Ξ» j β†’ pulll (L.factors _ _) βˆ™ eps j .snd)
        (Ξ» j β†’ pulll (L.factors _ _) βˆ™ F.pullr (L.factors _ _))

Finally, equality of morphisms of is given by equality on the underlying morphisms, so all of the relevant diagrams in commute.

    L' .commutes f =
      ∫Hom-path (F-Algebras F) (L.commutes f) prop!
    L' .factors eps p =
      ∫Hom-path (F-Algebras F) (L.factors _ _) prop!
    L' .unique eps p other q =
      ∫Hom-path (F-Algebras F) (L.unique _ _ _ Ξ» j β†’ ap fst (q j)) prop!

This gives us the following useful corollary: if is then is also complete.

  FAlg-is-complete : (F : Functor C C) β†’ is-complete oΞΊ β„“ΞΊ (FAlg F)
  FAlg-is-complete F K = Forget-algebra-lift-limit F K (complete (Ο€αΆ  (F-Algebras F) F∘ K))