Luftzig/elm-signal-processing/1.0.0

NOTE: the latest version is 1.1.0

Convolution

Functions for convolution See: https://en.wikipedia.org/wiki/Convolution

Functions:

convolve : List Float -> List Float -> List Float

Convolve two real number lists, using FFT for lists longer than 128 elements or direct convolution otherwise. Threshold was determined by benchmarks.

convolve [ 1, 0, 0, 0 ] [ 0, 0, 1, 1 ] --> [0, 0, 1, 1]
convolveDirectly : List Float -> List Float -> List Float

Convolve two lists of numbers directly by $$ zs_j = \sum_i^n {xs_i * ys_{j - i}} $$