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

Safe HaskellNone
LanguageHaskell98

Number.SI

Description

Numerical values equipped with SI units. This is considered as the user front-end.

Documentation

newtype T a v Source #

Constructors

Cons (PValue v) 
Instances
C a v => C a (T b v) Source # 
Instance details

Defined in Number.SI

Methods

(*>) :: a -> T b v -> T b v Source #

C a v => C a (T b v) Source # 
Instance details

Defined in Number.SI

(C a, Ord a, C a v, Show v, C a v) => C a (T a v) Source # 
Instance details

Defined in Number.SI

Methods

toScalar :: T a v -> a Source #

toMaybeScalar :: T a v -> Maybe a Source #

fromScalar :: a -> T a v Source #

Functor (T a) Source # 
Instance details

Defined in Number.SI

Methods

fmap :: (a0 -> b) -> T a a0 -> T a b #

(<$) :: a0 -> T a b -> T a a0 #

C (T a) Source # 
Instance details

Defined in Number.SI

Methods

zero :: C a0 => T a a0 Source #

(<+>) :: C a0 => T a a0 -> T a a0 -> T a a0 Source #

(*>) :: C a0 => a0 -> T a a0 -> T a a0 Source #

Eq v => Eq (T a v) Source # 
Instance details

Defined in Number.SI

Methods

(==) :: T a v -> T a v -> Bool #

(/=) :: T a v -> T a v -> Bool #

Fractional v => Fractional (T a v) Source # 
Instance details

Defined in Number.SI

Methods

(/) :: T a v -> T a v -> T a v #

recip :: T a v -> T a v #

fromRational :: Rational -> T a v #

Num v => Num (T a v) Source # 
Instance details

Defined in Number.SI

Methods

(+) :: T a v -> T a v -> T a v #

(-) :: T a v -> T a v -> T a v #

(*) :: T a v -> T a v -> T a v #

negate :: T a v -> T a v #

abs :: T a v -> T a v #

signum :: T a v -> T a v #

fromInteger :: Integer -> T a v #

Ord v => Ord (T a v) Source # 
Instance details

Defined in Number.SI

Methods

compare :: T a v -> T a v -> Ordering #

(<) :: T a v -> T a v -> Bool #

(<=) :: T a v -> T a v -> Bool #

(>) :: T a v -> T a v -> Bool #

(>=) :: T a v -> T a v -> Bool #

max :: T a v -> T a v -> T a v #

min :: T a v -> T a v -> T a v #

(Read v, Ord a, C a, C a v) => Read (T a v) Source # 
Instance details

Defined in Number.SI

Methods

readsPrec :: Int -> ReadS (T a v) #

readList :: ReadS [T a v] #

readPrec :: ReadPrec (T a v) #

readListPrec :: ReadPrec [T a v] #

(Show v, Ord a, C a, C a v) => Show (T a v) Source # 
Instance details

Defined in Number.SI

Methods

showsPrec :: Int -> T a v -> ShowS #

show :: T a v -> String #

showList :: [T a v] -> ShowS #

C v => C (T a v) Source # 
Instance details

Defined in Number.SI

Methods

zero :: T a v Source #

(+) :: T a v -> T a v -> T a v Source #

(-) :: T a v -> T a v -> T a v Source #

negate :: T a v -> T a v Source #

C v => C (T a v) Source # 
Instance details

Defined in Number.SI

Methods

isZero :: T a v -> Bool Source #

C v => C (T a v) Source # 
Instance details

Defined in Number.SI

Methods

(*) :: T a v -> T a v -> T a v Source #

one :: T a v Source #

fromInteger :: Integer -> T a v Source #

(^) :: T a v -> Integer -> T a v Source #

C v => C (T a v) Source # 
Instance details

Defined in Number.SI

Methods

abs :: T a v -> T a v Source #

signum :: T a v -> T a v Source #

C v => C (T a v) Source # 
Instance details

Defined in Number.SI

Methods

(/) :: T a v -> T a v -> T a v Source #

recip :: T a v -> T a v Source #

fromRational' :: Rational -> T a v Source #

(^-) :: T a v -> Integer -> T a v Source #

C v => C (T a v) Source # 
Instance details

Defined in Number.SI

Methods

sqrt :: T a v -> T a v Source #

root :: Integer -> T a v -> T a v Source #

(^/) :: T a v -> Rational -> T a v Source #

C v => C (T a v) Source # 
Instance details

Defined in Number.SI

Methods

pi :: T a v Source #

exp :: T a v -> T a v Source #

log :: T a v -> T a v Source #

logBase :: T a v -> T a v -> T a v Source #

(**) :: T a v -> T a v -> T a v Source #

sin :: T a v -> T a v Source #

cos :: T a v -> T a v Source #

tan :: T a v -> T a v Source #

asin :: T a v -> T a v Source #

acos :: T a v -> T a v Source #

atan :: T a v -> T a v Source #

sinh :: T a v -> T a v Source #

cosh :: T a v -> T a v Source #

tanh :: T a v -> T a v Source #

asinh :: T a v -> T a v Source #

acosh :: T a v -> T a v Source #

atanh :: T a v -> T a v Source #

lift :: (PValue v0 -> PValue v1) -> T a v0 -> T a v1 Source #

lift2 :: (PValue v0 -> PValue v1 -> PValue v2) -> T a v0 -> T a v1 -> T a v2 Source #

liftGen :: (PValue v -> x) -> T a v -> x Source #

lift2Gen :: (PValue v0 -> PValue v1 -> x) -> T a v0 -> T a v1 -> x Source #

scale :: C v => v -> T a v -> T a v Source #

showNat :: (Show v, C a, Ord a, C a v) => T Dimension a -> T a v -> String Source #

readsNat :: (Read v, C a v) => T Dimension a -> Int -> ReadS (T a v) Source #

quantity :: (C a, C v) => T Dimension -> v -> T a v Source #

hertz :: (C a, C v) => T a v Source #

second :: (C a, C v) => T a v Source #

minute :: (C a, C v) => T a v Source #

hour :: (C a, C v) => T a v Source #

day :: (C a, C v) => T a v Source #

year :: (C a, C v) => T a v Source #

meter :: (C a, C v) => T a v Source #

liter :: (C a, C v) => T a v Source #

gramm :: (C a, C v) => T a v Source #

tonne :: (C a, C v) => T a v Source #

newton :: (C a, C v) => T a v Source #

pascal :: (C a, C v) => T a v Source #

bar :: (C a, C v) => T a v Source #

joule :: (C a, C v) => T a v Source #

watt :: (C a, C v) => T a v Source #

kelvin :: (C a, C v) => T a v Source #

coulomb :: (C a, C v) => T a v Source #

ampere :: (C a, C v) => T a v Source #

volt :: (C a, C v) => T a v Source #

ohm :: (C a, C v) => T a v Source #

farad :: (C a, C v) => T a v Source #

bit :: (C a, C v) => T a v Source #

byte :: (C a, C v) => T a v Source #

baud :: (C a, C v) => T a v Source #

inch :: (C a, C v) => T a v Source #

foot :: (C a, C v) => T a v Source #

yard :: (C a, C v) => T a v Source #

astronomicUnit :: (C a, C v) => T a v Source #

parsec :: (C a, C v) => T a v Source #

mach :: (C a, C v) => T a v Source #

speedOfLight :: (C a, C v) => T a v Source #

electronVolt :: (C a, C v) => T a v Source #

calorien :: (C a, C v) => T a v Source #

horsePower :: (C a, C v) => T a v Source #