Signal Waveforms from Binary Codes#

Codewords#

  • In communication: Codewords represent the distinct messages or data blocks that we want to send (e.g., \(\{c_1, c_2, \ldots, c_M\}\)).

  • In radar: Codewords can be viewed as distinct chirp sequences (often PN sequences). Each unique codeword gives a unique temporal pattern in the transmitted signal.

One-to-One Mapping to Waveforms#

Codebook

We have an ordered list (or “codebook”) of \(M\) codewords. For each codeword:

\[ c_m = [c_{m1} \, c_{m2} \,\dots\, c_{mN}], \quad m=1,2,\ldots,M \]

Each \(c_{mj}\) is a symbol from a finite alphabet (in our example, bits \(\{0,1\}\)).

Constructing a Waveform

To transmit codeword \(c_m\), we map each symbol \(c_{mj}\) to a sub‐signal (e.g., a BPSK pulse of length \(T_c\) with + or − amplitude, or a segment of a chirp, etc.). we concatenate these sub‐signals (for \(j=1 \ldots N\)) to form the full waveform:

\[ s_m(t), \quad m = 1, 2, \ldots, M \]

In doing so, we ensure that every codeword \(c_m\) corresponds uniquely to one distinct waveform \(s_m(t)\).

Each bit \(c_{mj}\) (0 or 1) is mapped to one of two possible phase‐reversed waveforms of duration \(T_c\). Concretely:

  • If \(c_{mj} = 1\):

    \[ \text{Signal for bit }1: \quad +\sqrt{\frac{2\mathcal{E}_c}{T_c}}\cos\bigl(2\pi f_c t\bigr), \quad 0 \le t \le T_c \]
  • If \(c_{mj} = 0\):

    \[ \text{Signal for bit }0: \quad -\sqrt{\frac{2\mathcal{E}_c}{T_c}}\cos\bigl(2\pi f_c t\bigr), \quad 0 \le t \le T_c \]

Cardinality#

Because there is no overlap or reuse of codewords, each codeword in the set has a distinct counterpart waveform in the signal set. Thus, the codeword set \(\{c_m\}\) and the waveform set \(\{s_m(t)\}\) have the same number of elements \(M\).

  • Uniqueness Requirement
    In most applications (communication or radar), we want to distinguish unambiguously between the different codewords. This is only possible if each codeword maps to a unique (non‐confusable) waveform.

  • One Codeword → One Waveform
    The system does not merge codewords or split them further at the waveform level. It simply assigns each codeword to its own physical wave, preserving the exact count.

  • No Codeword Overlaps
    Two codewords \(c_m\) and \(c_{m'}\) can only correspond to the same waveform if they are identical (which they’re not by definition of being two different codewords). Hence, the mapping is a bijection (one‐to‐one and onto).

Thus, we end up with \(M\) possible (and only \(M\) possible) transmitted waveforms—exactly matching the \(M\) codewords.

Formation of the \(M\)-Waveforms

  1. Concatenate bit‐waveforms in time
    To transmit the \(m\)‐th codeword \(c_m\), we send the sequence of BPSK symbols corresponding to each bit \(c_{m1}, c_{m2}, \dots, c_{mN}\) in back‐to‐back intervals of length \(T_c\).

  2. Resulting waveform
    This produces one continuous waveform \(s_m(t)\), of total duration \(T\). Each \(s_m(t)\) is composed of \(N\) sub‐pulses (each of length \(T_c\)), with each sub‐pulse having the appropriate sign (\(+\) or \(-\)) of the carrier \(\cos(2\pi f_c t)\).

Hence, we get \(M\) distinct waveforms (one for each codeword),

\[ \{s_m(t)\}, \quad m = 1, 2, \ldots, M \]

Number of Possible Waveforms#

  • Binary Codewords:

    • Each codeword has length \(N\).

    • Each position in the codeword can be either 0 or 1.

    • Consequently, there are \(2^N\) distinct binary codewords of length \(N\).

  • Mapping Codewords to Waveforms (BPSK):

    • We use Binary Phase Shift Keying (BPSK) for each bit.

    • Each bit \(c_{mj}\in \{0,1\}\) is mapped to \(\pm \sqrt{\tfrac{\mathcal{E}}{N}}\), which in the continuous‐time domain becomes \(\pm \sqrt{\frac{2\mathcal{E}_c}{T_c}}\cos(2\pi f_c t)\) over one chip interval.

    • Therefore, each of the \(2^N\) binary sequences can be turned into a unique \(N\)-symbol BPSK waveform.

  • Subset Selection (\(M < 2^N\)):

    • In some applications, we might not need or want all \(2^N\) possible waveforms. Instead, we may select a subset of size \(M\) (\(M \le 2^N\)).

    • This subset becomes our signal set, and each codeword in that subset represents one of our \(M\) messages.

    • For instance, we might choose a smaller code (fewer than \(2^N\) codewords) with better error‐correcting properties, or in radar, we might use only some special PN (Pseudo‐Noise) sequences out of all possible sequences.

Hence, the maximum possible waveforms from all binary sequences is \(2^N\), but the actual number of used waveforms could be anywhere from 1 up to \(2^N\).

Signal Space and Geometric Representation#

  • Signal Space and the Hypercube

    • When each dimension (bit) is mapped to \(\pm\sqrt{\tfrac{\mathcal{E}}{N}}\), we get an \(N\)-dimensional vector whose coordinates are either \(+\sqrt{\tfrac{\mathcal{E}}{N}} \) or \(-\sqrt{\tfrac{\mathcal{E}}{N}}\).

    • Visually, we can imagine each symbol coordinate as an axis in an \(N\)-dimensional space.

    • The set of all \(2^N\) possible sign combinations \(\{+,-\}^N\) are the vertices of an \(N\)-dimensional hypercube (also known as a hypercube constellation).

  • Center at the Origin

    • Because the average of \(+1\) and \(-1\) is 0 (and we often normalize so the constellation is centered), we can interpret the hypercube as being centered at the origin of the coordinate system.

    • Each vertex is equally distant from the origin, because each point has the same energy (see next section).

  1. Examples (\(N=2\) and \(N=3\))

    • \(N=2\): we get 4 possible points: \((+,+)\), \((+,-)\), \((- ,+)\), \((- ,-)\). Geometrically, these are the 4 corners of a square (2D).

    • \(N=3\): we get 8 possible points forming the corners of a cube (3D).

    • For higher \(N\), it generalizes to a hypercube in \(N\) dimensions.

Vector / Block Representation

  • Discrete vector form
    Because each waveform is just a sequence of \(N\) BPSK chips, we can represent it in an \(N\)-dimensional vector form:

    \[ \vec{s}_m = [\, s_{m1},\, s_{m2},\, \ldots,\, s_{mN}\,] \]

    where each component \(s_{mj}\in \Bigl\{ +\sqrt{\frac{\mathcal{E}}{N}},\,-\sqrt{\frac{\mathcal{E}}{N}}\Bigr\}\).

  • Block length
    The parameter \(N\) is called the block length of the code, denoting how many bits (or BPSK symbols) are used to represent one entire codeword.

Thus, in an \(N\)-dimensional signal space, each waveform \(s_m\) is a vector with entries \(\pm \sqrt{\frac{\mathcal{E}}{N}}\). Two different codewords \(c_m\) and \(c_{m'}\) differ in at least one bit, leading to at least one symbol sign flip, and hence produce different vectors (and therefore different waveforms in time).

Waveform Energy#

  • Equal Energy per Symbol

    • By design, each dimension (each bit’s sub‐signal) has an energy of \(\frac{\mathcal{E}}{N}\).

    • This means that for each dimension we have amplitude \(\pm \sqrt{\frac{\mathcal{E}}{N}}\).

  • Total Energy of \(\mathcal{E}\)

    • In vector form, the waveform can be written as:

      \[ \vec{s}_m = \Bigl[s_{m1}, s_{m2}, \ldots, s_{mN}\Bigr], \quad s_{mj} \in \Bigl\{+\sqrt{\tfrac{\mathcal{E}}{N}}, -\sqrt{\tfrac{\mathcal{E}}{N}}\Bigr\} \]
    • The energy of this signal (sum of squares of coordinates) is:

      \[ \sum_{j=1}^N \Bigl(\sqrt{\tfrac{\mathcal{E}}{N}}\Bigr)^2 \;=\; \sum_{j=1}^N \tfrac{\mathcal{E}}{N} \;=\; \mathcal{E} \]
    • Hence every such BPSK waveform in this \(N\)-dimensional set has the same total energy, \(\mathcal{E}\).

  • Constant Energy Constellations

    • Having each possible signal point at the same distance from the origin means the constellation is a constant‐energy code.

    • This is beneficial in many contexts (e.g., power efficiency and simpler detection metrics, because the detector typically only has to measure differences in sign/polarity rather than amplitude).

Key Waveform Parameters

  • Symbol/Chip duration:

    \[ T_c = \frac{T}{N} \]

    so that the total block time \(T\) (for transmitting \(N\) bits in the codeword) is split into \(N\) smaller intervals. Each bit occupies one interval of length \(T_c\).

  • Energy per bit:

    \[ \mathcal{E}_c = \frac{\mathcal{E}}{N} \]

    meaning if the total energy allocated to transmit an entire codeword is \(\mathcal{E}\), then each bit‐interval has energy \(\mathcal{E}_c\). In other words, over the duration \(T_c\) of each BPSK symbol, the signal power integrates to \(\mathcal{E}_c\).

Thus, we can see that the amplitude is chosen as \(\sqrt{\frac{2\mathcal{E}_c}{T_c}}\) so that each bit has the correct energy \(\mathcal{E}_c\) when integrated over the interval \([0, T_c]\).

Minimum Distance#

Cross‐Correlation#

  • Waveform Construction
    Each \(N\)-bit codeword is mapped to an \(N\)-dimensional BPSK vector:

    \[ s_m = \bigl[s_{m1},\, s_{m2},\,\dots,\, s_{mN}\bigr] \]

    where \(s_{mj} \in \bigl\{ +\sqrt{\mathcal{E}/N},\,-\sqrt{\mathcal{E}/N}\bigr\}\)

  • Total of \(2^N\) Possible Vectors
    Because each of the \(N\) components can be \(\pm \sqrt{\mathcal{E}/N}\), there are \(2^N\) possible signal vectors (waveforms).

  • Selecting a Subset
    In practice, we might only pick \(M \le 2^N\) of these vectors as our actual codebook/signaling set. The cross‐correlation between any two chosen waveforms depends on how many coordinates (bits) they differ in.

It is noted that the cross‐correlation between two BPSK waveforms is proportional to their dot product in \(N\)-dimensional space. The dot product depends on how many matching or differing signs there are across their \(N\) coordinates.

Cross‐Correlation Coefficient (\(\rho\)) for Adjacent Points

  • Definition of Adjacent
    Two signal points (waveforms) are called adjacent if they differ in exactly one coordinate (i.e., they differ in exactly one bit out of \(N\)).

  • Example
    Consider two vectors \(s_m\) and \(s_{m'}\) that are identical in all but one dimension, say the \(j\)-th dimension.

    \[ s_{mj} = +\sqrt{\tfrac{\mathcal{E}}{N}}, \quad s_{m'j} = -\sqrt{\tfrac{\mathcal{E}}{N}}, \quad\text{and } s_{mk} = s_{m'k} \; \forall k \neq j \]

Dot Product and Correlation

  • Dot Product
    Since the two vectors differ in only the \(j\)-th coordinate, their dot product is:

    \[ s_m \cdot s_{m'} \;=\; \underbrace{\sum_{k \neq j} \Bigl(\sqrt{\tfrac{\mathcal{E}}{N}}\Bigr)^2}_{(N-1)\times(\tfrac{\mathcal{E}}{N})} \;+\; \underbrace{\Bigl(+\sqrt{\tfrac{\mathcal{E}}{N}}\Bigr)\Bigl(-\sqrt{\tfrac{\mathcal{E}}{N}}\Bigr)}_{-\,(\tfrac{\mathcal{E}}{N})} \]
    • For the \(N-1\) identical coordinates, each contributes \(+\frac{\mathcal{E}}{N}\).

    • For the 1 differing coordinate, the product is \(-\frac{\mathcal{E}}{N}\).

    Therefore,

    \[ s_m \cdot s_{m'} = (N-1)\,\tfrac{\mathcal{E}}{N} \;-\;\tfrac{\mathcal{E}}{N} = (N-2)\,\tfrac{\mathcal{E}}{N} \]
  • Normalization
    Each vector \(s_m\) has length \(\sqrt{\mathcal{E}}\). So the correlation coefficient between \(s_m\) and \(s_{m'}\) is

    \[ \rho = \frac{s_m \cdot s_{m'}}{\|s_m\|\;\|s_{m'}\|} = \frac{(N-2)\tfrac{\mathcal{E}}{N}}{\mathcal{E}} = \frac{N-2}{N} \]

Hence, two waveforms that differ in exactly one bit have cross‐correlation coefficient \(\rho = \frac{N-2}{N}\).

Note:
If waveforms differ in more than one bit, the dot product will change accordingly. The minimum correlation occurs when many bits differ (the vectors are more opposite), and the maximum correlation occurs when they match in most bits.

Minimum Distance Between Adjacent Points#

  • Euclidean Distance in \(N\)-Dimensional Space
    The distance between two points \(s_m\) and \(s_{m'}\) is:

    \[ d = \|s_m - s_{m'}\| \]
  • Case: Adjacent Points Differing in One Bit

    • Suppose they differ in exactly one coordinate:

      \[ s_{mj} - s_{m'j} = \bigl(\!+\!\sqrt{\tfrac{\mathcal{E}}{N}}\bigr) - \bigl(\!-\!\sqrt{\tfrac{\mathcal{E}}{N}}\bigr) = 2\,\sqrt{\tfrac{\mathcal{E}}{N}} \]
    • In the other \(N-1\) coordinates, the difference is zero (since they’re the same).

    Thus, the squared distance is

    \[ d^2 = \bigl(2\,\sqrt{\tfrac{\mathcal{E}}{N}}\bigr)^2 = 4\,\tfrac{\mathcal{E}}{N} \]

    Taking the square root:

    \[ d_{\min} \;=\; 2\,\sqrt{\tfrac{\mathcal{E}}{N}} = \sqrt{\tfrac{4\,\mathcal{E}}{N}} \]
  • Alternate Expression via Cross‐Correlation
    The formula given is

    \[ d_{\min} = \sqrt{2\,\mathcal{E}\,(1-\rho)} \quad\text{where}\; \rho = \frac{N-2}{N} \]

    Substituting \(\rho\):

    \[ 1 - \rho = 1 - \frac{N-2}{N} = \frac{2}{N} \]

    Hence,

    \[ \boxed{ d_{\min} = \sqrt{\tfrac{4\,\mathcal{E}}{N}} } \]

    which matches the direct geometric derivation.