ESSENCE/Experiment quantization noise

From CompetenceBase
Revision as of 17:03, 19 July 2024 by JoernNettingsmeier (talk | contribs) (Created page with "=Listen to quantization noise= An analog signal is ''continuous'' in time and value. Sampling turns it into a series of measurements which are ''discrete'' in time: a pulse...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Listen to quantization noise

An analog signal is continuous in time and value.

Sampling turns it into a series of measurements which are discrete in time: a pulse train.

Each measurement has limited resolution, depending on the number of bits of the analog-to-digital converter. It is quantized to one discrete value out of 2^N available values, where N is the number of bits the converter has.

The resulting rounding error leads to quantization noise. It creates a noise floor just like we know from analog sources like tape or vinyl records, just usually a lot softer. Each bit gives us around 6 dB of signal-to-noise ratio.

In the following experiment, we will hear how quantization noise sounds.

Step 1: a perfect 16-bit signal

Here is an anechoic recording (that means it was recorded in a chamber where the walls absorb all reflections) of a monologue from Shakespeare's Henry V. Computers cannot do analog, so we have to start with a very high-quality digital signal, with a sampling rate of 48 kHz and a resolution of 16 bits.

This file's quality is so high that you will not hear any quantization noise: original file

Step 2: a 12-bit signal

Now we will turn the level down by 24 dB. As expected, it is very soft now, but we also effectively lost 24 / 6 = 4 bits of information, and 12 bits remain from the original 16.

Now we will amplify it by 24 dB. It gets as loud as before, but we have lost resolution forever. That means our quantization noise floor is now 6 dB higher. That is very difficult to hear except in a quiet studio.

Step 3: an 8-bit signal

Let's turn the original file down by 48 dB. Now we lose 48 / 6 = 8 bits of information, and we now have only 8 bits left.

As we turn it back up by 48 dB for the original volume, the quantization noise becomes very audible.

8 bit is the resolution of vintage gaming computers from the 80s. It was great for playing games, but not so nice for music. It is also roughly the dynamic range for very simple consumer cassette recorders (if you remember those), without any noise reduction engaged.

Step 4: a 4-bit signal

If you are in a loud environment and could only hear subtle effects until now, let's go one step further:

We turn the original down by 72 dB to lose 72 / 6 = 12 bits, so only four bits are left. That means we now have 24 dB of dynamic range between the loudest signal we can handle and the volume of the noise floor. This is worse than anything you ever had to listen to, so the noise should be very obvious as we turn it back to the original volume.

"Noise" or "distortion"

Actually, the comparison of the noise floor is not fair to analog systems. They sound a lot better at the same noise level, because analog noise is random. Digital quantization noise on the other hand is signal-dependent, and that is why it is more correctly called quantization distortion. And distortion always sounds nastier than just random noise.

There is a way to remove quantization distortion completely. This technique is called dither.

Wikidata