DSPRelated.com
Forums

custom IIR filter

Started by svolpe February 6, 2009
I'm designing a custom IIR filter that has a specific transfer function
(not standard chev or any other filter).  I have it modeled in scilab and
have a linear system which I can plot.  

Were I'm lost is how to take the linear system (16th order system) and
break it down into 4 bi-quad sections.  My first thoughts were I would just
pump it through the pfss (partial fraction decomposition) function.  pfss
did decomposed my linear system into multiple systems however not all were
second order decompositions: one looked like this:
    - 0.0137799 - 0.0106260s
    --------------------------
    0.6863495 + 1.4513196s + s^2     

some of the other decompositions were even higher orders, one going as
high as s^11 in the denominator and s^10 in the numerator.

My conclusion is that pfss() was not the right way to do it so I guess my
real question is: given a linear system how do you decompose it into 2nd
order linear systems that can then be used in bi-quads for an IIR filter
design.

Regards,
Shane
                                 



On 6 Feb, 17:01, "svolpe" <shanevo...@gmail.com> wrote:

> given a linear system how do you decompose it into 2nd > order linear systems that can then be used in bi-quads for an IIR filter > design.
Assuming the coefficients in your filter are real-valued: 1) Compute the roots for the denominator 2) Group the roots into complex conjugate pairs 3) Compute the real-valued 2nd order polynomial from the pair 4) Repeat for the numerator 5) Group pairs of 2nd order numerators and denominators into SOSs. Rune

svolpe wrote:

> I'm designing a custom IIR filter that has a specific transfer function > (not standard chev or any other filter). I have it modeled in scilab and > have a linear system which I can plot. > > Were I'm lost is how to take the linear system (16th order system) and > break it down into 4 bi-quad sections. My first thoughts were I would just > pump it through the pfss (partial fraction decomposition) function. pfss > did decomposed my linear system into multiple systems however not all were > second order decompositions: one looked like this: > - 0.0137799 - 0.0106260s > -------------------------- > 0.6863495 + 1.4513196s + s^2 > > some of the other decompositions were even higher orders, one going as > high as s^11 in the denominator and s^10 in the numerator. > > My conclusion is that pfss() was not the right way to do it so I guess my > real question is: given a linear system how do you decompose it into 2nd > order linear systems that can then be used in bi-quads for an IIR filter > design.
There are three different problems here: 1. Solve polynomials for poles and zeroes in S domain. 2. Map poles and zeroes into Z domain in the way so the response will be preserved. 3. Assign poles and zeroes to the biquad sections in the optimal way. What is your question? Vladimir Vassilevsky DSP and Mixed Signal Design Consultant http://www.abvolt.com
"svolpe" <shanevolpe@gmail.com> writes:

> I'm designing a custom IIR filter that has a specific transfer function > (not standard chev or any other filter). I have it modeled in scilab and > have a linear system which I can plot. > > Were I'm lost is how to take the linear system (16th order system) and > break it down into 4 bi-quad sections.
OK, wait. Usually the "order" of a system containing poles is the order of the denominator polynomial of the transfer function (or sometimes it's called the "system function"). And a bi-quad has a second-order denominator. So you should require 8 bi-quads, not 4.
> My first thoughts were I would just > pump it through the pfss (partial fraction decomposition) function. pfss > did decomposed my linear system into multiple systems however not all were > second order decompositions: one looked like this: > - 0.0137799 - 0.0106260s > -------------------------- > 0.6863495 + 1.4513196s + s^2
What's wrong with that? That's a second-order system.
> some of the other decompositions were even higher orders, one going as > high as s^11 in the denominator and s^10 in the numerator.
Well, I can't find the pfss() function on the Matlab web site. In the past, I have simply used tf2sos().
> My conclusion is that pfss() was not the right way to do it so I guess my > real question is: given a linear system how do you decompose it into 2nd > order linear systems that can then be used in bi-quads for an IIR filter > design.
Use tf2sos(). -- % Randy Yates % "Maybe one day I'll feel her cold embrace, %% Fuquay-Varina, NC % and kiss her interface, %%% 919-577-9882 % til then, I'll leave her alone." %%%% <yates@ieee.org> % 'Yours Truly, 2095', *Time*, ELO http://www.digitalsignallabs.com
Randy Yates <yates@ieee.org> writes:

> "svolpe" <shanevolpe@gmail.com> writes: > >> I have it modeled in scilab >
[...]
> Well, I can't find the pfss() function on the Matlab web site. In the > past, I have simply used tf2sos().
Doh! Scilab != Matlab. Sorry! But you could try it out in GNU Octave, which is a FOSS application that has about 90 percent of Matlab's command-line functionality. -- % Randy Yates % "My Shangri-la has gone away, fading like %% Fuquay-Varina, NC % the Beatles on 'Hey Jude'" %%% 919-577-9882 % %%%% <yates@ieee.org> % 'Shangri-La', *A New World Record*, ELO http://www.digitalsignallabs.com