dimensional-0.12: Statically checked physical dimensions.

PortabilityGHC only?
StabilityExperimental
Maintainerbjorn.buckwalter@gmail.com
Safe HaskellNone

Numeric.Units.Dimensional.CGS

Description

Please refer to the literate Haskell code for documentation of both API and implementation.

Documentation

data CGSDim lh mh t Source

Instances

(NumType lh, NumType mh, NumType t) => Show (CGSDim lh mh t) 
(Div lh x lh', Div mh x mh', Div t x t') => Root (CGSDim lh mh t) x (CGSDim lh' mh' t') 
(Mul lh x lh', Mul mh x mh', Mul t x t') => Pow (CGSDim lh mh t) x (CGSDim lh' mh' t') 
(Sum lh lh' lh'', Sum mh mh' mh'', Sum t t' t'') => Div (CGSDim lh'' mh'' t'') (CGSDim lh' mh' t') (CGSDim lh mh t) 
(Sum lh lh' lh'', Sum mh mh' mh'', Sum t t' t'') => Mul (CGSDim lh mh t) (CGSDim lh' mh' t') (CGSDim lh'' mh'' t'') 

unit_SI :: Num a => Quantity (Dim l m t i th n j) a -> Unit (Dim l m t i th n j) aSource

unit_CGS :: forall a l m t i l2 m2 il it l' m' t'. (Floating a, Mul Zero l Zero, Mul Pos2 l l2, Mul Zero m Zero, Mul Pos2 m m2, Mul Zero t Zero, Mul Pos1 t t, Sum l2 Zero l2, Sum Zero m2 m2, Sum m2 Zero m2, Sum Zero t t, Mul Pos3 i il, Mul Pos1 i i, Mul Neg2 i it, Sum l2 il l', Sum m2 i m', Sum t it t') => Quantity (Dim l m t i Zero Zero Zero) a -> Unit (CGSDim l' m' t') aSource

fromSI :: (Floating a, Add l2 Zero l2, Add m2 Zero m2, Add l2 il l', Add m2 i m', Add t it t', Sub m2 m2 Zero, Sub t t Zero, Sub l' il l2, Sub m' i m2, Sub t' it t, Mul Zero l Zero, Mul Pos2 l l2, Mul Zero m Zero, Mul Pos2 m m2, Mul Zero t Zero, Mul Pos1 t t, Mul Pos3 i il, Mul Pos1 i i, Mul Neg2 i it) => Quantity (Dim l m t i Zero Zero Zero) a -> Quantity (CGSDim l' m' t') aSource

toSI :: forall a l m t i l2 m2 il it l' m' t'. (Floating a, Mul Zero l Zero, Mul Pos2 l l2, Mul Zero m Zero, Mul Pos2 m m2, Mul Zero t Zero, Mul Pos1 t t, Sum l2 Zero l2, Sum Zero m2 m2, Sum m2 Zero m2, Sum Zero t t, Mul Pos3 i il, Mul Pos1 i i, Mul Neg2 i it, Sum l2 il l', Sum m2 i m', Sum t it t') => Quantity (CGSDim l' m' t') a -> Quantity (Dim l m t i Zero Zero Zero) aSource