hmt-0.15: Haskell Music Theory

Safe Haskell | Safe
Language | Haskell98

Music.Theory.Z

Description

Generalised Z-n functions.

Synopsis

- lift_unary_Z :: Integral a => a -> (t -> a) -> t -> a
- lift_binary_Z :: Integral a => a -> (s -> t -> a) -> s -> t -> a
- z_add :: Integral a => a -> a -> a -> a
- z_sub :: Integral a => a -> a -> a -> a
- z_mul :: Integral a => a -> a -> a -> a
- z_negate :: Integral a => a -> a -> a
- z_fromInteger :: Integral a => a -> Integer -> a
- z_signum :: t -> t1 -> t2
- z_abs :: t -> t1 -> t2
- to_Z :: Integral i => i -> i -> i
- from_Z :: (Integral i, Num n) => i -> n
- z_complement :: (Enum a, Eq a, Num a) => a -> [a] -> [a]
- z_quot :: Integral i => i -> i -> i -> i
- z_rem :: Integral c => c -> c -> c -> c
- z_div :: Integral c => c -> c -> c -> c
- z_mod :: Integral c => c -> c -> c -> c
- z_quotRem :: Integral t => t -> t -> t -> (t, t)
- z_divMod :: Integral t => t -> t -> t -> (t, t)
- z_toInteger :: Integral i => i -> i -> i

# Documentation

lift_unary_Z :: Integral a => a -> (t -> a) -> t -> a Source #

lift_binary_Z :: Integral a => a -> (s -> t -> a) -> s -> t -> a Source #

z_add :: Integral a => a -> a -> a -> a Source #

z_sub :: Integral a => a -> a -> a -> a Source #

z_mul :: Integral a => a -> a -> a -> a Source #

z_negate :: Integral a => a -> a -> a Source #

z_fromInteger :: Integral a => a -> Integer -> a Source #

z_signum :: t -> t1 -> t2 Source #

z_abs :: t -> t1 -> t2 Source #

to_Z :: Integral i => i -> i -> i Source #

from_Z :: (Integral i, Num n) => i -> n Source #

z_complement :: (Enum a, Eq a, Num a) => a -> [a] -> [a] Source #

Z not in set.

    z_complement 5 [0,2,3] == [1,4]
    z_complement 12 [0,2,4,5,7,9,11] == [1,3,6,8,10]

z_quot :: Integral i => i -> i -> i -> i Source #

z_rem :: Integral c => c -> c -> c -> c Source #

z_div :: Integral c => c -> c -> c -> c Source #

z_mod :: Integral c => c -> c -> c -> c Source #

z_quotRem :: Integral t => t -> t -> t -> (t, t) Source #

z_divMod :: Integral t => t -> t -> t -> (t, t) Source #

z_toInteger :: Integral i => i -> i -> i Source #