All-Pass Filters and Time Delay

This post is largely based on information from patent applications reviewing prior art in the field, and on information provided by Andy Wehmeyer of Audiofrog. Compared to the source material, this has been greatly simplified and edited.

The core issue with stereo in cars is that sounds from stereo loudspeakers sound different at different listening positions. These variations have three main causes:

  1. The difference in time taken for the sounds from each speaker to arrive at, and then acoustically sum at, the listening position. (When the same sound comes from both left and right speakers at the same time at the same loudness, that should create a phantom center image).
  2. The varying dispersion patterns of loudspeakers from various angles.
  3. The intensity of the speaker drivers in closer proximity to the listener.

Points 2 and 3 are not addressed here.

Time-arrival differences at a listening position cause phase differences, which vary with frequency. For the following discussion, the term “inter-loudspeaker differential phase” (IDP) is used to describe the varying difference in phase. IDP predominantly affects the frequency response of the center image (which must be played by both speakers equally) and does not affect sounds which are on the far edges of the stage, which are played only by one speaker or the other.

A listener located equidistant from the two loudspeakers doesn’t hear any IDP, because sounds presented by both loudspeakers take the same amount of time to reach the listener. A listener offset from a pair of stereo loudspeakers – that is, where a listener is closer to one of the loudspeakers – hears the effects of IDP. The difference in path lengths for the sound to travel will be called the path-length difference, or PLD.

Frequency Response in Various Listening Positions with Effects of IPD

Variations in IDP result in audible and undesirable effects, including comb filtering and blurring of imaging. The image above shows the spatial relationship of two listening positions, each offset symmetrically in relation to two loudspeakers, and how the IDP varies with frequency for each of the two listening positions.  Some frequencies are predominantly in phase, some are predominantly out-of-phase. The frequencies where the IDP is predominantly out of phase cause undesirable audible effects, including blurring of imaging.

A simple solution is to delay the signals presented through the closer loudspeaker. The amount of delay used causes signals presented through both loudspeakers arrive at a listener’s ears at the same time. The result is that the IDP for the listener is zero, and the listener experiences no undesirable imaging artifacts.

One-Seat Time Delay

Delay, however, is not suitable for two in-car listeners—that is, where one listener is closer to the left loudspeaker, and the other listener is closer to the right loudspeaker. In a car, correcting the IDP for one listener by using delay makes the experience worse for the other listener – due to an increase of IDP. “The resulting effect can be unnatural enough as to cause the other listener significant discomfort.” (Dolby Labs, 2007)

Phase EQ

An alternative to time correction is to adjust, or equalize, the phase of various frequencies.

Note: For this analysis, phase values are limited to between −180 and 180 degrees, giving a total range of 360 degrees. In this article, frequencies closer to 0 degrees phase than −180 or 180 degrees (i.e., between −90 and 90 degrees) are considered “in phase”. Frequencies closer to −180 or 180 degrees than 0 degrees (i.e., between 90 and 270 degrees or between 90 and −90 degrees) are considered “out of phase”, or canceling. So “in phase” means there isn’t a huge hole, even if the sum isn’t as loud as it would normally be.)

It is widely accepted that the human hearing is sensitive to phase differences up to approximately 1500 Hz. Thus, below approximately 1500 Hz, IDP leads to significant distortion of the stereo center image. This is in addition to the magnitude distortion due to comb filtering, which is audible both below and above 1500 Hz.

In the vehicle environment described above, the comb filtering effect can be distinctly heard for frequencies below approximately 4 kHz. This is because the width of the peaks and notches – approximately 500 Hz in width – is equivalent to or larger than the critical bandwidth  humans can discern. Above approximately 6 kHz, we only discern wider bandwidths than that (since narrower bandwidth variations are caused by normal head motions and our brains learn to ignore such issues) and so the comb filtering effect becomes essentially inaudible.

Some advocate adjusting the IDP up to approximately 6 kHz. This may be achieved by adjusting phase at multiple frequencies, thus correcting the inter-loudspeaker differential phase at each listening position. Once applied, the resulting IDP observed at the listening position ideally is within plus/minus 90 degrees for both listeners Reducing the IDP in that manner significantly improves perceived imaging, and reduces the magnitude distortion – from very audible comb filtering with deep wide nulls, to a relatively benign ripple of plus/minus 3 dB that is substantially inaudible for most listeners.

One method is to add 180 degrees to the IDP in one or two involved bands of frequencies. The result is that the corrected IDP for both listeners is between −90 and 90 degrees in the involved band of notes. That is, frequencies below 1 kHz are predominantly “in phase” for each listener, and the listeners experience greatly improved imaging. The main deficiency with such methods is that they ignore the IDP at higher frequencies where phase correction can also be beneficial.

This is done using a second-order all-pass filter. Here is an approximation of the net effect of a second-order all-pass filter (the circularity of phase is not described here):

Second-order All-pass filter on One Channel of a Stereo Pair

The use of an all-pass filter introduces some amount of delay. One way to make the delay equivalent for each listener is to use an all-pass filter on one channel for the initial cancellation null @~200Hz, and another for the second cancellation band.

The image below shows an idealized representation – the sounds are now predominantly in phase for both listening positions @ ~200 Hz, so the image is much improved. However this method ignores frequencies higher than 200 Hz, and only addresses the single largest cancellation.

Most implementations of all-pass filters found in our in-vehicle testing address the primary 200Hz null, and some the secondary null.

Single 2nd-order All-pass filter @ 200 Hz Partially Correcting IPD

Multiway Speaker Systems

Many vehicles also use multi-way loudspeaker systems to reproduce the full range of audible frequencies. Low frequency loudspeakers typically are placed low in the doors, and mid/high frequency loudspeakers are placed either high on the doors or on the front dashboard. In these multi-way loudspeaker configurations, the Path Length Difference to the listener for the low frequency loudspeakers is often different than the PLD for the mid/high frequency loudspeakers. In this situation, and if the crossover frequency is low enough to be within the frequency range of the bands being phase adjusted, no single pair of filters can designed that works for both the low frequency and mid/high frequency loudspeakers. This problem can be addressed a number of ways.

First, because the human auditory system is more phase sensitive at lower frequencies, the path-length difference to the low-frequency loudspeakers may be used for the calculation to apply phase EQ correction, and then the upper frequency limit of the phase-adjusted bands may be avoided with the crossover filters. In these scenarios, we may see a first-order all-pass filter used instead of a second-order all-pass filter:

First-order All-pass Filter

Second, this method may be used multiple times to create separate filters tailored for each of the low and mid/high loudspeaker pairs. In this way, each of the low or mid/high loudspeaker pairs has filters that only adjust bands that fall in the frequency range of the loudspeakers, and each phase correction filter is designed based specifically for the PLD of that speaker pair.

Conclusion

Time delay can correct IPD effects for just one listening position. The use of time delay corrects for frequency response through the entire audible range, but the tradeoff is very poor performance from the other front seat (usually the passenger seat). All-pass filters can be used to essentially equalize phase and be effective at multiple positions, but their tradeoff is that multiple all-pass filters must be used to be effective at the most significant frequencies, and rarely do implementations correct up to the 6kHz threshold of audibility of IPD effects. There are also time-delay side effects of using a single all-pass filter on one channel to be accounted for.

Leave a Reply