-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | Algebraic structures -- -- Attempt to define algebraic structures in more robust and useful way. @package morphisms-objects @version 0.1.3 module Control.Object.Semigroup -- |
--   When providing a new instance, you should ensure it satisfies the one law:
--   * Associativity: x <> (y <> z) ≡ (x <> y) <> z
--   
class Semigroup a -- | Infix version of append (<>) :: Semigroup a => a -> a -> a module Control.Object.Monoid -- |
--   When providing a new instance, you should ensure it satisfies the two law:
--   * Right absorption: unit <> x ≡ x
--   * Left absorption: x <> unit ≡ x
--   
class Semigroup a => Monoid a unit :: Monoid a => a module Control.Object.Group -- |
--   When providing a new instance, you should ensure it satisfies the two law:
--   * Right absorption: x <> inverse x ≡ unit
--   * Left absorption: inverse x <> x ≡ unit
--   
class Monoid a => Group a inverse :: Group a => a -> a module Control.Object.Semilattice -- |
--   When providing a new instance, you should ensure it satisfies the three laws:
--   * Associativity: x /\ (y /\ z) ≡ (x /\ y) /\ z
--   * Commutativity: x /\ y ≡ y /\ x
--   * Idempotency: x /\ x ≡ x
--   
class Infimum a (/\) :: Infimum a => a -> a -> a -- |
--   When providing a new instance, you should ensure it satisfies the three laws:
--   * Associativity: x \/ (y \/ z) ≡ (x \/ y) \/ z
--   * Commutativity: x \/ y ≡ y \/ x
--   * Idempotency: x \/ x ≡ x
--   
class Supremum a (\/) :: Supremum a => a -> a -> a module Control.Object.Lattice -- |
--   When providing a new instance, you should ensure it satisfies the one law:
--   * Absorption: a \/ (a /\ b) ≡ a /\ (a \/ b) ≡ a
--   
class (Infimum a, Supremum a) => Lattice a module Control.Object.Semiring -- |
--   When providing a new instance, you should ensure it satisfies the two laws:
--   * Commutativity: a >< b = b >< a
--   * Distributivity: x <> (y >< z) = x <> y >< x <> z
--   
class Semigroup a => Semiring a (><) :: Semiring a => a -> a -> a module Control.Object.Setoid data Boolean True :: Boolean False :: Boolean (&&) :: Boolean -> Boolean -> Boolean infixr 3 && (||) :: Boolean -> Boolean -> Boolean infixr 9 || not :: Boolean -> Boolean bool :: a -> a -> Boolean -> a -- |
--   When providing a new instance, you should ensure it satisfies the four law:
--   * Reflexivity: x == x ≡ True
--   * Symmetry: x == y ≡ y == x
--   * Transitivity: x == y && y == z ≡ True ===> x == z ≡ True
--   * Negation: x /= y ≡ not (x == y)
--   
class Setoid a (==) :: Setoid a => a -> a -> Boolean (/=) :: Setoid a => a -> a -> Boolean module Control.Object.Chain data Ordering Less :: Ordering Equal :: Ordering Greater :: Ordering order :: a -> a -> a -> Ordering -> a -- |
--   When providing a new instance, you should ensure it satisfies the three law:
--   * Reflexivity: x <= x ≡ True
--   * Transitivity: x <= y && y <= z ≡ True ===> x <= z ≡ True
--   * Antisymmetry: x <= y && y <= x ≡ True ===> x == y ≡ True
--   
class Setoid a => Chain a (<=) :: Chain a => a -> a -> Ordering (>=) :: Chain a => a -> a -> Ordering (<) :: Chain a => a -> a -> Boolean (>) :: Chain a => a -> a -> Boolean module Control.Object