Monday, July 20, 2009

Coefficients of recursive (IIR) digital filters

From the above discussion, we can see that a recursive filter is basically like a non-recursive filter, with the addition of extra terms involving previous outputs (yn-1, yn-2 etc.).

A first-order recursive filter can be written in the general form

yn = (a0xn + a1xn-1 - b1yn-1) / b0

Note the minus sign in front of the "recursive" term b1yn-1, and the factor (1/b0) applied to all the coefficients. The reason for expressing the filter in this way is that it allows us to rewrite the expression in the following symmetrical form:

b0yn + b1yn-1 = a0xn + a1xn-1

In the case of a second-order filter, the general form is

yn = (a0xn + a1xn-1 + a2xn-2 - b1yn-1 - b2yn-2) / b0

An alternative "symmetrical" form of this expression is

b0yn + b1yn-1 + b2yn-2 = a0xn + a1xn-1 + a2xn-2

Note the convention that the coefficients of the inputs (the x's) are denoted by a's, while the coefficients of the outputs (the y's) are denoted by b's.

No comments:

Post a Comment