On 04/22/2011 11:30 PM, robert bristow-johnson wrote:> On Apr 23, 1:48 am, Tim Wescott<t...@seemywebsite.com> wrote: >> On 04/22/2011 07:24 PM, John wrote: >> >>> From a frequency domain point-of-view I would guess that a filterbank >>> is just a set of equally or un-equally spaced bins in the frequency >>> domain where you apply some processing to the power in each bin (or >>> should I call it band). >> >> Uh, yea. You may wish to place additional constraints, i.e. a graphics >> equalizer is a filter bank who's filter outputs, when summed, generate a >> flat response and that 'behaves nicely' when the gains on the individual >> filters are changed. >> > ... >> >> Google "graphics equalizer", or perhaps "DSP graphics equalizer". I >> don't do much at all with audio DSP, but there are established >> techniques that I have seen talked about here. > > Tim, *I* would be interested in hearing more about the established > techniques. as best as i can tell, it's kinda a bitch to sum up a > bunch of parallel BPFs with resonant frequencies nicely spaced and get > a perfectly flat "wire". i know the old analog graphic EQs *did* sum > up parallel BPFs, but i am suspicious that when all the sliders are > set to 0 dB, they came out to be a wire. maybe they did, but i would > like to see how they were designed. > > i've thunked about this a little (as have some others), and, to me, if > you wanted a graphic EQ that guaranteed flatness when all of the > sliders are set to 0 dB, we can imagine first a *cascade* of these > biquad peak/cut EQ (sometimes called parametric EQ) with fixed center > frequency (log spaced) and fixed bandwidth (in log freq) and > controllable boost/cut gain. each section would be a wire if set to 0 > dB, so the whole thing would be flat if all sliders were set to 0 dB. > > now the overall transfer function for those cascaded biquads (which > are a bunch of 2nd-order biquad transfer functions multiplied) can be > separated into 1st-order partial fractions (with complex coefficients) > and, it had occurred to me, those coefs could be determined (given the > specified slider gains) by a machine using a procedure like the > Heaviside partial fraction expansion method (sometimes called the > "cover-up method"). i had tried to see if i could get to anything > like a closed-form solution, but have not succeeded. (has anyone > tried something like this?) > > anyway, even with no closed-form solution, a deterministic program > could do the Heaviside cover-up method and convert from the cascaded > biquads (each with 5 coefficients that the cookbook gets from > specified resonant freq, bandwidth, and boost/cut gain) to parallel > biquads with 4 real coefficients each (and one big wire with scaler > summing in with the parallel biquads). > > but otherwise, i just don't see how a bunch of parallel BPFs would be > expected to easily add up to a truly flat response. not without some > trick that i'm clueless about. it's not a Linkwitz�Riley thingie, is > it?Huh. Maybe it's done with a cascade. There's a reason I qualified my comments with "I don't do much at all with audio DSP". -- Tim Wescott Wescott Design Services http://www.wescottdesign.com Do you need to implement control loops in software? "Applied Control Theory for Embedded Systems" was written for you. See details at http://www.wescottdesign.com/actfes/actfes.html
Question about filterbanks
Started by ●April 22, 2011
Reply by ●April 23, 20112011-04-23
Reply by ●April 23, 20112011-04-23
> On 23.4.11 9:30 , robert bristow-johnson wrote: > > > > > but otherwise, i just don't see how a bunch of parallel BPFs would be > > expected to easily add up to a truly flat response. �not without some > > trick that i'm clueless about. �it's not a Linkwitz�Riley thingie, is > > it? >On Apr 23, 4:45 pm, Tim Wescott <t...@seemywebsite.com> wrote:> > Huh. Maybe it's done with a cascade. There's a reason I qualified my > comments with "I don't do much at all with audio DSP".well, i'm not convinced that any DSP product that's a 1/3 octave graphic EQ would be doing this in cascade unless they had a very wide word width. after each cascaded section, you would have to cast back to the nominal single precision (however wide that is). There would be 31 sources of quantization noise injected in the signal path. and i'm pretty damn sure the analog graphic EQs weren't in series either, for much of the same reason. even with the Linkwitz�Riley filter design, i don't think they applied that to a 31-band graphic EQ either. On Apr 23, 1:43 pm, Tauno Voipio <tauno.voi...@notused.fi.invalid> wrote:> > Linkwitz-Rileys can do it, if the output polarities > are selected correctly before summing. It is used > in audio bandsplit compressors.yup, we know that. but if you're gonna be strict about adding to a flat response (just for other's information L-R does not add to a "wire", but sums to an all-pass filter), can you imagine the filter order for each parallel section if this has a lot of bands? just going from a 2-band crossover to a 3-band crossover (with a bandpass section in between) doubles the filter order. each time you add a band in between, you double the filter order for *all* of the bands in the filterbank. i think Dale is right here: On Apr 23, 1:43 pm, dbd <d...@ieee.org> wrote:> > Audio equalizer implementations may have been somewhat less than > perfect reconstruction.about the perfect reconstruction:> You can if the filters are perfect reconstruction and the filter paths > have equal delays. You almost can if the filters are near perfect > reconstruction and the filter paths have equal delays. There is a > considerable literature on FIR and IIR "perfect reconstruction" and > "near perfect reconstruction" filters.not to much on IIR perfect reconstruction, it seems. i did check just now and downloaded what i could (not being IEEE) and i see terms like "near perfect" (which we don't dispute, clearly those analog graphic EQs gotta be near perfect when the sliders are all set to 0 dB) or "noncausal". clearly, as i was mentioning before, you can Heaviside expand a collection of cascaded sections (that come out as a wire) into parallel sections, but there is a single wire path that goes around those parallel sections and gets summed into the big accumulator at the output. i have a suspicion that when all the sliders are set to 0 dB, the gain on that wire will be 0 dB and the gains on each of the parallel sections will be -inf dB. so this won't show how to add up, with non-zero coefficients, a bunch of BPFs with various resonant frequencies (in the L-R pair, the LPF and HPF have the same resonant frequency) and get a wire. now with FIR, i think we all know how to do that. with bands equally spaced in log-frequency, (the linear-freq bandwidth of the lower bands will be a lot smaller than the bandwidths of the higher bands), it gets hairy. i think the 'wavelet and filterbank" people deal with that by splitting the whole spectrum into two, to start with (crossover at half-Nyquist, so i think some anti-symmetrical half-band trick can be used), then decimating the bottom half and doing a similar bandsplit. if i remember right (hey Randy, remember our seminar at Wellesley MA in the 90s?), i think that "*perfect* reconstruction" is obtained because the aliases that are created by decimating the bottom and top halves (them filters ain't fully anti- aliasing) ends up annihilating each other in reconstruction. now do some precessing in the intermediate signal and there is no guarantee those aliases won't be a problem. anyway, i would still like to know if anyone came up with a nice, generalized algorithm that cleanly does the Heaviside partial fraction expansion. doesn't need to be closed form. r b-j
Reply by ●April 24, 20112011-04-24
On 04/23/2011 08:30 AM, robert bristow-johnson wrote:> i know the old analog graphic EQs *did* sum > up parallel BPFs, but i am suspicious that when all the sliders are > set to 0 dB, they came out to be a wire. maybe they did, but i would > like to see how they were designed.Hi r b-j, Lots of analog graphic EQs have a almost flat response when all sliders are at 0dB. Here is one simple way how it is done: The bandpass filters are not simple signal-in -> signal-out filters like we use them in audio DSP. Instead they are resonant tanks (think RLC) with one side connected to ground. Whatever you connected on the 'hot' side will see a frequency depenpendent current flowing to ground. If you hook up such a filter to a signal and measure the amount of current taken out of the system (via a simple resistor) you can see that it cuts the signal at the center frequency. The trick to get boost and flat response is how you connect the hot side of the filters: They are connected at the wiper of a pot. The other two sides of the pot are connected to the signal and to the negative feedback loop of an output-amplifier. If the wiper of the pot is in the middle, the filter will load down the signal and the negative feedback alike. The amplifier will just cancel out this effect and you get a wire like signal path. If the wiper of the pot is at the signal side you'll cut the signal as explained above. If otoh the wiper is at the negative feedback path you get the opposite effect. The negative feedback gets weaker at the center frequency. This results in a boost at the center frequency. For inbetween settings of the pot you can go from full boost to full cut. With this arrangement you can connect as much bandpass filters in parallel as you like. Also as long as the negative feedback amplifier is fast enough to keep up cancelling out the bandpass at 0dB ,the EQ will look like a flat wire. The filters itself could even distort to some degree without affecting the signal at 0db. At other boost/cut settings the distortion will appear on the output though.
Reply by ●April 24, 20112011-04-24
On Apr 22, 9:24�pm, "John" <j...@nospam.thanks> wrote:> Hi, > > I have a question about filter banks. > > From a frequency domain point-of-view I would guess that a filterbank is > just a set of equally or un-equally spaced bins in the frequency domain > where > you apply some processing to the power in each bin (or should I call it > band). > > Now...my question is...how do you make a filterbank in the time-domain...Do > you just create N band-pass filters and apply some processing to the > signal-output from each bandpass filter before summing up the N processed > filter outputs? Or is there more to it? Any links to a good tutorial on > the subject? > > Thank you.John, Look up sub-band decomposition. The term filter bank can be applied to many forms. Lately, it's been used mostly with wavelet decomposition. A good reference is Gil Strang's book on filter banks. Also look up the 2004 COMP.DSP conference papers. I have a paper there on different types of noise reduction. On of them discusses sub-band decomposition. Maurice Givens
Reply by ●April 24, 20112011-04-24
On Apr 24, 7:14�am, Nils <n.pipenbri...@cubic.org> wrote:> On 04/23/2011 08:30 AM, robert bristow-johnson wrote: > > > i know the old analog graphic EQs *did* sum > > up parallel BPFs, but i am suspicious that when all the sliders are > > set to 0 dB, they came out to be a wire. �maybe they did, but i would > > like to see how they were designed. > > Hi r b-j, > > Lots of analog graphic EQs have a almost flat response when all sliders > are at 0dB. > > Here is one simple way how it is done: > > The bandpass filters are not simple signal-in -> signal-out filters like > we use them in audio DSP. Instead they are resonant tanks (think RLC) > with one side connected to ground. Whatever you connected on the 'hot' > side will see a frequency depenpendent current flowing to ground. > > If you hook up such a filter to a signal and measure the amount of > current taken out of the system (via a simple resistor) you can see that > it cuts the signal at the center frequency. > > The trick to get boost and flat response is how you connect the hot side > of the filters: They are connected at the wiper of a pot. The other two > sides of the pot are connected to the signal and to the negative > feedback loop of an output-amplifier. > > If the wiper of the pot is in the middle, the filter will load down the > signal and the negative feedback alike. The amplifier will just cancel > out this effect and you get a wire like signal path. > > If the wiper of the pot is at the signal side you'll cut the signal as > explained above. If otoh the wiper is at the negative feedback path you > get the opposite effect. The negative feedback gets weaker at the center > frequency. This results in a boost at the center frequency. >Nils, is this schematic: http://www.freeinfosociety.com/electronics/schemview.php?id=622 a fair representation of what you are describing? (there are some other "graphic EQ schematic" to be found on Google if you search for that term.) i have a serious question regarding the input polarity of the output op-amp and the op-amp contained in the dashed-line box (the circuit for each band). when the output is connected directly to the + terminal of the input, i don't see that as operating in negative- feedback mode, and would expect it to behave more like a Schmidt trigger than as a linear amplifier (or as a linear component in a linear circuit). r b-j
Reply by ●April 24, 20112011-04-24
On 04/24/2011 08:32 PM, robert bristow-johnson wrote:> > i have a serious question regarding the input polarity of the output > op-amp and the op-amp contained in the dashed-line box (the circuit > for each band).Oh well, schematics from the internets :-) The polarities of the opamps are wrong. The OpAmp in the dashed box works as a gyrator or simulated inductor. The output amplifier is of course also the wrong way around. If you want to have a correct example take a look at the datasheet of the LA3600 graphic EQ chip: http://www.datasheetcatalog.com/datasheets_pdf/L/A/3/6/LA3600.shtml The signal input and feedback are on Pin 10 and 11, polarity is correct here. The OpAmps for the gyrators have been replaced with transistors. Otherwise the principle is the same. Nils
Reply by ●April 25, 20112011-04-25
On Apr 23, 4:24�am, "John" <j...@nospam.thanks> wrote:> Hi, > > I have a question about filter banks. > > From a frequency domain point-of-view I would guess that a filterbank is > just a set of equally or un-equally spaced bins in the frequency domain > where > you apply some processing to the power in each bin (or should I call it > band).No. 'Bin' in DSP relates to one coefficient of the DFT. There is a bit more to a filter than just that.> Now...my question is...how do you make a filterbank in the time-domain...Do > you just create N band-pass filtersYes.> and apply some processing to the > signal-output from each bandpass filter before summing up the N processed > filter outputs?No. You don't *need* to do more than 'split' the signal through the set of bandpass filters. Most bandpass filters will only produce garbage if you sum the signals back. If you want to do that, you will need to take specific precautions.> Or is there more to it? Any links to a good tutorial on > the subject?A filter is a filter. What you want to do with the output is a different story. Devide on the application first, and then search for literature on how to do whatever it is you want. Rune






