Reputation: 43
I am new to signal processing with Matlab. I have a signal which contains 10000 points. After doing the FFT I found the frequency point located near by 3 should be removed. I designed a FIR band-stop filter using a Kaiser window. I tried to increase the window length to about 512 or higher, and also increased the order in fir1. However, the normalized stop bands are always near by 0. I think the very large order of FIR will bring some problems. Are there other methods to design a narrow band stop filter and remain phase not changing? Thanks all! My code is shown below:
win=kaiser(513,10);
b=fir1(512,[2.8/1000,3.3/1000],'stop',win);
y=filtfilt(b,1,x); % x is input signal which length is 10000
Upvotes: 1
Views: 2273
Reputation: 281
for Zero-phase digital filtering there is filtfilt in matlab.
some filter have phase changes that are acceptable for different exercises, you can try a iir filter, for example butterworth filter in matlab.
[b,a] = butter(n,Wn,'stop')
Upvotes: 1