## Making Music with Computers

### Understanding the decibel as a logarithmic scale

Our understanding of "loudness" is expressed using a logarithmic scale. On this page we want to understand what that means, and to see how that applies to both sound pressure waves and to the meters on a mixing console (virtual or actual).

(Citation: Some examples in the following summary are borrowed from my Peabody Conservatory teacher Alan Kefauver's book The New Recording Studio Handbook.)

### Exponential notation

We know that:

10 X 10 X 10 = 1,000 or 103.

And we know that 0.001 = 10-3, since 0.001 = 1/103, (1/1000) and in any fraction with a power of ten in the denominator, the 10 can be moved to the numerator by changing the sign of its power.   Thus, in this case 1/103 is the same as 10-3/1, or just 10-3.

This form of notation greatly simplifies more complex-looking calculations, for example:

3,200,000 / 0.004 = (32 X 105) / (4 X 10-3) = (32 X 105+3) / 4 = 8 X 108 (note that when multiplying 10 to two different exponents, one simply adds the exponents:  105 * 103 = 108.  Why?  Write out 105 as 100,000 and 103 as 1000.  When you multiply them, how many zeros do you get?).

### The idea of Logarithms

The logarithm of a number is that power to which 10 must be raised (not multiplied) to equal the number. (We will only speak about log base 10 in this discussion).

Thus the (base 10) log of 100 is 2, since 102 is 100, and the log of 1000 is 3, since 103 is 1000.

It follows then that there must be a power of 10 in between 2 and 3, that would result in 10x= 500.

The details of determining 'x' in the above equation need not concern us, fortunately! We simply need to appreciate that the log of 500 in the above equation is x, a number between 2.0 and 3.0, then we can look up that number in a log table stored on your calculator or computer. And by the way, guessing doesn't work because it is not linear. The log of 500 is not 2.5, even though that would seem logical. If you go here, you'll find a logarithm calculator and you can test out various logs and anti-logs.

You'll see then that the log of 500 is 2.6989700043, meaning that 10 2.6989700043 is 500! If you put in the antilog and ask what is ten raised to the power of 2.5, you would get 316.22776602. 102.5 = 316.22776602.

We see then that logarithms are not linear, but plot by what is in fact called a logarithmic curve.

To see this, it is useful to look at the logarithms for the integers 1 to 10.

1 -> 0.0 ; 2 -> 0.301 ; 3 -> 0.477 ; 4 -> 0.602 ; 5 -> 0.699; 6 -> 0.788; 7 -> 0.845; 8 -> 0.903; 9 -> 0.954 10 -> 1;

These floating point numbers answer the question: to what exponent would you need to raise the number 10 to obtain the number, say 8? It turns out that 100.903 = 8.

To what power would we need to raise 10 to obtain the number 2? 100.301 = 2, and so on.

Creating a graph of these points in Max, we get this curve: ...which you'll notice first rises steeply, then begins to taper off. This is a basic logarithmic curve, in contrast to an exponential curve, which looks like: To understand the basics of the decibel scale, you need to understand that:

1) when numbers are multiplied, the log of the product is equal to the sum of the logs of the numbers ...

log (2 X 4) = log 2 + log 4
log 8 = log 2 + log 4
0.903 = 0.301 + 0.602 √

and also these important points:

2) when a number is doubled, the log increases by a constant amount: 0.301 (i.e., by log (2))
3) when a number is multiplied by 10, its log increases by 1 (that is, by log(10).  So since log of 4 is 0.602, then the log of 40 is 1.602, and the log of 400 is 2.602).
4) when a number is squared, its log is doubled

### Acoustic Power Measurements

The logarithmic perception of loudness is built into the human auditory system. Since the logarithms, as mentioned above, between 100 and 1000 are the numbers between 2 and 3, these logs become very useful when discussing sound intensity levels.

The decibel scale is based on the human threshold of hearing:

10-12 watts/m2

Yes, that is an incredibly small number, especially when compared with the sound of a jet aircraft at close range, which is:

10 watts/m2

which, by the way, is about the same intensity level as a stadium rock concert at close range!

We needn't, for this class, understand the physics of the watts/m2, except to understand that it refers to the intensity of a sound wave, and to appreciate that our perception of loudness has a range between the 'zero' reference point at the threshold of the faintest sound we can hear to an intensity level that is 10,000,000,000,000, or 10 trillion times as intense! It's rather amazing that our ears are capable responding to such a wide range of intensities.

Incidentally, our ears are not the only place we can sense sound waves.  At a loud rock concert or a club, you can often feel the bass notes in your body, hitting you with a certain force; this is a strong sound wave with a low frequency (and therefore a long wavelength) moving across space. Thunder would be another, non-harmonic example of this. Thunder rattling your windows is the result of a strong sound wave.

Since it would be most inconvenient to talk of one sound as being, say, 7 million times louder than another, we use the logarithmic decibel scale to vastly simplify our conversation about "loudness." We essentially bring sound pressure waves into a human context and work with our built-in logarithmic perception.

### The Decibel Scale

Here's the deal with working with decibels, and why a basic understanding of logarithms are necessary.

First off, here is what the decibel scale looks like, referenced to everyday acoustic experience:

 "Loudest Sound Possible" 194 dB Jet Engine, close 160 dB Threshold of pain 140 dB Jet Engine, 100' 130 dB Pneumatic Drill 125 dB Rock Concert 120 dB Sandblasting 120 dB NY Subway 100 dB Orchestra, FF 100 dB Truck Traffic 80 dB Busy Street 80 dB Small Orchestra 80 dB Average Conversation 60 dB Average Office 50 dB Subdued Conversation 40 dB Quiet Office 30 dB Rustling Leaves 20 dB Recording Studio 10 dB Threshold of Hearing 0 dB

The interesting question becomes that of "how much louder is something than something else." If a symphony orchestra playing fortissimo is 100 dB, would two orchestras in the same hall be 200 dB? If two rock bands were playing at either end of the arena, fully cranked, would the hall be exploding ear drums at 240 dB?

Well, clearly not, especially since the "loudest sound possible" is proven to be 194 dB, due to the fact that the low pressure of the wave, the rarefraction, would equal a vacuum. Indeed, one chart describes 160 dB at close range as the "instant perferation of the eardrum!"

This is where an understanding of logarithms, and doing a little math, is helpful and interesting.

### Let's do the math

A Bel is an acoustical measurement of the increase in intensity (I) of a sound.  It is expressed as the log of a ratio:

Bel = log (I1 / I2)

The change in loudness represented by a “Bel” turns out to be inconveniently large. It is more convenient to speak in terms of the decibel, (deci-Bel), that is, 1/10th of a Bel (i.e. dB).

Thus an increase in acoustic strength in deci-bel (dB) is 10 * log (I1 / I2). That is, once the log is obtained, we multiply it by 10 to move the decimal point over by one, allowing us to speak about 83 dB rather than "eight point three Bels).

In the chart above, the statement that a strong orchestra has a decibel value of 80 dB really means that its sound is 80 dB greater than the threshold of hearing.  So when we give an absolute measure in decibels, we are measuring the ratio of the intensity of two sound waves, the I1 referring to the sound we are measuring, and the I2 referring to the threshold of hearing, or the reference intensity (IR)  Thus:

dB = 10 log I/IR

We have seen that the threshold of hearing stands at 10-12 watts/m2.

We have also seen, or been told by experts who have measured such things, that a jet engine has a sound intensity of 10 watts/m2 when it’s about 100 meters away.

We calculate the Bel of this wave as follows:

Bel = log (101 / 10-12)

As we saw above, this becomes log (10(1+12)) or log 10,000,00,00,00,000 which looks like a crazy number until you realize, oh, it's just the number 13 -- we've raised 10 to the power of 13, so the log (base 10) of 10,000,000,000,000 (1 with 13 zeroes after it) is just 13. Cool?
We then just multiply that by 10 to get 130 dB.

What about the dB of rustling leaves?

The SIL (sound intensity level) of rustling leaves is 10-10 watts/m2. So that's
10 * log (10-10 / 10-12)** or 10 (log 102) or log 100 = 2, so that's 10 * 2 or 20 dB.

**(10-10 / 10-12) = 10-10+12 = 102.

So rustling leaves is 2 Bels (log of 102), or 20 dB.

### How loud is "twice as loud" (How do loudnesses add?)

So now we need to understand how the decibel relates to our common experience of something being "twice as loud" as something else. We've already surmised that two rock bands is not 2 X 120 dB. Two "subdued conversations" (each at 40 dB) in a room does not suddenly make the room as loud as heavy traffic at 80 dB! So what's going on here?

Well, again, it has to do with the logarithmic scale.

Imagine one of those air traffic workers on the tarmac who guide the planes in to the gate. We certainly understand why they are wearing those protective headphones since the plane we are on is generating 130 dB of sound pressure level to our friend on the ground. What will happen to her when another plane pulls along side? Do her headphones need extra super-protection when there are two planes?

Well, it turns out that the sound of two planes is "a mere" 133 dB. A doubling in sound intensity is only a 3 dB change in decibel level. Here's the math on that:

One jet produces 10 watts/m2. Two airplanes double the wattage (roughly speaking), so our air traffic worker is now subjected to 20 watts/m2 if both planes are at the same distance of roughly 100 meters from her.

How much, in dB, is 20 watts/m2 compared to 10 watts/m2?

Well, we want to take to this same formulation for finding the decibel of an airplane and express it in terms of 2 airplanes thus:

10 * log (2 X 101 / 10-12) , which give us 10 * log (2 X 101+12), which give us
10 * log (2 * 1013)

which can be manipulated algebraically, through distribution, to give us
10 * [log (2) + log (1013)]
(see above: "when numbers are multiplied, the log of the product is equal to the sum of the logs of the numbers ... ")

Well, the log of 2 (see chart above) is .301 (10.301 = 2) and the log of 1013 is, of course, 13.

This gives us: 10 * [0.301 + 13.0] = 10 * 13.301 = 133.01 or approx. 133 dB.

Bingo: two planes pulling up on either side of our friend on the tarmac only subjects her to an additional 3 dB of perceptible sound pressure increase. She's still below the threshold of pain, even without the protective earphones!

Interestingly, it turns out that increasing a sound’s intensity by a factor of 2 (i.e., by 3 dB) does not make it sound twice as loud!  As a rough rule of thumb, researchers have found that in order to increase the intensity so that a sound is perceived to be twice as loud, we must increase its dB level by about 10 dB – which means we need to increase its intensity by a factor of 10, not 2.  So if an orchestra has 5 violins playing as loudly as they can, and the conductor wants the sound to be twice as loud, the orchestra will need 50 violins!

Returning to more normal levels of monitoring, if we were to tell someone to make the music coming through the speakers "twice as loud," and we were to actually monitor the sound intensity levels in the air, these levels would be about ten times greater than before, which equates to an actual 10 dB change in SIL.

### How loud is "a little louder"

If we increase the intensity of a sound by 5% (i.e., increase the SIL by 0.2 dB), would a listener notice?  Probably not.  Though the sensitivity to change varies with different circumstance, it usually takes an increase of between 0.4 and 1 dB before a listener will be sure that the loudness has increased.  That’s an increase in intensity of between 10% and 25%.  So if our orchestra conductor has 20 violins playing, adding only 1 more (a 5% increase) won’t be noticed by the audience – unless, of course, that last violinist is hitting lots of wrong notes.  Does this make sense, experientially? If 8 people are talking in a room, and 8 more people come in and have a conversation at about the same conversational level, the sound intensity will have doubled – i.e., the level has risen 3 dB.  That’s certainly enough to be noticed, but not enough to make the conversation actually sound "twice as loud."  Of course, the extra people will make it harder for conversational partners to hear one another, so they are all likely to talk louder.

### Addendum: Inverse Square Law

While this bit doesn't involve us much in music making with computers, it's nice to appreciate an application of the inverse square law. Imagine that our air traffic person moves from 100 meters to 200 meters away from the planes. The sound radiating away from the planes has not changed, but that sound is radiating outward in a sphere, covering an area that is now 4 times greater than it was.  (The surface area of a sphere, like the area of a circle, is proportional to radius2, so doubling the radius will increase the area by a factor of 4.)  Since the same acoustic power (the Watts in W/m2) is now spread over 4 times the area (the mq ), the intensity will have decreased by a factor of 4.

As this is a decrease in intensity by a factor of 4, if follows that the SIL will diminish in this case by 6 dB.  That’s not quite enough of a decrease to make the sound “half” as loud.  To get to the distance where the sound appeared only half as loud, we’d need to multiply the distance by a bit more than a factor of 3; if our airport worker started 100 meters from the plane, she’d find it was half as loud when she’d moves to a total of 316 meters away from the plane.

Thus, according to the inverse square law, every time we double the distance away from a sound source in an open space, the level of sound will drop 6 dB. Not that important for our work, but pretty important if you're planning to run sound for an outdoor rock concert!

### The decibel in computer music

If this were a class on recording techniques, there would be a lot more to say about decibels in reference to real, physical recording consoles.

However, as this is a computer music class and you all will only be working in virtual space, with virtual mixing consoles, we need only concern ourselves with one more piece of information. This has to do with the monitoring meters in Max and in Ableton, Reason and any other commercial DAW (Digital Audio Workstation).

Here's the VU meter in Max. It simulates a typical ballistic metering device on an analogue mixing board. Here, "VU" stands for Volum Unit, and is a standardized divice displaying a representation of the signal level in audio equipment.

This graphic, borrowed from Wikipedia, shows how a VU meter averages peak responses (such as a drum hit). A VU meter, then, is designed to have a slower response to instantaneous peak input level, as found in drum hits.

We can see here that a full signal, at a value of 1.0, going into the VU meter, results in a sound level of 3 dB, but that this level is actually in the red. We see in the next graphic that a signal at the level of .707 results in an output exactly at 0 dB. This is historically how these meters were constructed. Specifically, it measured the voltage level of 1 mW of power in a 600 ohm resister, which dated back to the days of telephone audio circuits. It remains the case today, even in a virtual Max meter. What is considered to be "zero" dBu is the ideal maximum strength for an audio signal, delivered without distortion.** Note too that a level at 0.5 results in a dB level of -3 dB. **Here's the math on that:

The voltage drop across a 600 ohm resister through which 1 milliwatt (1 X 10-3) of power is being dissipated is the standard studio zero reference level. Using the formula P = V2/R, we discover that P = √(0.6) = 0.7.

### Professional and commercial audio signals

This is a little something about understanding the different rates or professional and commercial audio equipment. COMING SOON.

• Topics

• Assignments

• Terms