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
조회 수: 1 (최근 30일)
이전 댓글 표시
problem in convolution plot help please
댓글 수: 0
채택된 답변
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
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Audio I/O and Waveform Generation에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!