Comb Filtering in Rooms: Part 1

Comb filtering is a type of “interference.” Interference can be parsed into two categories: constructive and destructive.
Screen Shot 2014-10-20 at 10.27.55 AM       Screen Shot 2014-10-20 at 10.33.12 AM
In the graphs above, the bold line is the sum of mathematical signals. You might be wondering where the bold line is in the second graph. In the second graph, the sum of the two signals was destructive, and the amplitude of the signal was reduced to zero. In the first graph, the sum of the signals was constructive, and the amplitude increased by a factor of 3. The featured image at the top of this post shows the two individual signals that were summed to make the second graph. When one is up, the other is down, and always by the same amount. Imagine that the bold line is a copy of the lighter line that we dragged to the left. We can describe this mathematically by saying the signals are 180° out of phase. But imagine that we kept dragging the bold line farther and farther to the left. The two lines would eventually line up with each other (now you’ve shifted the signal 360°). If we kept going, they would become out of phase again (now you’ve shifted the signal 540°). When a copy of a signal is shifted by an odd number multiple of 180° and summed with the original signal, the signals will cancel with each other. This is the basis of comb filtering.

Until now we’ve been talking about shifting signals in terms of degrees. Now we are going to talk about shifting signals in time. Delaying a signal by 180° is equivalent to delaying it by half of the signal’s period. Let’s imagine that we’re listening to a piece of music on a pair of speakers. The spectrum of human hearing ranges from 20Hz to 20,000Hz. Now we move one speaker so that it is one foot farther from our ears than the other speaker. We have now delayed one signal. Given that each speaker is likely producing frequencies from around 40Hz to 18,000Hz, it is likely that the delay we created is half of the period of some frequency, and is therefore being canceled. It is also likely that other frequency’s half periods are odd numbered multiples of the delay, and will be canceled as well. Can you guess which ones? I can’t! So I derived a mathematical formula for it.

First, we need an expression for an odd number multiple. Any number multiplied by 2 is even. Any even number plus 1 is odd. So (2n+1), (where n is a whole number greater than or equal to 0; n = 0, 1, 2, 3, …) is an expression for odd number multiples. We are interested in situations where a signal is delayed by half of the frequency’s period. So here’s the math.

Delay = Δ seconds;  Period = T seconds; Frequency = f Hz  (Δ is the capital greek letter “Delta.”)

Δ/T = (180°(2n+1)) / 360° –This is a ratio that says our delay divided by our period is the same as an odd number multiple of 180° divided by 360°.

*******You might wonder why I don’t say Δ/T = (1/2)(2n+1). After all, that expression means that the delay is half of the period and is much simpler. I’m using the degrees to relate it to what we learned about interference before.********

You might know that T = 1 / f.

So f*Δ=(180°(2n+1)) / 360°

HERE’S THE FORMULA

Therefore: f = (180°(2n+1)) / (360°*Δ)   Now just plug in your delay time and values of n to find out which frequencies are canceled.

Let’s say your copied signal is delayed by .0005 seconds (aka half a millisecond). When n = 0,1,2,3,4,… f = 1000,3000,5000,7000,… respectively.

Ouch. Those are all frequencies you’d want to be hearing when you’re mixing audio. Comb filtering is something we should be concerned about.

Now we know how time delay corresponds to frequency cancellation. But how does time delay happen in listening environments? One obvious place is the difference in distance from your speakers to your ears, but a more subtle case is reflections from walls. This will be the subject of the next post.