Generic classes for floating point types. The interface is loosely based off of the C math library.
- data FPClassification
- class (Fractional a, Poset a) => Roundable a where
- class Fractional a => Floating a where
- class Floating a => RealFloat a where
- fma :: a -> a -> a -> a
- copysign :: a -> a -> a
- nextafter :: a -> a -> a
- atan2 :: a -> a -> a
- fmod :: a -> a -> a
- frem :: a -> a -> a
- fquotRem :: a -> a -> (Int, a)
- hypot :: a -> a -> a
- cbrt :: a -> a
- exp2 :: a -> a
- expm1 :: a -> a
- log10 :: a -> a
- log1p :: a -> a
- log2 :: a -> a
- logb :: a -> a
- erf :: a -> a
- erfc :: a -> a
- lgamma :: a -> a
- tgamma :: a -> a
- classify :: a -> FPClassification
- infinity :: a
- nan :: a
- pi :: a
Classification of floating point values.
Class for types which can be rounded to integers. The rounding functions in the Prelude are inadequate for floating point because they shoehorn their results into an integral type.
Discards the fractional component from a value. Results in
if the result cannot be represented as an integer, such as if the input
is infinite or NaN.
Class for floating point types (real or complex-valued).
Minimal complete definition: everything.
Class for real-valued floating point types.