Portability | portable |
---|---|
Stability | experimental |
Maintainer | hans@hanshoglund.se |
Safe Haskell | None |
Absolute pitch representation.
The canonical pitch representation is frequency in Hertz (Hz). For conversion, see
HasFrequency
.
- newtype Hertz = Hertz {}
- data Cents
- data Fifths
- class HasFrequency a where
- fifths :: HasFrequency a => a -> Fifths
- cents :: HasFrequency a => a -> Cents
Documentation
Absolute frequency in Hertz.
Number of pure octaves.
Cents are a logarithmic representation of frequency such that
f * (2/1) = frequency (cents f + 1200)
Number of pure fifths.
Fifths are a logarithmic representation of frequency.
f * (3/2) = frequency (fifths f + 1)
class HasFrequency a whereSource
fifths :: HasFrequency a => a -> FifthsSource
cents :: HasFrequency a => a -> CentsSource