Library
Back to reading

What Is Quantization?

What Is Quantization Error?

Preview: Learn more about quantization and quantization error.

Quantization is the process of converting a continuously varying analog signal into a finite number of discrete amplitude levels. It is one of the fundamental steps in converting analog information into digital form and lies at the heart of every digital communication system. Whenever sound is recorded by a smartphone, music is stored on a computer, or an analog sensor is connected to a digital processor, quantization is almost certainly taking place.

Most naturally occurring signals vary continuously. The voltage produced by a microphone, for example, changes smoothly in response to sound waves, while the output of a temperature sensor varies continuously as the temperature changes. Digital systems, however, cannot represent an infinite number of possible values. Instead, they must approximate each measured value by selecting the nearest value from a finite set of predetermined levels. This approximation is known as quantization.

Quantization follows the process of sampling. Sampling determines when the analog signal is measured, while quantization determines what numerical value is assigned to each sample. Together, these two operations form the basis of analog-to-digital conversion, allowing continuous physical phenomena to be represented as sequences of binary numbers that can be processed, stored, and transmitted digitally.

The number of available quantization levels depends upon the number of bits assigned to each sample. A system using 8 bits can represent 256 different amplitude levels, while a 16-bit system provides 65,536 levels. Increasing the number of bits reduces the spacing between adjacent levels, allowing the digital representation to more closely match the original analog signal.

Because the available levels are finite, quantization inevitably introduces a small error. The difference between the actual analog sample value and the nearest available quantization level is known as quantization error or quantization noise. This error is unavoidable whenever analog signals are converted into digital form, although it can usually be made sufficiently small that it is imperceptible in practical applications.

One useful analogy is to imagine measuring someone's height using only whole centimetres. If a person's actual height is 175.4 cm, it might be recorded as either 175 cm or 176 cm. The recorded value is very close to the true value but not exactly the same. Quantization works in much the same way, except that the measurement applies to the amplitude of an electrical signal rather than to physical height.

The magnitude of quantization error depends primarily on the number of quantization levels. Increasing the number of bits per sample reduces the size of each quantization interval and therefore decreases the maximum possible error. This is one reason why professional audio recording often employs 24-bit quantization, while compact discs use 16 bits and many telephone systems use only 8 bits, reflecting the differing quality requirements of each application.

In many practical systems, quantization error behaves like a small amount of random background noise. For signals that occupy many quantization levels, this quantization noise is usually much smaller than the desired signal and has little effect on perceived quality. However, if too few bits are used, the error becomes more noticeable, producing audible distortion in audio systems, visible artefacts in images and video, or reduced measurement accuracy in instrumentation.

Engineers employ several techniques to minimise the effects of quantization error. Simply increasing the number of bits provides the most direct improvement, but this also increases storage and transmission requirements. Alternative techniques, such as companding, allocate the available quantization levels more efficiently by providing finer resolution for small signals than for large ones. This approach is widely used in digital telephone systems to improve speech quality while maintaining relatively low bit rates.

Quantization is used throughout modern technology. Digital audio recorders, compact discs, smartphones, digital cameras, television systems, medical imaging equipment, industrial control systems, satellite communications, and wireless networks all rely upon analog-to-digital converters that perform quantization many millions of times each second. Without quantization, it would not be possible to process real-world analog signals using digital electronics.

It is important to distinguish quantization from sampling. Sampling determines how frequently the signal is measured and is governed by the Nyquist sampling criterion. Quantization determines how accurately each individual sample is represented. Increasing the sampling rate improves the ability to represent rapidly changing signals, whereas increasing the number of quantization bits improves the precision of each measurement. Both processes are essential for accurate analog-to-digital conversion.

Quantization and quantization error therefore represent fundamental concepts in digital communications and signal processing. Although quantization inevitably introduces a small approximation error, it enables continuous analog information to be represented efficiently using digital numbers. By carefully selecting the sampling rate and the number of quantization levels, engineers can ensure that the resulting digital representation is virtually indistinguishable from the original signal, making quantization one of the key technologies underlying the modern digital world.

Back to reading