annotate arrows/dsp/aspecsyn.m @ 6:0ce3c2070089

Removed duplicate code and fixed doc in timed_action.
author samer
date Mon, 14 Jan 2013 14:33:37 +0000
parents 672052bd81f8
children
rev   line source
samer@0 1 % aspecsyn - Spectral synthesis arrow
samer@0 2 %
samer@0 3 % aspecsyn ::
samer@0 4 % N:natural,
samer@0 5 % M:natural,
samer@0 6 % (N:natural-> [[N]]) ~'window function'
samer@0 7 % -> arrow( {[[N]]}, {[[M]]}, _).
samer@0 8 function o=aspecsyn(N,M,windowfn)
samer@0 9 o = (arr(@spec2fir) + asampler(@randn,[N,1])) ... % FIR filter coefficients and white noise
samer@0 10 * adynfir(N,N) * amult(spdiag(windowfn(N))) ... % windowed sample buffers
samer@0 11 * aolapadd(N,M);
samer@0 12 end