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

Safe HaskellNone
LanguageHaskell98

Number.ResidueClass

Synopsis

Documentation

add :: C a => a -> a -> a -> a Source

sub :: C a => a -> a -> a -> a Source

neg :: C a => a -> a -> a Source

mul :: C a => a -> a -> a -> a Source

divideMaybe :: C a => a -> a -> a -> Maybe a Source

The division may be ambiguous. In this case an arbitrary quotient is returned.

0:4 * 2:4 == 0/:4
2:4 * 2:4 == 0/:4

divide :: C a => a -> a -> a -> a Source

recip :: C a => a -> a -> a Source