Method and Apparatus for Selecting Bass Management Filter

Information

  • Patent Application
  • 20100246838
  • Publication Number
    20100246838
  • Date Filed
    March 26, 2009
    15 years ago
  • Date Published
    September 30, 2010
    13 years ago
Abstract
A method and apparatus for enhancing bass management selection. The method includes retrieving a filter response for at least one filter pair, determining expected speaker and woofer spectra, calculating optimal parameters utilizing the retrieved filter response and the determined spectra, measuring flatness to determine if the result is optimal, and utilizing the determined spectra with optimal result in selecting a bass management filters for each speaker.
Description
BACKGROUND OF THE INVENTION

1. Field of the Invention


Embodiments of the present invention generally relate to a method and apparatus for selecting bass management filters.


2. Background of the Invention


Bass management refers to routing the low frequency part of the signal to the most effective transducer, typically a subwoofer. Usually a lower cutoff frequency is determined for the regular speaker and an upper cutoff frequency is determined for the subwoofer using methods. Frequencies below the regular loudspeaker's lower cutoff cannot be effectively reproduced by that speaker and are removed by a high pass filter chosen based on the speaker's estimated cutoff frequency. The portion of the signal below the speaker's cutoff frequency is extracted by a corresponding low-pass filter and sent to the subwoofer instead, where it can be effectively reproduced.


This high-pass low-pass filter pair can be implemented as low-order power complementary infinite-impulse response (IIR) filters with frequency responses, as shown in FIG. 1. FIG. 1 is an embodiment of a bass management power complementary filter (40 Hz cross-over). However, such a system does not take into account environmental effects and potentially the phase relationship between the woofer and speaker. Therefore, there is a need for an improved bass management filter pair selection method and apparatus.


SUMMARY OF THE INVENTION

Embodiments of the present invention relate to a method and apparatus for enhancing bass management selection. The method includes retrieving a filter response for at least one filter pair, determining expected speaker and woofer spectra, calculating optimal parameters utilizing the retrieved filter response and the determined spectra, measuring flatness to determine if the result is optimal, and utilizing the determined spectra with optimal result in selecting a bass management filters for each speaker.





BRIEF DESCRIPTION OF THE DRAWINGS

So that the manner in which the above recited features of the present invention can be understood in detail, a more particular description of the invention, briefly summarized above, may be had by reference to embodiments, some of which are illustrated in the appended drawings. It is to be noted, however, that the appended drawings illustrate only typical embodiments of this invention and are therefore not to be considered limiting of its scope, for the invention may admit to other equally effective embodiments. In this application, a computer readable processor is any medium accessible by a computer for saving, writing, archiving, executing and/or accessing data. Furthermore, the method described herein may be coupled to a processing unit, wherein said processing unit is capable of performing the method.



FIG. 1 is an embodiment of a bass management power complementary filters;



FIG. 2 is an embodiment of a bass management filter selection;



FIG. 3 is an embodiment of a front left loudspeaker measured spectrum;



FIG. 4 is a flow diagram depicting an embodiment of a method for bass management filter selection;



FIG. 5 is an embodiment of an application with optimally delayed woofer signal;



FIG. 6 is an embodiment of a woofer measured spectrum;



FIG. 7 is an embodiment of an effect of choosing different bass management filters;



FIG. 8 is an embodiment of a total variance as a function of gs and gw;



FIG. 9 is an embodiment of a fourth order function of gs and gw;



FIG. 10 is an embodiment of a four constrained critical points;



FIG. 11 is an embodiment of an effect of woofer delay on critical variances;



FIG. 12 is an embodiment of an effect of woofer delay on critical variances;



FIG. 13 is an embodiment of a minimum total variance for different filter pair cross-over, with and without woofer delay; and



FIG. 14 is a flow diagram depicting an embodiment of another method for bass management filter selection.





DETAILED DESCRIPTION

Bass management, wherein an audio signal is divided between a loudspeaker and woofer, may require selection of high-pass and low-pass filters to divide the signal. Usually this is done by estimating the lower cutoff frequency of the loudspeaker. However it is also possible to select the bass management filters directly by looking at the expected response. This avoids any problem in determining the loudspeaker cutoff, takes into account the effect of the environment and potentially even the phase relationship between the woofer and speaker. Also the phase relationship can be changed by adding delay to the woofer signal. Other practical variations such as weighting functions, applying preferences and decibel (dB) scale comparisons are also discussed.



FIG. 2 is an embodiment of a bass management filter selection. FIG. 2 shows how loudspeaker and woofer measurements are taken with a microphone which determines measured spectra. Measured spectra are then used to choose appropriate bass management filters for each speaker. The measurement can be the same as the measurement used for other applications, such as, loudspeaker equalization. In loudspeaker equalization, filters may be designed to compensate for the loudspeaker responses that are applied to a signal.


In determining the spectra, generally, a known test signal is applied to the loudspeaker and a microphone, which has a known frequency response, receives its output. The unknown system, amplifier, loudspeaker, environment, may be tested by applying a known test signal and recording the output. The frequency response may be derived using standard techniques. This measured frequency response, used primarily to design equalization filters, may be used for several addition purposes, such as, distance detection, polarity detection and cutoff detection. However, the spectrum of the measured system is typically not smooth, as shown in FIG. 3. FIG. 3 is an embodiment of a front left loudspeaker measured spectrum. Thus, the first issue is that the irregularity in the measured spectrum makes accurate cutoff estimation difficult.


A second related issue is that the spectral effects of the environment can potentially affect which filter pair produces the best result. For instance sometimes a filter pair with a higher cutoff frequency could sound better if the combined effect of speaker and environment has some problems above the speaker's cutoff frequency which the woofer can better handle. A third issue is that there will be some region where the high-pass filtered loudspeaker signal and low-pass filtered woofer signal overlap. In that cross-over region the phase relationship between loudspeaker signal and woofer signal (and listening position) determines the amplitude at those frequencies.


Three issues with selecting bass management filter based on speaker cutoff were mentioned in the introduction:

    • 1. The difficulty in accurate estimation of loudspeaker cutoff
    • 2. Even when the loudspeaker cutoff in known, other factors can affect which bass management filters are best
    • 3. The interaction between the speaker and woofer signal in the crossover region.


Constraining the average magnitude to be a certain value over a certain frequency range is utilized for choosing a bass management filter pair which produces the flattest overall response. Thus, parameters are found which minimize the variance, which acts as a measure of flatness. This may be applied to all filter pairs. The filter pair that has the least variance given the constraints may be chosen. Some recommended variations are to use a frequency weighting, to penalize higher cross-over frequencies and to make final selections based on a dB scale re-evaluation.



FIG. 4 is a flow diagram depicting an embodiment of a method 400 for bass management filter selection. In FIG. 4, the basic loop followed by the proposed methods that consists of evaluating different possible bass management filters and saving the best result with its associated parameters.


Method 400 starts at step 402 and proceeds to step 404, wherein the method 400 retrieves the filter response for each filter pair. At step 406, the method 400 determines the expected speaker and woofer spectra. At step 408, the method 400 calculates optimal parameters. At step 410, the method 400 measures the flatness. If the flatness causes better results than prior itterations, the method 400 proceeds to step 414, wherein the parameters are saved and then proceeds to step 416. Otherwise, the method 400 proceeds to step 416, wherein the method 400 moves to the next filter pair for the current speaker if any remain. The method 400 proceeds to step 418. If there is more evaluation, the method 400 proceeds to step 404. Otherwise, the method 400 ends at step 420. The entire method may be repeated for additional speakers.


In one embodiment, the method addresses the first two issues by looking directly at the resulting signal, which eliminates the need to estimate cutoff frequency and includes the effects of the environment. However, such a method may not take the phase relationship between the loudspeaker and woofer into account. Instead the power from the loudspeaker and woofer is simply summed. This simplifies the computation greatly and can be used when the overlap between the high-pass and low-pass filters is small.


In one embodiment, the method takes the phase relationship into account, thus, dealing with the third problem. Not only is the phase relationship between the loudspeaker and woofer considered, it can also be manipulated by adding delay to the woofer signal, as shown in FIG. 5. FIG. 5 is an embodiment of an application with optimally delayed woofer signal. In FIG. 5, where gs refers to the speaker gain, gw refers to the woofer gain, and all parameters (gs, gw, the delay amount and which high-pass and low-pass filters are used) are determined by the method described below.


In one embodiment, the method determines and utilizes an optimal amount of delay for the bass-management woofer signal. This delay may be different from any other delay used to synchronize arrival time, and may be only used for bass management with a specific speaker in order to make the cross-over with that speaker as flat as possible.


For an example, the speaker spectrum of FIG. 3 was combined with the woofer spectrum from the same speaker set shown in FIG. 6, using different bass management filters with cross-over at 40 Hz and 200 Hz, as shown in FIG. 7. FIG. 6 is an embodiment of a woofer measured spectrum. FIG. 7 is an embodiment of an effect of choosing different bass management filters.


Note that, compared to the result using cross-over filters at 40 Hz, the result using a 200 Hz cross-over filter pair produces a hole between around 100 Hz to 200 Hz. This hole is caused by overly reducing the speaker output in this range where the woofer is also weak. These holes naturally decrease the flatness of the resulting spectrum, and hence, increase the variance which can be calculated. Interestingly, since the speaker can handle frequencies into the woofer range, the 40 Hz cross-over filters also appear to decrease the large bump in the woofer spectrum without creating new holes, allowing the gain on the woofer to be increased and improving the response below 50 Hz as well.


Let S[n] be the speaker frequency response at the nth frequency bin, defined as the complex value of the speaker spectrum at the nth bin, W[n] be the woofer frequency response at the nth bin, Fhi[n] and Flow[n] be the frequency responses at frequency bin n of the high-pass and low-pass filters respectively. Then for some set of speaker gains gs and woofer gains gw we can write













n
=
start


<
end




(






g
s




F
hi



[
n
]




S


[
n
]





2

+





g
w




F
low



[
n
]




W


[
n
]





2


)


=




n
=
start


<
end



1





(
1
)







which acts as a constraint, where start and end restrict the summations to relevant frequencies, usually starting at 20 Hz and ending anywhere above the woofer response, such as 375 Hz. Among the gs and gw, which satisfy (1) there is at least one pair of gains for which the variance is minimum, i.e.













n
=
start


<
end





(


(






g
s




F
hi



[
n
]




S


[
n
]





2

+





g
w





F
low



[
n
]




[
n
]





2


)

-
1

)

2


=
min




(
2
)







which can be thought of as representing the flattest response. In (1) and (2) only the power of the resulting signals is summed. This is reasonable when the high-pass signal and low-pass signal do not overlap much so if the filters have very sharp roll-offs, this method can be used. Simplifying notation let






s
k
2
=|F
hi
[k+start]S[k+start]|2   (3)






w
k
2
=|F
low
[k+start]W[k+start]|2   (4)






N=end−start   (5)





ĝs=gs2   (6)





ĝw=gw2   (7)


Then the constraint is simply













g
^

s






k
=
0


N
-
1




s
k
2



+



g
^

w






k
=
0


N
-
1




w
k
2




=
N




(
8
)







and the minimization objective is













k
=
0


N
-
1





(


(




g
^

s



s
k
2


+



g
^

w



w
k
2



)

-
1

)

2


=
min




(
9
)







Solving for the speaker gain, let










Λ
0

=




k
=
0


N
-
1




s
k
2






(
10
)







C
0

=




k
=
0


N
-
1




w
k
2






(
11
)







so that






ĝ
s
A
0

w
C
0
=N.   (12)


Then










g
^

s

=


N
-



g
^

w



C
0




A
0






(
13
)







Next to minimize










k
=
0


N
-
1





(


(




g
^

s



s
k
2


+



g
^

w



w
k
2



)

-
1

)

2


=
min




we let take the derivative with respect to ĝw and set equal to zero as





















g
^

w





(




k
=
0


N
-
1





(


(




g
^

s



s
k
2


+



g
^

w



w
k
2



)

-
1

)

2


)


=
0.




(
14
)







Substituting for ĝs in (14) using (13) gives


















g
^

w





(




k
=
0


N
-
1





(




N
-



g
^

w



C
0




A
0




s
k
2


+



g
^

w



w
k
2


-
1

)

2


)


=
0




and taking the derivative







2





k
=
0


N
-
1





(




N
-



g
^

w



C
0




A
0




s
k
2


+



g
^

w



w
k
2


-
1

)



(




-

C
0



A
0




s
k
2


+

w
k
2


)




=
0




we have










k
=
0


N
-
1





(


(



N






s
k
2



A
0


-
1

)

-



g
^

w



(




C
0


A
0




s
k
2


-

w
k
2


)



)



(




-

C
0



A
0




s
k
2


+

w
k
2


)



=
0




so that








g
^

w

=





k
=
0


N
-
1





(



N






s
k
2



A
0


-
1

)



(




-

C
0



A
0




s
k
2


+

w
k
2


)







k
=
0


N
-
1





(




C
0


A
0




s
k
2


-

w
k
2


)



(




-

C
0



A
0




s
k
2


+

w
k
2


)








after which the variance can be calculated for each filter pair






var
=




k
=
0


N
-
1






(


(




g
^

s



s
k
2


+



g
^

w



w
k
2



)

-
1

)

2

.






The filter pair with the lowest variance is then chosen, along with corresponding positive gains gs=√{square root over (ĝs)} and gw=√{square root over (ĝw)} for the speaker and woofer, respectively. The relative woofer gain can be found by dividing gw by gs.


In another embodiment, the method also accounts for phase. In such a method, let S[n] be the speaker frequency response at the nth frequency bin, W[n] be the woofer frequency response at the nth bin, Fhi[n] and Flow[n] be the frequency responses at frequency bin n of the high-pass and low-pass filters, respectively. Then, for some set of real valued speaker gains gs and woofer gains gw, we can write














<
end



n
-
start









g
s




F
hi



[
n
]




S


[
n
]



+


g
w




F
low



[
n
]




W


[
n
]






2


=





<
end



n
-
start



1





(
15
)







which acts as a constraint. This constraint is similar to (1) but sums the speaker and woofer signals before squaring. Among the gs and gw which satisfy (15) there is at least one pair of gains for which the variance is minimum, i.e.














<
end



n
=
start





(







g
s




F
hi



[
n
]




S


[
n
]



+


g
w




F
low



[
n
]




W


[
n
]






2

-
1

)

2


-
min




(
16
)







which can be compared with (2). In order to take phase into account we use the following notation






s
k
=F
hi
[k+start]S[k+start]  (17)






w
k
=F
low
[k+start]W[k+start]  (18)






N=end−start   (19)


where (17) and (18) can be compared with (3) and (4) respectively. Note especially that sk and wk are complex values. Then the constraint is














N
-
1



k
=
0









g
s



s
k


+


g
w



w
k





2


=
N




(
20
)







which can be contrasted with (8) while the minimization objective is














N
-
1



k
=
0





(







g
s



s
k


+


g
w



w
k





2

-
1

)

2


=
min




(
21
)







which can be compared with (9). Denoting complex conjugation with an overbar, expanding the constraint gives














N
-
1



k
=
0





(



g
s



s
k


+


g
w



w
k



)




(



g
s



s
k


+


g
w



w
k



)

_



=
N




(
22
)











N
-
1



k
=
0




(



g
s
2



s
k




s
_

k


+


g
s




g
w



(



s
k




w
_

k


+



s
_

k



w
k



)



+


g
w
2



w
k




w
_

k



)


=
N




(
23
)









g
s
2







N
-
1



k
=
0





s
k




s
_

k




+


g
s



g
w







N
-
1



k
=
0




(



s
k




w
_

k


+



s
_

k



w
k



)



+


g
w
2







N
-
1



k
=
0





w
k




w
_

k





=
N




(
24
)







and letting










A
0

=





N
-
1



k
=
0





s
k




s
_

k







(
25
)







B
0

=





N
-
1



k
=
0




(



s
k




w
_

k


+



s
_

k



w
k



)






(
26
)







C
0

=





N
-
1



k
=
0





w
k




w
_

k







(
27
)







we have






g
s
2
A
0
+g
s
g
w
B
0
+g
w
2
C
0
=N   (28)


which can be compared to (12). Also note that the A0 and C0 defined in (25) and (27) are the same as those defined in (10) and (11), and that A0, B0 and C0 are real numbers.


Next we expand the minimization objective function as follows:



















k
=
0



N
-
1





(







g
s



s
k


+


g
w



w
k





2

-
1

)

2


=
min





(
29
)
















k
=
0



N
-
1





(



(



g
s



s
k


+


g
w



w
k



)




(



g
s



s
k


+


g
w



w
k



)

_


-
1

)

2


=
min





(
30
)
















k
=
0



N
-
1





(



g
s
2



s
k




s
k

_


+


g
s




g
w



(



s
k




w
k

_


+



s
k

_



w
k



)



+


g
w
2



w
k




w
k

_


-
1

)

2


=
min





(
31
)












N
-
1



k
=
0




(



g
s
4



s
k
2




s
_

k
2


+


g
s
3



g
w


2


(



s
k
2




s
_

k




w
_

k


+


s
k




s
_

k
2



w
k



)


+


g
s
2




g
w
2



(



s
k
2




w
_

k
2


+



s
_

k
2



w
k
2


+

4


s
k




s
_

k



w
k




w
_

k



)



+


g
s



g
w
3


2


(




s
_

k



w
k
2




w
_

k


+


s
k



w
k




w
_

k
2



)


+


g
w
4



w
k
2




w
_

k
2


-

2


(



g
s
2



s
k




s
_

k


+


g

s









g
w



(



s
k




w
_

k


+



s
_

k



w
k



)



+


g
w
2



w
k




w
_

k



)


+
1

)


=
min






Let




(
32
)












A
1

=





N
-
1



k
=
0





s
k
2




s
_

k
2








(
33
)












B
1

=





N
-
1



k
=
0




2


(



s
k
2




s
_

k




w
_

k


+


s
k




s
_

k
2



w
k



)








(
34
)












C
1

=





N
-
1



k
=
0




(



s
k
2




w
_

k
2


+



s
_

k
2



w
k
2


+

4


s
k




s
_

k



w
k




w
_

k



)







(
35
)












D
1

=





k
=
0



N
-
1




2


(




s
_

k



w
k
2




w
_

k


+


s
k



w
k




w
_

k
2



)








(
36
)












E
1

=





N
-
1



k
=
0





w
k
2





w
_

k
2

.








(
37
)







Note that A1, B1, C1, D1 and E1 are all real numbers. We have






g
s
4
A
1
+g
s
3
g
w
B
1
+g
s
2
g
w
2
C
1
+g
s
g
w
3
D
1
+g
w
4
E
1−2(gs2A0+gsgwB0+gw2C0)+N=min   (38)


which using (28) simplifies to






g
s
4
A
1
+g
s
3
g
w
B
1
+g
s
2
g
w
2
C
1
+g
s
g
w
3
D
1
+g
w
4
E
1
−N=min   (39)


An example graph of the variance as a function of gs and gw is given in FIG. 8. FIG. 8 is an embodiment of a total variance as a function of gs and gw. The goal is to find the minimum variance on a constraint curve within this space utilizing Lagrange multipliers. In order to minimize






g
s
4
A
1
+g
s
3
g
w
B
1
+g
s
2
g
w
2
C
1
+g
s
g
w
3
D
1
+g
w
4
E
1=min   (40)


subject to






g
s
2
A
0
+g
s
g
w
B
0
+g
w
2
C
0
=N   (41)


we try to minimize






g
s
4
A
1
+g
s
3
g
w
B
1
+g
s
2
g
w
2
C
1
+g
s
g
2
3
D
1
+g
w
4
E
1−λ(gs2A0+gsgwB0+gw2C0−N)=min.   (42)


Taking the partial derivative with respect to gs and setting equal to zero we have



















g
s





(



g
s
4



A
1


+


g
s
3



g
w



B
1


+


g
s
2



g
w
2



C
1


+


g
s



g
w
3



D
1


+


g
w
4



E
1


-

λ


(



g
s
2



A
0


+


g
s



g
w



B
0


+


g
w
2



C
0


-
N

)



)





(
43
)






=



4


g
s
3



A
1


+

3


g
s
2



g
w



B
1


+

2


g
s



g
w
2



C
1


+


g
w
3



D
1


-

λ


(


2


g
s



A
0


+


g
w



B
0



)



=
0





(
44
)







which gives









λ
=




4






g
s
3



A
1


+

3


g
s
2



g
w



B
1


+

2


g
s



g
w
2



C
1


+


g
w
3



D
1





2


g
s



A
0


+


g
w



B
0




.





(
45
)







Likewise taking the partial derivative with respect to gw and setting to zero














g
w





(






g
s
4



A
1


+


g
s
3



g
w



B
1


+


g
s
2



g
w
2



C
1


+


g
s



g
w
3



D
1


+


g
w
4



E
1


-






λ


(



g
s
2



A
0


+


g
s



g
w



B
0


+


g
w
2



C
0


-
N

)





)





(
46
)






=




g
s
3



B
1


+

2


g
s
2



g
w



C
1


+

3


g
s



g
w
2



D
1


+

4


g
w
3



E
1


-

λ


(






g
s



B
0


+






2


g
w



C
0





)



=
0





(
47
)







gives









λ
=





g
s
3



B
1


+

2


g
s
2



g
w



C
1


+

3


g
s



g
w
2



D
1


+

4


g
w
3



E
1






g
s



B
0


+

2


g
w



C
0




.





(
48
)







Combining equations (45) and (48) gives












4






g
s
3



A
1


+

3


g
s
2



g
w



B
1


+

2


g
s



g
w
2



C
1


+


g
w
3



D
1





2


g
s



A
0


+


g
w



B
0




=




g
s
3



B
1


+

2


g
s
2



g
w



C
1


+

3


g
s



g
w
2



D
1


+

4


g
w
3



E
1






g
s



B
0


+

2


g
w



B
0








(
49
)





or












(





4






g
s
3



A
1


+

3


g
s
2



g
w



B
1


+







2


g
s



g
w
2



C
1


-


g
w
3



D
1






)



(






g
s



B
0


-






2


g
w



C
0





)


=


(






g
s
3



B
1


+

2


g
s
2



g
w



C
1


+







3


g
s



g
w
2



D
1


+

4


g
w
3



E
1






)



(





2


g
s



A
0


+







g
w



B
0





)






(
50
)







and grouping terms gives






g
s
4(4A1B0−2A0B1)+gs3gw(2B0B1+8A1C0−4A0C1)+gs2gw2(6B1C0−6A0D1)+gsgw3(4C0C1−2B0D1−8A0E1)+gw4(2C0D1−4B0E1)=0.   (52)


This is a fourth order polynomial and as such can be solved directly using the “Ferrari-Cardano” method. An example graph of this function based on FIG. 8 is shown in FIG. 9. FIG. 9 is an embodiment of a fourth order function of gs and gw.


Since we want gw as a function of gs, we can divide by (2C0D1−4B0E1) getting










g
w
4

+


g
s



g
w
3





4


C
0



C
1


-

2


B
0



D
1


-


8
0



E
1





2






C
0



D
1


-

4


B
0



E
1





+


g
s
2



g
w
2





6






B
1



C
0


-

6






A
0



D
1





2






C
0



D
1


-

4


B
0



E
1









(
53
)









+

g
s
3




g
w





2


B
0



B
1


+

8


A
1



C
0


-

4


A
0



C
1





2


C
0



D
1


-

4


B
0



E
1





+


g
s
4





4






A
1



B
0


-

2


A
0



B
1





2






C
0



D
1


-

4


B
0



E
1






=
0




(
54
)







and look for a solution





(gw−ags)(gw−bgs)(gw−cgs)(gw−dgs)=0   (55)


Letting gs=1 for the moment we find solutions x such that





(x−a)(x−b)(x−c)(x−d)=0.   (56)



FIG. 10 is an embodiment of four constrained critical points. In FIG. 10, the roots with gs−1 correspond to the slopes of unconstrained solutions through the origin. To apply the constraint (28) amounts to finding the intersection of these lines with the constraint function, appearing as an ellipse. For each solution x, the linear equation is





gw−xgs   (57)


and since






g
s
2
A
0
+g
s
g
w
B
0
+g
w
2
C
0
=N   (58)






g
s
2
A
0
+xg
s
2
B
0
+x
2
g
s
2
C
0
=N   (59)










g
s
2

=

N



x
2



C
0


+

xB
0

+

A
0







(
60
)







g
s

=


N



x
2



C
0


+

xB
0

+

A
0








(
61
)







and having gs we find gw easily





gw=xgs.   (62)


The up to four solutions found will be the critical points of the variance which means they will be either local minimums or maximums. To find the global minimum all one may calculate the actual variance for these solutions





var=gs4A1+gs3gwB1+gs2gwC1+gsgw3D1gw4E1−N   (63)


and save the solution with the lowest variance. Note sometimes gw can sometimes be negative. This indicates that phase inversion applied to the woofer signal works better in the crossover region due to the relative phases of the speaker and woofer frequency responses in that region.



FIG. 11 is an embodiment of an effect of woofer delay on critical variances. FIG. 11 shows the way the critical variances (local maximum or minimum variances) typically behave when applying delay to the woofer. Usually, there are either 2 or 4 real roots of (55) which are affected by the phase relationship between the woofer and speaker, so changing the woofer delay affects these roots. The maximum delay is extended to 8192 samples to show how the roots behave over a large range of delay values. However in practice a large delay (more than 20 milliseconds or so) can be undesirable for psychoacoustic reasons. In FIG. 11 the minimum total variance is achieved by using a 6465 sample delay on the woofer relative to the speaker, but this corresponds to a 0.134 second delay at a 48 kHz sampling rate. The minimum variance with delay less than 0.02 seconds occurs with a 479 sample delay.



FIG. 11 also shows that the roots with the minimum variance cross each other fairly regularly. The amount of delay between these root crossings in this example is about 700 samples, which at the 48000 Hz sampling rate, is a half period of a frequency around 35 Hz, within the range affected by cross-over (the actual cross-over point for the filters is at 40 Hz in this example).



FIG. 12 is an embodiment of an effect of woofer delay on critical variances. FIG. 12 shows the minimum variance of the four roots and the corresponding relative woofer gain (with the speaker gain held constant). As shown, where there is a root crossing, the woofer gain changes polarity. The polarity change flips all the woofer frequency's phases by 180 degrees, thus putting the cross-over region back into its best alignment with the speaker frequencies. As delay further increases, the alignment (in the sense of reducing total variance) improves to a point and then gets worse, until a complete phase reversal again is needed. This pattern continues as delay is added, but since the delay affects each frequency in the cross-over region differently, the pattern is somewhat irregular.



FIG. 13 is an embodiment of a minimum total variance for different filter pair cross-over frequencies, with and without woofer delay. FIG. 13 shows the reduction in variance achieved by adding the best delay to the woofer for filters with different cross-over points, every 10 Hz from 40 Hz to 200 Hz. Also using delay, the best cross-over point for this speaker in the sense of lowest variance is at 40 Hz while without using delay the best cross-over point is at 100 Hz. Thus using delay can affect which filter pair is chosen.


Most of the calculation involved is used to find the coefficients of the polynomials. To do this efficiently, we first calculate










a
k

=


s
k




s
_

k






(
64
)










b
k

=



(



s
k




w
_

k


+



s
_

k



w
k



)







=



2


(



Re
(

s
k

)



Re


(

w
k

)



+


Im


(

s
k

)




Im


(

w
k

)




)









(
65
)







c
k

=


w
k




w
_

k






(
66
)






So
,












A
0

=





k
=
0


N
-
1





s
k




s
_

k



=




k
=
0


N
-
1




a
k







(
67
)







B
0

=





k
=
0


N
-
1




(



s
k




w
_

k


+



s
_

k



w
k



)


=




k
=
0


N
-
1




b
k







(
68
)







C
0

=





k
=
0


N
-
1





w
k




w
_

k



=




k
=
0


N
-
1




c
k







(
69
)





And











A
1

=





k
=
0


N
-
1





s
k
2




s
_

k
2



=




k
=
0


N
-
1




a
k
2







(
70
)







B
1

=





k
=
0


N
-
1




2


(



s
k
2




s
_

k




w
_

k


+


s
k




s
_

k
2



w
k



)



=




k
=
0


N
-
1




2


a
k



b
k








(
71
)







C
1

=





k
=
0


N
-
1




(



s
k
2




w
_

k
2


+



s
_

k
2



w
k
2


+

4


s
k




s
_

k



w
k




w
_

k



)


=




k
=
0


N
-
1




(


b
k
2

+

2


a
k



c
k



)







(
72
)







D
1

=





k
=
0


N
-
1




2


(




s
_

k



w
k
2




w
_

k


+


s
k



w
k




w
_

k
2



)



=




k
-
0


N
-
1




2






c
k



b
k








(
73
)







E
1

=





k
=
0


N
-
1





w
k
2




w
_

k
2



=




k
=
0


N
-
1




c
k
2







(
74
)







It is also possible to change the phase relationship between the woofer and speaker by adding some delay to the woofer signal. In this case many more possibilities need to be checked. Fortunately not all the calculations need to be redone for each delay amount.


For a delay amount of n samples let





θ=πn/FFTlength   (75)


so that






e
−jπ(k+start)n/FFTlength
=e
−j(k−start)0

n
=cos((k+start)θn)−j sin((k+start)θn)   (76)


and the woofer response at frequency bin indexed by k changes as





wk→wke−j(k+start)θn.


When calculating the coefficients, some are not affected by this change, in particular










A
0

=




k
=
0


N
-
1





s
k




s
_

k







(
77
)







A
1

=




k
=
0


N
-
1





s
k
2




s
_

k
2







(
78
)







C
0

=





k
=
0


N
-
1





w
k






-

j


(

k
+
start

)





θ
n






w
_

k






j


(

k
+
start

)




θ
n





=




k
=
0


N
-
1





w
k




w
_

k








(
79
)







E
1

=





k
=
0


N
-
1





w
k
2






-
2



j


(

k
+
start

)




θ
n






w
_

k
2





2



j


(

k
+
start

)




θ
n





=




k
=
0


N
-
1





w
k
2




w
_

k
2








(
80
)







The remaining coefficients are affected by the woofer phase change.










B
0

=




k
=
0


N
-
1




(



s
k




w
_

k






j


(

k
+
start

)




θ
n




+



s
_

k



w
k






-

j


(

k
+
start

)





θ
n





)






(
81
)







B
1

=




k
=
0


N
-
1




2


(



s
k
2




s
_

k




w
_

k






j


(

k
+
start

)




θ
n




+


s
k




s
_

k
2



w
k






-

j


(

k
+
start

)





θ
n





)







(
82
)







C
1

=




k
=
0


N
-
1




(






s
k
2




w
_

k
2






-
j






2


(

k
+
start

)



θ
n




+



s
_

k
2



w
k
2





j





2


(

k
+
start

)



θ
n




+






4






s
k




s
_

k



w
k






-

j


(

k
+
start

)





θ
n






w
_

k






j


(

k
+
start

)




θ
n







)






(
83
)







D
1

=




k
=
0


N
-
1




2


(




s
_

k



w
k
2




w
_

k






-

j


(

k
+
start

)





θ
n




+


s
k



w
k




w
_

k
2






j


(

k
+
start

)




θ
n





)







(
84
)







To implement these efficiently we first calculate and store in an array





ak=sksk   (85)






{circumflex over (b)}
k=2(Re(sk)Re(wk))   (86)






{tilde over (b)}
k=2(Im(sk)Im(wk))   (87)





ck=wkwk   (88)


for k=0 to k=N−1 and in the same loop we can calculate










A
0

=




k
=
0


N
-
1




a
k






(
89
)







C
0

=




k
=
0


N
-
1




c
k






(
90
)







A
1

=




k
=
0


N
-
1




a
k
2






(
91
)







E
1

=




k
=
0


N
-
1




c
k
2






(
92
)








C
^

1

=




k
=
0


N
-
1




2






a
k




c
k

.







(
93
)







Next, for each delay t set





θn=πn/FFTlength


and calculate










B
1

=




k
=
0


N
-
1




2






a
k



b
k







(
94
)








C
~

1

=




k
=
0


N
-
1





b
k



b
k







(
95
)







D
1

=




k
=
0


N
-
1




2


c
k



b
k







(
96
)





with











b
k

=




b
^

k



cos


(


(

k
+
start

)



θ
n


)



-



b
~

k



sin


(


(

k
+
start

)



θ
n


)
















and cos((k+start)θn) and sin((k+start)θn) calculated from previous values, except for cos((start)θn) and sin((start)θn), as







[




cos


(


(

k
+
start

)



θ
n


)







sin


(


(

k
+
start

)



θ
n


)





]

=



[




cos


(

θ
n

)





-

sin


(

θ
n

)








sin


(

θ
n

)





cos


(

θ
n

)





]



[




cos


(


(

k
+
start
-
1

)



θ
n


)







sin


(


(

k
+
start
-
1

)



θ
n


)





]


.





Note, however, that cos((start)θn) and sin((start)θn) can also be calculated from previous values of n in a similar way












[




cos


(


(
start
)



θ
n


)







sin


(


(
start
)



θ
n


)





]

=



[




cos


(


(
start
)



θ
1


)





-

sin


(


(
start
)



θ
1


)








sin


(


(
start
)



θ
1


)





cos


(


(
start
)



θ
1


)





]



[




cos


(


(
start
)



θ

n
-
1



)







sin


(


(
start
)



θ

n
-
1



)





]


.






Finally set





C
1
={tilde over (C)}
1

1


and find the minimum variance as before. If this minimum is less than the lowest minimum among the values of n tried so far, it becomes the lowest minimum and the parameters that attain this minimum, gs, gw, n and the filter parameters, are retained replacing the previous set of best parameters. FIG. 14 is a flow diagram depicting an embodiment of another method 1400 for bass management filter selection.


Method 1400 starts at step 1402 and proceeds to step 1404, wherein the method 1400 retrieves the filter response for each filter pair. At step 1406, the method 1400 determines the expected speaker and woofer spectra. At step 1408, the method 1400 calculates parameters ak, bk, ck, A0, C0, A0, C1, and E1. At step 410, the method 1400 calculates B0, B1, C1, D1 and E1 for each delay. At step 1412, the method 1400 finds constrained minimum variance. At step 1414, the method 1400 determines if the results are good. If the results are better than prior results, the method 1400 proceeds to step 1416, wherein the parameters are saved and then proceeds to step 1418. Otherwise, the method 1400 proceeds to step 1418, wherein the method 1400 determines if there are more delays. If there are more delays, the method 1400 proceeds to step 1410; otherwise, the method proceeds to step 1420. At step 1420, the method 1400 determines if there are more filter pairs. If there are more filter pairs, the method 1400 proceeds to step 1404; otherwise the method 1400 proceeds to step 1422. The method 1400 ends at step 1422.


It is sometime useful to add weightings to the frequencies so that each octave has about the same relevance to overall variance as any other octave. This is simply done by applying a weight mk to the data sk and wk before further calculation. Letting ŝk=mksk and ŵk=mkwk the constraint of the such a method becomes













k
=
0


N
-
1









g
s




s
^

k


+


g
w




w
^

k





2


=
N




(
97
)







while the minimization objective becomes













k
=
0


N
-
1





(







g
s




s
^

k


+


g
w




w
^

k





2

-
1

)

2


=

min
.





(
98
)







Also, all else being nearly equal, lower filter pairs may be preferred in order to maximize the amount of the original signal conveyed by the intended speaker. This preference may be achieved by penalizing filter pairs with higher cross-over points. For instance, a function of the filter pair index can be added to the variance to create a composite score. The filter pair and other parameters that produce the lowest score win. Thus, the lower frequency filter cross-over are chosen unless the benefit from higher frequency filter cross-over is significant.


It may be difficult to deal with the logarithmic nature of human hearing. In order to do the calculations, a linear scale may be needed and, thus, the flatness, in terms of variance, is considered on a linear scale. However, low amplitudes can differ significantly on a decibel (dB) scale, even though a linear scale interprets such values as close to zero and not significantly different. One partial solution to this problem is to use the gain that gives minimum variance on a linear scale, but then calculate the variance on a dB scale for the purpose of making a final decision between filter pairs.


Thus, utilizing such methods for selecting bass management filters may occur without trying to determine the cutoff frequencies of the speakers involved. Instead, estimates of the effects of different high-pass/low-pass filter pairs are compared by calculating the expected variance with some weighting and choosing the filter pair, which is expected to produce the best result.


Eliminating the dependence on cutoff frequency is a big advantage since the cutoff frequency is often hard to determine, and is not the only factor in determining which bass management filters perform the best. In one embodiment, the method does not take phase into account, which can affect the result in the cross-over region. However the calculations are much simpler and if the cross-over region is not large, this method can be used. It also determines directly the gain to be applied to the woofer relative to the speaker. If, however, the cross-over region is significant, there is a risk of getting a large hole or bump in the spectrum due to interference between the woofer and speaker. Not only can the phase relationship between woofer and speaker be taken into account, it can be directly manipulated by applying a delay and/or phase inversion (negative gain) to the woofer.


In another embodiment, the method determines the best cross-over for bass management filters and best gain for the woofer relative to the speaker, while also determining the best delay to apply the woofer to improve the phase relationship between speaker and woofer in the cross-over region.


While the foregoing is directed to embodiments of the present invention, other and further embodiments of the invention may be devised without departing from the basic scope thereof, and the scope thereof is determined by the claims that follow.

Claims
  • 1. A method for enhancing bass management selection, the method comprising: retrieving a filter response for at least one filter pair;determining expected speaker and woofer spectra;calculating optimal parameters utilizing the retrieved filter response and the determined spectra;measuring flatness to determine if the result is optimal; andutilizing the determined spectra with optimal result in selecting a bass management filters for each speaker.
  • 2. The method of claim 1 further comprising repeating the method to produce optimal results of the at least one filter pair.
  • 3. The method of claim 1 further comprising changing the phase relationship between the woofer and the speaker by adding a delay to a woofer signal.
  • 4. The method of claim 3, wherein the delay results bass management selection for a speaker making a cross-over with the speaker that is optimally flat.
  • 5. The method of claim 3, wherein the selection of the delay is determined utilizing gs, speaker gain, and gw, woofer gain.
  • 6. The method of claim 3, wherein the delay improves the phase relationship between speaker and woofer in the cross-over region.
  • 7. The method of claim 1, wherein the method accounts for at least one of phase relationship between the loudspeaker and woofer or power from the loudspeaker and woofer.
  • 8. An apparatus for enhancing bass management selection, the method comprising: means for retrieving a filter response for at least one filter pair;means for determining expected speaker and woofer spectra;means for calculating optimal parameters utilizing the retrieved filter response and the determined spectra;means for measuring flatness to determine if the result is optimal; andmeans for utilizing the determined spectra with optimal result in selecting a pair of bass management filters for each speaker.
  • 9. The apparatus of claim 8 further comprising means for repeating the method to produce optimal results of the at least one filter pair.
  • 10. The apparatus of claim 8 further comprising means for changing the phase relationship between the woofer and the speaker by adding a delay to a woofer signal.
  • 11. The apparatus of claim 10, wherein the delay results in bass management selection for a speaker making a cross-over with the speaker that is optimally flat.
  • 12. The apparatus of claim 10, wherein the selection of the delay is determined by accounting for a gs, speaker gain, and a gw, woofer gain.
  • 13. The apparatus of claim 10, wherein the delay improves the phase relationship between speaker and woofer in the cross-over region.
  • 14. The apparatus of claim 8, wherein the method accounts for at least one of phase relationship between the loudspeaker and woofer or power from the loudspeaker and woofer.
  • 15. A computer readable medium comprising software that, when executed by a processor, causes the processor to perform a method for enhancing bass management selection, the method comprising: retrieving a filter response for at least one filter pair;determining expected speaker and woofer spectra;calculating optimal parameters utilizing the retrieved filter response and the determined spectra;measuring flatness to determine if the result is optimal; andutilizing the determined spectra with optimal result in selecting a bass management filters for each speaker.
  • 16. The method of claim 15 further comprising repeating the method to produce optimal results of the at least one filter pair.
  • 17. The method of claim 15 further comprising changing the phase relationship between the woofer and the speaker by adding a delay to a woofer signal.
  • 18. The method of claim 17, wherein the delay results in bass management filter selection for a speaker and woofer making a cross-over with the speaker that is optimally flat.
  • 19. The method of claim 17, wherein the selection of the delay is determined utilizing gs, speaker gain, and gw, woofer gain.
  • 20. The method of claim 17, wherein the delay improves the phase relationship between speaker and woofer in the cross-over region.
  • 21. The method of claim 15, wherein the method accounts for at least one of phase relationship between the loudspeaker and woofer or power from the loudspeaker and woofer.