Re: Frequency response of a complex IIR filter ("Richard F. Lyon" )


Subject: Re: Frequency response of a complex IIR filter
From:    "Richard F. Lyon"  <DickLyon@xxxxxxxx>
Date:    Sat, 28 Jan 2012 09:09:59 -0800
List-Archive:<http://lists.mcgill.ca/scripts/wa.exe?LIST=AUDITORY>

<!doctype html public "-//W3C//DTD W3 HTML//EN"> <html><head><style type="text/css"><!-- blockquote, dl, ul, ol, li { padding-top: 0 ; padding-bottom: 0 } --></style><title>Re: Frequency response of a complex IIR filter</title></head><body> <div>Matt, it's good that you answered, since I had somehow missed the query that I should have commented on.</div> <div><br></div> <div>I had pointed Piotr at the idea of using a complex final stage of the N stages of gammatone-family filters, to get a complex output (the real output and approximately its Hilbert transform), so that the phase and amplitude will be pretty well defined at all time instants.&nbsp; I'm not sure it's a great idea, but it's what I suggested for what I thought he wanted.&nbsp; The resulting filter is not exactly OZGF, but it's an OZGF with an imaginary part generated by approximate Hilbert transform.&nbsp; I haven't tried to estimate how good or useful that approximation is, which might be what he's trying to understand by looking at transfer functions.</div> <div><br></div> <div>In answer to Piotr's quesiton, the amplitude and phase transfer function should be computed via the FFT of the complex impulse response (also analtyically from the poles and zeros to make sure it agrees).&nbsp; The difference from the real case is that the result won't be symmetric across zero frequency: it will have a big bandpass response at one sign of frequency, and little or nothing for the other sign.&nbsp; The analytic version computed from poles and zeros will come out the same, recognizing that taking the complex output of the final coupled-form IIR stage leaves it with one complex pole, not a pole pair.</div> <div><br></div> <div>The &quot;coupled-form&quot; IIR two-pole filter is not so widely known or used, but has some advantages.&nbsp; Max Mathews talked me into adopting it for my needs, a few months before he passed away last year.&nbsp; It does have this nice feature that if you take both of its state variables as real and imaginary parts of an output, that it's just a one-pole complex filter.&nbsp; That's a good way to derive it, too. Start with a one-pole complex filter; when you take the real part, you generate another pole, conjugate to the first one; do the math.</div> <div><br></div> <div>Dick</div> <div><br></div> <div><br></div> <div>At 8:51 PM +1100 1/28/12, Matt Flax wrote:</div> <blockquote type="cite" cite>I have code here which you can use :<br> <a href="http://packages.debian.org/squeeze/libgtfb0-dev" >http://packages.debian.org/squeeze/libgtfb0-dev</a><br> <br> however it is in C++ - and it is higher order then what you mention.<br> I am a little confused by what you write below ...<br> Aren't you after a real time domain signal ?<br> <br> The history of the Gammatone goes back to short term integrals of neural spike trains (Joannesma) I am not sure of the significance of the phase - as the Gammatone was a nice mathematical choice (at the time) for fitting data which is both nonlinear and state dependent.<br> <br> The Gammachirp came along afterwards ... was very computationally complex, however attempted to match the experimental data more closely ... it varied filter shape with time ... I seem to remember having the C++ code for that lying around ... if I haven't released it yet!<br> <br> Matt<br> </blockquote> <blockquote type="cite" cite>On 27/01/12 01:02, Piotr Holonowicz wrote:<br> <blockquote type="cite" cite>Hi all!</blockquote> <blockquote type="cite" cite>I am trying to make a digital implementation of the One Zero Gammatone Filterbank (OZGF), however, I need the output to be complex instead of real. I have converted the filter equations by R. Lyon with the partial fraction expansion obtaining two conjugate poles, then treated it with the bilinear transform. The final stage is the coupled form of a complex IIR. In order to check the implementation, I would like to plot the frequency response of a single filter channel (= a cascade of three low-pass biquads + one bandpass biquad). But here is where I got a bit puzzled - for a real domain filter,&nbsp; the way to do it is to plot the magnitude and the phase of the FFT of the impulse response. How to do it however, with a complex output u+jv (&lt;=&gt; r exp (jw0)) ? My intuition says it might be done by computing y= r exp (w0) and then computing abs(fft(y)) and angle(fft(y)). Is this the correct way to do it or shall I treat the real and the imaginary output separately - in that case how to interpret the outcome?<br> I enclose the python prototype code, it requires only the numpy/scipy and the matplotlib(pylab) to run.</blockquote> <blockquote type="cite" cite>I'll be very thankful for help.</blockquote> <blockquote type="cite" cite>Best</blockquote> <blockquote type="cite" cite>Piotr Holonowicz<br> <br> PhD candidate at Music Technology Group<br> Universitat Pompeu Fabra<br> Barcelona,Spain</blockquote> </blockquote> <div><br></div> </body> </html>


This message came from the mail archive
/var/www/postings/2012/
maintained by:
DAn Ellis <dpwe@ee.columbia.edu>
Electrical Engineering Dept., Columbia University