numeric-prelude-0.4.3.2: An experimental alternative hierarchy of numeric type classes

Safe HaskellNone
LanguageHaskell98

MathObj.Monoid

Synopsis

Documentation

newtype GCD a Source #

It is only a monoid for non-negative numbers.

idt <*> GCD (-2) = GCD 2

Thus, use this Monoid only for non-negative numbers!

Constructors

GCD 

Fields

Instances
Eq a => Eq (GCD a) Source # 
Instance details

Defined in MathObj.Monoid

Methods

(==) :: GCD a -> GCD a -> Bool #

(/=) :: GCD a -> GCD a -> Bool #

Show a => Show (GCD a) Source # 
Instance details

Defined in MathObj.Monoid

Methods

showsPrec :: Int -> GCD a -> ShowS #

show :: GCD a -> String #

showList :: [GCD a] -> ShowS #

C a => C (GCD a) Source # 
Instance details

Defined in MathObj.Monoid

Methods

idt :: GCD a Source #

(<*>) :: GCD a -> GCD a -> GCD a Source #

cumulate :: [GCD a] -> GCD a Source #

newtype LCM a Source #

Constructors

LCM 

Fields

Instances
Eq a => Eq (LCM a) Source # 
Instance details

Defined in MathObj.Monoid

Methods

(==) :: LCM a -> LCM a -> Bool #

(/=) :: LCM a -> LCM a -> Bool #

Show a => Show (LCM a) Source # 
Instance details

Defined in MathObj.Monoid

Methods

showsPrec :: Int -> LCM a -> ShowS #

show :: LCM a -> String #

showList :: [LCM a] -> ShowS #

C a => C (LCM a) Source # 
Instance details

Defined in MathObj.Monoid

Methods

idt :: LCM a Source #

(<*>) :: LCM a -> LCM a -> LCM a Source #

cumulate :: [LCM a] -> LCM a Source #

newtype Min a Source #

Nothing is the largest element.

Constructors

Min 

Fields

Instances
Eq a => Eq (Min a) Source # 
Instance details

Defined in MathObj.Monoid

Methods

(==) :: Min a -> Min a -> Bool #

(/=) :: Min a -> Min a -> Bool #

Show a => Show (Min a) Source # 
Instance details

Defined in MathObj.Monoid

Methods

showsPrec :: Int -> Min a -> ShowS #

show :: Min a -> String #

showList :: [Min a] -> ShowS #

Ord a => C (Min a) Source # 
Instance details

Defined in MathObj.Monoid

Methods

idt :: Min a Source #

(<*>) :: Min a -> Min a -> Min a Source #

cumulate :: [Min a] -> Min a Source #

newtype Max a Source #

Nothing is the smallest element.

Constructors

Max 

Fields

Instances
Eq a => Eq (Max a) Source # 
Instance details

Defined in MathObj.Monoid

Methods

(==) :: Max a -> Max a -> Bool #

(/=) :: Max a -> Max a -> Bool #

Show a => Show (Max a) Source # 
Instance details

Defined in MathObj.Monoid

Methods

showsPrec :: Int -> Max a -> ShowS #

show :: Max a -> String #

showList :: [Max a] -> ShowS #

Ord a => C (Max a) Source # 
Instance details

Defined in MathObj.Monoid

Methods

idt :: Max a Source #

(<*>) :: Max a -> Max a -> Max a Source #

cumulate :: [Max a] -> Max a Source #