-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | (deprecated) Ring class, with several instances. -- -- Provides an algebraic ring class and instances for Gibbs free energy, -- partition function probabilities, and scores. Conversion between -- different entities is provided by a convert function. All entities are -- ready for the vector library. -- -- @package BiobaseTypes @version 0.0.2.2 -- | Algebraic ring structure. Very similar to others found throughout -- hackage. -- -- TODO maybe use on of the already-written packages? module Biobase.Types.Ring -- | Define the basic operations on a ring. class (Eq a, Ord a) => Ring a (.+.) :: Ring a => a -> a -> a (.*.) :: Ring a => a -> a -> a (.^.) :: Ring a => a -> Int -> a (.^^.) :: Ring a => a -> Double -> a neg :: Ring a => a -> a one :: Ring a => a zero :: Ring a => a isZero :: Ring a => a -> Bool module Biobase.Types.Energy -- | Some default instances. Left out the Num one, so that you have to -- explicitly instanciate if you want to go around the Ring structure. newtype Energy Energy :: Int -> Energy unEnergy :: Energy -> Int instance Prim Energy instance Unbox Energy instance Vector Vector Energy instance MVector MVector Energy instance Show Energy instance Read Energy instance Eq Energy instance Ord Energy instance Ring Energy module Biobase.Types.Score -- | Some default instances. Left out the Num one, so that you have to -- explicitly instanciate if you want to go around the Ring structure. newtype Score Score :: Int -> Score unScore :: Score -> Int instance Prim Score instance Unbox Score instance Vector Vector Score instance MVector MVector Score instance Show Score instance Read Score instance Eq Score instance Ord Score instance Ring Score module Biobase.Types.Partition -- | Some default instances. Left out the Num one, so that you have to -- explicitly instanciate if you want to go around the Ring structure. newtype Partition Partition :: Double -> Partition unPartition' :: Partition -> Double mkPartition :: Double -> Partition unPartition :: Partition -> Double logSum :: Double -> Double -> Double log1p :: Double -> Double expm1 :: Double -> Double instance Prim Partition instance Unbox Partition instance Vector Vector Partition instance MVector MVector Partition instance Show Partition instance Read Partition instance Eq Partition instance Ord Partition instance Ring Partition -- | Provides a converting function between different types. Most useful -- conversions are instanced here. module Biobase.Types.Convert -- | How to convert between different values. class Convert a b c convert :: Convert a b c => a -> b -> c -- | From (Gibbs free) energy to partition function values. -- -- TODO temperature is running around here: move to some library later on newtype Kelvin Kelvin :: Double -> Kelvin unKelvin :: Kelvin -> Double instance Convert Kelvin Energy Partition