Keeping It Transparent

Hard Clipping and Overload

Hard clipping occurs when too much gain is applied to a signal and it attempts to go beyond the limits of a device’s maximum input or output level. Peak levels greater than the maximum allowable signal level of a device are flattened, creating new harmonics that were not present in the original waveform.

For example, if a sine wave is clipped, the result is a square wave whose time domain waveform now contains sharp edges and whose frequency content contains additional harmonics.

A square wave is a specific type of waveform that is composed of odd numbered harmonics (1st, 3rd, 5th, 7th, and so on). One of the results of distortion is an increase in the numbers and levels of harmonics present in an audio signal.

Technical specifications for a device often indicate the total harmonic distortion for a given signal level, expressed as a percentage of the overall signal level. Because of the additional harmonics that are added to a signal when it is distorted, the sound takes on an increased brightness and harshness.

Clipping a signal flattens out the peaks of a waveform, adding sharp corners to a clipped peak. The new sharp corners in the time domain waveform represent increased high-frequency harmonic content in the signal, which would be confirmed through frequency domain analysis and representation of the signal.

Soft Clipping

A milder form of distortion known as soft clipping or overdrive is often used for creative effect on an audio signal. Its timbre is less harsh than clipping, the shape of an overdriven sine wave does not have the sharp corners that are present in a hard-clipped sine wave.

As is known from frequency analysis, the sharp corners and steep vertical portions of a clipped sine waveform indicate the presence of high-frequency harmonics. Hard clipping distortion is produced when a signal’s amplitude rises above the maximum output level of an amplifier. With gain stages such as solid-state microphone preamplifiers, there is an abrupt change from linear gain before clipping to nonlinear distortion.

Once a signal reaches the maximum level of a gain stage, it cannot go any higher regardless of an increasing input level; thus there are flattened peaks. It is the abruptness of the change from clean amplification to hard clipping that introduces such harsh-sounding distortion.

In the case of soft clipping, there is a gradual transition, instead of an abrupt change, between linear gain and maximum output level. When a signal level is high enough to reach into the transition range, there is some flattening of a signal’s peaks but the result is less harsh than with hard clipping. In recordings of pop and rock music especially, there are examples of the creative use of soft clipping and overdrive that enhance sounds and create new and interesting timbres.

Quantization Error Distortion

In the process of converting an analog signal to a digital PCM representation, analog amplitude levels for each sample get quantized to a finite number of steps. The number of bits of data stored per sample determines the number of possible quantization steps available to represent analog voltage levels.

An analog-to-digital converter records and stores sample values using binary digits, or bits, and the more bits available, the more quantization steps possible.

The Red Book standard for CD-quality audio specifies 16 bits per sample, which represents 216 or 65,536 possible steps from the highest positive voltage level to the lowest negative value. Usually higher bit depths are chosen for the initial stage of a recording.

Given the choice, most recording engineers will record using at least 24 bits per sample, which corresponds to 224 or 16,777,216 possible amplitude steps between the highest and lowest analog voltages. Even if the final product is only 16 bits, it is still better to record initially at 24 bits because any gain change or signal processing applied will require requantization.

The more quantization steps that are available to start with, the more accurate the representation of an analog signal. Each quantized step of linear PCM digital audio is an approximation of the original analog signal. Because it is an approximation, there will be some amount of error in any digital representation. Quantization error is essentially the distortion of an audio signal.

Engineers usually minimize quantization error distortion by applying dither or noise shaping, which randomizes the error. With the random error produced by dither, distortion is replaced by constant noise which is generally considered to be preferable over distortion.

The interesting thing about the amplitude quantization process is that the signal-to-error ratio drops as signal level is reduced. In other words, the error becomes more significant for lower-level signals.

For each 6 dB that a signal is below the maximum recording level of digital audio (0 dB FS), 1 bit of binary representation is lost. For each bit lost, the number of quantization steps is halved. A signal recorded at 16 bits per sample at an amplitude of ₃12 dB FS will only be using 14 of the 16 bits available, representing a total of 16,384 quantization steps.

Although the signal peaks of a recording may be near the 0 dB FS level, there are often other lower-level sounds within a mix that can suffer more from quantization error. Many recordings that have a wide dynamic range may include significant portions where audio signals hover at some level well below 0 dB FS.

One example of low-level sound within a recording is reverberation and the sense of space that it creates. With excessive quantization error, perhaps as the result of bit depth reduction, some of the sense of depth and width that is conveyed by reverberation is lost. By randomizing quantization error with the use of dither during bit depth reduction, some of the lost sense of space and reverberation can be reclaimed, but with the cost of added noise.

Jason Corey is an assistant professor of audio engineering and performing arts technology at the University of Michigan School of Music, Theatre & Dance, and is an active member of the Audio Engineering Society. Go here to find out more and order a copy of Audio Production and Critical Listening: Technical Ear Training.