Sign in

username or email:

password:



Not a member?
Forgot your password?

Search compdsp



Search tips

Ads

Discussion Groups

Free Online Books

See Also

Embedded SystemsFPGA

Discussion Groups | Comp.DSP | IIR optimization algorithms?

There are 4 messages in this thread.

You are currently looking at messages 1 to .


Is this discussion worth a thumbs up?

0

IIR optimization algorithms? - westocl - 2012-07-13 11:58:00


Any you guys know of any IIR optimization algorithms out there or any
suggestions on how to go about designing this filter.

Its a highpass, close to half band and the group delay in the pass band
needs to be about 3 samples with as much rejection in the lower half as
possible ... lets say better than 40;


As soon as I saw the low group delay i immediatly thought it had to be
IIR.

I would love to use some preexisting filter optimization algorithm, but
most of the things i see out there is for FIR.
(I have an exact group delay i would like,same for magnitude)


Any suggestions?

Thanks in advance
______________________________
New DSP Code Snippets Section now Live.   Learn more about the reward program for contributors here.

Re: IIR optimization algorithms? - mnentwig - 2012-07-13 14:44:00



Hello,

you could use an FIR filter if you simply design for linear phase, 3
samples group delay. It will need more taps than the symmetrical variant,
and won't be exactly linear-phase due to the impulse response asymmetry,
just like an IIR filter.

Design example (tried with Octave, should work in Matlab too)
http://www.dsprelated.com/blogimages/MarkusNentwig/bl_lsfir/leastSquaresFIR.m
Modify the frequencies and ripple requirement as you need, and balance with
the number of taps.

Frequency response
http://www.dsprelated.com/blogimages/MarkusNentwig/comp.dsp/highpassExample_120713/IIR_freqresp.
EMF
never mind the red crosses, they are the weighting factors that bend a
least-squares design into shape to meet the requirements.


Impulse response
http://www.dsprelated.com/blogimages/MarkusNentwig/comp.dsp/highpassExample_120713/IIR_impResp.E
MF

Details on the algorithm (iterative reweighted least-squares, IRLS):
http://www.dsprelated.com/showarticle/165.php

I'll check, whether my IRLS *IIR* script is any good for the problem.
______________________________
New DSP Code Snippets Section now Live.   Learn more about the reward program for contributors here.

Re: IIR optimization algorithms? - westocl - 2012-07-13 15:08:00

>Hello,
>
>you could use an FIR filter if you simply design for linear phase, 3
>samples group delay. It will need more taps than the symmetrical variant,
>and won't be exactly linear-phase due to the impulse response asymmetry,
>just like an IIR filter.
>
>Design example (tried with Octave, should work in Matlab too)
>http://www.dsprelated.com/blogimages/MarkusNentwig/bl_lsfir/leastSquaresFIR.m
>Modify the frequencies and ripple requirement as you need, and balance
with
>the number of taps.
>
>Frequency response
>http://www.dsprelated.com/blogimages/MarkusNentwig/comp.dsp/highpassExample_120713/IIR_freqr
esp.EMF
>never mind the red crosses, they are the weighting factors that bend a
>least-squares design into shape to meet the requirements.
>
>
>Impulse response
>http://www.dsprelated.com/blogimages/MarkusNentwig/comp.dsp/highpassExample_120713/IIR_impRe
sp.EMF
>
>Details on the algorithm (iterative reweighted least-squares, IRLS):
>http://www.dsprelated.com/showarticle/165.php
>
>I'll check, whether my IRLS *IIR* script is any good for the problem.



Thanks alot,

Ill take a real good look at it.  I thought the 3 samles was going to be
too stringent for the FIR option. Ill take a look at the paper. Im not sure
how the weights play into balancing the delay and the rejection at first
glance.
 
______________________________
New DSP Code Snippets Section now Live.   Learn more about the reward program for contributors here.

Re: IIR optimization algorithms? - mnentwig - 2012-07-13 15:44:00

And this would be a shot at an IIR filter:

http://www.dsprelated.com/blogimages/MarkusNentwig/comp.dsp/highpassExample_120713/highpassIIR.m


please check the results carefully.
It's quickly hacked up, but maybe it's useful.
This one needs to be tweaked manually (by changing weights), there is no
reweighting loop implemented.



At least the FIR script doesn't need any understanding of the theory, IMHO.
I'd use it by trial-and-error, change parameters and see what happens.
Keep an eye on the reported error when comparing alternatives.

The weights are interesting insofar as they tell you which frequencies
cause the highest 'cost' with regard to the number of needed taps. 
The difficult areas are usually obvious, but sometimes they'll point out
opportunities to get 20 dB more stopband rejection in some area essentially
for free.
______________________________
New DSP Code Snippets Section now Live.   Learn more about the reward program for contributors here.