필터 지우기
필터 지우기

How to design a Butterworth filter?

조회 수: 2 (최근 30일)
Todd
Todd 2012년 6월 29일
It is going to be a two-pole low-pass Butterworth filters with a nominal cutoff frequency of 15 Hz.
An additional note is "calculated breakpoint frequencies are 18 Hz and 19 Hz for the first and second pole respectively" not sure if this info is necessary

답변 (1개)

Yash
Yash 2012년 6월 30일
편집: Walter Roberson 2012년 7월 1일
i developed this code for my program, it may help you
a=wavread('1.wav');
ah=a.*hann(length(a));
aN=length(ah);
indexa=[0:1:aN-1];
fs=8000;
fa=[0:1:aN-1]*fs/aN;
aff=abs(fft(ah))/aN;
figure % for siren 1
plot (fa,aff);
xlabel(' FFT of Siren 1');
n = 1; % Filter order
lf = .5e3; % low frequency cutoff for bandpass
hf = 1.5e3; % high frequency cutoff for bandpass
[b,a] = butter(n, [lf hf]/(fs/2));
fout = filter(b,a,ah);
% Plot Spectrum figure
spec = fft(fout,nfft);
pfspec = spec(1:fix(nfft/2)); % Extract postive frequencies
plot(pfax/1e3,abs(pfspec))
xlabel('Hz')
ylabel('Magnitude')
title('Filter Signal Spectrum ')

카테고리

Help CenterFile Exchange에서 Digital Filter Analysis에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by