So I have a transfer function $ H(Z) = \frac{Y(z)}{X(z)} = \frac{1 + z^{-1}}{2(1-z^{-1})}$. I need to write the difference equation of this transfer function so I can implement the filter in terms of LSI components. I think this is an IIR filter hence why I am struggling because I usually only deal with FIR filters. I have tried to simplify the filter, and I get:

$H(z) = \frac{z+1}{2(z-1)}$

This gives me the gain (K = 0.5) and the poles as +1, and the zeroes as -1, hence filter is stable.

Can anyone help me? I usually divide through by the denominator, and hence get the difference equation, but I can't in this case. Then it's just a case of looking at the difference equation and implementing the filter with delays, multiples, adders etc.

  • 2
    $\begingroup$ A pole at z=1 results in a non BIBO stable system. $\endgroup$ – Juancho May 28 '18 at 18:32
  • $\begingroup$ @Juancho That's true, cheers for spotting it. $\endgroup$ – Lewis May 28 '18 at 20:45

$$\begin{align*}\dfrac{Y(z)}{X(z)} &= \dfrac{1+z^{-1}}{2(1-z^{-1})}\\ \\ 2(1-z^{-1})Y(z)&=(1+z^{-1})X(z)\\ \\ Y(z) -Y(z)z^{-1}&= \frac{1}{2}X(z) +\frac{1}{2}X(z)z^{-1}\\ \\ y[n]-y[n-1]&=\frac{1}{2}x[n] + \frac{1}{2}x[n-1]\\ \\ y[n]&=y[n-1]+\frac{1}{2}x[n] + \frac{1}{2}x[n-1]\\ \end{align*}$$

You'll need at least one register for the feedback of the output (the y[n-1] term).

You might as well call that register the accumulator, as this is essentially an integrator, integrating up the average of the two most recent input values. Integrators are not stable, so you may want to clip the output at some point instead of letting it roll over.

| improve this answer | |

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.