# How to classify filters?

In class, we have defined four types of filters: low-pass, high-pass, band-pass and band-stop. I have understood that in order to classify a filter into one of the fourth, one can use the signals:

1. DC: $1,1,1,\ldots$
2. Nyquist: $-1,1,-1,1,\ldots$
3. half-Nyquist: $1, 0, -1, 0, 1,\ldots$

Can you help me understand how to classify $y_n = x_n + x_{n-2}$ as a band stop filter?

• run your DC and Nyquist signals through your difference equation and see how big the result is. then run your half-Nyquist signal though the same difference equation and see how zero the result is. Mar 16 '18 at 22:58

You have all the necessary ingredients. Signals 1 and 2 are low- and high-pass. Signal 3 dwells in between.

Check what happens when filtering either signal 1 or 2 with taps $[1\,,0\,,1]$. Nnormally, you should find similar patterns: almost the same behavior, up to a factor. You will thus get an amplification factor, related to $|H(f)|$. This will give you two points for the amplitude spectrum at $f=0$ and $f=1$ (assuming this reference for Nyquist). Then a third mid-point will be given by the output for Signal 3.

Then, since the filter is FIR, its amplitude spectrum will be continuous, hence you can draw some interpolation between the 3 points.

Note that this a simple guess for a potential behavior of the filter. Summing the filter coefficients, and the coefficients with alternated signs, give you an idea of the behavior at DC et Nyquist. The third signal lies in the middle. Drawing spectra precisely as suggested by @ MarcusMüller would be more precise

Can you help me understand how to classify

Yes!

Just draw the (discrete) spectra of your three test signals; then multiply them piece-wise with the frequency response of your candidates, and compare with the response of your filter.

• I love assertive formulations :) Mar 16 '18 at 22:07