Safe Haskell | Safe |
---|---|
Language | Haskell2010 |
Data.Semigroup.Quantale
Description
Documentation
type UnitalQuantale a = (Monoid a, Quantale a) Source #
class Semigroup a => Quantale a where Source #
A residuated, partially ordered semigroup.
In the interest of broader usability we relax the common definition slightly
and use the term quantale
to describe any residuated, partially ordered semigroup.
This admits instances of hoops and triangular (co)-norms.
Laws:
x \\ x = mempty x <~ y iff mempty = x \\ y x <> (x \\ y) = y <> (y \\ x) (x <> y) \\ z = y \\ (x \\ z) (currying) x <> y <~ z iff y <~ x \\ z iff x <~ z // y.
See https://ncatlab.org/nlab/show/quantale.
TODO: There are several additional properties that apply when the poset structure is lattice-ordered (i.e. a residuated lattice) or when the semigroup is a monoid or semiring.
Minimal complete definition
Nothing
Methods
residL :: a -> ConnL a a Source #
residR :: a -> ConnR a a Source #
Instances
(==>) :: (Meet - Quantale) a => a -> a -> a infixr 1 Source #
Logical implication.
x==>
x =top
x/\
(x==>
y) = x/\
y y/\
(x==>
y) = y x==>
(y==>
z) = (x/\
y)==>
z x==>
(y/\
z) = (x==>
y)/\
(x==>
z)meetLe
((x==>
y)\/
x) ymeetLe
y (x==>
x/\
y)meetLe
x y =>meetLe
(z==>
x) (z==>
y)meetLe
x y =>meetLe
(x==>
z) (y==>
z)meetLe
x y = x==>
y==
top
meetLe
(x/\
y) z =meetLe
x (y==>
z)
See Heyting
for the laws.