Field Guide · algorithm

Also known as: interleaving, interleaver, de-interleaving

Interleaving reorders bits or symbols before transmission and restores their order on receive, so that a burst of channel errors — from a fade, a click of interference, or a dropped symbol — is spread thinly across many codewords instead of overwhelming one.1 It adds no redundancy of its own; it is a rearrangement that makes the redundancy already present in a forward-error-correction code far more effective, because FEC codes tolerate many scattered errors but only a few clustered ones.

write rows → read columns a contiguous burst becomes one error per codeword
A block interleaver writes codewords into a matrix by rows and transmits by columns; a burst on the channel is then split so each codeword loses only a few bits it can correct.

How it works

The reasoning is a simple counting argument. Suppose an FEC code corrects up to t errors per N-bit codeword, and the channel produces bursts up to B bits long. Sent one codeword at a time, a single B-bit burst with B > t is uncorrectable and the codeword is lost. Interleave D codewords together, though, and the same burst is diluted: consecutive channel bits now come from different codewords, so a burst of B bits deposits at most ⌈B/D⌉ errors into any one codeword. Choose the interleaving depth D large enough that ⌈B/D⌉ ≤ t and every codeword survives. The transmitter interleaves before sending; the receiver de-interleaves before decoding, undoing the permutation so the FEC sees near-random errors, which is the regime its correcting power is designed for.

Variants

  • Block interleaver. Write R codewords row-by-row into an R×C matrix, transmit column-by-column. Simple and exact, but it must fill and drain the whole block, so it adds latency proportional to the matrix size and protects only against bursts shorter than a column span. Best when data is naturally framed.
  • Convolutional interleaver. Feed symbols through a bank of shift-register delay lines of increasing length, cycling across the lines. It achieves the same burst-spreading with roughly half the memory and half the end-to-end latency of a block interleaver of equal power, and it works on a continuous stream — which is why it appears in DVB and DSL.
  • Matrix / product interleaving. Two-dimensional schemes (rows and columns) underpin product codes such as BPTC, where the interleave pattern is chosen so that a physical burst never lands entirely within one row or one column codeword.

In practice

Interleaving’s cost is latency and memory: deeper interleaving spreads longer bursts but delays every bit by the time it takes to fill and drain the interleaver, so voice systems must balance robustness against a delay budget of tens of milliseconds. The depth is therefore tuned to the channel’s expected fade duration at the symbol rate, not made arbitrarily large. A common design rule is to size the depth so the longest expected multipath fade, measured in symbols, is broken across more codewords than the code has spare correcting capacity.

Relevance to SDR

Nearly every digital land-mobile protocol interleaves its bursts. DMR uses a block interleave inside BPTC(196,96) so that the row/column Hamming passes see scattered errors; P25, TETRA, and NXDN all interleave their coded payloads; and broadcast systems from DAB to DVB lean on convolutional interleaving against fading. GopherTrunk implements the matching de-interleavers as an explicit step in each protocol’s decode chain — it reverses the standard’s bit permutation before handing the data to the FEC decoder. Getting that permutation exactly right is essential: an off-by-one de-interleave scrambles otherwise-perfect symbols into garbage, so it is a frequent culprit when a new protocol decoder “sees” a signal but never validates a frame.

Sources

  1. Interleaving (data) — Wikipedia, for reordering data to spread burst errors across codewords, and block vs convolutional interleavers. 

See also