To create a lattice filter in MATLAB, you can use the lattice function. Here's an example to create a 5th-order filter with a cutoff frequency of 0.4 radians:
main.m386 chars12 lines
The lattice function takes the filter coefficients in b and a as input and returns the lattice scaling coefficients (G) and reflection coefficients (L). These coefficients are used to implement the filter in a lattice structure. To filter a signal x, you can pass the scaling and reflection coefficients along with the input signal to the filter function.
gistlibby LogSnag