Exercises: 1. Detection
Work out your answer before opening a solution. Each exercise has three options and exactly one correct answer; the solution explains the choice.
For additive channels, noise is independent of the input unless stated otherwise. We use ${\rm Re}(X)$ and ${\rm Im}(X)$ for real and imaginary parts, $\ln$ for the natural logarithm, and $\operatorname{erfc}(u)=\frac2{\sqrt\pi}\int_u^\infty e^{-t^2}\,dt$ for the complementary error function. Answers may be left in terms of $\operatorname{erfc}$. Assign probability-zero decision boundaries arbitrarily; for ties with positive probability, follow the rule in the exercise. Symbols in Gaussian and uniform-noise examples represent amplitudes, with $E_{\rm s}=\mathrm E|X|^2$ and SNR equal to energy divided by total noise variance. Exponential-channel inputs represent energies, with the mean-energy convention stated in each exercise.
Exercise 1.1.
A bit-flipping channel (BSC) has crossover probability $p=\tfrac1{10}$, and the input bit is $0$ with probability $\Pr(X=0)=\tfrac45$. What does the MAP detector decide when $y=1$ is received, and what is the posterior probability $\Pr(X=1\mid Y=1)$?
(a) It decides $\hat x=0$, and $\Pr(X=1\mid Y=1)=\tfrac{1}{5}$.
(b) It decides $\hat x=1$, and $\Pr(X=1\mid Y=1)=\tfrac{9}{10}$.
(c) It decides $\hat x=1$, and $\Pr(X=1\mid Y=1)=\tfrac{9}{13}$.
Show solution
The correct answer is (c) ★
The MAP detector compares the joint scores $\Pr(x)W(y|x)$. At $y=1$ they are $\tfrac45\cdot\tfrac1{10}=\tfrac{2}{25}$ for $x=0$ and $\tfrac15\cdot\tfrac9{10}=\tfrac{9}{50}$ for $x=1$, so MAP decides $\hat x=1$ despite the unequal priors. At $y=0$ the scores are $\tfrac{18}{25}$ and $\tfrac1{50}$, so MAP decides $0$. Hence MAP and ML coincide, $g(y)=y$, with $P_{\rm e}(0)=P_{\rm e}(1)=P_{\rm e}=\tfrac1{10}$.
By Bayes' rule, $\Pr(X=1\mid Y=1)$ is the score of $x=1$ divided by $\Pr(Y=1)=\tfrac2{25}+\tfrac9{50}=\tfrac{13}{50}$, which gives $\tfrac{9/50}{13/50}=\tfrac9{13}$. Option (a) uses the prior alone, and option (b) confuses the likelihood $W(1|1)=\tfrac9{10}$ with the posterior: an output does not identify its input with certainty even when MAP and ML agree.
Exercise 1.2.
A bit-flipping channel (BSC) has crossover probability $p=\tfrac1{10}$, and the input bit is $0$ with probability $\Pr(X=0)=\tfrac{19}{20}$. What are the average error probability $P_{\rm e}$ of the MAP detector and its conditional error probability $P_{\rm e}(1)$ when $X=1$ is sent?
(a) $P_{\rm e}=\tfrac1{20}$ and $P_{\rm e}(1)=\tfrac1{10}$
(b) $P_{\rm e}=\tfrac1{20}$ and $P_{\rm e}(1)=1$
(c) $P_{\rm e}=\tfrac1{10}$ and $P_{\rm e}(1)=\tfrac1{10}$
Show solution
The correct answer is (b) ★
At $y=0$ the joint scores $\Pr(x)W(y|x)$ for $x=0,1$ are $\tfrac{171}{200}$ and $\tfrac{1}{200}$; at $y=1$ they are $\tfrac{19}{200}$ and $\tfrac{9}{200}$. In both cases $x=0$ wins, so the MAP detector always decides $0$: $\mathcal D_0=\{0,1\}$ and $\mathcal D_1=\varnothing$. It is never wrong when $0$ is sent and always wrong when $1$ is sent, $P_{\rm e}(0)=0$ and $P_{\rm e}(1)=1$, so $P_{\rm e}=\tfrac{19}{20}\cdot 0+\tfrac1{20}\cdot 1=\tfrac1{20}$.
The ML detector $g(y)=y$ has $P_{\rm e}(0)=P_{\rm e}(1)=P_{\rm e}=\tfrac1{10}$, option (c). MAP halves the average error, but it makes every occurrence of the rare input an error. Minimizing the average error does not minimize each conditional error separately; option (a) mixes the two detectors.
Exercise 1.3.
A bit-flipping channel (BSC) has crossover probability $p=\tfrac45$ and equiprobable inputs. Which is the ML detector, and what is its average error probability $P_{\rm e}$?
(a) $g(y)=1-y$, with $P_{\rm e}=\tfrac15$
(b) $g(y)=0$ for both outputs, with $P_{\rm e}=\tfrac12$
(c) $g(y)=y$, with $P_{\rm e}=\tfrac45$
Show solution
The correct answer is (a) ★
Since $p=\tfrac45>\tfrac12$, the likelihood $W(y|x)$ is larger for $x\neq y$: the channel flips more often than it preserves, and the ML detector flips the received bit, $g(y)=1-y$, with regions $\mathcal D_0=\{1\}$ and $\mathcal D_1=\{0\}$. It errs when the channel does not flip, so $P_{\rm e}(0)=P_{\rm e}(1)=\tfrac15$ and $P_{\rm e}=\tfrac15$. With equiprobable inputs this is also the MAP detector, hence no detector does better.
The detector $g(y)=y$ has conditional errors $(\tfrac45,\tfrac45)$ and average $\tfrac45$, option (c). The constant detector of option (b) has $\mathcal D_0=\{0,1\}$ and $\mathcal D_1=\varnothing$, conditional errors $(0,1)$ and average $\tfrac12$. It is legitimate for a detector to assign an empty region to a symbol, but here it is far from optimal.
Exercise 1.4.
A binary asymmetric channel has $W(1\mid0)=\tfrac15$ and $W(0\mid1)=\tfrac25$, and the input bit is $0$ with probability $\Pr(X=0)=\tfrac45$. What is the average error probability $P_{\rm e}$ of the MAP detector?
(a) $\tfrac{6}{25}$
(b) $\tfrac15$
(c) $\tfrac12$
Show solution
The correct answer is (b) ★
The missing transition probabilities are $W(0\mid0)=\tfrac45$ and $W(1\mid1)=\tfrac35$. The joint scores $\Pr(x)W(y|x)$ for $x=0,1$ are $\tfrac{16}{25}$ and $\tfrac{2}{25}$ at $y=0$, and $\tfrac{4}{25}$ and $\tfrac{3}{25}$ at $y=1$. The MAP detector decides $0$ for both outputs, so $P_{\rm e}(0)=0$, $P_{\rm e}(1)=1$ and $P_{\rm e}=\tfrac45\cdot0+\tfrac15\cdot1=\tfrac15$. Summing the scores column by column gives the output distribution, $\Pr(Y=0)=\tfrac{18}{25}$ and $\Pr(Y=1)=\tfrac{7}{25}$.
The ML detector decides $g(y)=y$, since $\tfrac45>\tfrac25$ and $\tfrac35>\tfrac15$, with $P_{\rm e}(0)=\tfrac15$, $P_{\rm e}(1)=\tfrac25$ and $P_{\rm e}=\tfrac45\cdot\tfrac15+\tfrac15\cdot\tfrac25=\tfrac{6}{25}$, option (a), which is larger as it must be. Option (c) averages the two conditional errors of MAP with equal weights instead of the priors.
Exercise 1.5.
A Z-channel has $W(0\mid0)=1$, $W(0\mid1)=\tfrac25$ and $W(1\mid1)=\tfrac35$, and the input bit is $0$ with probability $\Pr(X=0)=\tfrac14$. What is the posterior probability $\Pr(X=0\mid Y=0)$?
(a) $\tfrac{5}{11}$
(b) $\tfrac{5}{7}$
(c) $1$
Show solution
The correct answer is (a) ★
At $y=0$ the joint scores $\Pr(x)W(0|x)$ are $\tfrac14\cdot1=\tfrac14$ for $x=0$ and $\tfrac34\cdot\tfrac25=\tfrac{3}{10}$ for $x=1$. Their sum is $\Pr(Y=0)=\tfrac{11}{20}$, so by Bayes' rule $\Pr(X=0\mid Y=0)=\tfrac{1/4}{11/20}=\tfrac5{11}$ and $\Pr(X=1\mid Y=0)=\tfrac6{11}$. An output $1$ can only come from input $1$, so $\Pr(X=1\mid Y=1)=1$, but an output $0$ is not an unambiguous input $0$: option (c) is wrong. Option (b) normalizes the likelihoods $1$ and $\tfrac25$ without the prior.
Since $\tfrac6{11}>\tfrac5{11}$, the MAP detector decides $1$ at both outputs, with conditional errors $(1,0)$ and $P_{\rm e}=\tfrac14$. The ML detector decides the received bit, because $1>\tfrac25$ at $y=0$, with conditional errors $(0,\tfrac25)$ and $P_{\rm e}=\tfrac34\cdot\tfrac25=\tfrac{3}{10}$.
Exercise 1.6.
A channel with binary input first erases the bit with probability $\tfrac15$, producing the output $?$. Conditional on no erasure, it flips the bit with probability $\tfrac1{10}$. These probabilities are the same for either input, and $\Pr(X=0)=\tfrac35$. The receiver reports each unerased bit as received and replaces every erasure by the MAP decision at $y=?$. What is the average bit error probability $P_{\rm e}$ of this receiver?
(a) $\tfrac{4}{25}$
(b) $\tfrac{7}{25}$
(c) $\tfrac{2}{25}$
Show solution
The correct answer is (a) ★
In output order $0,1,?$, the transition rows are $(\tfrac{18}{25},\tfrac{2}{25},\tfrac15)$ for $x=0$ and $(\tfrac{2}{25},\tfrac{18}{25},\tfrac15)$ for $x=1$. At an erasure both likelihoods equal $\tfrac15$, so the MAP decision is the more probable bit, $0$. At $y=0,1$ the joint scores are $(\tfrac{54}{125},\tfrac{4}{125})$ and $(\tfrac{6}{125},\tfrac{36}{125})$, so reporting the received bit is the MAP decision there too. When $0$ is sent, an error requires a flip without erasure, $P_{\rm e}(0)=\tfrac{2}{25}$. When $1$ is sent, both a flip and an erasure lead to a wrong bit, $P_{\rm e}(1)=\tfrac{2}{25}+\tfrac15=\tfrac{7}{25}$. The average is $P_{\rm e}=\tfrac35\cdot\tfrac{2}{25}+\tfrac25\cdot\tfrac{7}{25}=\tfrac{4}{25}$.
Before the erasures are filled, the probability of an incorrect reported bit is $\tfrac45\cdot\tfrac1{10}=\tfrac{2}{25}$, option (c), and the erasure probability is $\tfrac15$; counting every erasure as a failure gives $\tfrac{7}{25}$, option (b). An erasure, an incorrect reported bit and an incorrect bit after filling are three different events.
Exercise 1.7.
An asymmetric erasure channel has $W(?\mid0)=\tfrac45$, $W(0\mid0)=\tfrac15$, $W(?\mid1)=\tfrac15$ and $W(1\mid1)=\tfrac45$; all other transition probabilities are zero. The input bit is $0$ with probability $\Pr(X=0)=\tfrac35$. What is the posterior probability $\Pr(X=0\mid Y=?)$ at an erasure?
(a) $\tfrac{3}{5}$
(b) $\tfrac{4}{5}$
(c) $\tfrac{6}{7}$
Show solution
The correct answer is (c) ★
At $y=?$ the joint scores $\Pr(x)W(?|x)$ are $\tfrac35\cdot\tfrac45=\tfrac{12}{25}$ for $x=0$ and $\tfrac25\cdot\tfrac15=\tfrac{2}{25}$ for $x=1$. Their sum is $\Pr(Y=?)=\tfrac{14}{25}$, so $\Pr(X=0\mid Y=?)=\tfrac{12}{14}=\tfrac67$. This differs from the prior $\tfrac35$ of option (a): the erasure itself is informative, because input $0$ is erased more often. Option (b) is the likelihood $W(?\mid0)$, which ignores the prior.
The ordinary outputs $0$ and $1$ identify the input without error. At an erasure, ML decides $0$ because $\tfrac45>\tfrac15$, and MAP also decides $0$. Both detectors have conditional errors $(0,\tfrac15)$ and $P_{\rm e}=\tfrac25\cdot\tfrac15=\tfrac{2}{25}$, which is much smaller than the erasure probability $\tfrac{14}{25}$.
Exercise 1.8.
Inputs and outputs take values in $\{0,1,2\}$ and the channel matrix, with rows indexed by the input, is $$W=\begin{pmatrix}3/5&3/10&1/10\\1/5&1/2&3/10\\1/10&1/5&7/10\end{pmatrix}.$$ The input probabilities are $(\tfrac1{10},\tfrac7{10},\tfrac15)$. What is the average error probability $P_{\rm e}$ of the MAP detector?
(a) $\tfrac{3}{10}$
(b) $\tfrac{9}{20}$
(c) $\tfrac{2}{3}$
Show solution
The correct answer is (a) ★
The joint scores $\Pr(x)W(y|x)$, with rows indexed by $x$ and columns by $y$, are $(0.06,0.03,0.01)$, $(0.14,0.35,0.21)$ and $(0.02,0.04,0.14)$. The middle row is the largest in every column, so the MAP detector decides $\hat x=1$ whatever is received. Its conditional errors are $(1,0,1)$ and $P_{\rm e}=\tfrac1{10}+\tfrac15=\tfrac{3}{10}$. At $y=2$, for instance, $\Pr(Y=2)=0.36$ and the largest posterior is $\Pr(X=1\mid Y=2)=\tfrac{0.21}{0.36}=\tfrac{7}{12}$.
Each column of $W$ has its largest entry on the diagonal, so the ML detector decides $g(y)=y$, with conditional errors $(\tfrac25,\tfrac12,\tfrac3{10})$ and $P_{\rm e}=\tfrac1{25}+\tfrac7{20}+\tfrac3{50}=\tfrac{9}{20}$, option (b). Option (c) averages the three conditional errors of MAP with equal weights instead of the input probabilities.
Exercise 1.9.
The inputs $0$ and $1$ are equiprobable and the outputs take values in $\{0,1,2\}$. The channel rows are $W(\cdot\mid0)=(\tfrac12,\tfrac15,\tfrac3{10})$ and $W(\cdot\mid1)=(\tfrac1{10},\tfrac35,\tfrac3{10})$. A colleague proposes the detector that decides $0$ only when $y=1$ and decides $1$ otherwise. What are its conditional error probabilities $(P_{\rm e}(0),P_{\rm e}(1))$ and its average error probability $P_{\rm e}$?
(a) $(\tfrac12,\tfrac1{10})$ and $P_{\rm e}=\tfrac{3}{10}$
(b) $(\tfrac45,\tfrac35)$ and $P_{\rm e}=\tfrac{7}{10}$
(c) $(\tfrac15,\tfrac25)$ and $P_{\rm e}=\tfrac{3}{10}$
Show solution
The correct answer is (b) ★
First identify the decision regions: $\mathcal D_0=\{1\}$ and $\mathcal D_1=\{0,2\}$. Then sum the channel law over the outputs outside the region of the transmitted symbol: $P_{\rm e}(0)=W(0\mid0)+W(2\mid0)=\tfrac12+\tfrac3{10}=\tfrac45$ and $P_{\rm e}(1)=W(1\mid1)=\tfrac35$. The average is $P_{\rm e}=\tfrac12\cdot\tfrac45+\tfrac12\cdot\tfrac35=\tfrac{7}{10}$, worse than deciding at random.
The ML detector decides $0$ at $y=0$, $1$ at $y=1$, and faces a tie at $y=2$. Breaking the tie toward $0$ gives conditional errors $(\tfrac15,\tfrac25)$ and $P_{\rm e}=\tfrac{3}{10}$, option (c). Nearest-point detection on the numerical alphabet, which assigns $y=2$ to $1$, gives $(\tfrac12,\tfrac1{10})$ and also $P_{\rm e}=\tfrac{3}{10}$, option (a); it is the other ML tie-breaking rule. Equal average errors need not mean equal conditional errors.
Exercise 1.10.
Equiprobable symbols $X\in\{-2,+2\}$ are sent over the real Gaussian channel $Y=X+Z$ with $Z\sim\mathcal N(0,2)$, that is, noise variance $\sigma^2=2$. The receiver uses the ML detector. What is the average error probability $P_{\rm e}$?
(a) $\tfrac12\operatorname{erfc}(\sqrt2)$
(b) $\tfrac12\operatorname{erfc}(1)$
(c) $\operatorname{erfc}(1)$
Show solution
The correct answer is (b) ★
With equiprobable symbols MAP and ML coincide, and in Gaussian noise ML is the nearest-point rule: the threshold is at $y=0$, with $\mathcal D_{-2}=(-\infty,0)$ and $\mathcal D_{+2}=(0,\infty)$; the value $y=0$ has probability zero and may be assigned to either symbol. When $x=-2$ is sent, an error occurs when $Z>2$; when $x=+2$ is sent, when $Z<-2$. For a real Gaussian of variance $\sigma^2$, $\Pr(Z>a)=\tfrac12\operatorname{erfc}\bigl(a/(\sqrt2\sigma)\bigr)$, and here $a=2$ and $\sqrt2\sigma=2$, so each conditional error is $\tfrac12\operatorname{erfc}(1)\approx 0.079$. The average is the same, $P_{\rm e}=\tfrac12\operatorname{erfc}(1)$.
The symbol energy is $E_{\rm s}=4$ and $\mathrm{SNR}=E_{\rm s}/\sigma^2=2$, consistent with $P_{\rm e}=\tfrac12\operatorname{erfc}\bigl(\sqrt{\mathrm{SNR}/2}\bigr)$. Option (a) uses $a/\sigma$ instead of $a/(\sqrt2\sigma)$ in the argument, which is the complex-channel formula. Option (c) adds the two error regions, but each symbol has only one error region: the regions $Z>2$ and $Z<-2$ belong to different transmitted symbols and are not summed.
Exercise 1.11.
On-off signaling $X\in\{0,3\}$ with $\Pr(X=0)=\tfrac34$ and $\Pr(X=3)=\tfrac14$ is used over the real Gaussian channel $Y=X+Z$ with $Z\sim\mathcal N(0,1)$. The MAP detector decides $\hat x=3$ when $y>t$ and $\hat x=0$ otherwise. What is the threshold $t$?
(a) $t=\tfrac32+\tfrac13\ln 3$
(b) $t=\tfrac32-\tfrac13\ln 3$
(c) $t=\tfrac32+\tfrac16\ln 3$
Show solution
The correct answer is (a) ★
MAP decides $3$ when $\tfrac14 e^{-(y-3)^2/2}>\tfrac34 e^{-y^2/2}$. Taking logarithms, the terms in $y^2$ cancel and the inequality becomes $3y-\tfrac92>\ln 3$, that is, $y>t=\tfrac32+\tfrac13\ln 3\approx 1.87$. The threshold lies above the ML midpoint $\tfrac32$: the region of the more probable symbol $0$ grows. The shift is $\sigma^2\ln 3$ divided by the distance $3$ between the symbols, not by twice the symbol value.
The error events are $Z>t$ for $x=0$ and $t-3>Z$ for $x=3$, so $P_{\rm e}(0)=\tfrac12\operatorname{erfc}\bigl(\tfrac{t}{\sqrt2}\bigr)$, $P_{\rm e}(3)=\tfrac12\operatorname{erfc}\bigl(\tfrac{3-t}{\sqrt2}\bigr)$ and $P_{\rm e}=\tfrac38\operatorname{erfc}\bigl(\tfrac{t}{\sqrt2}\bigr)+\tfrac18\operatorname{erfc}\bigl(\tfrac{3-t}{\sqrt2}\bigr)\approx 0.055$, below the ML value $\tfrac12\operatorname{erfc}\bigl(\tfrac{3}{2\sqrt2}\bigr)\approx 0.067$. The average energy is $E_{\rm s}=\tfrac14\cdot 9=\tfrac94$, so $\mathrm{SNR}=\tfrac94$.
Exercise 1.12.
The symbols $X\in\{-2,0,2\}$ with probabilities $\bigl(\tfrac14,\tfrac12,\tfrac14\bigr)$ are sent through the real Gaussian channel $Y=X+Z$ with noise variance $\sigma^2=2$. The receiver uses the nearest-point detector. What is the average error probability $P_{\rm e}$?
(a) $\tfrac23\operatorname{erfc}\bigl(\tfrac12\bigr)$
(b) $\tfrac12\operatorname{erfc}\bigl(\tfrac12\bigr)$
(c) $\tfrac34\operatorname{erfc}\bigl(\tfrac12\bigr)$
Show solution
The correct answer is (c) ★
The thresholds are the midpoints $-1$ and $1$, at distance $1$ from every symbol. Each tail has probability $\Pr(Z>1)=\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2\sigma}\bigr)=\tfrac12\operatorname{erfc}\bigl(\tfrac12\bigr)$. The outer symbols have one error tail each, so $P_{\rm e}(\pm2)=\tfrac12\operatorname{erfc}\bigl(\tfrac12\bigr)$. For $x=0$ the error set in noise coordinates is $(-\infty,-1)\cup(1,\infty)$, two disjoint tails, so $P_{\rm e}(0)=\operatorname{erfc}\bigl(\tfrac12\bigr)$, even though this symbol carries no energy.
Averaging with the priors, $P_{\rm e}=\tfrac14\cdot\tfrac12\operatorname{erfc}\bigl(\tfrac12\bigr)+\tfrac12\operatorname{erfc}\bigl(\tfrac12\bigr)+\tfrac14\cdot\tfrac12\operatorname{erfc}\bigl(\tfrac12\bigr)=\tfrac34\operatorname{erfc}\bigl(\tfrac12\bigr)\approx 0.36$. Counting one tail for the middle symbol gives $\tfrac12\operatorname{erfc}\bigl(\tfrac12\bigr)$; averaging with equal weights gives $\tfrac23\operatorname{erfc}\bigl(\tfrac12\bigr)$. The energy is $E_{\rm s}=\tfrac14\cdot4+\tfrac14\cdot4=2$, so $\mathrm{SNR}=1$.
Exercise 1.13.
The symbols $X\in\{-2,0,2\}$ with probabilities $\bigl(\tfrac14,\tfrac12,\tfrac14\bigr)$ are sent through $Y=X+Z$ with $Z\sim\mathcal N(0,2)$. The receiver uses the MAP detector. What is the decision region $\mathcal D_0$ of the symbol $0$?
(a) $\mathcal D_0=(-1,1)$
(b) $\mathcal D_0=(-1-\ln 2,\,1+\ln 2)$
(c) $\mathcal D_0=(-1+\ln 2,\,1-\ln 2)$
Show solution
The correct answer is (b) ★
For $y>0$ the symbol $-2$ cannot beat $2$, so it suffices to compare $0$ and $2$: MAP decides $2$ when $\tfrac14 e^{-(y-2)^2/4}>\tfrac12 e^{-y^2/4}$. Taking logarithms, $y-1>\ln 2$, so the boundary is $b=1+\ln 2\approx 1.69$, and by symmetry the other boundary is $-b$. Hence $\mathcal D_0=(-b,b)$, wider than the nearest-point region $(-1,1)$: the prior favors the middle symbol, and the shift is $\sigma^2\ln 2$ divided by the distance $2$. Shrinking the region, as in $(-1+\ln 2,1-\ln 2)$, moves the boundaries in the wrong direction.
With noise variance $2$, each tail at distance $a$ has probability $\tfrac12\operatorname{erfc}\bigl(\tfrac a2\bigr)$. Therefore $P_{\rm e}(0)=\operatorname{erfc}\bigl(\tfrac b2\bigr)$, $P_{\rm e}(\pm2)=\tfrac12\operatorname{erfc}\bigl(\tfrac{2-b}{2}\bigr)$ and $P_{\rm e}=\tfrac12\operatorname{erfc}\bigl(\tfrac b2\bigr)+\tfrac14\operatorname{erfc}\bigl(\tfrac{2-b}{2}\bigr)\approx 0.32$, smaller than the nearest-point value $\tfrac34\operatorname{erfc}\bigl(\tfrac12\bigr)\approx 0.36$. The middle error decreases, the outer errors increase, and the weighted average cannot exceed the nearest-point value because MAP minimizes it.
Exercise 1.14.
Equiprobable symbols $X\in\{-3,0,1\}$ are sent through the real Gaussian channel $Y=X+Z$ with $Z\sim\mathcal N(0,1)$, and the receiver uses the nearest-point detector. What is the average error probability $P_{\rm e}$?
(a) $\tfrac13\Bigl[\tfrac12\operatorname{erfc}\bigl(\tfrac{3}{2\sqrt2}\bigr)+\operatorname{erfc}\bigl(\tfrac{1}{2\sqrt2}\bigr)\Bigr]$
(b) $\tfrac23\operatorname{erfc}\bigl(\tfrac{1}{2\sqrt2}\bigr)$
(c) $\tfrac13\Bigl[\operatorname{erfc}\bigl(\tfrac{3}{2\sqrt2}\bigr)+\operatorname{erfc}\bigl(\tfrac{1}{2\sqrt2}\bigr)\Bigr]$
Show solution
The correct answer is (c) ★
The thresholds are the midpoints $-\tfrac32$ and $\tfrac12$, so the regions are $(-\infty,-\tfrac32)$, $(-\tfrac32,\tfrac12)$ and $(\tfrac12,\infty)$. The outer symbols have one tail each: $P_{\rm e}(-3)=\tfrac12\operatorname{erfc}\bigl(\tfrac{3}{2\sqrt2}\bigr)$ and $P_{\rm e}(1)=\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{2\sqrt2}\bigr)$. The middle symbol has two tails at different distances, $\tfrac32$ on the left and $\tfrac12$ on the right, so $P_{\rm e}(0)=\tfrac12\operatorname{erfc}\bigl(\tfrac{3}{2\sqrt2}\bigr)+\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{2\sqrt2}\bigr)$.
Averaging the three conditional errors gives $P_{\rm e}=\tfrac13\bigl[\operatorname{erfc}\bigl(\tfrac{3}{2\sqrt2}\bigr)+\operatorname{erfc}\bigl(\tfrac{1}{2\sqrt2}\bigr)\bigr]\approx 0.25$. Counting only the nearer tail of the middle symbol loses $\tfrac12\operatorname{erfc}\bigl(\tfrac{3}{2\sqrt2}\bigr)$; using the smallest spacing for every tail gives the uniform 3-PAM formula $\tfrac23\operatorname{erfc}\bigl(\tfrac{1}{2\sqrt2}\bigr)$, which is far too large. The energy is $E_{\rm s}=\tfrac13(9+0+1)=\tfrac{10}{3}$, so $\mathrm{SNR}=\tfrac{10}{3}$.
Exercise 1.15.
Equiprobable symbols $X\in\{-1,1\}$ are sent through the real Gaussian channel $Y=X+Z$ with $Z\sim\mathcal N(0,1)$. The receiver decides $\hat x=1$ if $y>1$ and $\hat x=-1$ otherwise. What is its average error probability $P_{\rm e}$?
(a) $\tfrac12\operatorname{erfc}\bigl(\sqrt2\bigr)$
(b) $\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)$
(c) $\tfrac14+\tfrac14\operatorname{erfc}\bigl(\sqrt2\bigr)$
Show solution
The correct answer is (c) ★
The threshold sits on the symbol $1$. When $x=-1$ is sent, an error requires $Z>2$, so $P_{\rm e}(-1)=\tfrac12\operatorname{erfc}\bigl(\tfrac{2}{\sqrt2}\bigr)=\tfrac12\operatorname{erfc}\bigl(\sqrt2\bigr)$. When $x=1$ is sent, an error requires $Z\leq 0$, which has probability $\tfrac12$. Hence $P_{\rm e}=\tfrac12\cdot\tfrac12\operatorname{erfc}\bigl(\sqrt2\bigr)+\tfrac12\cdot\tfrac12=\tfrac14+\tfrac14\operatorname{erfc}\bigl(\sqrt2\bigr)\approx 0.26$. The small tail of one symbol is paid with a coin flip on the other.
For a general threshold $t$, $P_{\rm e}(t)=\tfrac14\bigl[\operatorname{erfc}\bigl(\tfrac{1+t}{\sqrt2}\bigr)+\operatorname{erfc}\bigl(\tfrac{1-t}{\sqrt2}\bigr)\bigr]$, minimized at $t=0$, the ML threshold, where it equals $\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)\approx 0.16$. The value $\tfrac12\operatorname{erfc}\bigl(\sqrt2\bigr)$ would require both symbols to be at distance $2$ from the threshold.
Exercise 1.16.
Equiprobable symbols $X\in\{-1,1\}$ are sent through $Y=X+Z$ with $Z\sim\mathcal N(0,1)$. A window detector decides $\hat x=1$ when $|y|<1$ and $\hat x=-1$ otherwise, so that $\mathcal D_1=(-1,1)$ and $\mathcal D_{-1}=(-\infty,-1]\cup[1,\infty)$. What is its average error probability $P_{\rm e}$?
(a) $\tfrac12+\tfrac14\operatorname{erfc}\bigl(\sqrt2\bigr)$
(b) $\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)$
(c) $\tfrac12$
Show solution
The correct answer is (c) ★
When $x=1$ is sent, $Y=1+Z$ leaves the window $(-1,1)$ when $Z\leq-2$ or $Z\geq0$, two disjoint events, so $P_{\rm e}(1)=\tfrac12\operatorname{erfc}\bigl(\sqrt2\bigr)+\tfrac12$. When $x=-1$ is sent, an error means entering the window, $2>Z>0$, so $P_{\rm e}(-1)=\tfrac12-\tfrac12\operatorname{erfc}\bigl(\sqrt2\bigr)$. Forgetting the upper limit $Z<2$ gives $P_{\rm e}(-1)=\tfrac12$ and the wrong average $\tfrac12+\tfrac14\operatorname{erfc}\bigl(\sqrt2\bigr)$.
The two $\operatorname{erfc}$ terms cancel in the average: $P_{\rm e}=\tfrac12\bigl[P_{\rm e}(1)+P_{\rm e}(-1)\bigr]=\tfrac12$ exactly. The detector reacts to the observation, but with equiprobable inputs it performs no better than always answering the same symbol, and far worse than the ML threshold at $0$, whose error is $\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)\approx0.16$.
Exercise 1.17.
Two binary constellations with equiprobable symbols, $\{-1,1\}$ and $\{1,3\}$, are used over the real Gaussian channel with noise variance $\sigma^2=1$, each with its nearest-point detector. The first one has $P_{\rm e}=\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)$ and $\mathrm{SNR}=1$. What are the average error probability and the SNR of the constellation $\{1,3\}$?
(a) $P_{\rm e}=\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)$ and $\mathrm{SNR}=5$
(b) $P_{\rm e}=\tfrac12\operatorname{erfc}\bigl(\sqrt{\tfrac52}\bigr)$ and $\mathrm{SNR}=5$
(c) $P_{\rm e}=\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)$ and $\mathrm{SNR}=1$
Show solution
The correct answer is (a) ★
The threshold of $\{1,3\}$ is the midpoint $2$, and both symbols are at distance $1$ from it, exactly as in $\{-1,1\}$ with threshold $0$. The observation and the boundary translate together, so every conditional error is $\Pr(Z>1)=\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)\approx0.16$ in both constellations.
The energies differ: $E_{\rm s}=\mathbb E|X|^2$ is $1$ for $\{-1,1\}$ and $\tfrac12(1+9)=5$ for $\{1,3\}$, so the SNRs are $1$ and $5$. The second constellation spends four units of energy on its mean $2$, which carries no information: both have variance $1$. A larger SNR does not force a smaller error here, and the 2-PAM formula $\tfrac12\operatorname{erfc}\bigl(\sqrt{\mathrm{SNR}/2}\bigr)$ applies only to constellations centered at the origin.
Exercise 1.18.
Equiprobable symbols $X\in\{\pm2\pm j\}$ are sent over the complex Gaussian channel with circular noise of total variance $\sigma^2=2$, and the receiver uses the nearest-point detector. What is the symbol error probability $P_{\rm e}$?
(a) $1-\bigl[1-\tfrac12\operatorname{erfc}\bigl(\sqrt2\bigr)\bigr]\bigl[1-\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)\bigr]$
(b) $1-\bigl[1-\tfrac12\operatorname{erfc}(1)\bigr]\bigl[1-\tfrac12\operatorname{erfc}\bigl(\tfrac12\bigr)\bigr]$
(c) $\tfrac12\operatorname{erfc}\bigl(\sqrt2\bigr)+\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)$
Show solution
The correct answer is (a) ★
The perpendicular bisectors are the two axes, so each symbol owns a quadrant. The real and imaginary parts of the noise are independent Gaussians of variance $\sigma^2/2=1$ each. The real component crosses its boundary at distance $2$ with probability $p_R=\tfrac12\operatorname{erfc}\bigl(\tfrac{2}{\sqrt2}\bigr)=\tfrac12\operatorname{erfc}\bigl(\sqrt2\bigr)$, and the imaginary component at distance $1$ with probability $p_I=\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)$. Using the total variance $2$ for each component would give the arguments $1$ and $\tfrac12$ instead.
A decision is correct only if both components are correct, and the two events are independent, so $P_{\rm e}=1-(1-p_R)(1-p_I)=p_R+p_I-p_Rp_I\approx0.178$, the same for the four symbols. The plain sum $p_R+p_I$ counts twice the outputs that cross both boundaries. The two component errors differ because the rectangle has unequal sides. Each symbol has energy $4+1=5$, so $E_{\rm s}=5$ and $\mathrm{SNR}=\tfrac52$.
Exercise 1.19.
A QPSK symbol is $X=S_R+jS_I$ with independent signs $S_R,S_I\in\{-1,1\}$, $\Pr(S_R=1)=\tfrac34$ and $\Pr(S_I=1)=\tfrac12$. It is sent over the complex Gaussian channel with circular noise of total variance $\sigma^2=2$. Which rule describes the MAP detector?
(a) Decide $S_R=1$ if $\operatorname{Re}(y)>-\tfrac12\ln3$, and $S_I=1$ if $\operatorname{Im}(y)>0$.
(b) Decide $S_R=1$ if $\operatorname{Re}(y)>\tfrac12\ln3$, and $S_I=1$ if $\operatorname{Im}(y)>0$.
(c) Decide $S_R=1$ if $\operatorname{Re}(y)>-\tfrac12\ln3$, and $S_I=1$ if $\operatorname{Im}(y)>-\tfrac12\ln3$.
Show solution
The correct answer is (a) ★
Both the prior and the likelihood factor into a real and an imaginary part, each with noise variance $\sigma^2/2=1$, so the MAP rule decides the two signs separately. The imaginary sign is equiprobable and its threshold is $0$. For the real sign, MAP decides $1$ when $\tfrac34 e^{-(r-1)^2/2}>\tfrac14 e^{-(r+1)^2/2}$ with $r=\operatorname{Re}(y)$, that is, $\ln3+2r>0$, so the threshold is $t=-\tfrac12\ln3\approx-0.55$. It moves toward the less probable sign $-1$, enlarging the region of $S_R=1$; a positive threshold would favor the wrong sign, and the imaginary axis has no reason to shift.
The region of $s_R+js_I$ is the intersection of the correct side of the vertical line $\operatorname{Re}(y)=t$ and of the horizontal line $\operatorname{Im}(y)=0$. The average real error is $p_R=\tfrac38\operatorname{erfc}\bigl(\tfrac{1-t}{\sqrt2}\bigr)+\tfrac18\operatorname{erfc}\bigl(\tfrac{1+t}{\sqrt2}\bigr)$, the imaginary error is $p_I=\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)$, and by independence $P_{\rm e}=1-(1-p_R)(1-p_I)\approx0.266$, versus $1-\bigl[1-\tfrac12\operatorname{erfc}\bigl(\tfrac1{\sqrt2}\bigr)\bigr]^2\approx0.292$ for the nearest-point detector. $E_{\rm s}=2$ and $\mathrm{SNR}=1$.
Exercise 1.20.
Equiprobable QPSK symbols $X\in\{\pm1\pm j\}$ are sent over the complex Gaussian channel with circular noise of total variance $\sigma^2=2$. The receiver ignores the imaginary part: it outputs $\hat x=1+j$ if $\operatorname{Re}(y)>0$ and $\hat x=-1+j$ otherwise. What is its average error probability $P_{\rm e}$?
(a) $\tfrac12+\tfrac14\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)$
(b) $\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)-\tfrac14\operatorname{erfc}^2\bigl(\tfrac{1}{\sqrt2}\bigr)$
(c) $\tfrac12+\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)$
Show solution
The correct answer is (a) ★
The regions of $1+j$ and $-1+j$ are the right and left half-planes; the regions of $1-j$ and $-1-j$ are empty. Whenever a lower symbol is sent the receiver is certainly wrong, so $P_{\rm e}(1-j)=P_{\rm e}(-1-j)=1$. For an upper symbol only the real sign matters, and the real noise component has variance $\sigma^2/2=1$, so $P_{\rm e}(1+j)=P_{\rm e}(-1+j)=\Pr(\operatorname{Re}Z<-1)=\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)$.
Averaging over the four equiprobable symbols, $P_{\rm e}=\tfrac12\cdot1+\tfrac12\cdot\tfrac12\operatorname{erfc}\bigl(\tfrac1{\sqrt2}\bigr)=\tfrac12+\tfrac14\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)\approx0.58$. Forgetting the weight $\tfrac12$ of the upper symbols gives $\tfrac12+\tfrac12\operatorname{erfc}\bigl(\tfrac1{\sqrt2}\bigr)$. The nearest-point detector uses the four quadrants and has $P_{\rm e}=1-\bigl[1-\tfrac12\operatorname{erfc}\bigl(\tfrac1{\sqrt2}\bigr)\bigr]^2=\operatorname{erfc}\bigl(\tfrac1{\sqrt2}\bigr)-\tfrac14\operatorname{erfc}^2\bigl(\tfrac1{\sqrt2}\bigr)\approx0.29$.
Exercise 1.21.
Equiprobable symbols $X\in\{-2,+2\}$ are transmitted over the complex Gaussian channel with circular noise of total variance $\sigma^2=4$, so that the real and imaginary parts of the noise are independent Gaussians of variance $2$ each. The receiver uses the nearest-point detector. What is the average error probability $P_{\rm e}$?
(a) $\tfrac12\operatorname{erfc}(1)$
(b) $\tfrac12\operatorname{erfc}(\sqrt2)$
(c) $\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)$
Show solution
The correct answer is (a) ★
The perpendicular bisector of the two points is the imaginary axis, so the decision regions are the two half-planes and only $\re Y$ matters. When $+2$ is sent, an error occurs when $\re Z<-2$. The real part of the noise is a real Gaussian of variance $\sigma^2/2=2$, so $P_{\rm e}(+2)=\tfrac12\operatorname{erfc}\bigl(2/(\sqrt2\cdot\sqrt2)\bigr)=\tfrac12\operatorname{erfc}(1)$, and by symmetry this is also $P_{\rm e}(-2)$ and the average.
Option (c) is the error of the same symbols on the real Gaussian channel of variance $4$, where all the noise lies in the decision direction, $\tfrac12\operatorname{erfc}\bigl(2/(\sqrt2\cdot2)\bigr)=\tfrac12\operatorname{erfc}(1/\sqrt2)$. Both channels have $E_{\rm s}=4$ and $\mathrm{SNR}=E_{\rm s}/\sigma^2=1$, yet their errors differ because only half of the complex noise affects this decision. Option (b) forgets the $\sqrt2$ in the argument of $\operatorname{erfc}$.
Exercise 1.22.
The equiprobable constellation $\{\sqrt2,\,j\sqrt2,\,-\sqrt2,\,-j\sqrt2\}$ is transmitted over the complex Gaussian channel with circular noise of total variance $\sigma^2=2$, and the receiver uses the nearest-point detector. What is the average error probability $P_{\rm e}$?
(a) $\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)-\tfrac14\operatorname{erfc}^2\bigl(\tfrac{1}{\sqrt2}\bigr)$
(b) $\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)$
(c) $\operatorname{erfc}(1)-\tfrac14\operatorname{erfc}^2(1)$
Show solution
The correct answer is (a) ★
The decision region of $x=\sqrt2$ is the wedge $\re y>|\im y|$, bounded by the two diagonals. Writing $y=\sqrt2+z$, a correct decision requires $\re z+\im z>-\sqrt2$ and $\re z-\im z>-\sqrt2$. With $U=(\re Z+\im Z)/\sqrt2$ and $V=(\re Z-\im Z)/\sqrt2$, an orthogonal rotation of circular noise with components of variance $\sigma^2/2=1$, the variables $U$ and $V$ are independent Gaussians of variance $1$ and the conditions become $U>-1$ and $V>-1$. Hence $P_{\rm c}=\bigl[1-\tfrac12\operatorname{erfc}(1/\sqrt2)\bigr]^2$ and $P_{\rm e}(\sqrt2)=\operatorname{erfc}(1/\sqrt2)-\tfrac14\operatorname{erfc}^2(1/\sqrt2)$. By rotation symmetry, this is the error of every symbol and the average.
This is exactly the QPSK result $2p-p^2$ with $p=\tfrac12\operatorname{erfc}(a/\sigma)$ and $a=1$: the constellation is the square $\{\pm1\pm j\}$ rotated by $45$ degrees, with the same $E_{\rm s}=2$ and $\mathrm{SNR}=1$, and rotating a constellation does not change its performance. Option (b) adds the two boundary crossings and ignores that they can happen together. Option (c) uses the distance $\sqrt2$ from the symbol to the origin instead of its distance $1$ to each boundary.
Exercise 1.23.
Equiprobable QPSK symbols $\{+1+j,\,+1-j,\,-1+j,\,-1-j\}$ are sent through $Y=X+N$, where the noise is $N=Z+jZ$ with a single real Gaussian $Z\sim\mathcal N(0,1)$, so that $\mathbb E|N|^2=2$ but the two components are identical. The receiver uses the nearest-point detector (the quadrant of $y$), without assuming that it is optimal for this channel. What is the average error probability $P_{\rm e}$?
(a) $\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)-\tfrac14\operatorname{erfc}^2\bigl(\tfrac{1}{\sqrt2}\bigr)$
(b) $\tfrac12\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)$
(c) $\tfrac34\operatorname{erfc}\bigl(\tfrac{1}{\sqrt2}\bigr)$
Show solution
The correct answer is (c) ★
When $+1+j$ is sent, $Y=(1+Z)+j(1+Z)$: both components cross their boundary together, so the decision is correct exactly when $Z>-1$ and $P_{\rm e}(+1+j)=\Pr(Z<-1)=\tfrac12\operatorname{erfc}(1/\sqrt2)$. The same holds for $-1-j$, which needs $Z<1$. When $+1-j$ is sent, $Y=(1+Z)+j(-1+Z)$ and a correct decision needs $1+Z>0$ and $-1+Z<0$, that is $Z>-1$ and $Z<1$, so $P_{\rm e}(+1-j)=\Pr(|Z|>1)=\operatorname{erfc}(1/\sqrt2)$, and likewise for $-1+j$. Averaging, $P_{\rm e}=\tfrac14\bigl(\tfrac12+\tfrac12+1+1\bigr)\operatorname{erfc}(1/\sqrt2)=\tfrac34\operatorname{erfc}(1/\sqrt2)$.
Option (a) is the circular QPSK formula $2p-p^2$ with $p=\tfrac12\operatorname{erfc}(1/\sqrt2)$, which would apply if the two components were independent Gaussians of variance $1$. Here they are perfectly correlated, so $\Pr(\text{both conditions})$ is not the product of the marginal probabilities and the product rule is invalid, even though $\mathbb E|N|^2$ matches the circular model. Option (b) counts only the same-sign symbols.
Exercise 1.24.
Equiprobable energies $X\in\{0,2\}$ are sent over the additive exponential noise channel $Y=X+Z$, where $Z$ is exponential with mean $\mu=1$, so that $W(y|x)=e^{-(y-x)}$ for $y\geq x$ and $0$ otherwise. What is the average error probability of the ML detector?
(a) $\tfrac12 e^{-1}$
(b) $e^{-2}$
(c) $\tfrac12 e^{-2}$
Show solution
The correct answer is (c) ★
The support matters. For $0\leq y<2$ only $x=0$ can have been sent, since $W(y|2)=0$. For $y\geq2$ both are possible and $W(y|2)=e^{2}W(y|0)>W(y|0)$, so the ML detector decides $2$. Its threshold is at $2$, the larger symbol, not halfway between the two. When $2$ is sent, $Y\geq2$ with certainty and $P_{\rm e}(2)=0$; when $0$ is sent, an error needs $Z\geq2$, so $P_{\rm e}(0)=e^{-2}$ and $P_{\rm e}=\tfrac12e^{-2}$. Outputs below $0$ are impossible and may be assigned arbitrarily.
Option (a) is the nearest-point detector with threshold $1$, which has errors $(e^{-1},0)$ and average $\tfrac12e^{-1}$: on this channel the nearest-point rule is not ML, because the noise density is not symmetric around the transmitted symbol. Option (b) forgets that only one of the two symbols can be in error. The inputs are energies, their mean is $E_{\rm s}=(0+2)/2=1$ and the ratio $E_{\rm s}/\mu=1$ plays the role of the SNR; this is a different convention from $\mathbb E|X|^2/\sigma^2$ on the Gaussian channels.
Exercise 1.25.
Energies $X\in\{0,2\}$ with priors $\Pr(X=0)=\tfrac45$ and $\Pr(X=2)=\tfrac15$ are sent over the additive exponential noise channel $Y=X+Z$, where the true noise $Z$ is exponential with mean $\mu=1$. A receiver knows the priors but mistakenly builds its MAP rule for exponential noise of mean $2$, and uses that rule. What is the actual average error probability of this receiver, evaluated under the true channel?
(a) $\tfrac45 e^{-2}$
(b) $\tfrac15$
(c) $\tfrac45 e^{-1}$
Show solution
The correct answer is (b) ★
With assumed mean $2$ the likelihoods are $\tfrac12e^{-(y-x)/2}$ for $y\geq x$. For $0\leq y<2$ only $x=0$ is feasible. For $y\geq2$ the two MAP scores share the factor $\tfrac12e^{-y/2}$ and reduce to $\Pr(0)=\tfrac45$ against $\Pr(2)\,e^{2/2}=\tfrac{e}{5}$. Since $4>e$, the receiver decides $0$ for every reachable observation. Under the true channel this rule is never wrong when $0$ is sent and always wrong when $2$ is sent, so the errors are $(0,1)$ and $P_{\rm e}=\tfrac15$.
With the correct mean $1$ the weights on $y\geq2$ are $\tfrac45$ against $\tfrac{e^2}{5}$, and $e^2>4$, so the true MAP detector decides $2$ for $y\geq2$: its errors are $(e^{-2},0)$ and $P_{\rm e}=\tfrac45e^{-2}\approx0.108$, option (a). Option (c) keeps the threshold at $2$ but evaluates the tail with the assumed mean $2$. The optimality of MAP holds for the channel model used to design the detector; the probabilities of the implemented rule must be computed under the true channel.
Exercise 1.26.
Equiprobable energies $X\in\{0,1,3\}$ are sent over the additive exponential noise channel $Y=X+Z$, where $Z$ is exponential with mean $\mu=1$, and the receiver uses the ML detector. What is the average error probability?
(a) $\tfrac13\bigl(e^{-1}+e^{-2}\bigr)$
(b) $\tfrac13\bigl(e^{-1/2}+e^{-1}\bigr)$
(c) $\tfrac13\bigl(e^{-1}+e^{-2}+e^{-3}\bigr)$
Show solution
The correct answer is (a) ★
For an observation $y$, the feasible symbols are those with $x\leq y$, and among them $W(y|x)=e^{-y}e^{x}$ grows with $x$: the ML detector selects the largest feasible symbol. On the reachable half-line the regions are $\mathcal D_0=[0,1)$, $\mathcal D_1=[1,3)$ and $\mathcal D_3=[3,\infty)$. When $0$ is sent, an error needs $Z\geq1$, so $P_{\rm e}(0)=e^{-1}$; when $1$ is sent, it needs $1+Z\geq3$, so $P_{\rm e}(1)=e^{-2}$. When $3$ is sent, the noise can only push the output upward, there is no larger symbol, and $P_{\rm e}(3)=0$. Averaging, $P_{\rm e}=\tfrac13(e^{-1}+e^{-2})$.
Option (b) is the nearest-point detector with thresholds $\tfrac12$ and $2$, which is not ML on this channel. Option (c) assigns an error to the largest symbol too. The mean input energy is $E_{\rm s}=(0+1+3)/3=\tfrac43$, and the ratio $E_{\rm s}/\mu=\tfrac43$ is the SNR of this energy channel.
Exercise 1.27.
Energies $X\in\{0,1,3\}$ with priors $\Pr(X=0)=\tfrac35$, $\Pr(X=1)=\tfrac1{10}$ and $\Pr(X=3)=\tfrac3{10}$ are sent over the additive exponential noise channel $Y=X+Z$, where $Z$ is exponential with mean $\mu=1$. What is the average error probability of the MAP detector?
(a) $\tfrac35 e^{-3}+\tfrac1{10}$
(b) $\tfrac35 e^{-1}+\tfrac1{10}e^{-2}$
(c) $\tfrac35 e^{-3}$
Show solution
The correct answer is (a) ★
For a feasible symbol $x\leq y$ the MAP score is $\Pr(x)\,e^{-y}e^{x}$, and the factor $e^{-y}$ is common, so the comparison is between the constant weights $\tfrac35$, $\tfrac{e}{10}\approx0.27$ and $\tfrac{3e^3}{10}\approx6.0$. Since $\tfrac{e}{10}<\tfrac35$, symbol $1$ never wins, not even when it becomes feasible, and its decision region is empty. Symbol $3$ wins as soon as $y\geq3$. Hence MAP decides $0$ on $[0,3)$ and $3$ on $[3,\infty)$. The conditional errors are $P_{\rm e}(0)=\Pr(Z\geq3)=e^{-3}$, $P_{\rm e}(1)=1$ and $P_{\rm e}(3)=0$, and the average is $\tfrac35e^{-3}+\tfrac1{10}\approx0.130$.
Option (c) forgets that the symbol with an empty region is always wrong. Option (b) is the ML detector, with boundaries at $1$ and $3$, whose average $\tfrac35e^{-1}+\tfrac1{10}e^{-2}\approx0.234$ is larger: the middle symbol is rare enough that sacrificing it pays off. The mean input energy is $E_{\rm s}=0+\tfrac1{10}+\tfrac9{10}=1$.
Exercise 1.28.
Equiprobable symbols $X\in\{-1,+1\}$ are sent through $Y=X+Z$, where $Z$ is uniform on $[-2,2]$. The two output supports $[-3,1]$ and $[-1,3]$ overlap on $[-1,1]$, where both likelihoods equal $\tfrac14$, so the ML detector ties on a whole interval. Consider the ML detector that decides $+1$ on the entire overlap, that is $\hat x=-1$ for $y<-1$ and $\hat x=+1$ for $y\geq-1$. What are its conditional error probabilities $\bigl(P_{\rm e}(-1),P_{\rm e}(+1)\bigr)$?
(a) $\bigl(\tfrac12,\tfrac12\bigr)$
(b) $\bigl(\tfrac14,\tfrac14\bigr)$
(c) $\bigl(\tfrac12,0\bigr)$
Show solution
The correct answer is (c) ★
When $-1$ is sent, $Y=-1+Z$ is uniform on $[-3,1]$ and the detector errs when $Y\geq-1$, that is $Z\geq0$, an event of probability $\tfrac12$. When $+1$ is sent, $Y$ is uniform on $[-1,3]$, which lies entirely in the region of $+1$, so $P_{\rm e}(+1)=0$. The average is $\tfrac12\cdot\tfrac12+\tfrac12\cdot0=\tfrac14$.
Option (b) is the nearest-point detector, with threshold at $0$, which is also an ML detector: each error interval has length $1$ out of a support of length $4$, so both conditional errors are $\tfrac14$ and the average is again $\tfrac14$. Unlike the Gaussian case, where ties occur on a probability-zero boundary, here the tie-breaking rule changes the conditional errors on a set of positive probability, although all ML choices share the same average. The noise variance is $\tfrac{4^2}{12}=\tfrac43$, $E_{\rm s}=1$ and the variance-based SNR is $\tfrac34$.
Exercise 1.29.
Symbols $X\in\{-1,+1\}$ with $\Pr(X=+1)=\tfrac45$ are sent through $Y=X+Z$, where $Z$ is uniform on $[-2,2]$, so the two output supports $[-3,1]$ and $[-1,3]$ overlap on $[-1,1]$. What is the average error probability of the MAP detector?
(a) $\tfrac14$
(b) $\tfrac1{10}$
(c) $\tfrac15$
Show solution
The correct answer is (b) ★
On the overlap $[-1,1]$ both likelihoods equal $\tfrac14$, so the posterior equals the prior, $\Pr(X=+1\,|\,y)=\tfrac45$, and MAP decides $+1$ there. On $[-3,-1)$ only $-1$ is possible and on $(1,3]$ only $+1$ is possible. Hence the MAP detector is the threshold $-1$ on the reachable support. When $-1$ is sent, it errs when $-1+Z\geq-1$, so $P_{\rm e}(-1)=\tfrac12$; when $+1$ is sent, it never errs. The average is $\tfrac15\cdot\tfrac12+\tfrac45\cdot0=\tfrac1{10}$.
Option (a) is the nearest-point detector, with conditional errors $(\tfrac14,\tfrac14)$ and average $\tfrac14$, which ignores the prior. Option (c) assumes that $-1$ is always lost, forgetting that it is still detected correctly on $[-3,-1)$. The priors decide how an overlap is split even when the densities are flat.
Exercise 1.30.
Equiprobable symbols $X\in\{-2,0,+2\}$ are sent through $Y=X+Z$, where $Z$ is uniform on $[-\tfrac12,\tfrac12]$, and the receiver uses the nearest-point detector with thresholds at $\pm1$. The average symbol energy is $E_{\rm s}=\tfrac83$ and the noise variance is $\tfrac1{12}$, so $\mathrm{SNR}=32$. What is the average error probability?
(a) $0$
(b) $\tfrac12\operatorname{erfc}(4)$
(c) $\tfrac23\operatorname{erfc}(\sqrt6)$
Show solution
The correct answer is (a) ★
The output supports are $[-\tfrac52,-\tfrac32]$, $[-\tfrac12,\tfrac12]$ and $[\tfrac32,\tfrac52]$. They are disjoint and each lies entirely inside the decision region of its symbol, $(-\infty,-1)$, $(-1,1)$ and $(1,\infty)$. Every conditional error probability is therefore exactly $0$, and so is the average, at the finite value $\mathrm{SNR}=E_{\rm s}/\operatorname{Var}(Z)=\tfrac{8/3}{1/12}=32$.
Option (c) is what the Gaussian 3-PAM formula $\tfrac23\operatorname{erfc}\bigl(1/(\sqrt2\sigma)\bigr)$ gives with $\sigma^2=\tfrac1{12}$, and option (b) is the 2-PAM formula $\tfrac12\operatorname{erfc}(\sqrt{\mathrm{SNR}/2})$ at $\mathrm{SNR}=32$. Neither applies: uniform noise is bounded, whereas Gaussian noise has tails at arbitrarily large distances, and a Gaussian formula cannot be transferred to another channel by substituting the same variance.
Exercise 1.31.
Equiprobable symbols $0$ and $1$ are sent over $Y=X+Z$, where the noise $Z$ is uniform on $[0,2]$. Two receivers are compared. Receiver A applies the nearest-point rule directly to $Y$, with threshold $\tfrac12$. Receiver B first subtracts the noise mean $\mathbb E(Z)=1$ from $Y$ and then chooses the nearest input, which amounts to a threshold at $\tfrac32$ in the original coordinate. What are the average error probabilities of receivers A and B, in that order?
(a) $\tfrac34$ and $\tfrac14$
(b) $\tfrac38$ and $\tfrac14$
(c) $\tfrac38$ and $\tfrac18$
Show solution
The correct answer is (b) ★
When $0$ is sent, $Y=Z\in[0,2]$; when $1$ is sent, $Y=1+Z\in[1,3]$. Receiver A errs for input $0$ when $Z>\tfrac12$, with probability $\tfrac34$, and never errs for input $1$, since $Y\geq1>\tfrac12$. Its average is $\tfrac12\cdot\tfrac34+\tfrac12\cdot0=\tfrac38$. Receiver B errs for input $0$ when $Z>\tfrac32$ and for input $1$ when $1+Z< \tfrac32$, that is $Z< \tfrac12$; both have probability $\tfrac14$, so the average is $\tfrac14$.
Receiver B is in fact ML: the two likelihoods are both $\tfrac12$ on the overlap $[1,2]$ and only one of them is positive elsewhere, so any threshold inside $[1,2]$ is an ML rule, and $\tfrac32$ is one of them. Receiver A decides $1$ on $(\tfrac12,1)$, where input $1$ is impossible. With non-Gaussian noise, nearest point need not be ML, and the supports of the likelihoods matter.
Exercise 1.32.
Equiprobable QPSK symbols $\{\pm1\pm j\}$ are sent over $Y=X+Z$, where the real and imaginary parts of $Z$ are independent and uniform on $[-2,2]$. The receiver uses nearest-point detection, with the four quadrants as decision regions. What is the symbol error probability?
(a) $\tfrac{7}{16}$
(b) $\tfrac12$
(c) $\tfrac14$
Show solution
The correct answer is (a) ★
Take $x=1+j$. The decision is correct when $\re Z>-1$ and $\im Z>-1$. In noise coordinates this is a square of side $3$ inside the support $[-2,2]^2$ of area $16$, so $P_{\rm c}=\tfrac{9}{16}$ and $P_{\rm e}(x)=\tfrac{7}{16}$, the same for the four symbols by symmetry, hence also the average.
Equivalently, each component crosses its boundary with probability $\tfrac14$ and the two events are independent, so $P_{\rm e}=\tfrac14+\tfrac14-\tfrac1{16}=\tfrac{7}{16}$. Adding the two probabilities without subtracting the intersection gives $\tfrac12$, and $\tfrac14$ counts one component only. Each component has variance $\tfrac43$, the total noise variance is $\tfrac83$, and with $E_{\rm s}=2$ the SNR is $\tfrac34$; the product calculation is the same as for Gaussian noise, but the one-dimensional tails are uniform.
Exercise 1.33.
A binary erasure channel has inputs $0,1$ and outputs $0,1,?$, with $W(x|x)=1-\varepsilon$, $W(?|x)=\varepsilon$ and zero otherwise, for $0< \varepsilon< 1$. The prior is $\Pr(X=0)=q$, with $0< q< 1$ and $q\neq\tfrac12$. What is the average error probability of the MAP detector?
(a) $\varepsilon\min(q,1-q)$
(b) $\tfrac12\varepsilon$
(c) $\varepsilon\max(q,1-q)$
Show solution
The correct answer is (a) ★
A non-erased output identifies the input, since the channel never flips a bit, so every detector decides $\hat x=y$ there without error. At an erasure both likelihoods equal $\varepsilon$: any choice is ML, and the MAP detector compares $q\varepsilon$ with $(1-q)\varepsilon$ and decides the more probable bit. It errs only when the other bit was sent and erased, so $P_{\rm e}=\varepsilon\min(q,1-q)$.
Breaking the ML tie toward $0$ gives conditional errors $(0,\varepsilon)$ and average $(1-q)\varepsilon$; toward $1$ it gives $(\varepsilon,0)$ and $q\varepsilon$. The MAP detector picks the smaller of the two, and $\tfrac12\varepsilon$ is the value for every tie-breaking rule only when $q=\tfrac12$. Choosing the less probable bit at the erasure gives the worst value, $\varepsilon\max(q,1-q)$.
Exercise 1.34.
Equiprobable 8-PAM symbols $\{\pm a,\pm3a,\pm5a,\pm7a\}$, with $a>0$, are sent over the real Gaussian channel $Y=X+Z$, $Z\sim\mathcal N(0,\sigma^2)$, and detected with the nearest-point rule. Let $\mathrm{SNR}=E_{\rm s}/\sigma^2$, where $E_{\rm s}$ is the average symbol energy. What is the average error probability?
(a) $\tfrac34\operatorname{erfc}\bigl(\sqrt{\mathrm{SNR}/42}\bigr)$
(b) $\tfrac78\operatorname{erfc}\bigl(\sqrt{\mathrm{SNR}/42}\bigr)$
(c) $\tfrac78\operatorname{erfc}\bigl(\sqrt{\mathrm{SNR}/21}\bigr)$
Show solution
The correct answer is (b) ★
The boundaries are the seven midpoints $0,\pm2a,\pm4a,\pm6a$, each at distance $a$ from its two neighbors. An outer point has one boundary and errs with probability $\tfrac12\operatorname{erfc}\bigl(a/(\sqrt2\sigma)\bigr)$; each of the six inner points has two and errs with probability $\operatorname{erfc}\bigl(a/(\sqrt2\sigma)\bigr)$. Averaging, $P_{\rm e}=\tfrac{2\cdot\frac12+6}{8}\operatorname{erfc}\bigl(a/(\sqrt2\sigma)\bigr)=\tfrac78\operatorname{erfc}\bigl(a/(\sqrt2\sigma)\bigr)$. The energy is $E_{\rm s}=\tfrac{2a^2}{8}(1+9+25+49)=21a^2$, so $a^2/(2\sigma^2)=\mathrm{SNR}/42$.
Option (c) forgets the factor $2$ of the real Gaussian tail, and (a) uses the 4-PAM prefactor. For general even $M$, $E_{\rm s}=(M^2-1)a^2/3$ and $P_{\rm e}=\tfrac{M-1}{M}\operatorname{erfc}\bigl(\sqrt{3\,\mathrm{SNR}/(2(M^2-1))}\bigr)$. At high SNR, doubling $M$ while keeping the argument fixed multiplies the SNR by $(4M^2-1)/(M^2-1)\approx4$, about $6$ dB per extra bit per symbol ($7$ dB from $2$ to $4$ levels, $6.2$ dB from $4$ to $8$).
Exercise 1.35.
Input energies $0$ and $2A$, with $A>0$, have priors $\Pr(X=0)=q$ and $\Pr(X=2A)=1-q$, where $0< q< 1$. The channel is $Y=X+Z$ with exponential noise of mean $\mu>0$: $f_Z(z)=\mu^{-1}e^{-z/\mu}$ for $z\geq0$ and zero otherwise. For which values of $q$ does the MAP detector decide $0$ for every observation $y$, including $y\geq2A$?
(a) $q>\tfrac{1}{1+e^{2A/\mu}}$
(b) $q>\tfrac12$
(c) $q>\tfrac{e^{2A/\mu}}{1+e^{2A/\mu}}$
Show solution
The correct answer is (c) ★
For $y< 2A$ the likelihood of $2A$ is zero, so MAP decides $0$ whatever the prior. For $y\geq2A$ both likelihoods are positive and share the factor $\mu^{-1}e^{-y/\mu}$, so MAP compares $q$ with $(1-q)e^{2A/\mu}$. The comparison does not depend on $y$: an observation above $2A$ carries a fixed amount of evidence, the likelihood ratio $e^{2A/\mu}$, in favor of $2A$. The detector decides $0$ everywhere when $q>(1-q)e^{2A/\mu}$, that is $q>q_*=e^{2A/\mu}/(1+e^{2A/\mu})$, which is larger than $\tfrac12$. Option (a) inverts the ratio and is smaller than $\tfrac12$.
For $q< q_*$ the MAP detector is the ML one, with threshold at $2A$, conditional errors $(e^{-2A/\mu},0)$ and $P_{\rm e}=q\,e^{-2A/\mu}$. For $q>q_*$ it ignores the observation and errs exactly when $2A$ is sent, $P_{\rm e}=1-q$. Both expressions coincide at $q=q_*$, where every tie-breaking rule on $y\geq2A$ gives the same average, so $P_{\rm e,MAP}=\min\{q\,e^{-2A/\mu},1-q\}$.
Exercise 1.36.
A nearest-point detector is used with the constellation $\{0,\,2,\,2j,\,-1-j\}$ in the complex plane. Write $y=u+jv$. Which inequalities describe the decision region of the point $0$, and what is its shape?
(a) $\{u< 1,\ v< 1\}$, an unbounded quadrant
(b) $\{u< 1,\ v< 1,\ u+v>-1\}$, a bounded triangle with vertices $(1,1)$, $(1,-2)$ and $(-2,1)$
(c) $\{u< 1,\ v< 1,\ u+v>-2\}$, a bounded triangle with vertices $(1,1)$, $(1,-3)$ and $(-3,1)$
Show solution
The correct answer is (b) ★
The region of $0$ is the set of points closer to $0$ than to each of the other three. Comparing squared distances gives the perpendicular bisectors $u=1$ (with $2$), $v=1$ (with $2j$) and $u+v=-1$ (with $-1-j$, through the midpoint $-\tfrac12-\tfrac j2$). The three half-planes $u< 1$, $v< 1$ and $u+v>-1$ intersect in the triangle with vertices $(1,1)$, $(1,-2)$ and $(-2,1)$, each equidistant from three constellation points. Option (a) ignores $-1-j$, and option (c) draws the bisector through $-1-j$ instead of through the midpoint.
The other regions are $\mathcal D_2=\{u>1,\ v< u,\ 3u+v>1\}$, $\mathcal D_{2j}=\{v>1,\ v>u,\ u+3v>1\}$ and $\mathcal D_{-1-j}=\{u+v< -1,\ 3u+v< 1,\ u+3v< 1\}$. Only part of each bisector is a boundary: $v=u$ above $(1,1)$, $3u+v=1$ beyond $(1,-2)$ and $u+3v=1$ beyond $(-2,1)$. For 8-PSK, $\{e^{j\pi k/4}\}$, each point owns the sector of angular width $\pi/4$ centered on its angle $k\pi/4$, bounded by the rays at $k\pi/4\pm\pi/8$, and all boundaries pass through the origin.
Exercise 1.37.
Equiprobable QPSK symbols $\{\pm a\pm ja\}$, with $a>0$, are sent over the complex Gaussian channel with total noise variance $\sigma^2$ (independent real and imaginary parts of variance $\sigma^2/2$ each). The receiver uses nearest-point detection, and the symbols carry a Gray labeling: $a+ja\mapsto00$, $-a+ja\mapsto10$, $-a-ja\mapsto11$, $a-ja\mapsto01$. With $E_{\rm b}=E_{\rm s}/\log_2M$ the energy per bit, what is the bit error probability $P_{\rm b}$?
(a) $\tfrac12\operatorname{erfc}\bigl(\sqrt{E_{\rm b}/(2\sigma^2)}\bigr)$
(b) $\operatorname{erfc}\bigl(\sqrt{E_{\rm b}/\sigma^2}\bigr)-\tfrac14\operatorname{erfc}^2\bigl(\sqrt{E_{\rm b}/\sigma^2}\bigr)$
(c) $\tfrac12\operatorname{erfc}\bigl(\sqrt{E_{\rm b}/\sigma^2}\bigr)$
Show solution
The correct answer is (c) ★
With this labeling the first bit is $0$ exactly when $\re x>0$ and the second when $\im x>0$, so the nearest-point detector decides the first bit from the sign of $\re y$ and the second from the sign of $\im y$. Each bit is wrong when its noise component, a real Gaussian of variance $\sigma^2/2$, is below $-a$, which has probability $p=\tfrac12\operatorname{erfc}(a/\sigma)$. The bit error probability is the average fraction of wrong bits, so $P_{\rm b}=p$ exactly. Since $E_{\rm s}=2a^2$ and $M=4$, $E_{\rm b}=a^2$ and $P_{\rm b}=\tfrac12\operatorname{erfc}\bigl(\sqrt{E_{\rm b}/\sigma^2}\bigr)$.
Option (a) uses the real-channel variance convention, and (b) is the symbol error probability $2p-p^2$, which counts the diagonal error (both bits wrong, probability $p^2$) as one event. Binary transmission $\{-A,A\}$ over the same complex channel has $E_{\rm b}=E_{\rm s}=A^2$ and $P_{\rm b}=\tfrac12\operatorname{erfc}(A/\sigma)=\tfrac12\operatorname{erfc}\bigl(\sqrt{E_{\rm b}/\sigma^2}\bigr)$: Gray QPSK is two independent binary transmissions, one per axis, and costs the same energy per bit for the same bit error probability.
Exercise 1.38.
A message of $n=1000$ independent symbols is sent over a memoryless channel. Each symbol is detected from its own observation, with error probability $P_{\rm e}=10^{-3}$. What is the probability that the detected message contains at least one error?
(a) $(1-10^{-3})^{1000}$, close to $e^{-1}$
(b) $1-(1-10^{-3})^{1000}$, close to $1-e^{-1}$
(c) Exactly $1$, since $nP_{\rm e}=1$
Show solution
The correct answer is (b) ★
Let $A_i$ be the event that symbol $i$ is detected correctly, of probability $1-P_{\rm e}$. The symbols are independent, the noise samples of a memoryless channel are independent, and each decision uses only its own observation, so the $A_i$ are independent and the product rule gives $\Pr(\text{all correct})=(1-P_{\rm e})^n$. Hence $\Pr(\text{at least one error})=1-(1-P_{\rm e})^n=1-(1-10^{-3})^{1000}$.
Option (a) is the probability of a fully correct message, and (c) adds the $n$ error probabilities as if the events were disjoint, which is only an upper bound. Since $\ln(1-P_{\rm e})\approx-P_{\rm e}$, the rule of thumb $(1-P_{\rm e})^n\approx e^{-nP_{\rm e}}=e^{-1}$ is accurate here, so the answer is close to $1-e^{-1}$, well above one half: what matters is $nP_{\rm e}$, the expected number of errors, and a $99.9\%$ per-symbol success still leaves most thousand-symbol messages with an error. This is the motivation for coding in Topic 2.
Exercise 1.39.
Equiprobable binary inputs are sent over a discrete channel with outputs $0,1,2$ and law $W(\cdot|0)=(\tfrac12,\tfrac15,\tfrac3{10})$, $W(\cdot|1)=(\tfrac1{10},\tfrac35,\tfrac3{10})$. A front end replaces $Y$ by the binary value $V$, with $V=0$ when $Y\in\{0,1\}$ and $V=1$ when $Y=2$. What are the minimum average error probabilities of a detector that observes only $V$ and of a detector that observes $Y$, in that order?
(a) $\tfrac12$ and $\tfrac3{20}$
(b) $\tfrac3{10}$ and $\tfrac3{10}$
(c) $\tfrac12$ and $\tfrac3{10}$
Show solution
The correct answer is (c) ★
By the sum rule, the induced law from $X$ to $V$ adds the merged probabilities: $\Pr(V=0|X=x)=\tfrac7{10}$ and $\Pr(V=1|X=x)=\tfrac3{10}$ for both inputs. Thus $V$ is independent of $X$, the posterior of either input is $\tfrac12$ at both values of $V$, and every detector based on $V$ has average error $\tfrac12$.
From $Y$, the MAP (here ML) detector decides $0$ at $y=0$ ($\tfrac12>\tfrac1{10}$), $1$ at $y=1$ ($\tfrac35>\tfrac15$) and either bit at $y=2$, a tie. Its probability of a correct decision is $\sum_y\max_x\Pr(x)W(y|x)=\tfrac12\bigl(\tfrac12+\tfrac35+\tfrac3{10}\bigr)=\tfrac7{10}$, so the minimum error is $\tfrac3{10}$; the value $\tfrac3{20}$ forgets the errors at $y=2$. Merging $0$ and $1$ discards the output values that distinguished the inputs, so a binary front end need not keep the useful part of the observation.
Exercise 1.40.
A binary asymmetric channel has $W(1|0)=\tfrac15$ and $W(0|1)=\tfrac25$, with equiprobable inputs. A randomized receiver always decides $1$ at $y=1$, and at $y=0$ decides $1$ with probability $s$ and $0$ with probability $1-s$, where $0\leq s\leq1$. For which $s$ are the two conditional error probabilities $P_{\rm e}(0)$ and $P_{\rm e}(1)$ equal, and what is their common value?
(a) $s=\tfrac14$, both equal to $\tfrac25$
(b) $s=\tfrac16$, both equal to $\tfrac13$
(c) $s=\tfrac13$, both equal to $\tfrac4{15}$
Show solution
The correct answer is (b) ★
When $0$ is sent, output $1$ (probability $\tfrac15$) is always an error, and output $0$ (probability $\tfrac45$) is an error with probability $s$: $P_{\rm e}(0)=\tfrac15+\tfrac45s$. When $1$ is sent, only output $0$ (probability $\tfrac25$) can lead to an error, and it does when the receiver decides $0$: $P_{\rm e}(1)=\tfrac25(1-s)$. Equating, $\tfrac15+\tfrac45s=\tfrac25-\tfrac25s$ gives $s=\tfrac16$ and both errors equal $\tfrac13$. Option (c) forgets the flipped outputs in $P_{\rm e}(0)$, and (a) forgets that randomizing also lowers $P_{\rm e}(1)$.
Since $P_{\rm e}(0)$ increases with $s$ and $P_{\rm e}(1)$ decreases, their maximum is smallest at the crossing, so $s=\tfrac16$ minimizes the worst conditional error within this family. The ML detector ($s=0$) decides the received bit, with conditional errors $(\tfrac15,\tfrac25)$, average $\tfrac3{10}$ and worst value $\tfrac25$. The randomized rule lowers the worst conditional error to $\tfrac13$ but raises the average to $\tfrac13$: which detector is best depends on the criterion.
Exercise 1.41.
The channel is $Y=X+Z$ with $X\in\{-1,1\}$, $Z\sim\mathcal N(0,1)$ and $\Pr(X=1)=q$, where $0 < q < 1$. A receiver that is known to be the MAP detector chooses $\hat x=1$ exactly when $y>(\ln 3)/2$. What is the prior $q$?
(a) $q=\tfrac14$
(b) $q=\tfrac34$
(c) $q=\tfrac1{10}$
Show solution
The correct answer is (a) ★
The MAP detector compares $q\,W(y|1)$ with $(1-q)\,W(y|-1)$. After canceling the common Gaussian factor, the log ratio of the score of $1$ to that of $-1$ is $\ln\tfrac{q}{1-q}+2y$, so MAP chooses $1$ when $y>t$ with $t=\tfrac12\ln\tfrac{1-q}{q}$, that is, $q=\tfrac{1}{1+e^{2t}}$. For $t=(\ln3)/2$ we get $e^{2t}=3$ and $q=\tfrac14$. A positive threshold means that the receiver demands stronger evidence for the less likely symbol $1$; option (b) has the wrong sign and option (c) forgets that the exponent is $2y$, not $4y$.
With this prior, $P_{\rm e}(-1)=\tfrac12\operatorname{erfc}\!\bigl(\tfrac{t+1}{\sqrt2}\bigr)$ and $P_{\rm e}(1)=\tfrac12\operatorname{erfc}\!\bigl(\tfrac{1-t}{\sqrt2}\bigr)$, so $P_{\rm e}=\tfrac38\operatorname{erfc}\!\bigl(\tfrac{t+1}{\sqrt2}\bigr)+\tfrac18\operatorname{erfc}\!\bigl(\tfrac{1-t}{\sqrt2}\bigr)\approx0.127$.
Exercise 1.42.
Let $X\in\{-1,0,1\}$ with probabilities $\Pr(X=-1)=\Pr(X=1)=\tfrac{19}{40}$ and $\Pr(X=0)=\tfrac1{20}$, and let $Y=X+Z$ with $Z\sim\mathcal N(0,1)$. Which is the decision region $\mathcal D_0$ of the input $0$ under the MAP detector?
(a) The interval $|y|<\tfrac12$
(b) The interval $|y|<\tfrac12+\ln\tfrac{19}{2}$
(c) The empty set: the MAP detector never decides $0$
Show solution
The correct answer is (c) ★
Write $r=\tfrac{1/20}{19/40}=\tfrac2{19}$. Canceling the common Gaussian factor, the score of $0$ beats that of $1$ when $r\,e^{-y^2/2}>e^{-(y-1)^2/2}$, that is, $y<\tfrac12+\ln r$, and it beats that of $-1$ when $y>-\tfrac12-\ln r$. Since $\tfrac12+\ln\tfrac2{19}\approx-1.75<0$, the two conditions cannot hold at the same time, and $\mathcal D_0$ is empty. Option (a) is the ML region, which ignores the prior, and option (b) has the sign of the logarithm reversed. Even at $y=0$, each outer score $\tfrac{19}{40}e^{-1/2}\approx0.288$ exceeds the middle score $\tfrac1{20}$.
The two outer symbols have equal priors, so MAP decides by the sign of $y$ (the tie at $y=0$ has probability zero). Hence $P_{\rm e}(\pm1)=\tfrac12\operatorname{erfc}\!\bigl(\tfrac1{\sqrt2}\bigr)$, $P_{\rm e}(0)=1$ and $P_{\rm e}=\tfrac{19}{40}\operatorname{erfc}\!\bigl(\tfrac1{\sqrt2}\bigr)+\tfrac1{20}\approx0.201$. A constellation point need not have a nonempty MAP region when priors are unequal.
Exercise 1.43.
Equiprobable symbols $X\in\{-1,1\}$ are sent through $Y=X+Z$, where the noise has the Laplace density $f_Z(z)=\tfrac12e^{-|z|}$ on the real line, with mean $0$ and variance $2$. What is the average error probability of the ML detector?
(a) $P_{\rm e}=\tfrac12\operatorname{erfc}\!\bigl(\tfrac12\bigr)$
(b) $P_{\rm e}=\tfrac12e^{-1}$
(c) $P_{\rm e}=e^{-1}$
Show solution
The correct answer is (b) ★
Since $W(y|x)=\tfrac12e^{-|y-x|}$ decreases with $|y-x|$, ML is nearest-point detection with boundary at $0$. For input $1$ the error requires $Z<-1$, so $P_{\rm e}(1)=\int_{-\infty}^{-1}\tfrac12e^{-|z|}\,dz=\tfrac12e^{-1}$; by symmetry $P_{\rm e}(-1)$ is the same, and so is the average. Option (c) forgets the factor $\tfrac12$ of the density, that is, it integrates $e^{-z}$ over the tail as if the noise were one-sided.
Option (a) is the error of Gaussian noise with the same variance $2$, namely $\tfrac12\operatorname{erfc}\!\bigl(\tfrac{1}{\sqrt2\cdot\sqrt2}\bigr)$. With $E_{\rm s}=1$ both channels have the same variance-based SNR, $\tfrac12$, yet the Laplace error ($0.184$) is smaller than the Gaussian one ($0.240$). Equal variance does not imply equal tail probabilities at a given threshold.
Exercise 1.44.
Equiprobable symbols $X\in\{-1,1\}$ pass through $Y=-2X+Z$, where $Z\sim\mathcal N(0,1)$ and the gain $-2$ is known at the receiver. Which option gives the ML detector and its average error probability?
(a) $\hat x=1$ when $y>0$, with $P_{\rm e}=\tfrac12\operatorname{erfc}\!\bigl(\sqrt2\bigr)$
(b) $\hat x=1$ when $y<0$, with $P_{\rm e}=\tfrac12\operatorname{erfc}\!\bigl(\tfrac1{\sqrt2}\bigr)$
(c) $\hat x=1$ when $y<0$, with $P_{\rm e}=\tfrac12\operatorname{erfc}\!\bigl(\sqrt2\bigr)$
Show solution
The correct answer is (c) ★
The noiseless received points are $-2x$: $+2$ for $x=-1$ and $-2$ for $x=1$. The likelihood $W(y|x)$ is a Gaussian centered at $-2x$, so ML picks the input whose received point is nearest to $y$: $\hat x=1$ for $y<0$ and $\hat x=-1$ for $y>0$. The boundary is at distance $2$ from each received point, so $P_{\rm e}(\pm1)=\Pr(Z>2)=\tfrac12\operatorname{erfc}\!\bigl(\tfrac{2}{\sqrt2}\bigr)=\tfrac12\operatorname{erfc}(\sqrt2)\approx0.023$, which is also the average.
Option (a) applies nearest-point detection to $y$ with the transmitted alphabet $\{-1,1\}$ and reverses the half-lines: it is wrong with probability $1-\tfrac12\operatorname{erfc}(\sqrt2)\approx0.977$. Option (b) uses the transmitted energy $\mathrm E|X|^2=1$ instead of the received energy $\mathrm E|{-2X}|^2=4$; the received SNR is $4$, not $1$.
Exercise 1.45.
Equiprobable inputs $0$ and $2+2j$ are sent through $Y=X+Z_R+jZ_I$, with independent noises $Z_R\sim\mathcal N(0,1)$ and $Z_I\sim\mathcal N(0,4)$. Write $y=u+jv$. What is the average error probability of the ML detector?
(a) $P_{\rm e}=\tfrac12\operatorname{erfc}\!\Bigl(\sqrt{\tfrac52}\Bigr)$
(b) $P_{\rm e}=\tfrac12\operatorname{erfc}\!\Bigl(\sqrt{\tfrac58}\Bigr)$
(c) $P_{\rm e}=\tfrac12\operatorname{erfc}\!\Bigl(\sqrt{\tfrac25}\Bigr)$
Show solution
The correct answer is (b) ★
Up to a common factor, $W(y|x)=\exp\bigl[-\tfrac{(u-x_R)^2}{2}-\tfrac{(v-x_I)^2}{8}\bigr]$, so ML minimizes the weighted distance $(u-x_R)^2+\tfrac14(v-x_I)^2$. Expanding for $x=0$ and $x=2+2j$, ML chooses $2+2j$ when $4u+v>5$. Under input $0$ the statistic $4Z_R+Z_I$ is Gaussian with variance $16+4=20$, so $P_{\rm e}(0)=\Pr(4Z_R+Z_I>5)=\tfrac12\operatorname{erfc}\!\bigl(\tfrac{5}{\sqrt{40}}\bigr)=\tfrac12\operatorname{erfc}\!\bigl(\sqrt{5/8}\bigr)$; under $2+2j$ the statistic has mean $10$ and the error across the threshold $5$ is the same.
Option (c) is the error of ordinary Euclidean nearest-point detection, which chooses $2+2j$ when $u+v>2$: the statistic $Z_R+Z_I$ has variance $5$ and the error is $\tfrac12\operatorname{erfc}\!\bigl(\sqrt{2/5}\bigr)$, larger than ML because Euclidean distance is not ML when the two axes have unequal variances. Option (a) drops the factor $4$ in the variance of the ML statistic. Finally $E_{\rm s}=\tfrac{0+8}{2}=4$ and the total noise variance is $5$, so $\mathrm{SNR}=\tfrac45$.
Exercise 1.46.
Equiprobable complex inputs $0$, $2$ and $1+j\sqrt3$ (an equilateral triangle of side $2$) are sent through a complex Gaussian channel with total noise variance $\sigma^2=2$, and the receiver uses nearest-point detection. Each input has two neighbors at distance $2$, so the probability of crossing one given boundary is $p=\tfrac12\operatorname{erfc}\!\bigl(\tfrac1{\sqrt2}\bigr)$. Which statement about the average error probability $P_{\rm e}$ is correct?
(a) $P_{\rm e}=1-(1-p)^2=2p-p^2$, because the two boundary crossings are independent events
(b) $P_{\rm e}$ is strictly smaller than $2p-p^2$: the two boundary crossings are not independent, because both involve the real noise component
(c) $P_{\rm e}=2p$, because the two boundary crossings are disjoint events
Show solution
The correct answer is (b) ★
Write $y=u+jv$. Comparing squared distances, the region of $0$ is $\{u<1,\ u+\sqrt3v<2\}$. The noise components are independent with variance $1$ each, so, conditioning on $Z_R=u$, correct detection requires $Z_I<(2-u)/\sqrt3$ and $$P_{\rm c}(0)=\int_{-\infty}^{1}\phi(u)\Bigl[1-\tfrac12\operatorname{erfc}\!\Bigl(\tfrac{2-u}{\sqrt6}\Bigr)\Bigr]du\approx0.745,\qquad \phi(u)=\tfrac{e^{-u^2/2}}{\sqrt{2\pi}}.$$ By the symmetry of the triangle and of circular noise, all three conditional errors coincide, so $P_{\rm e}=1-P_{\rm c}(0)\approx0.255$, which is smaller than $2p-p^2\approx0.292$ and than $2p\approx0.317$. There is no closed form in terms of $\operatorname{erfc}$ alone, but the comparison does not need the value.
The two boundary events involve $Z_R$ and $Z_R+\sqrt3Z_I$, which share $Z_R$ and are not independent. Treating them as independent gives option (a), $1-(1-p)^2$, and adding their probabilities (the union bound) gives option (c), $2p$; both overestimate because the two events overlap, and the union bound is never an equality here because the two crossings can happen together. The average energy is $E_{\rm s}=\tfrac{0+4+4}{3}=\tfrac83$, so $\mathrm{SNR}=\tfrac43$.
Exercise 1.47.
Equiprobable 4-PAM amplitudes $-3,-1,1,3$ are sent through a real Gaussian channel with noise variance $1$ and detected by nearest-point detection, whose symbol error probability is $P_{\rm e}=\tfrac34\operatorname{erfc}\!\bigl(\tfrac1{\sqrt2}\bigr)$. Each symbol carries two bits with the Gray labeling $00,01,11,10$ in increasing amplitude order. Counting all wrong destinations, not only the adjacent ones, what is the exact bit error probability?
(a) $P_{\rm b}=\tfrac12\operatorname{erfc}\!\bigl(\tfrac1{\sqrt2}\bigr)-\tfrac18\operatorname{erfc}\!\bigl(\tfrac3{\sqrt2}\bigr)+\tfrac18\operatorname{erfc}\!\bigl(\tfrac5{\sqrt2}\bigr)$
(b) $P_{\rm b}=\tfrac38\operatorname{erfc}\!\bigl(\tfrac1{\sqrt2}\bigr)+\tfrac14\operatorname{erfc}\!\bigl(\tfrac3{\sqrt2}\bigr)-\tfrac18\operatorname{erfc}\!\bigl(\tfrac5{\sqrt2}\bigr)$
(c) $P_{\rm b}=\tfrac38\operatorname{erfc}\!\bigl(\tfrac1{\sqrt2}\bigr)$
Show solution
The correct answer is (b) ★
The boundaries are $-2,0,2$. Write $e_k=\tfrac12\operatorname{erfc}\!\bigl(\tfrac{k}{\sqrt2}\bigr)$. From the outer input $-3$, the detector decides $-1$, $1$ and $3$ with probabilities $e_1-e_3$, $e_3-e_5$ and $e_5$; from the inner input $-1$, it decides $-3$, $1$ and $3$ with probabilities $e_1$, $e_1-e_3$ and $e_3$. The other two rows follow by reflection. With Gray labels, the numbers of bits in which $-3$ differs from $-1,1,3$ are $1,2,1$, and $-1$ differs from $-3,1,3$ in $1,1,2$ bits. The expected numbers of wrong bits are $e_1+e_3-e_5$ for an outer input and $2e_1+e_3$ for an inner one. Averaging over the four inputs and dividing by the two bits per symbol, $$P_{\rm b}=\tfrac12\cdot\tfrac{2(e_1+e_3-e_5)+2(2e_1+e_3)}{4}=\tfrac{3e_1+2e_3-e_5}{4}=\tfrac38\operatorname{erfc}\!\bigl(\tfrac1{\sqrt2}\bigr)+\tfrac14\operatorname{erfc}\!\bigl(\tfrac3{\sqrt2}\bigr)-\tfrac18\operatorname{erfc}\!\bigl(\tfrac5{\sqrt2}\bigr)\approx0.1197.$$
Option (c) is $P_{\rm e}/2\approx0.1190$, the value obtained by assuming that every error flips exactly one bit; it is only an approximation, because an error to a nonadjacent point flips two bits. Option (a) is the bit error probability of the natural labeling $00,01,10,11$, about $0.1583$, where the neighbors $01$ and $10$ differ in two bits. Gray labeling reduces the bit error probability but does not make $P_{\rm b}$ equal to $P_{\rm e}/2$ exactly.
Exercise 1.48.
Equiprobable symbols $X\in\{-1,1\}$ are sent through $Y=X+Z$ with $Z\sim\mathcal N(0,1)$. The receiver reports $-1$ when $y<-\tfrac12$, reports $1$ when $y>\tfrac12$, and otherwise abstains with an erasure. What is the probability that a reported bit is wrong, that is, the error probability conditioned on the receiver reporting a bit?
(a) $\tfrac12\operatorname{erfc}\!\bigl(\tfrac{1}{2\sqrt2}\bigr)$
(b) $\tfrac{\tfrac12\operatorname{erfc}\!\bigl(\tfrac{3}{2\sqrt2}\bigr)}{1-\tfrac12\operatorname{erfc}\!\bigl(\tfrac{1}{2\sqrt2}\bigr)+\tfrac12\operatorname{erfc}\!\bigl(\tfrac{3}{2\sqrt2}\bigr)}$
(c) $\tfrac12\operatorname{erfc}\!\bigl(\tfrac{3}{2\sqrt2}\bigr)$
Show solution
The correct answer is (b) ★
For input $1$, a wrong bit requires $Z<-\tfrac32$, with probability $w=\tfrac12\operatorname{erfc}\!\bigl(\tfrac{3}{2\sqrt2}\bigr)\approx0.067$; an erasure requires $-\tfrac32\le Z\le-\tfrac12$, with probability $\tfrac12\operatorname{erfc}\!\bigl(\tfrac{1}{2\sqrt2}\bigr)-w\approx0.242$; a correct bit requires $Z>-\tfrac12$, with probability $c=1-\tfrac12\operatorname{erfc}\!\bigl(\tfrac{1}{2\sqrt2}\bigr)\approx0.691$. By symmetry the same three numbers hold for input $-1$, so they are the unconditional probabilities and they sum to one. Conditioning on a bit being reported, $\Pr(\text{wrong}\mid\text{bit reported})=\tfrac{w}{w+c}\approx0.088$.
Option (c) is the unconditional probability $w$ of a wrong bit, without the conditioning. Option (a) counts every erasure as a failure, $w+\text{erasure}=\tfrac12\operatorname{erfc}\!\bigl(\tfrac{1}{2\sqrt2}\bigr)\approx0.309$, which is larger than the error $\tfrac12\operatorname{erfc}\!\bigl(\tfrac1{\sqrt2}\bigr)\approx0.159$ of ordinary nearest-point detection. Abstaining makes the retained decisions more reliable at the cost of discarding about $24\%$ of the observations.
Exercise 1.49.
Equiprobable symbols $X\in\{-a,a\}$, with $a>0$ a design parameter, are sent with additive noise uniform on $[-b,b]$, $b>0$ fixed, and nearest-point detection. The noise variance is $b^2/3$. What is the smallest SNR $=E_{\rm s}/\operatorname{Var}(Z)$ that guarantees $P_{\rm e}\le\tfrac1{20}$?
(a) $\mathrm{SNR}=\tfrac{27}{10}$
(b) $\mathrm{SNR}=\tfrac{243}{100}$
(c) $\mathrm{SNR}=\tfrac{81}{100}$
Show solution
The correct answer is (b) ★
The boundary is $0$. For input $a$ the error requires $Z<-a$, a tail of length $b-a$ out of $2b$ when $a < b$, and an event of probability zero when $a\ge b$. By symmetry the same holds for $-a$, so $P_{\rm e}=\max\{0,\tfrac{b-a}{2b}\}$. The target $\tfrac{b-a}{2b}\le\tfrac1{20}$ requires $a\ge\tfrac9{10}b$, hence the smallest symbol energy is $E_{\rm s}=a^2=\tfrac{81}{100}b^2$ and the smallest SNR is $\tfrac{81b^2/100}{b^2/3}=\tfrac{243}{100}=2.43$.
Option (c) is the ratio $a^2/b^2$, which forgets that the variance of the uniform noise is $b^2/3$ and not $b^2$; option (a) multiplies by $3$ the ratio $a/b$ instead of its square. For comparison, zero error first occurs at $a=b$, that is, at $\mathrm{SNR}=3$: the shifted supports then touch only at a point of probability zero, so the tie assignment does not matter.
Exercise 1.50.
A binary asymmetric channel has $W(1|0)=\tfrac1{10}$ and $W(0|1)=\tfrac3{10}$, and the prior $\Pr(X=0)=q$ varies over $0\le q\le1$. For each $q$ the MAP detector is used. Which prior makes the MAP error probability largest, and what is that error?
(a) $q=\tfrac78$, with $P_{\rm e}=\tfrac18$
(b) $q=\tfrac12$, with $P_{\rm e}=\tfrac15$
(c) $q=\tfrac14$, with $P_{\rm e}=\tfrac14$
Show solution
The correct answer is (c) ★
At output $0$, MAP compares $\tfrac9{10}q$ with $\tfrac3{10}(1-q)$ and chooses $0$ when $q>\tfrac14$. At output $1$, it compares $\tfrac1{10}q$ with $\tfrac7{10}(1-q)$ and chooses $0$ when $q>\tfrac78$. Hence MAP always decides $1$ for $q<\tfrac14$, follows the received bit for $\tfrac14 < q < \tfrac78$, and always decides $0$ for $q>\tfrac78$; at $q=\tfrac14$ and $q=\tfrac78$ one output is tied and either choice gives the same error. The minimum error is therefore $$P_{\rm e}(q)=\begin{cases}q,&0\le q\le\tfrac14,\\ \tfrac3{10}-\tfrac q5,&\tfrac14\le q\le\tfrac78,\\ 1-q,&\tfrac78\le q\le1.\end{cases}$$ The first piece increases and the other two decrease, so the maximum is $P_{\rm e}=\tfrac14$ at $q=\tfrac14$.
Option (b) is the equiprobable prior, whose MAP error is only $\tfrac3{10}-\tfrac1{10}=\tfrac15$; option (a) is the other transition point, where the error is $\tfrac18$. For an asymmetric channel the equiprobable prior need not be the hardest one for the optimal detector.