proarrow-0: Category theory with a central role for profunctors
Safe HaskellNone
LanguageHaskell2010

Proarrow.Profunctor.Composition

Synopsis
  • data ((p :: j +-> k) :.: (q :: i +-> j)) (a :: k) (c :: i) where
    • (:.:) :: forall {j} {k} {i} (p :: j +-> k) (a :: k) (b :: j) (q :: i +-> j) (c :: i). p a b -> q b c -> (p :.: q) a c
  • bimapComp :: forall {j} {k} {i} (a :: j +-> k) (b :: j +-> k) (c :: i +-> j) (d :: i +-> j). (a ~> b) -> (c ~> d) -> (a :.: c) ~> (b :.: d)
  • o :: forall {i} {j} {k} (p :: j +-> k) (q :: j +-> k) (r :: i +-> j) (s :: i +-> j). Prof p q -> Prof r s -> Prof (p :.: r) (q :.: s)

Documentation

data ((p :: j +-> k) :.: (q :: i +-> j)) (a :: k) (c :: i) where Source Comments #

Constructors

(:.:) :: forall {j} {k} {i} (p :: j +-> k) (a :: k) (b :: j) (q :: i +-> j) (c :: i). p a b -> q b c -> (p :.: q) a c 

Instances

Instances details
(MonoidalProfunctor p, MonoidalProfunctor q) => MonoidalProfunctor (p :.: q :: k -> j2 -> Type) Source Comments # 
Instance details

Defined in Proarrow.Profunctor.Composition

Methods

par0 :: (p :.: q) (Unit :: k) (Unit :: j2) Source Comments #

par :: forall (x1 :: k) (x2 :: j2) (y1 :: k) (y2 :: j2). (p :.: q) x1 x2 -> (p :.: q) y1 y2 -> (p :.: q) (x1 ** y1) (x2 ** y2) Source Comments #

(Profunctor p, Profunctor q) => Profunctor (p :.: q :: j1 -> k -> Type) Source Comments # 
Instance details

Defined in Proarrow.Profunctor.Composition

Methods

dimap :: forall (c :: j1) (a :: j1) (b :: k) (d :: k). (c ~> a) -> (b ~> d) -> (p :.: q) a b -> (p :.: q) c d Source Comments #

(\\) :: forall (a :: j1) (b :: k) r. ((Ob a, Ob b) => r) -> (p :.: q) a b -> r Source Comments #

(Corepresentable p, Corepresentable q) => Corepresentable (p :.: q :: k -> j2 -> Type) Source Comments # 
Instance details

Defined in Proarrow.Profunctor.Composition

Methods

coindex :: forall (a :: k) (b :: j2). (p :.: q) a b -> ((p :.: q) %% a) ~> b Source Comments #

cotabulate :: forall (a :: k) (b :: j2). Ob a => (((p :.: q) %% a) ~> b) -> (p :.: q) a b Source Comments #

corepMap :: forall (a :: k) (b :: k). (a ~> b) -> ((p :.: q) %% a) ~> ((p :.: q) %% b) Source Comments #

(Representable p, Representable q) => Representable (p :.: q :: k -> j2 -> Type) Source Comments # 
Instance details

Defined in Proarrow.Profunctor.Composition

Methods

index :: forall (a :: k) (b :: j2). (p :.: q) a b -> a ~> ((p :.: q) % b) Source Comments #

tabulate :: forall (b :: j2) (a :: k). Ob b => (a ~> ((p :.: q) % b)) -> (p :.: q) a b Source Comments #

repMap :: forall (a :: j2) (b :: j2). (a ~> b) -> ((p :.: q) % a) ~> ((p :.: q) % b) Source Comments #

(Adjunction l1 r1, Adjunction l2 r2) => Adjunction (l1 :.: l2 :: i -> k -> Type) (r2 :.: r1 :: k -> i -> Type) Source Comments # 
Instance details

Defined in Proarrow.Adjunction

Methods

unit :: forall (a :: k). Ob a => ((r2 :.: r1) :.: (l1 :.: l2)) a a Source Comments #

counit :: ((l1 :.: l2) :.: (r2 :.: r1)) :~> ((~>) :: CAT i) Source Comments #

Adjunction p q => Promonad (q :.: p :: k -> k -> Type) Source Comments # 
Instance details

Defined in Proarrow.Adjunction

Methods

id :: forall (a :: k). Ob a => (q :.: p) a a Source Comments #

(.) :: forall (b :: k) (c :: k) (a :: k). (q :.: p) b c -> (q :.: p) a b -> (q :.: p) a c Source Comments #

Adjunction p q => Procomonad (p :.: q :: i -> i -> Type) Source Comments # 
Instance details

Defined in Proarrow.Adjunction

Methods

extract :: (p :.: q) :~> ((~>) :: CAT i) Source Comments #

duplicate :: (p :.: q) :~> ((p :.: q) :.: (p :.: q)) Source Comments #

Functor ((:.:) :: (j +-> k) -> (i +-> j) -> k -> i -> Type) Source Comments # 
Instance details

Defined in Proarrow.Profunctor.Composition

Methods

map :: forall (a :: j +-> k) (b :: j +-> k). (a ~> b) -> ((:.:) a :: (i +-> j) -> k -> i -> Type) ~> ((:.:) b :: (i +-> j) -> k -> i -> Type) Source Comments #

Profunctor j => Adjunction (Star ((:.:) j :: (i2 +-> k) -> i1 -> i2 -> Type) :: (i1 -> i2 -> Type) -> (i2 +-> k) -> Type) (Star (Rift ('OP j) :: (i2 +-> i1) -> k -> i2 -> Type) :: (k -> i2 -> Type) -> (i2 +-> i1) -> Type) Source Comments # 
Instance details

Defined in Proarrow.Profunctor.Rift

Methods

unit :: forall (a :: i2 +-> k). Ob a => (Star (Rift ('OP j) :: (i2 +-> i1) -> k -> i2 -> Type) :.: Star ((:.:) j :: (i2 +-> k) -> i1 -> i2 -> Type)) a a Source Comments #

counit :: (Star ((:.:) j :: (i2 +-> k) -> i1 -> i2 -> Type) :.: Star (Rift ('OP j) :: (i2 +-> i1) -> k -> i2 -> Type)) :~> ((~>) :: CAT (i1 -> i2 -> Type)) Source Comments #

Profunctor p => Functor ((:.:) p :: (i +-> j) -> k -> i -> Type) Source Comments # 
Instance details

Defined in Proarrow.Profunctor.Composition

Methods

map :: forall (a :: i +-> j) (b :: i +-> j). (a ~> b) -> (p :.: a) ~> (p :.: b) Source Comments #

type (p :.: q :: k -> j1 -> Type) %% (a :: k) Source Comments # 
Instance details

Defined in Proarrow.Profunctor.Composition

type (p :.: q :: k -> j1 -> Type) %% (a :: k) = q %% (p %% a)
type (p :.: q :: k -> j1 -> Type) % (a :: j1) Source Comments # 
Instance details

Defined in Proarrow.Profunctor.Composition

type (p :.: q :: k -> j1 -> Type) % (a :: j1) = p % (q % a)

bimapComp :: forall {j} {k} {i} (a :: j +-> k) (b :: j +-> k) (c :: i +-> j) (d :: i +-> j). (a ~> b) -> (c ~> d) -> (a :.: c) ~> (b :.: d) Source Comments #

o :: forall {i} {j} {k} (p :: j +-> k) (q :: j +-> k) (r :: i +-> j) (s :: i +-> j). Prof p q -> Prof r s -> Prof (p :.: r) (q :.: s) Source Comments #

Horizontal composition