-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/


-- | Fine-grained library for constructing and manipulating lattices
--   
--   In mathematics, a lattice is a partially ordered set in which every
--   two elements have a unique supremum (also called a least upper bound
--   or <tt>join</tt>) and a unique infimum (also called a greatest lower
--   bound or <tt>meet</tt>).
@package lattices
@version 1.5.0


module Algebra.PartialOrd

-- | A partial ordering on sets:
--   <a>http://en.wikipedia.org/wiki/Partially_ordered_set</a>
--   
--   This can be defined using either <tt>joinLeq</tt> or <tt>meetLeq</tt>,
--   or a more efficient definition can be derived directly.
--   
--   <pre>
--   Reflexive:     a <a>leq</a> a
--   Antisymmetric: a <a>leq</a> b &amp;&amp; b <a>leq</a> a ==&gt; a == b
--   Transitive:    a <a>leq</a> b &amp;&amp; b <a>leq</a> c ==&gt; a <a>leq</a> c
--   </pre>
--   
--   The superclass equality (which can be defined using
--   <a>partialOrdEq</a>) must obey these laws:
--   
--   <pre>
--   Reflexive:  a == a
--   Transitive: a == b &amp;&amp; b == c ==&gt; a == b
--   </pre>
class Eq a => PartialOrd a
leq :: PartialOrd a => a -> a -> Bool

-- | The equality relation induced by the partial-order structure
partialOrdEq :: PartialOrd a => a -> a -> Bool

-- | Least point of a partially ordered monotone function. Checks that the
--   function is monotone.
lfpFrom :: PartialOrd a => a -> (a -> a) -> a

-- | Least point of a partially ordered monotone function. Does not checks
--   that the function is monotone.
unsafeLfpFrom :: Eq a => a -> (a -> a) -> a

-- | Greatest fixed point of a partially ordered antinone function. Checks
--   that the function is antinone.
gfpFrom :: PartialOrd a => a -> (a -> a) -> a

-- | Greatest fixed point of a partially ordered antinone function. Does
--   not check that the function is antinone.
unsafeGfpFrom :: Eq a => a -> (a -> a) -> a
instance GHC.Classes.Ord a => Algebra.PartialOrd.PartialOrd (Data.Set.Base.Set a)
instance Algebra.PartialOrd.PartialOrd Data.IntSet.Base.IntSet
instance (GHC.Classes.Ord k, Algebra.PartialOrd.PartialOrd v) => Algebra.PartialOrd.PartialOrd (Data.Map.Base.Map k v)
instance Algebra.PartialOrd.PartialOrd v => Algebra.PartialOrd.PartialOrd (Data.IntMap.Base.IntMap v)
instance (Algebra.PartialOrd.PartialOrd a, Algebra.PartialOrd.PartialOrd b) => Algebra.PartialOrd.PartialOrd (a, b)


-- | This module re-exports orphan instances from <a>Eq</a> module, and
--   <tt>(PartialOrd v, Finite k) =&gt; PartialOrd (k -&gt; v)</tt>
--   instance.
module Algebra.PartialOrd.Instances
instance (Algebra.PartialOrd.PartialOrd v, Data.Universe.Class.Finite k) => Algebra.PartialOrd.PartialOrd (k -> v)


-- | In mathematics, a lattice is a partially ordered set in which every
--   two elements have a unique supremum (also called a least upper bound
--   or <tt>join</tt>) and a unique infimum (also called a greatest lower
--   bound or <tt>meet</tt>).
--   
--   In this module lattices are defined using <a>meet</a> and <a>join</a>
--   operators, as it's constructive one.
module Algebra.Lattice

-- | A algebraic structure with element joins:
--   <a>http://en.wikipedia.org/wiki/Semilattice</a>
--   
--   <pre>
--   Associativity: x \/ (y \/ z) == (x \/ y) \/ z
--   Commutativity: x \/ y == y \/ x
--   Idempotency:   x \/ x == x
--   </pre>
class JoinSemiLattice a where (\/) = join join = (\/)
(\/) :: JoinSemiLattice a => a -> a -> a

-- | <i>Deprecated: Use <a>\/</a> infix operator</i>
join :: JoinSemiLattice a => a -> a -> a

-- | A algebraic structure with element meets:
--   <a>http://en.wikipedia.org/wiki/Semilattice</a>
--   
--   <pre>
--   Associativity: x /\ (y /\ z) == (x /\ y) /\ z
--   Commutativity: x /\ y == y /\ x
--   Idempotency:   x /\ x == x
--   </pre>
class MeetSemiLattice a where (/\) = meet meet = (/\)
(/\) :: MeetSemiLattice a => a -> a -> a

-- | <i>Deprecated: Use <a>/\</a> infix operator</i>
meet :: MeetSemiLattice a => a -> a -> a

-- | The combination of two semi lattices makes a lattice if the absorption
--   law holds: see <a>http://en.wikipedia.org/wiki/Absorption_law</a> and
--   <a>http://en.wikipedia.org/wiki/Lattice_(order)</a>
--   
--   <pre>
--   Absorption: a \/ (a /\ b) == a /\ (a \/ b) == a
--   </pre>
class (JoinSemiLattice a, MeetSemiLattice a) => Lattice a

-- | The partial ordering induced by the join-semilattice structure
joinLeq :: (Eq a, JoinSemiLattice a) => a -> a -> Bool

-- | The join of at a list of join-semilattice elements (of length at least
--   one)
joins1 :: JoinSemiLattice a => [a] -> a

-- | The partial ordering induced by the meet-semilattice structure
meetLeq :: (Eq a, MeetSemiLattice a) => a -> a -> Bool

-- | The meet of at a list of meet-semilattice elements (of length at least
--   one)
meets1 :: MeetSemiLattice a => [a] -> a

-- | A join-semilattice with some element |bottom| that / approaches.
--   
--   <pre>
--   Identity: x \/ bottom == x
--   </pre>
class JoinSemiLattice a => BoundedJoinSemiLattice a
bottom :: BoundedJoinSemiLattice a => a

-- | A meet-semilattice with some element |top| that / approaches.
--   
--   <pre>
--   Identity: x /\ top == x
--   </pre>
class MeetSemiLattice a => BoundedMeetSemiLattice a
top :: BoundedMeetSemiLattice a => a

-- | Lattices with both bounds
class (Lattice a, BoundedJoinSemiLattice a, BoundedMeetSemiLattice a) => BoundedLattice a

-- | The join of a list of join-semilattice elements
joins :: (BoundedJoinSemiLattice a, Foldable f) => f a -> a

-- | The meet of a list of meet-semilattice elements
meets :: (BoundedMeetSemiLattice a, Foldable f) => f a -> a

-- | <a>True</a> to <a>top</a> and <a>False</a> to <a>bottom</a>
fromBool :: BoundedLattice a => Bool -> a

-- | Monoid wrapper for MeetSemiLattice
newtype Meet a
Meet :: a -> Meet a
[getMeet] :: Meet a -> a

-- | Monoid wrapper for JoinSemiLattice
newtype Join a
Join :: a -> Join a
[getJoin] :: Join a -> a

-- | Implementation of Kleene fixed-point theorem
--   <a>http://en.wikipedia.org/wiki/Kleene_fixed-point_theorem</a>. Forces
--   the function to be monotone.
lfp :: (Eq a, BoundedJoinSemiLattice a) => (a -> a) -> a

-- | Implementation of Kleene fixed-point theorem
--   <a>http://en.wikipedia.org/wiki/Kleene_fixed-point_theorem</a>. Forces
--   the function to be monotone.
lfpFrom :: (Eq a, BoundedJoinSemiLattice a) => a -> (a -> a) -> a

-- | Implementation of Kleene fixed-point theorem
--   <a>http://en.wikipedia.org/wiki/Kleene_fixed-point_theorem</a>.
--   Assumes that the function is monotone and does not check if that is
--   correct.
unsafeLfp :: (Eq a, BoundedJoinSemiLattice a) => (a -> a) -> a

-- | Implementation of Kleene fixed-point theorem
--   <a>http://en.wikipedia.org/wiki/Kleene_fixed-point_theorem</a>. Forces
--   the function to be antinone.
gfp :: (Eq a, BoundedMeetSemiLattice a) => (a -> a) -> a

-- | Implementation of Kleene fixed-point theorem
--   <a>http://en.wikipedia.org/wiki/Kleene_fixed-point_theorem</a>. Forces
--   the function to be antinone.
gfpFrom :: (Eq a, BoundedMeetSemiLattice a) => a -> (a -> a) -> a

-- | Implementation of Kleene fixed-point theorem
--   <a>http://en.wikipedia.org/wiki/Kleene_fixed-point_theorem</a>.
--   Assumes that the function is antinone and does not check if that is
--   correct.
unsafeGfp :: (Eq a, BoundedMeetSemiLattice a) => (a -> a) -> a
instance GHC.Generics.Generic (Algebra.Lattice.Meet a)
instance Data.Data.Data a => Data.Data.Data (Algebra.Lattice.Meet a)
instance GHC.Enum.Bounded a => GHC.Enum.Bounded (Algebra.Lattice.Meet a)
instance GHC.Show.Show a => GHC.Show.Show (Algebra.Lattice.Meet a)
instance GHC.Read.Read a => GHC.Read.Read (Algebra.Lattice.Meet a)
instance GHC.Classes.Ord a => GHC.Classes.Ord (Algebra.Lattice.Meet a)
instance GHC.Classes.Eq a => GHC.Classes.Eq (Algebra.Lattice.Meet a)
instance GHC.Generics.Generic (Algebra.Lattice.Join a)
instance Data.Data.Data a => Data.Data.Data (Algebra.Lattice.Join a)
instance GHC.Enum.Bounded a => GHC.Enum.Bounded (Algebra.Lattice.Join a)
instance GHC.Show.Show a => GHC.Show.Show (Algebra.Lattice.Join a)
instance GHC.Read.Read a => GHC.Read.Read (Algebra.Lattice.Join a)
instance GHC.Classes.Ord a => GHC.Classes.Ord (Algebra.Lattice.Join a)
instance GHC.Classes.Eq a => GHC.Classes.Eq (Algebra.Lattice.Join a)
instance GHC.Classes.Ord a => Algebra.Lattice.JoinSemiLattice (Data.Set.Base.Set a)
instance GHC.Classes.Ord a => Algebra.Lattice.MeetSemiLattice (Data.Set.Base.Set a)
instance GHC.Classes.Ord a => Algebra.Lattice.Lattice (Data.Set.Base.Set a)
instance GHC.Classes.Ord a => Algebra.Lattice.BoundedJoinSemiLattice (Data.Set.Base.Set a)
instance (GHC.Classes.Ord a, Data.Universe.Class.Finite a) => Algebra.Lattice.BoundedMeetSemiLattice (Data.Set.Base.Set a)
instance (GHC.Classes.Ord a, Data.Universe.Class.Finite a) => Algebra.Lattice.BoundedLattice (Data.Set.Base.Set a)
instance Algebra.Lattice.JoinSemiLattice Data.IntSet.Base.IntSet
instance Algebra.Lattice.BoundedJoinSemiLattice Data.IntSet.Base.IntSet
instance (GHC.Classes.Eq a, Data.Hashable.Class.Hashable a) => Algebra.Lattice.JoinSemiLattice (Data.HashSet.HashSet a)
instance (GHC.Classes.Eq a, Data.Hashable.Class.Hashable a) => Algebra.Lattice.MeetSemiLattice (Data.HashSet.HashSet a)
instance (GHC.Classes.Eq a, Data.Hashable.Class.Hashable a) => Algebra.Lattice.BoundedJoinSemiLattice (Data.HashSet.HashSet a)
instance (GHC.Classes.Ord k, Algebra.Lattice.JoinSemiLattice v) => Algebra.Lattice.JoinSemiLattice (Data.Map.Base.Map k v)
instance (GHC.Classes.Ord k, Algebra.Lattice.MeetSemiLattice v) => Algebra.Lattice.MeetSemiLattice (Data.Map.Base.Map k v)
instance (GHC.Classes.Ord k, Algebra.Lattice.Lattice v) => Algebra.Lattice.Lattice (Data.Map.Base.Map k v)
instance (GHC.Classes.Ord k, Algebra.Lattice.JoinSemiLattice v) => Algebra.Lattice.BoundedJoinSemiLattice (Data.Map.Base.Map k v)
instance (GHC.Classes.Ord k, Data.Universe.Class.Finite k, Algebra.Lattice.BoundedMeetSemiLattice v) => Algebra.Lattice.BoundedMeetSemiLattice (Data.Map.Base.Map k v)
instance (GHC.Classes.Ord k, Data.Universe.Class.Finite k, Algebra.Lattice.BoundedLattice v) => Algebra.Lattice.BoundedLattice (Data.Map.Base.Map k v)
instance Algebra.Lattice.JoinSemiLattice v => Algebra.Lattice.JoinSemiLattice (Data.IntMap.Base.IntMap v)
instance Algebra.Lattice.JoinSemiLattice v => Algebra.Lattice.BoundedJoinSemiLattice (Data.IntMap.Base.IntMap v)
instance (GHC.Classes.Eq k, Data.Hashable.Class.Hashable k) => Algebra.Lattice.JoinSemiLattice (Data.HashMap.Base.HashMap k v)
instance (GHC.Classes.Eq k, Data.Hashable.Class.Hashable k) => Algebra.Lattice.MeetSemiLattice (Data.HashMap.Base.HashMap k v)
instance (GHC.Classes.Eq k, Data.Hashable.Class.Hashable k) => Algebra.Lattice.BoundedJoinSemiLattice (Data.HashMap.Base.HashMap k v)
instance Algebra.Lattice.JoinSemiLattice v => Algebra.Lattice.JoinSemiLattice (k -> v)
instance Algebra.Lattice.MeetSemiLattice v => Algebra.Lattice.MeetSemiLattice (k -> v)
instance Algebra.Lattice.Lattice v => Algebra.Lattice.Lattice (k -> v)
instance Algebra.Lattice.BoundedJoinSemiLattice v => Algebra.Lattice.BoundedJoinSemiLattice (k -> v)
instance Algebra.Lattice.BoundedMeetSemiLattice v => Algebra.Lattice.BoundedMeetSemiLattice (k -> v)
instance Algebra.Lattice.BoundedLattice v => Algebra.Lattice.BoundedLattice (k -> v)
instance Algebra.Lattice.JoinSemiLattice ()
instance Algebra.Lattice.BoundedJoinSemiLattice ()
instance Algebra.Lattice.MeetSemiLattice ()
instance Algebra.Lattice.BoundedMeetSemiLattice ()
instance Algebra.Lattice.Lattice ()
instance Algebra.Lattice.BoundedLattice ()
instance (Algebra.Lattice.JoinSemiLattice a, Algebra.Lattice.JoinSemiLattice b) => Algebra.Lattice.JoinSemiLattice (a, b)
instance (Algebra.Lattice.MeetSemiLattice a, Algebra.Lattice.MeetSemiLattice b) => Algebra.Lattice.MeetSemiLattice (a, b)
instance (Algebra.Lattice.Lattice a, Algebra.Lattice.Lattice b) => Algebra.Lattice.Lattice (a, b)
instance (Algebra.Lattice.BoundedJoinSemiLattice a, Algebra.Lattice.BoundedJoinSemiLattice b) => Algebra.Lattice.BoundedJoinSemiLattice (a, b)
instance (Algebra.Lattice.BoundedMeetSemiLattice a, Algebra.Lattice.BoundedMeetSemiLattice b) => Algebra.Lattice.BoundedMeetSemiLattice (a, b)
instance (Algebra.Lattice.BoundedLattice a, Algebra.Lattice.BoundedLattice b) => Algebra.Lattice.BoundedLattice (a, b)
instance Algebra.Lattice.JoinSemiLattice GHC.Types.Bool
instance Algebra.Lattice.MeetSemiLattice GHC.Types.Bool
instance Algebra.Lattice.Lattice GHC.Types.Bool
instance Algebra.Lattice.BoundedJoinSemiLattice GHC.Types.Bool
instance Algebra.Lattice.BoundedMeetSemiLattice GHC.Types.Bool
instance Algebra.Lattice.BoundedLattice GHC.Types.Bool
instance Algebra.Lattice.JoinSemiLattice a => Data.Semigroup.Semigroup (Algebra.Lattice.Join a)
instance Algebra.Lattice.BoundedJoinSemiLattice a => GHC.Base.Monoid (Algebra.Lattice.Join a)
instance GHC.Base.Functor Algebra.Lattice.Join
instance GHC.Base.Applicative Algebra.Lattice.Join
instance GHC.Base.Monad Algebra.Lattice.Join
instance Control.Monad.Zip.MonadZip Algebra.Lattice.Join
instance Data.Universe.Class.Universe a => Data.Universe.Class.Universe (Algebra.Lattice.Join a)
instance Data.Universe.Class.Finite a => Data.Universe.Class.Finite (Algebra.Lattice.Join a)
instance Algebra.Lattice.MeetSemiLattice a => Data.Semigroup.Semigroup (Algebra.Lattice.Meet a)
instance Algebra.Lattice.BoundedMeetSemiLattice a => GHC.Base.Monoid (Algebra.Lattice.Meet a)
instance GHC.Base.Functor Algebra.Lattice.Meet
instance GHC.Base.Applicative Algebra.Lattice.Meet
instance GHC.Base.Monad Algebra.Lattice.Meet
instance Control.Monad.Zip.MonadZip Algebra.Lattice.Meet
instance Data.Universe.Class.Universe a => Data.Universe.Class.Universe (Algebra.Lattice.Meet a)
instance Data.Universe.Class.Finite a => Data.Universe.Class.Finite (Algebra.Lattice.Meet a)
instance Algebra.Lattice.JoinSemiLattice Data.Monoid.All
instance Algebra.Lattice.BoundedJoinSemiLattice Data.Monoid.All
instance Algebra.Lattice.MeetSemiLattice Data.Monoid.All
instance Algebra.Lattice.BoundedMeetSemiLattice Data.Monoid.All
instance Algebra.Lattice.Lattice Data.Monoid.All
instance Algebra.Lattice.BoundedLattice Data.Monoid.All
instance Algebra.Lattice.JoinSemiLattice Data.Monoid.Any
instance Algebra.Lattice.BoundedJoinSemiLattice Data.Monoid.Any
instance Algebra.Lattice.MeetSemiLattice Data.Monoid.Any
instance Algebra.Lattice.BoundedMeetSemiLattice Data.Monoid.Any
instance Algebra.Lattice.Lattice Data.Monoid.Any
instance Algebra.Lattice.BoundedLattice Data.Monoid.Any
instance Algebra.Lattice.JoinSemiLattice a => Algebra.Lattice.JoinSemiLattice (Data.Monoid.Endo a)
instance Algebra.Lattice.BoundedJoinSemiLattice a => Algebra.Lattice.BoundedJoinSemiLattice (Data.Monoid.Endo a)
instance Algebra.Lattice.MeetSemiLattice a => Algebra.Lattice.MeetSemiLattice (Data.Monoid.Endo a)
instance Algebra.Lattice.BoundedMeetSemiLattice a => Algebra.Lattice.BoundedMeetSemiLattice (Data.Monoid.Endo a)
instance Algebra.Lattice.Lattice a => Algebra.Lattice.Lattice (Data.Monoid.Endo a)
instance Algebra.Lattice.BoundedLattice a => Algebra.Lattice.BoundedLattice (Data.Monoid.Endo a)
instance Algebra.Lattice.JoinSemiLattice a => Algebra.Lattice.JoinSemiLattice (Data.Tagged.Tagged t a)
instance Algebra.Lattice.BoundedJoinSemiLattice a => Algebra.Lattice.BoundedJoinSemiLattice (Data.Tagged.Tagged t a)
instance Algebra.Lattice.MeetSemiLattice a => Algebra.Lattice.MeetSemiLattice (Data.Tagged.Tagged t a)
instance Algebra.Lattice.BoundedMeetSemiLattice a => Algebra.Lattice.BoundedMeetSemiLattice (Data.Tagged.Tagged t a)
instance Algebra.Lattice.Lattice a => Algebra.Lattice.Lattice (Data.Tagged.Tagged t a)
instance Algebra.Lattice.BoundedLattice a => Algebra.Lattice.BoundedLattice (Data.Tagged.Tagged t a)
instance Algebra.Lattice.JoinSemiLattice (Data.Proxy.Proxy a)
instance Algebra.Lattice.BoundedJoinSemiLattice (Data.Proxy.Proxy a)
instance Algebra.Lattice.MeetSemiLattice (Data.Proxy.Proxy a)
instance Algebra.Lattice.BoundedMeetSemiLattice (Data.Proxy.Proxy a)
instance Algebra.Lattice.Lattice (Data.Proxy.Proxy a)
instance Algebra.Lattice.BoundedLattice (Data.Proxy.Proxy a)
instance Algebra.Lattice.JoinSemiLattice a => Algebra.Lattice.JoinSemiLattice (Data.Functor.Identity.Identity a)
instance Algebra.Lattice.BoundedJoinSemiLattice a => Algebra.Lattice.BoundedJoinSemiLattice (Data.Functor.Identity.Identity a)
instance Algebra.Lattice.MeetSemiLattice a => Algebra.Lattice.MeetSemiLattice (Data.Functor.Identity.Identity a)
instance Algebra.Lattice.BoundedMeetSemiLattice a => Algebra.Lattice.BoundedMeetSemiLattice (Data.Functor.Identity.Identity a)
instance Algebra.Lattice.Lattice a => Algebra.Lattice.Lattice (Data.Functor.Identity.Identity a)
instance Algebra.Lattice.BoundedLattice a => Algebra.Lattice.BoundedLattice (Data.Functor.Identity.Identity a)
instance Algebra.Lattice.JoinSemiLattice a => Algebra.Lattice.JoinSemiLattice (Data.Functor.Const.Const a b)
instance Algebra.Lattice.BoundedJoinSemiLattice a => Algebra.Lattice.BoundedJoinSemiLattice (Data.Functor.Const.Const a b)
instance Algebra.Lattice.MeetSemiLattice a => Algebra.Lattice.MeetSemiLattice (Data.Functor.Const.Const a b)
instance Algebra.Lattice.BoundedMeetSemiLattice a => Algebra.Lattice.BoundedMeetSemiLattice (Data.Functor.Const.Const a b)
instance Algebra.Lattice.Lattice a => Algebra.Lattice.Lattice (Data.Functor.Const.Const a b)
instance Algebra.Lattice.BoundedLattice a => Algebra.Lattice.BoundedLattice (Data.Functor.Const.Const a b)
instance Algebra.Lattice.JoinSemiLattice Data.Void.Void
instance Algebra.Lattice.MeetSemiLattice Data.Void.Void
instance Algebra.Lattice.Lattice Data.Void.Void


module Algebra.Lattice.Dropped

-- | Graft a distinct top onto an otherwise unbounded lattice. As a bonus,
--   the top will be an absorbing element for the join.
data Dropped a
Top :: Dropped a
Drop :: a -> Dropped a

-- | Interpret <tt><a>Dropped</a> a</tt> using the
--   <a>BoundedMeetSemiLattice</a> of <tt>a</tt>.
retractDropped :: BoundedMeetSemiLattice a => Dropped a -> a
instance GHC.Generics.Generic1 Algebra.Lattice.Dropped.Dropped
instance GHC.Generics.Generic (Algebra.Lattice.Dropped.Dropped a)
instance Data.Data.Data a => Data.Data.Data (Algebra.Lattice.Dropped.Dropped a)
instance GHC.Read.Read a => GHC.Read.Read (Algebra.Lattice.Dropped.Dropped a)
instance GHC.Show.Show a => GHC.Show.Show (Algebra.Lattice.Dropped.Dropped a)
instance GHC.Classes.Ord a => GHC.Classes.Ord (Algebra.Lattice.Dropped.Dropped a)
instance GHC.Classes.Eq a => GHC.Classes.Eq (Algebra.Lattice.Dropped.Dropped a)
instance GHC.Base.Functor Algebra.Lattice.Dropped.Dropped
instance Data.Foldable.Foldable Algebra.Lattice.Dropped.Dropped
instance Data.Traversable.Traversable Algebra.Lattice.Dropped.Dropped
instance GHC.Base.Applicative Algebra.Lattice.Dropped.Dropped
instance GHC.Base.Monad Algebra.Lattice.Dropped.Dropped
instance Control.DeepSeq.NFData a => Control.DeepSeq.NFData (Algebra.Lattice.Dropped.Dropped a)
instance Data.Hashable.Class.Hashable a => Data.Hashable.Class.Hashable (Algebra.Lattice.Dropped.Dropped a)
instance Algebra.Lattice.JoinSemiLattice a => Algebra.Lattice.JoinSemiLattice (Algebra.Lattice.Dropped.Dropped a)
instance Algebra.Lattice.MeetSemiLattice a => Algebra.Lattice.MeetSemiLattice (Algebra.Lattice.Dropped.Dropped a)
instance Algebra.Lattice.Lattice a => Algebra.Lattice.Lattice (Algebra.Lattice.Dropped.Dropped a)
instance Algebra.Lattice.BoundedJoinSemiLattice a => Algebra.Lattice.BoundedJoinSemiLattice (Algebra.Lattice.Dropped.Dropped a)
instance Algebra.Lattice.MeetSemiLattice a => Algebra.Lattice.BoundedMeetSemiLattice (Algebra.Lattice.Dropped.Dropped a)
instance Algebra.Lattice.BoundedLattice a => Algebra.Lattice.BoundedLattice (Algebra.Lattice.Dropped.Dropped a)


module Algebra.Lattice.Levitated

-- | Graft a distinct top and bottom onto an otherwise unbounded lattice.
--   The top is the absorbing element for the join, and the bottom is the
--   absorbing element for the meet.
data Levitated a
Top :: Levitated a
Levitate :: a -> Levitated a
Bottom :: Levitated a

-- | Interpret <tt><a>Levitated</a> a</tt> using the <a>BoundedLattice</a>
--   of <tt>a</tt>.
retractLevitated :: BoundedLattice a => Levitated a -> a
instance GHC.Generics.Generic1 Algebra.Lattice.Levitated.Levitated
instance GHC.Generics.Generic (Algebra.Lattice.Levitated.Levitated a)
instance Data.Data.Data a => Data.Data.Data (Algebra.Lattice.Levitated.Levitated a)
instance GHC.Read.Read a => GHC.Read.Read (Algebra.Lattice.Levitated.Levitated a)
instance GHC.Show.Show a => GHC.Show.Show (Algebra.Lattice.Levitated.Levitated a)
instance GHC.Classes.Ord a => GHC.Classes.Ord (Algebra.Lattice.Levitated.Levitated a)
instance GHC.Classes.Eq a => GHC.Classes.Eq (Algebra.Lattice.Levitated.Levitated a)
instance GHC.Base.Functor Algebra.Lattice.Levitated.Levitated
instance Data.Foldable.Foldable Algebra.Lattice.Levitated.Levitated
instance Data.Traversable.Traversable Algebra.Lattice.Levitated.Levitated
instance GHC.Base.Applicative Algebra.Lattice.Levitated.Levitated
instance GHC.Base.Monad Algebra.Lattice.Levitated.Levitated
instance Control.DeepSeq.NFData a => Control.DeepSeq.NFData (Algebra.Lattice.Levitated.Levitated a)
instance Data.Hashable.Class.Hashable a => Data.Hashable.Class.Hashable (Algebra.Lattice.Levitated.Levitated a)
instance Algebra.Lattice.JoinSemiLattice a => Algebra.Lattice.JoinSemiLattice (Algebra.Lattice.Levitated.Levitated a)
instance Algebra.Lattice.MeetSemiLattice a => Algebra.Lattice.MeetSemiLattice (Algebra.Lattice.Levitated.Levitated a)
instance Algebra.Lattice.Lattice a => Algebra.Lattice.Lattice (Algebra.Lattice.Levitated.Levitated a)
instance Algebra.Lattice.JoinSemiLattice a => Algebra.Lattice.BoundedJoinSemiLattice (Algebra.Lattice.Levitated.Levitated a)
instance Algebra.Lattice.MeetSemiLattice a => Algebra.Lattice.BoundedMeetSemiLattice (Algebra.Lattice.Levitated.Levitated a)
instance Algebra.Lattice.Lattice a => Algebra.Lattice.BoundedLattice (Algebra.Lattice.Levitated.Levitated a)


module Algebra.Lattice.Lexicographic

-- | A pair lattice with a lexicographic ordering. This means in a join the
--   second component of the resulting pair is the second component of the
--   pair with the larger first component. If the first components are
--   equal, then the second components will be joined. The meet is similar
--   only it prefers the smaller first component.
--   
--   An application of this type is versioning. For example, a
--   Last-Writer-Wins register would look like 'Lexicographc (Ordered
--   Timestamp) v' where the lattice structure handles the, presumably
--   rare, case of matching <tt>Timestamps</tt>. Typically this is done in
--   an arbitary, but deterministic manner.
data Lexicographic k v
Lexicographic :: !k -> !v -> Lexicographic k v
instance GHC.Generics.Generic1 (Algebra.Lattice.Lexicographic.Lexicographic k)
instance GHC.Generics.Generic (Algebra.Lattice.Lexicographic.Lexicographic k v)
instance (Data.Data.Data v, Data.Data.Data k) => Data.Data.Data (Algebra.Lattice.Lexicographic.Lexicographic k v)
instance (GHC.Read.Read v, GHC.Read.Read k) => GHC.Read.Read (Algebra.Lattice.Lexicographic.Lexicographic k v)
instance (GHC.Show.Show v, GHC.Show.Show k) => GHC.Show.Show (Algebra.Lattice.Lexicographic.Lexicographic k v)
instance (GHC.Classes.Ord v, GHC.Classes.Ord k) => GHC.Classes.Ord (Algebra.Lattice.Lexicographic.Lexicographic k v)
instance (GHC.Classes.Eq v, GHC.Classes.Eq k) => GHC.Classes.Eq (Algebra.Lattice.Lexicographic.Lexicographic k v)
instance Data.Foldable.Foldable (Algebra.Lattice.Lexicographic.Lexicographic k)
instance Data.Traversable.Traversable (Algebra.Lattice.Lexicographic.Lexicographic k)
instance GHC.Base.Functor (Algebra.Lattice.Lexicographic.Lexicographic k)
instance Algebra.Lattice.BoundedJoinSemiLattice k => GHC.Base.Applicative (Algebra.Lattice.Lexicographic.Lexicographic k)
instance Algebra.Lattice.BoundedJoinSemiLattice k => GHC.Base.Monad (Algebra.Lattice.Lexicographic.Lexicographic k)
instance (Control.DeepSeq.NFData k, Control.DeepSeq.NFData v) => Control.DeepSeq.NFData (Algebra.Lattice.Lexicographic.Lexicographic k v)
instance (Data.Hashable.Class.Hashable k, Data.Hashable.Class.Hashable v) => Data.Hashable.Class.Hashable (Algebra.Lattice.Lexicographic.Lexicographic k v)
instance (Algebra.PartialOrd.PartialOrd k, Algebra.Lattice.JoinSemiLattice k, Algebra.Lattice.JoinSemiLattice v) => Algebra.Lattice.JoinSemiLattice (Algebra.Lattice.Lexicographic.Lexicographic k v)
instance (Algebra.PartialOrd.PartialOrd k, Algebra.Lattice.MeetSemiLattice k, Algebra.Lattice.MeetSemiLattice v) => Algebra.Lattice.MeetSemiLattice (Algebra.Lattice.Lexicographic.Lexicographic k v)
instance (Algebra.PartialOrd.PartialOrd k, Algebra.Lattice.Lattice k, Algebra.Lattice.Lattice v) => Algebra.Lattice.Lattice (Algebra.Lattice.Lexicographic.Lexicographic k v)
instance (Algebra.PartialOrd.PartialOrd k, Algebra.Lattice.BoundedJoinSemiLattice k, Algebra.Lattice.BoundedJoinSemiLattice v) => Algebra.Lattice.BoundedJoinSemiLattice (Algebra.Lattice.Lexicographic.Lexicographic k v)
instance (Algebra.PartialOrd.PartialOrd k, Algebra.Lattice.BoundedMeetSemiLattice k, Algebra.Lattice.BoundedMeetSemiLattice v) => Algebra.Lattice.BoundedMeetSemiLattice (Algebra.Lattice.Lexicographic.Lexicographic k v)
instance (Algebra.PartialOrd.PartialOrd k, Algebra.Lattice.BoundedLattice k, Algebra.Lattice.BoundedLattice v) => Algebra.Lattice.BoundedLattice (Algebra.Lattice.Lexicographic.Lexicographic k v)
instance (Algebra.PartialOrd.PartialOrd k, Algebra.PartialOrd.PartialOrd v) => Algebra.PartialOrd.PartialOrd (Algebra.Lattice.Lexicographic.Lexicographic k v)


module Algebra.Lattice.Lifted

-- | Graft a distinct bottom onto an otherwise unbounded lattice. As a
--   bonus, the bottom will be an absorbing element for the meet.
data Lifted a
Lift :: a -> Lifted a
Bottom :: Lifted a

-- | Interpret <tt><a>Lifted</a> a</tt> using the
--   <a>BoundedJoinSemiLattice</a> of <tt>a</tt>.
retractLifted :: BoundedJoinSemiLattice a => Lifted a -> a
instance GHC.Generics.Generic1 Algebra.Lattice.Lifted.Lifted
instance GHC.Generics.Generic (Algebra.Lattice.Lifted.Lifted a)
instance Data.Data.Data a => Data.Data.Data (Algebra.Lattice.Lifted.Lifted a)
instance GHC.Read.Read a => GHC.Read.Read (Algebra.Lattice.Lifted.Lifted a)
instance GHC.Show.Show a => GHC.Show.Show (Algebra.Lattice.Lifted.Lifted a)
instance GHC.Classes.Ord a => GHC.Classes.Ord (Algebra.Lattice.Lifted.Lifted a)
instance GHC.Classes.Eq a => GHC.Classes.Eq (Algebra.Lattice.Lifted.Lifted a)
instance GHC.Base.Functor Algebra.Lattice.Lifted.Lifted
instance Data.Foldable.Foldable Algebra.Lattice.Lifted.Lifted
instance Data.Traversable.Traversable Algebra.Lattice.Lifted.Lifted
instance GHC.Base.Applicative Algebra.Lattice.Lifted.Lifted
instance GHC.Base.Monad Algebra.Lattice.Lifted.Lifted
instance Control.DeepSeq.NFData a => Control.DeepSeq.NFData (Algebra.Lattice.Lifted.Lifted a)
instance Data.Hashable.Class.Hashable a => Data.Hashable.Class.Hashable (Algebra.Lattice.Lifted.Lifted a)
instance Algebra.Lattice.JoinSemiLattice a => Algebra.Lattice.JoinSemiLattice (Algebra.Lattice.Lifted.Lifted a)
instance Algebra.Lattice.MeetSemiLattice a => Algebra.Lattice.MeetSemiLattice (Algebra.Lattice.Lifted.Lifted a)
instance Algebra.Lattice.Lattice a => Algebra.Lattice.Lattice (Algebra.Lattice.Lifted.Lifted a)
instance Algebra.Lattice.JoinSemiLattice a => Algebra.Lattice.BoundedJoinSemiLattice (Algebra.Lattice.Lifted.Lifted a)
instance Algebra.Lattice.BoundedMeetSemiLattice a => Algebra.Lattice.BoundedMeetSemiLattice (Algebra.Lattice.Lifted.Lifted a)
instance Algebra.Lattice.BoundedLattice a => Algebra.Lattice.BoundedLattice (Algebra.Lattice.Lifted.Lifted a)


module Algebra.Lattice.Op

-- | The opposite lattice of a given lattice. That is, switch meets and
--   joins.
newtype Op a
Op :: a -> Op a
[getOp] :: Op a -> a
instance GHC.Generics.Generic1 Algebra.Lattice.Op.Op
instance GHC.Generics.Generic (Algebra.Lattice.Op.Op a)
instance Data.Data.Data a => Data.Data.Data (Algebra.Lattice.Op.Op a)
instance GHC.Read.Read a => GHC.Read.Read (Algebra.Lattice.Op.Op a)
instance GHC.Show.Show a => GHC.Show.Show (Algebra.Lattice.Op.Op a)
instance GHC.Classes.Ord a => GHC.Classes.Ord (Algebra.Lattice.Op.Op a)
instance GHC.Classes.Eq a => GHC.Classes.Eq (Algebra.Lattice.Op.Op a)
instance Data.Foldable.Foldable Algebra.Lattice.Op.Op
instance Data.Traversable.Traversable Algebra.Lattice.Op.Op
instance GHC.Base.Functor Algebra.Lattice.Op.Op
instance GHC.Base.Applicative Algebra.Lattice.Op.Op
instance GHC.Base.Monad Algebra.Lattice.Op.Op
instance Control.DeepSeq.NFData a => Control.DeepSeq.NFData (Algebra.Lattice.Op.Op a)
instance Data.Hashable.Class.Hashable a => Data.Hashable.Class.Hashable (Algebra.Lattice.Op.Op a)
instance Algebra.Lattice.MeetSemiLattice a => Algebra.Lattice.JoinSemiLattice (Algebra.Lattice.Op.Op a)
instance Algebra.Lattice.JoinSemiLattice a => Algebra.Lattice.MeetSemiLattice (Algebra.Lattice.Op.Op a)
instance (Algebra.Lattice.Lattice a, GHC.Classes.Ord a) => Algebra.Lattice.Lattice (Algebra.Lattice.Op.Op a)
instance Algebra.Lattice.BoundedMeetSemiLattice a => Algebra.Lattice.BoundedJoinSemiLattice (Algebra.Lattice.Op.Op a)
instance Algebra.Lattice.BoundedJoinSemiLattice a => Algebra.Lattice.BoundedMeetSemiLattice (Algebra.Lattice.Op.Op a)
instance (Algebra.Lattice.BoundedLattice a, GHC.Classes.Ord a, GHC.Enum.Bounded a) => Algebra.Lattice.BoundedLattice (Algebra.Lattice.Op.Op a)
instance Algebra.PartialOrd.PartialOrd a => Algebra.PartialOrd.PartialOrd (Algebra.Lattice.Op.Op a)


module Algebra.Lattice.Ordered

-- | A total order gives rise to a lattice. Join is max, meet is min.
newtype Ordered a
Ordered :: a -> Ordered a
[getOrdered] :: Ordered a -> a
instance GHC.Generics.Generic1 Algebra.Lattice.Ordered.Ordered
instance GHC.Generics.Generic (Algebra.Lattice.Ordered.Ordered a)
instance Data.Data.Data a => Data.Data.Data (Algebra.Lattice.Ordered.Ordered a)
instance GHC.Read.Read a => GHC.Read.Read (Algebra.Lattice.Ordered.Ordered a)
instance GHC.Show.Show a => GHC.Show.Show (Algebra.Lattice.Ordered.Ordered a)
instance GHC.Classes.Ord a => GHC.Classes.Ord (Algebra.Lattice.Ordered.Ordered a)
instance GHC.Classes.Eq a => GHC.Classes.Eq (Algebra.Lattice.Ordered.Ordered a)
instance Data.Foldable.Foldable Algebra.Lattice.Ordered.Ordered
instance Data.Traversable.Traversable Algebra.Lattice.Ordered.Ordered
instance GHC.Base.Functor Algebra.Lattice.Ordered.Ordered
instance GHC.Base.Applicative Algebra.Lattice.Ordered.Ordered
instance GHC.Base.Monad Algebra.Lattice.Ordered.Ordered
instance Control.DeepSeq.NFData a => Control.DeepSeq.NFData (Algebra.Lattice.Ordered.Ordered a)
instance Data.Hashable.Class.Hashable a => Data.Hashable.Class.Hashable (Algebra.Lattice.Ordered.Ordered a)
instance GHC.Classes.Ord a => Algebra.Lattice.JoinSemiLattice (Algebra.Lattice.Ordered.Ordered a)
instance GHC.Classes.Ord a => Algebra.Lattice.MeetSemiLattice (Algebra.Lattice.Ordered.Ordered a)
instance (Algebra.Lattice.Lattice a, GHC.Classes.Ord a) => Algebra.Lattice.Lattice (Algebra.Lattice.Ordered.Ordered a)
instance (GHC.Classes.Ord a, GHC.Enum.Bounded a) => Algebra.Lattice.BoundedJoinSemiLattice (Algebra.Lattice.Ordered.Ordered a)
instance (GHC.Classes.Ord a, GHC.Enum.Bounded a) => Algebra.Lattice.BoundedMeetSemiLattice (Algebra.Lattice.Ordered.Ordered a)
instance (Algebra.Lattice.BoundedLattice a, GHC.Classes.Ord a, GHC.Enum.Bounded a) => Algebra.Lattice.BoundedLattice (Algebra.Lattice.Ordered.Ordered a)
instance GHC.Classes.Ord a => Algebra.PartialOrd.PartialOrd (Algebra.Lattice.Ordered.Ordered a)



-- | <i>Deprecated: Use Data.Universe.Class</i>
module Algebra.Enumerable

-- | Finitely enumerable things
class Enumerable a
universe :: Enumerable a => [a]
universeBounded :: (Enum a, Bounded a) => [a]

-- | Wrapper used to mark where we expect to use the fact that something is
--   Enumerable
newtype Enumerated a
Enumerated :: a -> Enumerated a
[unEnumerated] :: Enumerated a -> a
instance GHC.Classes.Ord a => GHC.Classes.Ord (Algebra.Enumerable.Enumerated a)
instance GHC.Classes.Eq a => GHC.Classes.Eq (Algebra.Enumerable.Enumerated a)
instance Algebra.Enumerable.Enumerable a => Algebra.Enumerable.Enumerable (Algebra.Enumerable.Enumerated a)
instance Algebra.Enumerable.Enumerable GHC.Types.Bool
instance Algebra.Enumerable.Enumerable GHC.Types.Int
instance Algebra.Enumerable.Enumerable a => Algebra.Enumerable.Enumerable (GHC.Base.Maybe a)
instance (Algebra.Enumerable.Enumerable a, Algebra.Enumerable.Enumerable b) => Algebra.Enumerable.Enumerable (Data.Either.Either a b)
instance Algebra.Enumerable.Enumerable ()
instance (Algebra.Enumerable.Enumerable a, Algebra.Enumerable.Enumerable b) => Algebra.Enumerable.Enumerable (a, b)
