Monadic adjunctions🔗
An adjunction
between functors
and
is monadic if the induced comparison functor
(where the right-hand side is the Eilenberg-Moore
category of the monad of the adjunction) is an
equivalence of categories.
module
.Functor.Adjoint.Monadic
Cat{o₁ h₁ o₂ h₂ : _}
{C : Precategory o₁ h₁}
{D : Precategory o₂ h₂}
{L : Functor C D} {R : Functor D C}
(L⊣R : L ⊣ R)
where
private
module C = Cat.Reasoning C
module D = Cat.Reasoning D
module L = Cat.Functor.Reasoning L
module R = Cat.Functor.Reasoning R
module adj = _⊣_ L⊣R
: Monad C
L∘R = Adjunction→Monad L⊣R
L∘R
open Monad L∘R
private
module Kleisli = Cat.Reasoning (Kleisli L∘R)
module EM = Cat.Reasoning (Eilenberg-Moore L∘R)
The composition of R.₁
with the
adjunction counit
natural
transformation gives R
an Algebra
structure, thus extending
R
to a functor
: Functor D (Eilenberg-Moore L∘R)
Comparison-EM .F₀ x = R.₀ x , alg where
Comparison-EM : Algebra-on C L∘R (R.₀ x)
alg .Algebra-on.ν = R.₁ (adj.counit.ε _)
alg .Algebra-on.ν-unit = adj.zag
alg .Algebra-on.ν-mult = R.weave (adj.counit.is-natural _ _ _) alg
Construction of the functorial action of Comparison-EM
.F₁ x .hom = R.₁ x
Comparison-EM .F₁ x .preserves = R.weave (sym (adj.counit.is-natural _ _ _))
Comparison-EM .F-id = ext R.F-id
Comparison-EM .F-∘ f g = ext (R.F-∘ _ _) Comparison-EM
An adjunction is monadic if Comparison-EM
is an equivalence of categories, thus
exhibiting
as the category of
: Type _
is-monadic = is-equivalence Comparison-EM is-monadic