IIr filter layout to formula problems

I am trying to create the formula for this layout but I have the feeling that I made a mistake.

The formula that I have at the moment is:

Can someone tell me if this is correct?

• There are several formula where you linked to. This site can use MathJax if that helps. Why don't you embed your formula directly. Anyhoo this looks like a standard 2nd order IIR diagram - what part are you having problems with? – Andy aka Apr 14 '14 at 17:46
• Hi, I think you have accepted an answer that is wrong. Your formula, although a little unusual in the way it expressed negative powers of Z is correct. – Andy aka Apr 16 '14 at 18:27

Retrace every branch from output to input and sum them up together to get the transfer function of the filter.Let the signal s[n] be input signal into the buffer $b_0$ (ie the signal just after the first summer)

$$y[n] = b_0s[n] + b_1s[n-1] + b_2s[n-2]$$ $$s[n] = x[n] + a_1s[n-1] + a_2s[n-2]$$

Then take the Z-transform of both sides of both equations.

From the first equation: $$Y(z) = b_0S(z) + b_1z^{-1}S(z) + b_2z^{-2}S(z)$$ $$\frac{Y(z)}{S(z)} = b_0 + b_1z^{-1} + b_2z^{-2}$$

Then for the second equation:

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

$$\frac{S(z)}{X(z)} = \frac{1}{1 - a_1z^{-1} - a_2z^{-2}}$$

meaning to get the final equation we just multiply the two

$$\frac{Y(z)}{X(z)} = \frac{b_0 + b_1z^{-1} + b_2z^{-2}}{1 - a_1z^{-1} - a_2z^{-2}}$$

• This answer is wrong IMHO. There is no iterative process in this formula at all. – Andy aka Apr 16 '14 at 18:25
• Had misread diagram, error fixed – KillaKem Apr 16 '14 at 19:28
• So, apart from NOW confirming that the op's answer is correct, you're basically saying the same as me but feeding the derivation on a plate to the OP. Sometimes a little bit of subtlety helps the OP a lot more. Having said that, I'm not particularly noted for my subtlety so I'll leave it. – Andy aka Apr 16 '14 at 20:26

I won't tell you if it's correct but I'll show you what it should be: -

Don't forget the minus signs on the "a" coefficients. It was taken from here.

There is the form that uses $Z^{-1}$ - it would make the first formula in the picture this: -

$y[n] = \omega[n]\cdot(b_0 + b_1Z^{-1} + b_2Z^{-2})$ and from inspection you should recognize the $\omega[n]$ is the output from the summer to the left. Hope this helps.