Safe Haskell | Safe-Inferred |
---|---|

Language | Haskell2010 |

- symmetric :: Eq b => (t -> t -> b) -> t -> t -> Bool
- antisymmetric :: Eq b => (b -> b -> b) -> b -> b -> Bool
- inverts :: Eq b => (b -> b1) -> (b1 -> b) -> b -> Bool
- involutive :: Eq b => (b -> b) -> b -> Bool
- nonDecreasing :: Ord b => (b -> b) -> b -> Bool
- increasing :: Ord b => (b -> b) -> b -> Bool
- fixes :: Eq b => (b -> b) -> b -> Bool
- idempotent :: Eq b => (b -> b) -> b -> Bool
- leftId :: Eq b => (t -> b -> b) -> t -> b -> Bool
- rightId :: Eq b => (b -> t -> b) -> t -> b -> Bool
- identity :: Eq b => (b -> b -> b) -> b -> b -> Bool
- associative :: Eq b => (b -> b -> b) -> b -> b -> b -> Bool
- monoidal :: Eq b => (b -> b -> b) -> b -> b -> b -> b -> Bool
- equalizes :: Eq b => (a -> b) -> (t -> a) -> (t -> a) -> t -> Bool
- eqBy :: Eq b => (a -> b) -> a -> a -> Bool
- leqBy :: Ord b => (a -> b) -> a -> a -> Bool
- leBy :: Ord b => (a -> b) -> a -> a -> Bool
- symmetricBy :: Eq b => (a -> b) -> (t -> t -> a) -> t -> t -> Bool
- antisymmetricBy :: Eq b => (t -> b) -> (t -> t -> t) -> t -> t -> Bool
- invertsBy :: Eq b => (s -> b) -> (s -> b1) -> (b1 -> s) -> s -> Bool
- involutiveBy :: Eq b => (b1 -> b) -> (b1 -> b1) -> b1 -> Bool
- nonDecreasingBy :: Ord b => (a -> b) -> (a -> a) -> a -> Bool
- increasingBy :: Ord b => (a -> b) -> (a -> a) -> a -> Bool
- fixesBy :: Eq b => (s -> b) -> (s -> s) -> s -> Bool
- idempotentBy :: Eq b => (s -> b) -> (s -> s) -> s -> Bool
- associativeBy :: Eq b => (a -> b) -> (a -> a -> a) -> a -> a -> a -> Bool
- monoidalBy :: Eq b => (a -> b) -> (a -> a -> a) -> a -> a -> a -> a -> Bool
- leftIdBy :: Eq b => (a -> b) -> (t -> a -> a) -> t -> a -> Bool
- rightIdBy :: Eq b => (a -> b) -> (a -> t -> a) -> t -> a -> Bool
- identityBy :: Eq b => (t -> b) -> (t -> t -> t) -> t -> t -> Bool

# Documentation

symmetric :: Eq b => (t -> t -> b) -> t -> t -> Bool Source

f a b == f b a

symmetric (==) :: Int -> Int -> Bool

symmetric (+) :: Int -> Int -> Bool

antisymmetric :: Eq b => (b -> b -> b) -> b -> b -> Bool Source

implies `symmetric`

f a b`a == b`

antisymmetric (-) :: Int -> Int -> Bool

inverts :: Eq b => (b -> b1) -> (b1 -> b) -> b -> Bool Source

a == (g . f) a

inverts pred succ :: Int -> Bool

inverts succ pred :: Char -> Bool

involutive :: Eq b => (b -> b) -> b -> Bool Source

nonDecreasing :: Ord b => (b -> b) -> b -> Bool Source

a <= f a

nonDecreasing id

nonDecreasing (\x -> if even x then x else succ x)

increasing :: Ord b => (b -> b) -> b -> Bool Source

a < f a

increasing succ :: Int -> Bool

fixes :: Eq b => (b -> b) -> b -> Bool Source

Alias for `idempotent`

idempotent :: Eq b => (b -> b) -> b -> Bool Source

f a == f (f a)

idempotent (const "thingy")

idempotent (*0)

idempotent (&& False)

associative :: Eq b => (b -> b -> b) -> b -> b -> b -> Bool Source

f a (f b c) == f (f a b) c

associative (&&)

associative (||)

associative (++)

associative (*)

monoidal :: Eq b => (b -> b -> b) -> b -> b -> b -> b -> Bool Source

and `identity`

f e`associative`

f a b c

monoidal (&&) True

monoidal (||) False

monoidal (++) []

monoidal (*) 1

equalizes :: Eq b => (a -> b) -> (t -> a) -> (t -> a) -> t -> Bool Source

eq (f a) == eq (g a)

equalizes even (*2) (*4)

equalizes (const [4]) (take 7) (take 12)

symmetricBy :: Eq b => (a -> b) -> (t -> t -> a) -> t -> t -> Bool Source

antisymmetricBy :: Eq b => (t -> b) -> (t -> t -> t) -> t -> t -> Bool Source

involutiveBy :: Eq b => (b1 -> b) -> (b1 -> b1) -> b1 -> Bool Source

nonDecreasingBy :: Ord b => (a -> b) -> (a -> a) -> a -> Bool Source

increasingBy :: Ord b => (a -> b) -> (a -> a) -> a -> Bool Source

idempotentBy :: Eq b => (s -> b) -> (s -> s) -> s -> Bool Source

associativeBy :: Eq b => (a -> b) -> (a -> a -> a) -> a -> a -> a -> Bool Source

monoidalBy :: Eq b => (a -> b) -> (a -> a -> a) -> a -> a -> a -> a -> Bool Source

identityBy :: Eq b => (t -> b) -> (t -> t -> t) -> t -> t -> Bool Source