Infinite Impulse Response (IIR) Filter

Consider an IIR filter such that:

$\displaystyle \sum_{k=0}^{N-1}{a_k y_{n-k}} = \sum_{k=0}^{M-1}{b_k x_{n-k}},$ (4.1)

or equivalently,

$\displaystyle H(z) = \frac{Y(z)}{X(z)} = \frac{\sum_{k=0}^{M-1}{b_k z^{-k}}}{\sum_{k=0}^{N-1}{a_k z^{-k}}}.$ (4.2)

So the output can be written as:

$\displaystyle y_n = \sum_{k=0}^{M-1}{c_k x_{n-k}} - \sum_{k=1}^{N-1}{d_k y_{n-k}},$ (4.3)

where $ c_k = b_k/a_0$ , $ d_k = a_k/a_0$ , and $ n=0,1,\ldots,L-1$ , $ L=length(x)$ .

In ComLinC, the IIR filter is implemented according to eq. 4.3.

To use the IIR filter, call the function cl_filter_iir(). The function prototype looks like the following:

 gsl_vector* cl_filter_iir( gsl_vector*	b,
			   gsl_vector*	a,
			   gsl_vector*	x );
b,a are the filter coefficients defined in eq. 4.2. x is the input to the filter. The output of cl_filter_iir is a double vector of the same length as the input vector.

Kefei Lu 2007-12-03