# Infinite impulse response

(Redirected from IIR filter)

Infinite impulse response (IIR) is a property applying to many linear time-invariant systems. Common examples of linear time-invariant systems are most electronic and digital filters. Systems with this property are known as IIR systems or IIR filters, and are distinguished by having an impulse response which does not become exactly zero past a certain point, but continues indefinitely. This is in contrast to a finite impulse response (FIR) in which the impulse response h(t) does become exactly zero at times t > T for some finite T, thus being of finite duration.

In practice, the impulse response, even of IIR systems, usually approaches zero and can be neglected past a certain point. However the physical systems which give rise to IIR or FIR responses are dissimilar, and therein lies the importance of the distinction. For instance, analog electronic filters composed of resistors, capacitors, and/or inductors (and perhaps linear amplifiers) are generally IIR filters. On the other hand, discrete-time filters (usually digital filters) based on a tapped delay line employing no feedback are necessarily FIR filters. The capacitors (or inductors) in the analog filter have a "memory" and their internal state never completely relaxes following an impulse (assuming the classical model of capacitors and inductors where quantum effects are ignored). But in the latter case, after an impulse has reached the end of the tapped delay line, the system has no further memory of that impulse and has returned to its initial state; its impulse response beyond that point is exactly zero.

## Implementation and design

Although almost all analog electronic filters are IIR, digital filters may be either IIR or FIR. The presence of feedback in the topology of a discrete-time filter (such as the block diagram shown below) generally creates an IIR response. The z domain transfer function of an IIR filter contains a non-trivial denominator, describing those feedback terms. The transfer function of an FIR filter, on the other hand, has only a numerator as expressed in the general form derived below. All of the ${\displaystyle a_{i}}$ coefficients with ${\displaystyle i>0}$ (feedback terms) are zero and the filter has no finite poles.

The transfer functions pertaining to IIR analog electronic filters have been extensively studied and optimized for their amplitude and phase characteristics. These continuous-time filter functions are described in the Laplace domain. Desired solutions can be transferred to the case of discrete-time filters whose transfer functions are expressed in the z domain, through the use of certain mathematical techniques such as the bilinear transform, impulse invariance, or pole–zero matching method. Thus digital IIR filters can be based on well-known solutions for analog filters such as the Chebyshev filter, Butterworth filter, and elliptic filter, inheriting the characteristics of those solutions.

## Transfer function derivation

Digital filters are often described and implemented in terms of the difference equation that defines how the output signal is related to the input signal:

{\displaystyle {\begin{aligned}y\left[n\right]&={\frac {1}{a_{0}}}(b_{0}x[n]+b_{1}x[n-1]+\cdots +b_{P}x[n-P]\\&-a_{1}y[n-1]-a_{2}y[n-2]-\cdots -a_{Q}y[n-Q])\end{aligned}}}

where:

• ${\displaystyle \ P}$ is the feedforward filter order
• ${\displaystyle \ b_{i}}$ are the feedforward filter coefficients
• ${\displaystyle \ Q}$ is the feedback filter order
• ${\displaystyle \ a_{i}}$ are the feedback filter coefficients
• ${\displaystyle \ x[n]}$ is the input signal
• ${\displaystyle \ y[n]}$ is the output signal.

A more condensed form of the difference equation is:

${\displaystyle \ y[n]={\frac {1}{a_{0}}}\left(\sum _{i=0}^{P}b_{i}x[n-i]-\sum _{j=1}^{Q}a_{j}y[n-j]\right)}$

which, when rearranged, becomes:

${\displaystyle \ \sum _{j=0}^{Q}a_{j}y[n-j]=\sum _{i=0}^{P}b_{i}x[n-i]}$

To find the transfer function of the filter, we first take the Z-transform of each side of the above equation, where we use the time-shift property to obtain:

${\displaystyle \ \sum _{j=0}^{Q}a_{j}z^{-j}Y(z)=\sum _{i=0}^{P}b_{i}z^{-i}X(z)}$

We define the transfer function to be:

{\displaystyle {\begin{aligned}H(z)&={\frac {Y(z)}{X(z)}}\\&={\frac {\sum _{i=0}^{P}b_{i}z^{-i}}{\sum _{j=0}^{Q}a_{j}z^{-j}}}\end{aligned}}}

Considering that in most IIR filter designs coefficient ${\displaystyle \ a_{0}}$ is 1, the IIR filter transfer function takes the more traditional form:

{\displaystyle {\begin{aligned}H(z)&={\frac {\sum _{i=0}^{P}b_{i}z^{-i}}{1+\sum _{j=1}^{Q}a_{j}z^{-j}}}\end{aligned}}}
An example of a block diagram of an IIR filter. The ${\displaystyle z^{-1}}$ block is a unit delay.

## Stability

The transfer function allows one to judge whether or not a system is bounded-input, bounded-output (BIBO) stable. To be specific, the BIBO stability criterion requires that the ROC of the system includes the unit circle. For example, for a causal system, all poles of the transfer function have to have an absolute value smaller than one. In other words, all poles must be located within a unit circle in the ${\displaystyle z}$-plane.

The poles are defined as the values of ${\displaystyle z}$ which make the denominator of ${\displaystyle H(z)}$ equal to 0:

${\displaystyle \ 0=\sum _{j=0}^{Q}a_{j}z^{-j}}$

Clearly, if ${\displaystyle a_{j}\neq 0}$ then the poles are not located at the origin of the ${\displaystyle z}$-plane. This is in contrast to the FIR filter where all poles are located at the origin, and is therefore always stable.

IIR filters are sometimes preferred over FIR filters because an IIR filter can achieve a much sharper transition region roll-off than an FIR filter of the same order.

## Example

Let the transfer function ${\displaystyle H(z)}$ of a discrete-time filter be given by:

${\displaystyle H(z)={\frac {B(z)}{A(z)}}={\frac {1}{1-az^{-1}}}}$

governed by the parameter ${\displaystyle a}$, a real number with ${\displaystyle 0<|a|<1}$. ${\displaystyle H(z)}$ is stable and causal with a pole at ${\displaystyle a}$. The time-domain impulse response can be shown to be given by:

${\displaystyle h(n)=a^{n}u(n)}$

where ${\displaystyle u(n)}$ is the unit step function. It can be seen that ${\displaystyle h(n)}$ is non-zero for all ${\displaystyle n\geq 0}$, thus an impulse response which continues infinitely.

IIR filter example