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

Proarrow.Profunctor.Ran

Documentation

type (|>) (j1 :: i +-> j) (p :: i +-> k) = Ran ('OP j1) p Source Comments #

data Ran (j1 :: OPPOSITE (i +-> j)) (p :: i +-> k) (a :: k) (b :: j) where Source Comments #

Constructors

Ran 

Fields

  • :: forall {k} {j} {i} (a :: k) (b :: j) (j2 :: i +-> j) (p :: i +-> k). (Ob a, Ob b)
     
  • => { unRan :: forall (x :: i). Ob x => j2 b x -> p a x
     
  •    } -> Ran ('OP j2) p a b
     

Instances

Instances details
(Profunctor p, Profunctor j2) => Profunctor (Ran ('OP j2) p :: j1 -> k -> Type) Source Comments # 
Instance details

Defined in Proarrow.Profunctor.Ran

Methods

dimap :: forall (c :: j1) (a :: j1) (b :: k) (d :: k). (c ~> a) -> (b ~> d) -> Ran ('OP j2) p a b -> Ran ('OP j2) p c d Source Comments #

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

(p ~ j, Profunctor p) => Promonad (Ran ('OP p) p :: k -> k -> Type) Source Comments # 
Instance details

Defined in Proarrow.Profunctor.Ran

Methods

id :: forall (a :: k). Ob a => Ran ('OP p) p a a Source Comments #

(.) :: forall (b :: k) (c :: k) (a :: k). Ran ('OP p) p b c -> Ran ('OP p) p a b -> Ran ('OP p) p a c Source Comments #

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

Defined in Proarrow.Profunctor.Ran

Methods

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

Profunctor j2 => Adjunction (Star (Precompose j2 :: (j1 +-> k) -> k -> i -> Type) :: (k -> i -> Type) -> (j1 +-> k) -> Type) (Star (Ran ('OP j2) :: (i +-> k) -> k -> j1 -> Type) :: (k -> j1 -> Type) -> (i +-> k) -> Type) Source Comments # 
Instance details

Defined in Proarrow.Profunctor.Ran

Methods

unit :: forall (a :: j1 +-> k). Ob a => (Star (Ran ('OP j2) :: (i +-> k) -> k -> j1 -> Type) :.: Star (Precompose j2 :: (j1 +-> k) -> k -> i -> Type)) a a Source Comments #

counit :: (Star (Precompose j2 :: (j1 +-> k) -> k -> i -> Type) :.: Star (Ran ('OP j2) :: (i +-> k) -> k -> j1 -> Type)) :~> ((~>) :: CAT (k -> i -> Type)) Source Comments #

Profunctor j2 => Functor (Ran ('OP j2) :: (i +-> k) -> k -> j1 -> Type) Source Comments # 
Instance details

Defined in Proarrow.Profunctor.Ran

Methods

map :: forall (a :: i +-> k) (b :: i +-> k). (a ~> b) -> Ran ('OP j2) a ~> Ran ('OP j2) b Source Comments #

runRan :: forall {j1} {i} {k} j2 (b :: j1) (x :: i) p (a :: k). Profunctor j2 => j2 b x -> Ran ('OP j2) p a b -> p a x Source Comments #

flipRan :: forall {i} {k2} {k} (j :: i -> k2) (p :: PRO k k2). (Functor j, Profunctor p) => (Costar j |> p) ~> (p :.: Star j) Source Comments #

flipRanInv :: forall {j1} {i} {k} (j2 :: j1 -> i) (p :: PRO k i). (Functor j2, Profunctor p) => (p :.: Star j2) ~> (Costar j2 |> p) Source Comments #

newtype Precompose (j1 :: i +-> j) (p :: j +-> k) (a :: k) (b :: i) Source Comments #

Constructors

Precompose 

Fields

Instances

Instances details
(Profunctor j3, Profunctor p) => Profunctor (Precompose j3 p :: j2 -> k -> Type) Source Comments # 
Instance details

Defined in Proarrow.Profunctor.Ran

Methods

dimap :: forall (c :: j2) (a :: j2) (b :: k) (d :: k). (c ~> a) -> (b ~> d) -> Precompose j3 p a b -> Precompose j3 p c d Source Comments #

(\\) :: forall (a :: j2) (b :: k) r. ((Ob a, Ob b) => r) -> Precompose j3 p a b -> r Source Comments #

Profunctor j2 => Adjunction (Star (Precompose j2 :: (j1 +-> k) -> k -> i -> Type) :: (k -> i -> Type) -> (j1 +-> k) -> Type) (Star (Ran ('OP j2) :: (i +-> k) -> k -> j1 -> Type) :: (k -> j1 -> Type) -> (i +-> k) -> Type) Source Comments # 
Instance details

Defined in Proarrow.Profunctor.Ran

Methods

unit :: forall (a :: j1 +-> k). Ob a => (Star (Ran ('OP j2) :: (i +-> k) -> k -> j1 -> Type) :.: Star (Precompose j2 :: (j1 +-> k) -> k -> i -> Type)) a a Source Comments #

counit :: (Star (Precompose j2 :: (j1 +-> k) -> k -> i -> Type) :.: Star (Ran ('OP j2) :: (i +-> k) -> k -> j1 -> Type)) :~> ((~>) :: CAT (k -> i -> Type)) Source Comments #

Profunctor j2 => Functor (Precompose j2 :: (j1 +-> k) -> k -> i -> Type) Source Comments # 
Instance details

Defined in Proarrow.Profunctor.Ran

Methods

map :: forall (a :: j1 +-> k) (b :: j1 +-> k). (a ~> b) -> Precompose j2 a ~> Precompose j2 b Source Comments #

ranCompose :: forall {j1} {j2} {i1} {k} (i2 :: PRO j1 j2) (j3 :: PRO j2 i1) (p :: PRO k i1). (Profunctor i2, Profunctor j3, Profunctor p) => (i2 |> (j3 |> p)) ~> ((i2 :.: j3) |> p) Source Comments #

ranComposeInv :: forall {j1} {j2} {i1} {k} (i2 :: PRO j1 j2) (j3 :: PRO j2 i1) (p :: PRO k i1). (Profunctor i2, Profunctor j3, Profunctor p) => ((i2 :.: j3) |> p) ~> (i2 |> (j3 |> p)) Source Comments #

ranHom :: forall {k} {i} (p :: PRO k i). Profunctor p => p ~> (((~>) :: CAT i) |> p) Source Comments #

ranHomInv :: forall {k} {i} (p :: PRO k i). Profunctor p => (((~>) :: CAT i) |> p) ~> p Source Comments #