Remove unwanted narrowband interference

3 ビュー (過去 30 日間)
clement Ang
clement Ang 2019 年 10 月 17 日
回答済み: Kaashyap Pappu 2019 年 10 月 22 日
I have this corrupted audio with the sound of a human lung, and would need to remove its interference.
I have attempted both high pass filter and passband filter, would appreciate if someone can help take a look at my code, and see where I should edit to get a clearer sound.
Corrupted Audio:
https://drive.google.com/file/d/15xrvx8pynmhCd86MY-1Zfc7EmDMv-MwP/view?usp=sharing
My current code:
[y,fs]=audioread('lungaudio.wav'); %y=samples, fs = sampling frequency
Ts=1/fs; %Sampling period
nfft=length(y);
nfft2=2^nextpow2(nfft);
ff=fft(y,nfft2);
fff=ff(1:nfft2/2);
plot(abs(fff));
xfft=fs*(0:nfft2/2-1)/nfft2;
plot(xfft,abs(fff));
xlabel('Frequency/Hz');
ylabel('Normalized Amplitude');
title('Frequency Domain Signal');
fc=550;
[b,a]=butter(6,fc/(fs/2), 'high'); %lowpass filter to only get 60hz
y_filtered=filter(b,a,y);
plot(y_filtered)
% sound(y_filtered,fs);
Graph Obtained:
  1 件のコメント
Daniel M
Daniel M 2019 年 10 月 17 日
I think you mean to use 'low' in your call to butter.
See this recent question also regarding audio of a lung (perhaps a classmate?)

サインインしてコメントする。

回答 (1 件)

Kaashyap Pappu
Kaashyap Pappu 2019 年 10 月 22 日
Increasing the order of the Butterworth filter could help improve the response. Alternatively, the buttord function can be used to get the optimal order and cutoff frequency values to give to the “butter” function.
Hope this helps!

カテゴリ

Help Center および File ExchangeDigital Filter Design についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by