EC-23.3 Convolutional Codes, and the Viterbi Decoder
You can draw the state diagram and trellis of a convolutional encoder, trace the Viterbi algorithm through several stages by hand, and explain why soft decisions and a finite traceback depth are what make it practical.
Before:S5-3. Digital Signal ProcessingEC-11. Data Communications and Computer Networks
A convolutional encoder has no block boundary: it is a small shift register whose output depends on the last few inputs, so the code is a continuous stream. Decoding it optimally means finding the most likely path through a trellis, and the algorithm that does so is one of the genuinely beautiful results in engineering. Working through a small example by hand is worth more than reading about it three times.
Work through these
The encoder as a shift register, and its constraint length
The output at each moment depends on the current input and a few previous ones, and how many is the constraint length. That number sets both the strength of the code and the cost of decoding it.
NPTEL: Error Control Coding — An Introduction to Convolutional Codes (IIT Kanpur) · CourseState diagram and trellis: the same machine drawn two ways
The state diagram shows the transitions and the trellis shows the same transitions repeated through time. Decoding is a search over the trellis, so being able to draw one accurately is the prerequisite for everything after.
NPTEL: Error Control Coding — An Introduction to Convolutional Codes (IIT Kanpur) · CourseThe Viterbi algorithm: keeping one survivor per state
At each stage only the best path into each state can ever be part of the best overall path, so all the others are discarded. That single observation is what turns an exponential search into a linear one.
NPTEL: Error Control Coding — An Introduction to Convolutional Codes (IIT Kanpur) · CourseSoft-decision metrics, and the gain they buy
Accumulating a distance built from the demodulator's confidence rather than from decided bits improves performance by roughly two decibels. The algorithm is otherwise unchanged, which makes it a rare free improvement.
NPTEL: Error Control Coding — An Introduction to Convolutional Codes (IIT Kanpur) · CourseTraceback depth, latency and memory
The survivors converge after a few constraint lengths, so a decoder can output a decision that far behind the present rather than waiting for the end. That choice sets both the memory and the latency of the decoder.
Free distance, and predicting performance without simulating it
The smallest distance between distinct paths through the trellis predicts the error rate at high signal-to-noise ratio. It lets two candidate codes be compared before either is implemented.
Sign in to keep your progress.
Free resources
We haven't checked most of these for screen reader use yet.
Links last checked 4 Sept 2026.
Stuck here?
Ask a mentor. A real person answers, and they can see exactly which topic you're on. Usually within a couple of working days.
Checking your session…
Topics shown in module order.