I intend to explain a very powerful concept in data conversion: the Sigma-Delta loop. Before I do so, I will describe quantization noise (which sigma delta loops attempt to alleviate).

Quantization noise occurs during the analog-to-digital conversion (ADC) process. Since an analog signal can attain any value, it has infinite precision. This infinite precision excludes the fact that all analog signals have some amount of circuit noise that limits their precision. On the other hand, digital signals are represented as 0s and 1s—and a finite combination of them. As a result, during the conversion, we go from an infinite precision to a finite precision. The resulting error in this rounding is called quantization noise.

We will analyze 3 examples of quantization, and analyze the noise both in the time domain and in the frequency domain.

Sampled Sinusoid

Our first example of quantization is that of an infinitely precise sinusoid. In this case, we are sampling this sinusoid at 16x its frequency. The sinusoid frequency is 1/16 Hz. The sampling rate is 1 Hz. So, for every cycle of the sinusoid, we get 16 samples:

timesin(2*pi*t/16)Rounded (4-bit)Error
00.000000.0000.00000
10.382680.375-0.00768
20.707110.7500.04289
30.923880.875-0.04888
41.000001.0000.00000
50.923880.875-0.04888
60.707110.7500.04289
70.382680.375-0.00768
80.000000.0000.00000
9-0.38268-0.3750.00768
10-0.70711-0.750-0.04289
11-0.92388-0.8750.04888
12-1.00000-1.0000.00000
13-0.92388-0.8750.04888
14-0.70711-0.750-0.04289
15-0.38268-0.3750.00768
160.000000.0000.00000

The important thing to note is that the error (since it is solely dependent on the sinusoid) is periodic. It repeats every 16 samples. (In fact, it inverts itself every 8 samples.)

This periodicity results in tones of the sinusoid in the spectral analysis of the samples:

Sum of Four Prime Sinusoids

In this case, we sum 4 sinusoids, of frequency 1/15 Hz, 1/16 Hz, 1/17 Hz, and 1/19 Hz.

Time(sin(2*pi*t/15)+sin(2*pi*t/16)+sin(2*pi*t/17)+sin(2*pi*t/19))/4Rounding (4-bit)Error
00.000000.0000.00000
10.368840.3750.00616
20.684540.625-0.05954
30.901820.875-0.02682
40.989911.0000.01009
50.937080.875-0.06208
60.752170.750-0.00217
70.463190.5000.03681
80.112950.1250.01205
9-0.24741-0.250-0.00259
10-0.56604-0.625-0.05896
11-0.79809-0.7500.04809
12-0.91215-0.8750.03715
13-0.89463-0.8750.01963
14-0.75140-0.7500.00140
15-0.50644-0.5000.00644
16-0.19792-0.250-0.05208
170.127900.125-0.00290
180.423680.375-0.04868
190.648020.625-0.02302
200.771470.750-0.02147
210.780400.750-0.03040
220.678500.625-0.05350
230.485550.5000.01445
240.233810.2500.01619
25-0.037300.0000.03730
26-0.28741-0.2500.03741
27-0.48136-0.500-0.01864
28-0.59414-0.625-0.03086

You’ll notice that in this case, the quantization error does not repeat. It will repeat eventually (after 77520 samples)—because that is when the input repeats. In our little observation window, things look random. The point of this example is that depending on the complexity of the input, the quantization noise can look random:

We don’t merely see harmonics of each input—we see complex inter-modulations of these tones. I dislike the term inter-modulation in this case since there are really no polynomial non-linearities in the quantizer. In fact, one cannot see any pattern to the resulting non-linearities: they are not stronger near the harmonics of the tones, exhibiting trailing side-bands that are characteristic of true inter-modulation.

In fact, I often wonder as a circuit designer if our methods of applying a sinusoid and computing noise and distortion are overly conservative. Agreed, they give us insight in the workings of the circuits. But, do they accurately predict the behavior of the system for (say) CDMA or OFDM modulation on it? What if we add a GSM or VSB adjacent channel?

Sinusoid with Random Noise

Our final case is a sinusoidal input (such as in the first example) with added random noise to it.

timesin(2*pi*t/16)+noiseRounded (4-bit)Error
00.158390.125-0.03339
10.518630.500-0.01863
20.766470.750-0.01647
31.102451.1250.02255
41.079411.1250.04559
51.044851.000-0.04485
60.812840.8750.06216
70.480700.5000.01930
80.156750.125-0.03175
9-0.23475-0.250-0.01525
10-0.55725-0.5000.05725
11-0.83914-0.875-0.03586
12-0.84315-0.875-0.03185
13-0.80978-0.7500.05978
14-0.69691-0.750-0.05309
15-0.33005-0.375-0.04495
160.130320.125-0.00532

I have chosen the noise to be large enough to overwhelm the input. In this case, the error no longer looks periodic. Its statistics are basically dictated by the noise, not the signal.

In this case, there is no tonal quality to the quantization noise—not even over large periods of observation (in contrast to the previous example). In fact, this method of adding noise (called dither) is often used in audio equipment, since audiophiles have a larger aversion to tonal distortion than to random noise.

There’s no free lunch here. The overall spectrum exhibits more total error (the added dither plus the quantization noise) than in the first example—we have improved the quality of the overall noise, but not the quantity:

In contrast, the sigma-delta loop randomizes noise by introducing a chaotic memory element. I will explain the sigma-delta in detail in the future posts.