Design an IIR Bandpass Chebyshev Type-2 Filter using Scipy – Python
IR stands for Infinite Impulse Response, It is one of the striking features of many linear-time invariant systems that are distinguished by having an impulse response h(t)/h(n) which does not become zero after some point but instead continues infinitely.
What is IIR Chebyshev Filter?
IIR Chebyshev is a filter that is linear-time invariant filter just like the Butterworth however, it has a steeper roll-off compared to the Butterworth Filter. Chebyshev Filter is further classified as Chebyshev Type-I and Chebyshev Type-II according to the parameters such as pass band ripple and stop ripple.
How is Chebyshev Filter different from Butterworth?
Chebyshev Filter has a steeper roll-off compared to the Butterworth Filter.
What is Chebyshev Type-2 Filter?
Chebyshev Type-2 minimizes the absolute difference between the ideal and actual frequency response over the entire stopband by incorporating an equal ripple in the stopband.
The specifications are as follows:
- Pass band frequency: 1400-2100 Hz
- Stop band frequency: 1050-24500 Hz
- Pass band ripple: 0.4dB
- Stop band attenuation: 50 dB
- Sampling frequency: 7 kHz
We will plot the magnitude, phase, impulse, step response of the filter.
Step 1: Importing all the necessary libraries.
Step 2: Defining user-defined functions mfreqz() and impz(). The mfreqz is a function for magnitude and phase plotand the impz is a function for impulse and step response]
Step 3:Define variables with the given specifications of the filter.
Step 4: Compute the cut-off frequency
Step 5: Compute order of the Chebyshev type-2 digital filter.
Step 6: Design digital Chebyshev type-2 bandpass filter.
Step 7: Plot magnitude and phase response.
Step 8: Plot impulse and step response of the filter.
Below is the complete implementation of the above stepwise approach: