I have a question about the zeroes in a simple second order FIR filter. I'll list out the major beat points of calculating where the zeroes are before asking the question (I'm following "Designing Audio Effect Plug-Ins in C++", section 5.17).

Starting with a simple second order FIR filter difference function:


We can z transform it to:

$Y(z) = X(z)(a_0+a_1z^{-1}+a_2z^{-2})$

Which gives us the transfer function:

$H(z) = a_0+a_1z^{-1}+a_2z^{-2}$

We can factor out $a_0$ to make it a gain parameter, and replace $a_1$ with $\alpha_1$, and $a_2$ with $\alpha_2$, where $\alpha_1 = \frac{a_1}{a_0}$ and $\alpha_2 = \frac{a_2}{a_0}$:

$H(z) = a_0(1+\alpha_1z^{-1}+\alpha_2z^{-2})$

To find the zeros, we can ignore $a_0$ and just look at the part inside the parentheses.


We know that the zeroes need to be complex conjugates, so can change it to this:


where $Z_1=Re^{j\theta}$ and $Z_2=Re^{-j\theta}$

Using Euler's equation, we can expand and do algebra to get this:


Comparing that to the earlier equation:


We can see that this equation has a zero where:



The other zero has the same radius $R$, but has a negative theta ($-\theta$).

Ok so my question is this. Using values $a_0=1$, $a_1=-1.27$, $a_2=0.81$, we get $R=0.9$ and $\theta=\frac{\pi}{4}$.

That seems to be correct and works well, but let's say that $a_1=-3.6$. We get the same radius $R$, but to calculate $\theta$ we have:


... which is not a valid thing. cosine never has a value of 2, so acos(2.0) is not defined.

Where did i go wrong or how is this situation handled?


The reason for this is that the maths centres on a false assumption:

We know that the zeroes need to be complex conjugates

Do the zeros need to be complex conjugates? Can they not be 2 real zeros?

I sympathise here because I also read this book and the maths portion ended up utterly confusing me because of very odd methods.

A more general method would be at this point:


Rearrange thus:


Here on the top we have a quadratic equation, which you can use any quadratic solver for.

For your first case, I arrive at 0.635 $\pm$ 0.637i, which is a pair of complex numbers denoting the conjugate zeros - correct.

For your second, I arrive at two real zeros, one at 3.36 and one at 0.24 - so it is most definitely able to be computed!

And finally, you will have noted the $z^{2}$ term lying on the bottom, which indicates that there is a square pole at 0+0i. If these zeros were poles then there would similarly be a square zero at 0+0i.

All of these results can be verified with the zplane function in MATLAB.

It took me some time with this book and checking results with the zplane function in matlab to realise that his methods of working really don't work on a general basis, and frankly overcomplicate things. It has however been awhile since I've looked at it so maybe I similarly misinterpreted his maths

  • $\begingroup$ Thank you so much! I'm going to give this a go, and when it checks out experimentally, i will accept this answer. $\endgroup$ – Alan Wolfe Jan 5 '20 at 2:02
  • $\begingroup$ Someone else told me that there is a complex domain inverse cosine, which may be what the author intended. I'm not sure though, and the quadratic equation is way more friendly and familiar. Thanks! $\endgroup$ – Alan Wolfe Jan 5 '20 at 4:10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.