- Filter coefficients in Matlab are specified in terms of the following general filter difference equation:
- In this way, a filter with difference equation
*y*[*n*] =*x*[*n*] +*x*[*n*-1] would be specified with feedforward coefficients*b*= [1 1] and a feedback coefficient*a*= 1. - Likewise, a filter with difference equation
*y*[*n*] =*x*[*n*] + 0.9*y*[*n*-1] would be specified with a feedforward coefficient*b*= 1 and feedback coefficients*a*= [1 -0.9]. - In Matlab, we can filter an input signal
*x*with a filter specified by coefficients*b*and*a*as y = filter(b, a, x). - In Matlab, we can plot a filter's frequency response using the freqz function: freqz(b, a).

©2004-2020 McGill University. All Rights Reserved. Maintained by Gary P. Scavone. |