Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Windowing functions.
Synopsis
- type Window x = x -> x
- type Table x = [x]
- window_table :: (Integral n, Fractional a, Enum a) => n -> Window a -> Table a
- square :: Num a => a -> a
- gaussian :: Floating a => a -> Window a
- hann :: Floating a => Window a
- hamming :: Floating a => Window a
- rectangular :: Window a
- sine :: Floating a => Window a
- triangular :: Fractional a => Window a
- gaussian_table :: (Integral n, Floating b, Enum b) => n -> b -> [b]
- hamming_table :: Int -> [Double]
- hann_table :: Int -> [Double]
- sine_table :: (Integral n, Floating b, Enum b) => n -> [b]
- triangular_table :: (Integral n, Fractional b, Enum b) => n -> [b]
Type and conversion
window_table :: (Integral n, Fractional a, Enum a) => n -> Window a -> Table a Source #
Generate an n element table from a (0,1) normalised window function.
Math
Window functions
rectangular :: Window a Source #
Unit (id
) window, also known as a Dirichlet window.
triangular :: Fractional a => Window a Source #
Triangular window, ie. Bartlett window with zero end-points.
Tables
gaussian_table :: (Integral n, Floating b, Enum b) => n -> b -> [b] Source #
import Sound.SC3.Plot plotTable [gaussian_table 1024 0.25,gaussian_table 1024 0.5]
hamming_table :: Int -> [Double] Source #
plotTable [hann_table 128,hamming_table 128]
hann_table :: Int -> [Double] Source #
window_table
. hann
.
plotTable [hann_table 128]
sine_table :: (Integral n, Floating b, Enum b) => n -> [b] Source #
window_table
. sine
.
plotTable [sine_table 128]
triangular_table :: (Integral n, Fractional b, Enum b) => n -> [b] Source #
plotTable [triangular_table (2^9)]