Design a nonrecursive filter that responds strongly to W = p/2
Start with an ideal lowpass filter with unity passband gain in the range -p/8 < W < p/8
|
Since the input is LTI (linear time invariant), the impulse response can be written as such:
|
I will only keep terms corresponding to -15 <= n <= 15 for this impulse response creating a desired impulse response with a window M = 15.
This desired hd[n] impulse response looks as such:
|
Using a Hamming window to improve the filter response with equation w[n] = 0.54 + 0.46 * cos(np/M) where M=15
This gives the actual impulse response ha[n] = hd[n] * w[n]
Here is a graph of ha[n]:
|
The next two steps will be combined. In order to achieve a bandpass filter with its peak response at p/2, ha[n] is multiplied by cos(np/2)
The result is then shifted forward to begin at n = 0
Here is a graph of that result:
|
To implement the filter, the convolution of ha[n] and the input x[n] is taken
The graph of y[n] = ha[n]·x[n] is shown below for the input selected above:
As you can see, the response of the filter to x[n] is greatest when W = p/2
|