DSP Blockset    

Lowpass and Highpass Discrete-Time FIR Filters.   The magnitude response illustrated below shows a lowpass order-41 FIR filter with normalized cutoff frequency fn0 = 0.5. The right plot shows a zoomed view of the transition region. For an input signal sampled at 1 kHz, this filter would provide a cutoff frequency of 250 Hz.

The equivalent MATLAB code for this filter design is

and the filter can be designed in the Digital FIR Filter Design block by making the following selections in the dialog box:

The cutoff frequency for a highpass filter (Highpass selected from the Filter type menu) is defined in the same way: -6 dB down from the passband level. The equivalent MATLAB code for the highpass filter design is

For highpass designs, the filter order must be even (so that the filter is Type I). MATLAB therefore automatically increases the filter order to 42 for this example.


 Specifying Classical Discrete-Time Filter Parameters Bandpass and Bandstop Discrete-Time FIR Filters