NivaarExam PrepOfficial exam papers ↗

22-Elec-A3 Signals and Communications · Undated paper

Question 2 of 5: Non-Uniform (Two-Range) PCM Quantizer Design

Nivaar worked solution (AI-drafted; not reviewed by a licensed engineer)

Notes on this paper

Paper format. National Exams, May 2019 — 16-Elec-A3 Signals and Communications. Three hours, closed book, one approved Casio or Sharp calculator. Five questions, all of equal value; the rubric instructs candidates to answer all 5 questions, so all five are worked in full below.

Reference texts. B. P. Lathi and Z. Ding, Modern Digital and Analog Communication Systems, 4th ed. — the primary EGBC reference for this exam code; B. P. Lathi, Linear Systems and Signals, 2nd ed.; A. V. Oppenheim and A. S. Willsky, Signals and Systems, 2nd ed.; J. G. Proakis and D. G. Manolakis, Digital Signal Processing, 4th ed.; S. Haykin, Communication Systems, 5th ed.

The printed paper fixes two readings: Question 1 specifies the ideal low-pass bandwidth as B = 25 kHz, and Question 2 states that the signal bandwidth is 10 kHz. The paper’s own running header reads “16-Elec-A3/May 2019”, so it is the May 2019 sitting.

Question 2: Non-Uniform (Two-Range) PCM Quantizer Design (20 marks)

Question text not reproduced: the examination questions are © Engineers and Geoscientists BC. Open the official past paper (linked at the top of this page) to read the question, then follow the worked solution below.

Given. Signal bandwidth $W = 10$ kHz; peak value $m_p$ (the answer is expressed as a fraction of $m_p$, which is never given numerically); maximum quantization error $0.001\,m_p$ for $|m_s| \le m_p/2$ and $0.004\,m_p$ otherwise; 20% oversampling above the Nyquist rate.

Find. The step size, threshold list and level count in each zone; the number of bits per sample; and the resulting bit rate.

Approach. A rounding (nearest-level) quantizer of step $\Delta$ has a worst-case error of $\Delta/2$, so each error specification fixes a step size directly. Divide each zone's width by its step to count levels, round the count up where it is not an integer, add the zones, and take $n = \lceil \log_2 L \rceil$ bits.

  1. Convert each error specification into a step size. For uniform quantization with rounding to the nearest level, a sample can lie at most half a step from its representation level, so $e_{\max} = \Delta/2$ and $\Delta = 2e_{\max}$: $$\Delta_{\text{in}} = 2(0.001\,m_p) = 0.002\,m_p, \qquad \Delta_{\text{out}} = 2(0.004\,m_p) = 0.008\,m_p.$$ The inner (fine) step is four times smaller than the outer (coarse) step, which is exactly the companding idea: spend resolution where the amplitude density is highest.
  2. Count the levels in the inner zone. The fine zone runs from $-m_p/2$ to $+m_p/2$, a total width of $m_p$: $$L_{\text{in}} = \frac{m_p}{\Delta_{\text{in}}} = \frac{m_p}{0.002\,m_p} = 500\ \text{levels}.$$ This divides exactly, so the inner step stays at its specified value $0.002\,m_p$ and the inner worst-case error is exactly $0.001\,m_p$.
  3. Count the levels in each outer zone, and round in the safe direction. Each outer zone (from $m_p/2$ to $m_p$, and its mirror image) has width $m_p/2$: $$\frac{0.5\,m_p}{0.008\,m_p} = 62.5\ \text{levels},$$ which is not an integer. The count must be rounded up, not to the nearest integer: taking 62 levels would give $\Delta = 0.5/62 = 0.008065\,m_p$ and an error of $0.004032\,m_p$, which violates the 0.4% specification. Taking 63 levels gives $$\Delta_{\text{out}} = \frac{0.5\,m_p}{63} = 0.0079365\,m_p, \qquad e_{\max} = 0.0039683\,m_p \lt 0.004\,m_p. \checkmark$$
  4. State the quantizer characteristic (part a). With the origin at the centre of the fine zone, the decision thresholds and output levels are:
    Input rangeStepThresholdsOutput levelsCount
    $-m_p \le m_s \lt -m_p/2$$0.0079365\,m_p$$-m_p + k\Delta_{\text{out}}$, $k = 1\ldots62$midpoints $-m_p + (k-\tfrac12)\Delta_{\text{out}}$63
    $-m_p/2 \le m_s \le +m_p/2$$0.002\,m_p$$-m_p/2 + k\Delta_{\text{in}}$, $k = 1\ldots499$midpoints $-m_p/2 + (k-\tfrac12)\Delta_{\text{in}}$500
    $+m_p/2 \lt m_s \le +m_p$$0.0079365\,m_p$$m_p/2 + k\Delta_{\text{out}}$, $k = 1\ldots62$midpoints $m_p/2 + (k-\tfrac12)\Delta_{\text{out}}$63
    Each output level is the midpoint of its interval, which is what makes the worst-case error equal to half the step.
-mp-mp/20+mp/2+mpFINE zoneerror < 0.1% of mpCOARSEerror < 0.4%COARSEerror < 0.4%step size0.007937 mp0.0020 mp0.007937 mplevels6350063total 626 levels => n = 10 bits per sampleinput sample value m(kT)
Figure 2.1 — the piecewise-uniform quantizer. The inner zone |m| ≤ mp/2 is divided into 500 fine steps; each outer zone gets 63 coarse steps. Tick spacing is schematic, not to scale.
  1. Total the levels and size the codeword (part b). $$L = L_{\text{in}} + 2L_{\text{out}} = 500 + 2(63) = 626\ \text{levels}.$$ A unique binary code needs $n$ bits with $2^n \ge L$: $$n = \lceil \log_2 626 \rceil = \lceil 9.29 \rceil = 10, \qquad 2^9 = 512 \lt 626 \le 1024 = 2^{10},$$ $$\boxed{\,n = 10\ \text{bits per sample}\,}$$ A natural assignment is to let the most significant bits identify the zone and the remainder index the level within it; 1024 − 626 = 398 codewords are simply left unused.
  2. Set the sampling rate and bit rate (part c). The Nyquist rate for a 10 kHz signal is $2W = 20$ kHz, and 20% oversampling raises it to $$f_s = 1.20 \times 2W = 1.20 \times 20\ \text{kHz} = 24\ \text{kHz}.$$ Each sample carries 10 bits, so $$R_b = n f_s = 10 \times 24{,}000,$$ $$\boxed{\,R_b = 240\ \text{kbit/s}\,}$$

Check: the level counts above assume a rounding quantizer, for which the worst-case error is half a step. A truncating quantizer has a worst-case error of a full step, which would double every level count to 1252 and push the codeword to 11 bits. The rounding convention is the standard one and is assumed throughout.

ResultValue
Inner (fine) step and levels$0.002\,m_p$; 500 levels over $|m_s| \le m_p/2$
Outer (coarse) step and levels$0.0079365\,m_p$; 63 levels per zone (error $0.00397\,m_p$)
Total quantization levels$L = 626$
Bits per sample$n = 10$
Sampling rate$f_s = 24$ kHz (20% above Nyquist)
Bit rate$R_b = 240$ kbit/s