To implement 3 point moving average filter using convolution in matlab on wav file i used following code but the code is working but there is problem in convolution .here is the m file

3 次查看(过去 30 天)
problem in convolution plot help please

采纳的回答

Walter Roberson
Walter Roberson 2015-7-25
You never apply the filter or the convolution to the sound array. You read in the sound array and you play the sound, but you never filter it.
You convolve [1 2 3] with the kernel 1/3*[1 1 1], and you use stem() to plot the result against [1 2 3], but that has nothing to do with the sound.
You filter [1 2 3] with 1/3*[1 1 1] but you never use the result.
You fft([1 2 3]) and you stem() the values [1 2 3] at the positions returned as fft() values. I would have expected you would stem using [1 2 3] as the positions (first argument) and the fft() as the values (second argument), but that is not what you did.
Please note that the result of fft() is usually complex. For plotting you should be considering plotting real() or imag() or abs() of the fft()

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Audio Processing Algorithm Design 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by