MATLAB: FIR bandpass filter by using frequency sampling method.

filter fir

I have to design FIR bandpass filter by using frequency sampling method. In function fir2, the inputs are desired frequency and magnitude point. However, I was given sampling frequency at 1000 Hz and Pass-band 100 Hz to 200 Hz, filter order = 30. How can I find desired frequency and magnitude point from information given.
I tried to use filterDesign app, but there is sampling frequency method.
Thanks

Best Answer

The Nyquist frequency is one-half your sampling frequency, or 500 Hz. You have to normalise your passband frequencies by dividing them by the Nyquist frequency.
Your normalised passband frequencies are then 100/500 and 200/500. The documentation for fir2 has all the other information you need.