Filters: Recalling the basics
The following points on filters can only help to recall some of the basics and might provide the direction for further study. This is not a coherently written article but only a brief collection of interesting points that would explain filters in general.
To start with...
Analogue filters provide the required filtering using op-amps, capacitors etc and Digital filters uses a digital processors chip (like DSP)
In digital filters, an analog input is ADCed (sampled and quantized/digitized), then this is input to a processor, which perform some calculation on this input like xn+xn-1 or xn + yn-1, where x is input & y is output. The (filtered) result is then fed to DACs which convert them back to analog form.
Calculation inside a processor define a filter
If output is directly dependent on present and/or previous inputs, then this is called non-recursive filter or FIR
If output is dependent not only input values but also on previous outputs, then this is called recursive filter or IIR.
IIR - theoretically produces an infinite response to an impulse input (value 1 at time 0.) Practically, the output fades to 0 after a finite period!
FIR - Produces a response for finite period for the same impulse input
From the definitions it appears that IIR (recursive) filters require more calculation than IIR? No, actually FIR requires more calculation (less order filters) than IIR fitlers to achieve the same freq response characteristics Eg of recursive filter: y0 = x0 + y-1 y1 = x1 + y0 y2 = x2 + y1 and so on.
So, y9 = x9 + y8 for IIR calculation but for non-recursive, y9= x0+x1+x2+x3+x4+x5+x6+x7+x8+x9 (all prev inputs should be saved in memory.) Thus FIR requires more calc than IIR.
For IIR, order is the number of largest previous input or previous output. yn = xn + yn-1 is first order eg. yn = xn-1 + xn-2 +yn-1 +yn-2 is second order eg Ex of zero order IIR filter?? Impossible becoz yn = xn (is not FIR) and yn = yn is linear device and not a kind of filter by any definition.
Transfer function: Puts the filter expression in compact convenient form (op/ip) From this we can derive many characteristics of a filter like freq response. so yn = xn + yn-1 can be represented as
yn = xn + z^-1yn (1-z^-1)yn = xn TF = yn/xn = 1/(1-z^-1) of IIR filter
For FIR, TF doesn't contain any denominator. eg. yn = a0 + a1z^-1+ a2z^-2