These are two Matlab functions for computing convolutions using the FFT. They
replicate the syntax of Matlab's conv
function, particularly the
shape={full,valid,same}
argument. There is a
MathWorks blog post
discussing the tradeoffs and explaining why Matlab's conv
doesn't use FFTs.
See the function help strings for details.
You can use the included script test_correctness.m
to be sure fftconv
is
computing the right thing.
If you get the timeit
function from Matlab Central
you can run test_timing.m
to produce plots like this one: