License | BSD-style (see the file LICENSE) |
---|---|
Maintainer | sjoerd@w3future.com |
Stability | experimental |
Portability | non-portable |
Safe Haskell | Safe |
Language | Haskell2010 |
Synopsis
- type YonedaEmbedding k = Postcompose (Hom k) (Op k) :.: (Postcompose (Swap k (Op k)) (Op k) :.: Tuple k (Op k))
- pattern YonedaEmbedding :: Category k => YonedaEmbedding k
- data Yoneda (k :: * -> * -> *) f = Yoneda
- fromYoneda :: (Category k, Functor f, Dom f ~ Op k, Cod f ~ (->)) => f -> Nat (Op k) (->) (Yoneda k f) f
- toYoneda :: (Category k, Functor f, Dom f ~ Op k, Cod f ~ (->)) => f -> Nat (Op k) (->) f (Yoneda k f)
- haskUnit :: Obj (->) ()
- data M1 = M1
- haskIsTotal :: Adjunction (->) (Nat (Op (->)) (->)) M1 (YonedaEmbedding (->))
Documentation
type YonedaEmbedding k = Postcompose (Hom k) (Op k) :.: (Postcompose (Swap k (Op k)) (Op k) :.: Tuple k (Op k)) Source #
pattern YonedaEmbedding :: Category k => YonedaEmbedding k Source #
The Yoneda embedding functor, C -> Set^(C^op)
.
data Yoneda (k :: * -> * -> *) f Source #
Instances
(Category k, Functor f, Dom f ~ Op k, Cod f ~ ((->) :: Type -> Type -> Type)) => Functor (Yoneda k f) Source # |
|
type Dom (Yoneda k f) Source # | |
Defined in Data.Category.Yoneda | |
type Cod (Yoneda k f) Source # | |
Defined in Data.Category.Yoneda | |
type (Yoneda k f) :% a Source # | |
fromYoneda :: (Category k, Functor f, Dom f ~ Op k, Cod f ~ (->)) => f -> Nat (Op k) (->) (Yoneda k f) f Source #
fromYoneda
and toYoneda
are together the isomophism from the Yoneda lemma.
toYoneda :: (Category k, Functor f, Dom f ~ Op k, Cod f ~ (->)) => f -> Nat (Op k) (->) f (Yoneda k f) Source #
haskIsTotal :: Adjunction (->) (Nat (Op (->)) (->)) M1 (YonedaEmbedding (->)) Source #