25-Comp-B5 Computer Communications · December 2016
Question 1 of 7: Sampling and Aliasing
Nivaar worked solution (AI-drafted; not reviewed by a licensed engineer)
Notes on this paper
98-Comp-B5, Computer Communications — National Exams, December 2016. Closed-book, 3 hours; seven questions of equal value (20% each); ANY FIVE constitute a complete exam (all seven answered below as a complete study resource).
Reference texts: Stallings, Data and Computer Communications, 10th ed. — sampling and aliasing (Ch.5, Q1), Shannon–Hartley channel capacity (Ch.3, Q2), LAN/network topologies (Ch.16, Q3), decibels and signal-to-noise ratio (Ch.3, Q4), IP addressing and subnetting (Ch.18, Q6), and physical/link/network-layer terminology (Ch.3, 9, 11, 17, Q7); Kurose & Ross, Computer Networking: A Top-Down Approach, 8th ed. — error detection via CRC (Ch.5, Q5), IP addressing (Ch.4, Q6), and TCP/IP terminology (Ch.1, Q7).
Given. Signal frequency $f_0 = 60\text{ Hz}$; sampling frequency $f_s = 400\text{ Hz}$; peak-to-peak amplitude $10\text{ V}$.
Find. Two other sinusoid frequencies whose samples at $f_s$ are indistinguishable from the samples of the $60\text{ Hz}$ tone, why this happens, and how to deal with it in practice.
Approach. A sampled sinusoid is indistinguishable from any other sinusoid whose frequency differs by an integer multiple of the sampling frequency ($f = n f_s \pm f_0$); the two smallest such "images" of $f_0=60\text{ Hz}$ at $n=1$ are the ones asked for.
State the aliasing (image-frequency) relation. For a real sinusoid sampled at $f_s$, every frequency $f = n f_s \pm f_0$ ($n=1,2,3,\ldots$) reproduces the same sequence of sample MAGNITUDES as $f_0$, because $\sin\!\big(2\pi (n f_s \pm f_0) t\big)\big|_{t=k/f_s} = \sin\!\big(2\pi(\pm f_0)k/f_s + 2\pi nk\big)$, and the added $2\pi nk$ term (an integer multiple of $2\pi$) vanishes at every sample instant.
Evaluate the two smallest images ($n=1$).
$$f_{\text{alias},1} = f_s - f_0 = 400 - 60 = \boxed{340\text{ Hz}}$$
$$f_{\text{alias},2} = f_s + f_0 = 400 + 60 = \boxed{460\text{ Hz}}$$
The $460\text{ Hz}$ tone reproduces the $60\text{ Hz}$ samples with no phase adjustment; the $340\text{ Hz}$ tone reproduces them only after a $180^{\circ}$ phase flip (equivalently, opposite amplitude sign) — a $340\text{ Hz}$ sinusoid of the opposite sign lands on exactly the same sample points as the $60\text{ Hz}$ wave every $T_s = 1/400 = 2.5\text{ ms}$, as plotted below.
Why this happens. This is aliasing (frequency folding): sampling a continuous signal is equivalent, in the frequency domain, to replicating its spectrum at every multiple of $f_s$. Because $f_s=400\text{ Hz}$ is being asked to represent tones spaced $400\text{ Hz}$ apart, the sampler cannot tell $60\text{ Hz}$, $340\text{ Hz}$ and $460\text{ Hz}$ apart — all three collapse onto the same discrete-time sequence of numbers.
How to deal with it in practice. Satisfy the Nyquist sampling criterion for every frequency component actually present in the signal ($f_s > 2f_{\max}$), and, since real signals always carry some out-of-band noise or interference, place an anti-aliasing low-pass filter ahead of the sampler/ADC to attenuate any energy above $f_s/2$ before it can fold back into the band of interest.
Fig. Q1 — the 60 Hz signal (solid blue) and its two 400 Hz aliases (460 Hz same-phase, 340 Hz phase-flipped, both dashed) coincide at every sample instant (black dots), so the sampler cannot tell them apart.
Quantity
Value
Alias frequency 1
340 Hz
Alias frequency 2
460 Hz
Phenomenon
Aliasing (frequency folding)
Mitigation
Sample above the Nyquist rate ($f_s>2f_{\max}$) and use an anti-aliasing low-pass filter