Notice that each point is equally spaced by a distance \(d\). We can write our constellation as follows
\[
A = \left\{ \frac{-3d}{2}, \frac{-d}{2}, \frac{d}{2}, \frac{3d}{2} \right\}
\]
We could write the probability of \(\tilde{a}\) on our constellation diagram to see what we can expect to detect.
Code
import matplotlib.pyplot as pltimport numpy as npimport scipy.stats as statsx = [-3, -1, 1, 3]labels = [r"$\frac{-3d}{2}$", r"$\frac{-d}{2}$", r"$\frac{d}{2}$", r"$\frac{3d}{2}$"]plt.figure(figsize=(6, 1))plt.box(False)plt.plot(x, [0, 0, 0, 0], 'ko-')plt.xticks(x, labels)for v in x: mu = v variance =1 sigma = np.sqrt(variance) x = np.linspace(mu -3*sigma, mu +3*sigma, 100) plt.plot(x, stats.norm.pdf(x, mu, sigma))plt.yticks([])plt.show()
Notice that at every point there is some \(a[n]\) which has a higher likelihood than any others. This value is the maximum likelihood estimate. We can thus split our constellation to determine how a received symbol will be detected. We call these separate regions decision regions\(D_a\). In this case, our decision regions are between the thresholds \(-d, 0, +d\).
These decision region tells us how a particular received symbol would be detected. For example, let the actual symbol \(\hat{A} = \frac{+d}{2}\). Then if the received symbol \(\tilde{A}\) falls within the correct range, i.e. \(0 \leq \tilde{A} \leq +d\), we would detect it correctly. We can thus describe our decision regions based on their range of acceptable values, i.e. \(D_{\frac{+d}{2}} = \{\tilde{a}: 0 \leq \tilde{a} \leq +d\}\).
We can similarly define an error in detection if the received symbol falls outside the region in which the correct symbol resides. Mathematically, we say an error occurs when \(\tilde{a} \notin D_{a}\), or \(\tilde{a} \in D^C_{a}\).
2 Analysis of Probability of Error
We can think of our received symbols as random variables. We can express the probability of an error as follows by using the total probability law
\[
\mathbb{P}[\hat{A}_{ML} \neq A] = \sum_{a \in A} \mathbb{P}[\hat{A} \neq A \mid A = a] \mathbb{P}[A=a]
\]
Very often, we assume that symbols are uniformly distributed, so the term \(\mathbb{P}[A=a]\) is simply \(\frac{1}{|A|}\). We can then rewrite the above expression
This equation is true in general for constellations with uniform distributions and Gaussian noise. If we look at the picture from before, though, we see that there is some symmetry to take advantage of.
Notice that the probability of error in the shaded region near \(-d\) is the same size as the shaded region near \(+d\), only mirrored. We can take advantage of this property to make our computations easier.
2.1 Example
We can compute the probability of detecting \(\hat{A}\) when we know \(A=\frac{-3d}{2}\)
\[
\mathbb{P} [\hat{A} \neq A \mid A = \frac{-3d}{2}] = \int_{-d}^{\infty} N(\tilde{a}, \frac{-3d}{2}, \frac{N_0}{2}) d\tilde{a}
\]
The first step whenever integrating a Guassian distribution with a non-zero mean and non-unit variance is to normalize it. We can say \(b=\frac{\tilde{a} - \frac{-3d}{2}}{\sqrt \frac{N_0}{2}}\) and then rewrite our equation using \(b\)
\[
\mathbb{P} [\hat{A} \neq A \mid A = \frac{-3d}{2}] = \int_{\frac{d / 2}{\sqrt{N_0 / 2}}}^{\infty} N(b, 0, 1) db
\]
There are a few conventions in performance analysis to be aware of.
Rewrite result in terms of \(\frac{E_s}{N_0}\) where \(E_s = \mathbb{E}[|A|^2]\), i.e. the average energy of the symbol constellation. For the specific case of 4-PAM, the average energy (computation left to the reader) is \(5/4 d^2\). This leaves the probability of error to be