22-Elec-B3 Digital Communications Systems · December 2016
Question 5 of 5: Sampling and D/A Conversion
Nivaar worked solution (AI-drafted; not reviewed by a licensed engineer) · Last updated
Notes on this paper
Reference texts.
S. Haykin, Communication Systems, 5th ed. — noise and link budgets, information theory and source coding, matched-filter detection, sampling and quantisation.
B. P. Lathi and Z. Ding, Modern Digital and Analog Communication Systems, 4th ed. — PCM, line coding, optimum binary receivers, error probability.
J. G. Proakis and D. G. Manolakis, Digital Signal Processing: Principles, Algorithms and Applications, 4th ed. — sampling theorem, aliasing, quantisation noise.
A. V. Oppenheim and A. S. Willsky, Signals and Systems, 2nd ed. — convolution, time reversal, the Fourier view of sampling.
Question 5: Sampling and D/A Conversion (25 marks)
Given. Compact-disc audio parameters: sampling frequency $f_s = 44.1$ kHz, resolution $n = 16$ bits per sample, and for part (d) a converter input restricted to the range −5 V to +5 V.
Find. (a) the largest signal bandwidth the sampling rate supports; (b) an explanation of PCM and the resulting bit rate; (c) an example of aliasing; (d) the worst-case quantisation error; (e) why perceptually coded audio needs far less rate.
Approach. Apply the Nyquist criterion to bound the bandwidth, multiply sampling rate by resolution to get the PCM bit rate, take half a quantisation step as the worst-case rounding error, and treat parts (c) and (e) as short qualitative arguments grounded in the sampling theorem and in perceptual coding respectively.
Part (a) — Apply the Nyquist criterion. Exact reconstruction of a strictly bandlimited signal requires the sampling rate to be at least twice the highest frequency present, $f_s \ge 2B$, so
$$B \le \frac{f_s}{2} = \frac{44.1\ \text{kHz}}{2}$$
$$\boxed{B_{\max} = 22.05\ \text{kHz}}$$
This is why 44.1 kHz was chosen for the compact disc: it puts the folding frequency just above the roughly 20 kHz limit of human hearing, leaving a 2 kHz transition band for the anti-alias filter.
Part (b) — Compute the PCM bit rate. PCM digitises a waveform in three steps: sample it at a uniform rate $f_s$, quantise each sample to the nearest of $2^{n}$ discrete levels, and encode each level as an $n$-bit binary word, so the analogue waveform becomes a serial bit stream. The rate is therefore the product of the sampling rate and the word length:
$$R_b = f_s \times n = 44\,100 \times 16$$
$$\boxed{R_b = 705\,600\ \text{bit/s} = 705.6\ \text{kbit/s per channel}}$$
Compact-disc audio is two-channel, so the stereo payload is $2\times705.6 = 1.4112$ Mbit/s — the familiar 1.41 Mbit/s figure quoted for uncompressed CD audio.
Part (d) — Find the quantisation step and the worst-case error. A 16-bit converter divides the full-scale range into $2^{16} = 65\,536$ equal levels, so with a range of $+5 - (-5) = 10$ V,
$$\Delta = \frac{V_{FS}}{2^{n}} = \frac{10\ \text{V}}{65\,536} = 152.588\ \mu\text{V}.$$
A rounding quantiser assigns each sample to the nearest level, so the error never exceeds half a step:
$$\boxed{|e|_{\max} = \frac{\Delta}{2} = 76.29\ \mu\text{V}}$$
Assuming the error is uniformly distributed over $\pm\Delta/2$ gives an RMS quantisation noise of $\Delta/\sqrt{12} = 44.05\ \mu$V, and hence the familiar signal-to-quantisation-noise figure $\mathrm{SQNR} \approx 6.02n + 1.76 = 98.1$ dB for a full-scale sinusoid.
Part (c) — an example of aliasing. Aliasing is what happens when a signal component above the folding frequency $f_s/2$ is sampled: the sampled sequence is indistinguishable from that of a lower-frequency tone, and the reconstruction filter therefore produces the wrong frequency. Concretely, feeding a 30 kHz tone into a CD-rate converter without an anti-alias filter yields samples identical to those of a $|30 - 44.1| = 14.1$ kHz tone, so a supersonic component the listener could never have heard reappears as an audible whistle in the middle of the band, as Figure 5.1 shows. The everyday visual counterpart is the wagon-wheel effect in film, where a wheel rotating faster than half the 24 frame/s rate appears to turn slowly backwards; the cure in both cases is the same, namely a low-pass anti-alias filter ahead of the sampler that removes energy above $f_s/2$ before it can fold.
Figure 5.1 — Part (c). A 30 kHz tone (dashed) sampled at 44.1 kHz. The sample values are identical to those of a 14.1 kHz tone (solid), so the reconstructor cannot tell the two apart and outputs the alias.
Part (e) — why MP3 needs far less rate. Because MP3 is a lossy perceptual coder, whereas PCM is an exact waveform representation. An MP3 encoder runs a psychoacoustic model of the listener alongside a filter bank, and wherever a loud component masks a quieter one nearby in frequency or immediately following it in time, the quieter component is coded coarsely or discarded outright — bits are spent only where the ear can detect their absence. The residual coefficients are then entropy-coded, and the exploitation of stereo redundancy between channels removes more. The result is a stream near 128 kbit/s that most listeners cannot distinguish from the 1.41 Mbit/s original, roughly an eleven-fold reduction, at the cost of a bit stream from which the original samples can never be recovered exactly — which is precisely the trade the source coding theorem of Question 2 says must be made if a rate below the source entropy is wanted.
Result
Value
(a) Maximum signal bandwidth
22.05 kHz ($f_s/2$)
(b) PCM data rate, 16 bits/sample
705.6 kbit/s per channel (1.4112 Mbit/s stereo)
(c) Aliasing example
30 kHz tone at $f_s = 44.1$ kHz folds to an audible 14.1 kHz alias
(d) Quantisation step $\Delta = V_{FS}/2^{16}$
152.59 $\mu$V
(d) Maximum quantisation error
76.29 $\mu$V ($\Delta/2$)
Resulting SQNR ($6.02n + 1.76$)
98.1 dB
(e) Why MP3 is smaller
Lossy perceptual coding — masked content is discarded, then entropy coded (~128 kbit/s)