MATLAB Answers

difference between convolution code and 'conv' function

hi guys, can anyone tell me what is the different between using convolution code and the 'conv' function to find out system response of convolution computation in signal processing?

  0 Comments

Sign in to comment.

1 Answer

Answer by John D'Errico
on 16 Sep 2019 at 8:10
 Accepted Answer

No difference at all, IF you are asking about the difference between a hand written code to do a numerical convolution computation. The two would be the same.
Caveat 1: That is true, except for floating point issues, since we do not know the exact sequence of floating point operations that will be performed. This ensures that as long as floating point numbers are involved, there will probably be errors in the least significant bits if the results. If the arguments are all sufficiently small integers to avoid a FLINT overflow, then the result will always be exact.
Caveat 2: If you are asking about the difference between conv and an analytical convolution of two functions, then of course a numerical computation will only be an approximation to an analytical result! As the number of points in the numerical convolution increases in the limit towards infinity, so that both arguments asymptotically approach the symbolic functions they are sampled from, then the differences between the numerical convolution and the analytical result it approximates will decrease towards zero.