Safe Haskell | Safe |
---|---|
Language | Haskell2010 |
Synopsis
- ratw08 :: Cast k Rational (Extended Word8)
- ratw16 :: Cast k Rational (Extended Word16)
- ratw32 :: Cast k Rational (Extended Word32)
- ratw64 :: Cast k Rational (Extended Word64)
- ratwxx :: Cast k Rational (Extended Word)
- ratnat :: Cast k Rational (Extended Natural)
- rati08 :: Cast k Rational (Extended Int8)
- rati16 :: Cast k Rational (Extended Int16)
- rati32 :: Cast k Rational (Extended Int32)
- rati64 :: Cast k Rational (Extended Int64)
- ratixx :: Cast k Rational (Extended Int)
- ratint :: Cast k Rational (Extended Integer)
- ratrat :: Cast k (Rational, Rational) Rational
- reduce :: Integral a => Ratio a -> Ratio a
- shiftr :: Num a => a -> Ratio a -> Ratio a
- data Ratio a = !a :% !a
Rational
shiftr :: Num a => a -> Ratio a -> Ratio a Source #
Shift by n 'units of least precision' where the ULP is determined by the denominator
This is an analog of shift32
for rationals.
Rational numbers, with numerator and denominator of some Integral
type.
Note that Ratio
's instances inherit the deficiencies from the type
parameter's. For example, Ratio Natural
's Num
instance has similar
problems to Natural
's.
!a :% !a |