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

Proarrow.Object.Dual

Documentation

type Dual (a :: k) = a ~~> (Bottom :: k) Source Comments #

dual' :: forall {k} (a :: k) (a' :: k). StarAutonomous k => (a ~> a') -> Dual a' ~> Dual a Source Comments #

dual :: forall {k} (a :: k). (StarAutonomous k, Ob a) => Obj (Dual a) Source Comments #

class Closed k => StarAutonomous k where Source Comments #

Minimal complete definition

bottomObj, (doubleNeg | doubleNeg')

Associated Types

type Bottom :: k Source Comments #

Methods

bottomObj :: Obj (Bottom :: k) Source Comments #

doubleNeg :: forall (a :: k). (StarAutonomous k, Ob a) => Dual (Dual a) ~> a Source Comments #

doubleNeg' :: forall (a :: k) (a' :: k). (a ~> a') -> Dual (Dual a) ~> a' Source Comments #

Instances

Instances details
StarAutonomous BOOL Source Comments # 
Instance details

Defined in Proarrow.Category.Instance.Bool

Associated Types

type Bottom 
Instance details

Defined in Proarrow.Category.Instance.Bool

type Bottom = 'FLS

Methods

bottomObj :: Obj (Bottom :: BOOL) Source Comments #

doubleNeg :: forall (a :: BOOL). (StarAutonomous BOOL, Ob a) => Dual (Dual a) ~> a Source Comments #

doubleNeg' :: forall (a :: BOOL) (a' :: BOOL). (a ~> a') -> Dual (Dual a) ~> a' Source Comments #

StarAutonomous KIND Source Comments # 
Instance details

Defined in Proarrow.Category.Instance.Cat

Associated Types

type Bottom 
Instance details

Defined in Proarrow.Category.Instance.Cat

type Bottom = 'K ()

Methods

bottomObj :: Obj (Bottom :: KIND) Source Comments #

doubleNeg :: forall (a :: KIND). (StarAutonomous KIND, Ob a) => Dual (Dual a) ~> a Source Comments #

doubleNeg' :: forall (a :: KIND) (a' :: KIND). (a ~> a') -> Dual (Dual a) ~> a' Source Comments #

StarAutonomous () Source Comments # 
Instance details

Defined in Proarrow.Object.Dual

Associated Types

type Bottom 
Instance details

Defined in Proarrow.Object.Dual

type Bottom = '()

Methods

bottomObj :: Obj (Bottom :: ()) Source Comments #

doubleNeg :: forall (a :: ()). (StarAutonomous (), Ob a) => Dual (Dual a) ~> a Source Comments #

doubleNeg' :: forall (a :: ()) (a' :: ()). (a ~> a') -> Dual (Dual a) ~> a' Source Comments #

Num a => StarAutonomous (MatK a) Source Comments # 
Instance details

Defined in Proarrow.Category.Instance.Mat

Associated Types

type Bottom 
Instance details

Defined in Proarrow.Category.Instance.Mat

type Bottom = 'M ('S 'Z) :: MatK a

Methods

bottomObj :: Obj (Bottom :: MatK a) Source Comments #

doubleNeg :: forall (a0 :: MatK a). (StarAutonomous (MatK a), Ob a0) => Dual (Dual a0) ~> a0 Source Comments #

doubleNeg' :: forall (a0 :: MatK a) (a' :: MatK a). (a0 ~> a') -> Dual (Dual a0) ~> a' Source Comments #

(StarAutonomous j, StarAutonomous k) => StarAutonomous (j, k) Source Comments # 
Instance details

Defined in Proarrow.Object.Dual

Associated Types

type Bottom 
Instance details

Defined in Proarrow.Object.Dual

type Bottom = '(Bottom :: j, Bottom :: k)

Methods

bottomObj :: Obj (Bottom :: (j, k)) Source Comments #

doubleNeg :: forall (a :: (j, k)). (StarAutonomous (j, k), Ob a) => Dual (Dual a) ~> a Source Comments #

doubleNeg' :: forall (a :: (j, k)) (a' :: (j, k)). (a ~> a') -> Dual (Dual a) ~> a' Source Comments #

doubleNegInv' :: forall k (a :: k) (a' :: k) (b :: k) (b' :: k). (Closed k, SymMonoidal k) => (a ~> a') -> (b ~> b') -> a ~> ((a' ~~> b) ~~> b') Source Comments #

dualityCounit' :: forall {k} (a :: k). StarAutonomous k => Obj a -> (Dual a ** a) ~> (Bottom :: k) Source Comments #

dualityCounit :: forall {k} (a :: k). (SymMonoidal k, StarAutonomous k, Ob a) => (Dual a ** a) ~> (Bottom :: k) Source Comments #

class ((Bottom :: k) ~ (Unit :: k), StarAutonomous k, SymMonoidal k) => CompactClosed k where Source Comments #

Minimal complete definition

(distribDual | distribDual')

Methods

distribDual :: forall (a :: k) (b :: k). (Ob a, Ob b) => Dual (a ** b) ~> (Dual a ** Dual b) Source Comments #

distribDual' :: forall (a :: k) (a' :: k) (b :: k) (b' :: k). (a ~> a') -> (b ~> b') -> Dual (a' ** b') ~> (Dual a ** Dual b) Source Comments #

Instances

Instances details
CompactClosed KIND Source Comments # 
Instance details

Defined in Proarrow.Category.Instance.Cat

Methods

distribDual :: forall (a :: KIND) (b :: KIND). (Ob a, Ob b) => Dual (a ** b) ~> (Dual a ** Dual b) Source Comments #

distribDual' :: forall (a :: KIND) (a' :: KIND) (b :: KIND) (b' :: KIND). (a ~> a') -> (b ~> b') -> Dual (a' ** b') ~> (Dual a ** Dual b) Source Comments #

CompactClosed () Source Comments # 
Instance details

Defined in Proarrow.Object.Dual

Methods

distribDual :: forall (a :: ()) (b :: ()). (Ob a, Ob b) => Dual (a ** b) ~> (Dual a ** Dual b) Source Comments #

distribDual' :: forall (a :: ()) (a' :: ()) (b :: ()) (b' :: ()). (a ~> a') -> (b ~> b') -> Dual (a' ** b') ~> (Dual a ** Dual b) Source Comments #

Num a => CompactClosed (MatK a) Source Comments # 
Instance details

Defined in Proarrow.Category.Instance.Mat

Methods

distribDual :: forall (a0 :: MatK a) (b :: MatK a). (Ob a0, Ob b) => Dual (a0 ** b) ~> (Dual a0 ** Dual b) Source Comments #

distribDual' :: forall (a0 :: MatK a) (a' :: MatK a) (b :: MatK a) (b' :: MatK a). (a0 ~> a') -> (b ~> b') -> Dual (a' ** b') ~> (Dual a0 ** Dual b) Source Comments #

(CompactClosed j, CompactClosed k) => CompactClosed (j, k) Source Comments # 
Instance details

Defined in Proarrow.Object.Dual

Methods

distribDual :: forall (a :: (j, k)) (b :: (j, k)). (Ob a, Ob b) => Dual (a ** b) ~> (Dual a ** Dual b) Source Comments #

distribDual' :: forall (a :: (j, k)) (a' :: (j, k)) (b :: (j, k)) (b' :: (j, k)). (a ~> a') -> (b ~> b') -> Dual (a' ** b') ~> (Dual a ** Dual b) Source Comments #

combineDual' :: forall k (a :: k) (a' :: k) (b :: k) (b' :: k). CompactClosed k => (a ~> a') -> (b ~> b') -> (Dual a' ** Dual b') ~> Dual (a ** b) Source Comments #

combineDual :: forall {k} (a :: k) (b :: k). (CompactClosed k, Ob a, Ob b) => (Dual a ** Dual b) ~> Dual (a ** b) Source Comments #

dualityUnit' :: forall {k} (a :: k). CompactClosed k => Obj a -> (Unit :: k) ~> (a ** Dual a) Source Comments #

dualityUnit :: forall {k} (a :: k). (CompactClosed k, Ob a) => (Unit :: k) ~> (a ** Dual a) Source Comments #

compactClosedTrace :: forall {k} (u :: k) (x :: k) (y :: k). (CompactClosed k, Ob x, Ob y, Ob u) => ((x ** u) ~> (y ** u)) -> x ~> y Source Comments #