Kleisli category on a (co)monad #
THIS FILE IS SYNCHRONIZED WITH MATHLIB4. Any changes to this file require a corresponding PR to mathlib4.
This file defines the Kleisli category on a monad (T, η_ T, μ_ T)
as well as the co-Kleisli
category on a comonad (U, ε_ U, δ_ U)
. It also defines the Kleisli adjunction which gives rise to
the monad (T, η_ T, μ_ T)
as well as the co-Kleisli adjunction which gives rise to the comonad
(U, ε_ U, δ_ U)
.
References #
The objects for the Kleisli category of the monad T : monad C
, which are the same
thing as objects of the base category C
.
Equations
Instances for category_theory.kleisli
Equations
- category_theory.kleisli.inhabited T = {default := inhabited.default _inst_2}
The Kleisli category on a monad T
.
cf Definition 5.2.9 in Riehl.
Equations
- category_theory.kleisli.kleisli.category T = {to_category_struct := {to_quiver := {hom := λ (X Y : C), X ⟶ ↑T.obj Y}, id := λ (X : category_theory.kleisli T), T.η.app X, comp := λ (X Y Z : category_theory.kleisli T) (f : X ⟶ Y) (g : Y ⟶ Z), f ≫ ↑T.map g ≫ T.μ.app Z}, id_comp' := _, comp_id' := _, assoc' := _}
The left adjoint of the adjunction which induces the monad (T, η_ T, μ_ T)
.
The right adjoint of the adjunction which induces the monad (T, η_ T, μ_ T)
.
Equations
- category_theory.kleisli.adjunction.from_kleisli T = {obj := λ (X : category_theory.kleisli T), T.to_functor.obj X, map := λ (X Y : category_theory.kleisli T) (f : X ⟶ Y), T.to_functor.map f ≫ T.μ.app Y, map_id' := _, map_comp' := _}
The Kleisli adjunction which gives rise to the monad (T, η_ T, μ_ T)
.
cf Lemma 5.2.11 of Riehl.
Equations
- category_theory.kleisli.adjunction.adj T = category_theory.adjunction.mk_of_hom_equiv {hom_equiv := λ (X : C) (Y : category_theory.kleisli T), equiv.refl (X ⟶ T.to_functor.obj Y), hom_equiv_naturality_left_symm' := _, hom_equiv_naturality_right' := _}
The composition of the adjunction gives the original functor.
The objects for the co-Kleisli category of the comonad U : monad C
, which are the same
thing as objects of the base category C
.
Equations
Instances for category_theory.cokleisli
Equations
- category_theory.cokleisli.inhabited U = {default := inhabited.default _inst_2}
The co-Kleisli category on a comonad U
.
Equations
- category_theory.cokleisli.cokleisli.category U = {to_category_struct := {to_quiver := {hom := λ (X Y : C), ↑U.obj X ⟶ Y}, id := λ (X : category_theory.cokleisli U), U.ε.app X, comp := λ (X Y Z : category_theory.cokleisli U) (f : X ⟶ Y) (g : Y ⟶ Z), U.δ.app X ≫ ↑U.map f ≫ g}, id_comp' := _, comp_id' := _, assoc' := _}
The right adjoint of the adjunction which induces the comonad (U, ε_ U, δ_ U)
.
The left adjoint of the adjunction which induces the comonad (U, ε_ U, δ_ U)
.
Equations
- category_theory.cokleisli.adjunction.from_cokleisli U = {obj := λ (X : category_theory.cokleisli U), U.to_functor.obj X, map := λ (X Y : category_theory.cokleisli U) (f : X ⟶ Y), U.δ.app X ≫ U.to_functor.map f, map_id' := _, map_comp' := _}
The co-Kleisli adjunction which gives rise to the monad (U, ε_ U, δ_ U)
.
Equations
- category_theory.cokleisli.adjunction.adj U = category_theory.adjunction.mk_of_hom_equiv {hom_equiv := λ (X : category_theory.cokleisli U) (Y : C), equiv.refl (U.to_functor.obj X ⟶ Y), hom_equiv_naturality_left_symm' := _, hom_equiv_naturality_right' := _}
The composition of the adjunction gives the original functor.