Hi all, I implemented a butterworth crossover with the matlab (code given below). The code is working perfectly for a 4th order butterworth crossover(i.e. 24 dB/Octave). Th added response for the lowpass and high pass filters of the butterworth crossover gives 3 dB increase at the corner frequency which is expected. But the same is not obtained when i use 2nd and 3rd order butterworth filters. Instead of having a 3 dB increase at the cutoff i am getting all pass response for 3rd order and a dip at cutoff for 2nd order butterworth filter. Can anybody help me with this? your help is very much appreciated. See the code below for your reference. %Butterworth crossover filterorder=4; cutoff=1000; fs=44100; [b,a] = butter(filterorder,cutoff/fs,'low'); h1=freqz(b,a,44100); semilogx(10*log(abs(h1)),'r'); hold [b,a] = butter(filterorder,cutoff/fs,'high'); h2=freqz(b,a,44100); semilogx(10*log(abs(h2)),'b'); h=h1+h2; semilogx(10*log(abs(h)),'g'); grid Regards Gangadhar

# help needed for Butterworth crossover response

Started by ●July 16, 2007

Reply by ●July 16, 20072007-07-16

gangadhar.m wrote:> Hi all, > > I implemented a butterworth crossover with the matlab (code given below). > > The code is working perfectly for a 4th order butterworth crossover(i.e. > 24 dB/Octave). Th added response for the lowpass and high pass filters of > the butterworth crossover gives 3 dB increase at the corner frequency which > is expected. > > But the same is not obtained when i use 2nd and 3rd order butterworth > filters. Instead of having a 3 dB increase at the cutoff i am getting all > pass response for 3rd order and a dip at cutoff for 2nd order butterworth > filter.The phase shift at the cutoff frequency depends on the order of the filters. You should combine the filter outputs so they add in phase.> Can anybody help me with this? your help is very much appreciated.I like this phrase. Anybody can certainly help you with this depending on how much is the real appreciation. Vladimir Vassilevsky DSP and Mixed Signal Design Consultant http://www.abvolt.com

Reply by ●July 17, 20072007-07-17

Hi, As you said, the phase shift is playing a major role. Can you please tell me how should I proceed now to achieve 3 dB increase at the cut off frequency for all butterworth crossovers(2nd,3rd and 4th orders) irrsepective of change in the order. Actually same kind of behaviour is observed in implememntation of LR Crossovers also (i.e i got correct flat all pass response for LR 4 Crossover and a big dip at cutoff in case of LR 2 Crossover). Is there any way for the phase adjustment while combining the filter responses? I really appreciate your help in this. Thanks and regards Gangadhar> > >gangadhar.m wrote: >> Hi all, >> >> I implemented a butterworth crossover with the matlab (code givenbelow).>> >> The code is working perfectly for a 4th order butterworthcrossover(i.e.>> 24 dB/Octave). Th added response for the lowpass and high pass filtersof>> the butterworth crossover gives 3 dB increase at the corner frequencywhich>> is expected. >> >> But the same is not obtained when i use 2nd and 3rd order butterworth >> filters. Instead of having a 3 dB increase at the cutoff i am gettingall>> pass response for 3rd order and a dip at cutoff for 2nd orderbutterworth>> filter. > >The phase shift at the cutoff frequency depends on the order of the >filters. You should combine the filter outputs so they add in phase. > >> Can anybody help me with this? your help is very much appreciated. > >I like this phrase. Anybody can certainly help you with this depending >on how much is the real appreciation. > > >Vladimir Vassilevsky > >DSP and Mixed Signal Design Consultant > >http://www.abvolt.com >

Reply by ●July 17, 20072007-07-17

gangadhar.m wrote:> Hi, > > ... Can you please tell > me how should I proceed now to achieve 3 dB increase at the cut off > frequency for all butterworth crossovers(2nd,3rd and 4th orders) > irrsepective of change in the order. ...Butterworth is Butterworth. If you change it in any way, it's not Butterworth any more. Try Linkwitz-Reilly. Jerry -- Engineering is the art of making what you want from things you can get. ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯

Reply by ●July 18, 20072007-07-18

Dear Jerry, As i mentioned earlier i get the same kind of response in case of Linkwitz Riley filters also..... In net, i find papers where they have flat all pass response for Linkwitz Riley crossovers(LR-2, LR-3 and LR-4 filters) but for me, all pass response is observed only for the LR-4 crossover and big dig at cutoff for the other LR Crossovers. Similar cases are observed for Butterworth crossovers also. Since we are having butterworth crossovers available, i assume that all butterworth crossovers shoud be able to exhibit 3dB increase at the cutoff irrsepective of their order. How can I achieve that? Please help me if my understanding is not correct. Regards Gangadhar>gangadhar.m wrote: >> Hi, >> >> ... Can you please tell >> me how should I proceed now to achieve 3 dB increase at the cut off >> frequency for all butterworth crossovers(2nd,3rd and 4th orders) >> irrsepective of change in the order. ... > >Butterworth is Butterworth. If you change it in any way, it's not >Butterworth any more. Try Linkwitz-Reilly. > >Jerry >-- >Engineering is the art of making what you want from things you can get. >¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯ >

Reply by ●July 18, 20072007-07-18

I got the answer. I have to use Polarity inversion also as specified in the document availabe at the link www.lake.com.au/documentation/Lake%20Contour%20Classical%20Crossover%20Notes.pdf The document says that "When using 24 dB and 48 dB L-R crossovers, there is no need to reverse the polarity of adjacent crossover channels. However, the 12 dB and 36 dB L-R crossovers will require polarity reversals. In order to provide the desired constant magnitude summation, the polarity of an output channel must be inverted." Thank you all Gangadhar> >Dear Jerry, > >As i mentioned earlier i get the same kind of response in case ofLinkwitz>Riley filters also..... In net, i find papers where they have flat allpass>response for Linkwitz Riley crossovers(LR-2, LR-3 and LR-4 filters) > >but for me, all pass response is observed only for the LR-4 crossoverand>big dig at cutoff for the other LR Crossovers. Similar cases areobserved>for Butterworth crossovers also. > >Since we are having butterworth crossovers available, i assume that all >butterworth crossovers shoud be able to exhibit 3dB increase at thecutoff>irrsepective of their order. How can I achieve that? > >Please help me if my understanding is not correct. > >Regards >Gangadhar >>gangadhar.m wrote: >>> Hi, >>> >>> ... Can you please tell >>> me how should I proceed now to achieve 3 dB increase at the cut off >>> frequency for all butterworth crossovers(2nd,3rd and 4th orders) >>> irrsepective of change in the order. ... >> >>Butterworth is Butterworth. If you change it in any way, it's not >>Butterworth any more. Try Linkwitz-Reilly. >> >>Jerry >>-- >>Engineering is the art of making what you want from things you can get. >>¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯ >> >

Reply by ●July 18, 20072007-07-18

gangadhar.m wrote:> Dear Jerry, > > As i mentioned earlier i get the same kind of response in case of Linkwitz > Riley filters also..... In net, i find papers where they have flat all pass > response for Linkwitz Riley crossovers(LR-2, LR-3 and LR-4 filters) > > but for me, all pass response is observed only for the LR-4 crossover and > big dig at cutoff for the other LR Crossovers. Similar cases are observed > for Butterworth crossovers also. > > Since we are having butterworth crossovers available, i assume that all > butterworth crossovers shoud be able to exhibit 3dB increase at the cutoff > irrsepective of their order. How can I achieve that? > > Please help me if my understanding is not correct.A Butterworth low-pass filter is one whose frequency-response derivatives are all zero at w = 0. Band-pass and high-pass Butterworth filters can be derived from it by the usual transformations or derived directly by setting all derivatives to zero at w = infinity (high-pass) or at the center frequency (band-pass). A consequence is that the transfer function of a Butterworth low-pass prototype of order n is H(s) = 1/sqrt(1 + (w/w_c)^2n) That's it, unalterably. If that response isn't suitable, then Butterworth isn't suitable. This response can only be approximated by a digital filter, and the approximation is usually crude by the standards of those who listen with their calculators instead of with their ears. There is another degree of freedom with crossovers. It is not written in stone that the corner frequencies of the high-pass and low-pass sections must be equal. Jerry -- Engineering is the art of making what you want from things you can get. ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯

Reply by ●July 18, 20072007-07-18

Jerry Avins wrote:> A Butterworth low-pass filter is one whose frequency-response > derivatives are all zero at w = 0. Band-pass and high-pass Butterworth > filters can be derived from it by the usual transformations or derived > directly by setting all derivatives to zero at w = infinity (high-pass) > or at the center frequency (band-pass). A consequence is that the > transfer function of a Butterworth low-pass prototype of order n is > > H(s) = 1/sqrt(1 + (w/w_c)^2n) > > That's it, unalterably. If that response isn't suitable, then > Butterworth isn't suitable. This response can only be approximated by a > digital filter, and the approximation is usually crude by the standards > of those who listen with their calculators instead of with their ears.Actually, if a filter is specified by the frequency response, going digital improves it. Warping provides for the better roloff then in the analog case.> There is another degree of freedom with crossovers.There are many degrees of freedom if you have nothing more important to do. Vladimir Vassilevsky DSP and Mixed Signal Design Consultant http://www.abvolt.com

Reply by ●July 18, 20072007-07-18

Vladimir Vassilevsky wrote: ...> Actually, if a filter is specified by the frequency response, going > digital improves it. Warping provides for the better roloff then in the > analog case.Warping sharpens the band edge. Whether that's an improvement depends on circumstance. A filter with sharper-than-Butterworth transition isn't a Butterworth filter. ... Jerry -- Engineering is the art of making what you want from things you can get. ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯

Reply by ●July 25, 20072007-07-25

In article <nNydnXeVrvc0IwDbnZ2dnUVZ_gCdnZ2d@giganews.com>, gangadhar.m@jasmin-infotech.com says...> > >I got the answer. I have to use Polarity inversion also as specified in the >document availabe at the link >www.lake.com.au/documentation/Lake%20Contour%20Classical%20Crossover%20Notes.pdf> > >The document says that > >"When using 24 dB and 48 dB L-R crossovers, there is no need to reverse >the polarity of adjacent crossover channels. However, the 12 dB and 36 dB >L-R crossovers will require polarity reversals. In order to provide the >desired constant magnitude summation, the polarity of an output channel >must be inverted."To add a bit of info: Odd-order Butterworth highpass and lowpass pairs all have the allpass summation property regardless of the polarity of the summation. However, the order of the resulting allpass is different depending on polarity. If you want to have the summation be an allpass with the minimum number of poles, you need to invert polarity for 3rd-order (18 dB/oct), 7th order, 11th order... For example, the allpass sum of a 3rd-order Butterworth has two poles if the summation is in uninverted polarity and one pole if the sum has one input with inverted polarity (view with monospaced font): 3 2 1 s s - s + 1 _____________________ + _____________________ = ____________ 3 2 3 2 2 s + 2+s + 2+s + 1 s + 2+s + 2+s + 1 s + s + 1 3 1 s 1 - s _____________________ - _____________________ = _______ 3 2 3 2 s + 1 s + 2+s + 2+s + 1 s + 2+s + 2+s + 1 Polarity for 5th order, 9th order... should not be inverted, Finally, the allpass summation property is preserved if the Butterworth filter is transformed into an IIR digital filter via the binlear transform.