---
title: "Short note: Convolutional codes"
subject: "Communication Systems"
chapter: 8
key: "semester_6/communication_systems:short-note-convolutional-codes"
source: https://www.bctengineer.com/q/semester_6/communication_systems/short-note-convolutional-codes
site: BCT Engineering
---

# Short note: Convolutional codes

Communication Systems · Chapter 8: Error Detection and Correction Coding

- Asked in: 2071 Magh (old course), 4 marks; 2068 Jestha (old course), 5 marks; 2080 Bhadra (CS II), 4 marks; 2079 Bhadra (CS II), 5 marks; 2075 Chaitra (CS II), 5 marks (asked 5 times)
- Video: [Convolutional Codes (Basics, Designing & Parameters) Explained in Digital Communication](https://www.youtube.com/watch?v=hPNfiFmx5Dk) — Engineering Funda
- Answer checked by Claude Opus 5.5 (high effort) on 2026-10-14
- Page: https://www.bctengineer.com/q/semester_6/communication_systems/short-note-convolutional-codes
- Whole chapter: https://www.bctengineer.com/md/semester_6/communication_systems/chapter-8

## Question

Write a short note on convolutional codes.

## Short answer

Convolutional codes are error-correcting codes with memory, where each output depends on current and previous inputs. Described by (n,k,K) with rate k/n and constraint length K. Encoding uses shift registers and generator polynomials; decoding typically uses the Viterbi algorithm. They operate on continuous streams and are used in GSM, satellite, and Wi-Fi.

## Answer

A **convolutional code** is an error-correcting code in which the encoder has memory: each group of output bits depends on the current input bit and on the previous $K-1$ input bits stored in a shift register. The code is described by $(n,k,K)$: $k$ input bits produce $n$ output bits, giving code rate $r=k/n$, and $K$ is the **constraint length**.

#### Encoder

A rate-1/2, $K=3$ encoder with generators $g^{(1)}=(1,1,1)$ and $g^{(2)}=(1,0,1)$:

```text
 m -->[ m_i ]-->[ m_i-1 ]-->[ m_i-2 ]
        |  \        |         /  |
        |   \--(+)--+--------/   |   c1 = mi+mi-1+mi-2
        |                        |
        +---------(+)------------+   c2 = mi+mi-2
                 output: c1 c2 c1 c2 ...
```

Each output is the modulo-2 convolution of the input with a generator sequence: $c_i^{(j)}=\sum_l g_l^{(j)}m_{i-l}$.

**Example:** input 1 0 0 1 1 (plus two flushing 0s) gives 11 10 11 11 01 01 11.

#### Representations

- **Code tree:** branches up for 0, down for 1, labelled with output bits.
- **Trellis diagram:** states (contents of memory) against time; repeats after $K-1$ steps.
- **State diagram:** $2^{K-1}$ states with transitions labelled input/output.

#### Decoding

The **Viterbi algorithm** (maximum-likelihood) finds the trellis path with minimum Hamming distance from the received sequence; sequential decoding is used for large $K$.

#### Features

- Works on a continuous bit stream, no block division.
- Strong error correction with soft-decision decoding; free distance $d_{free}$ measures power.
- Used in GSM, satellite and deep-space links, Wi-Fi (often with interleaving).

## Check yourself

The answer's key points as multiple-choice questions, with the correct option and why.

1. What makes a convolutional code different from a block code?
   A. Its output depends only on the current input bit
   B. Its encoder has memory: outputs depend on the current and previous K-1 input bits
   C. It uses a parity check matrix only
   D. It can only detect errors
   Answer: B. A shift register stores previous bits so each output group depends on the present and previous K-1 bits. (Key point: Encoder memory)

2. For an (n,k,K) convolutional code, what are the code rate and the meaning of K?
   A. Rate = n/k; K = number of outputs
   B. Rate = k/n; K = constraint length (number of bits influencing an output)
   C. Rate = k/K; K = number of states
   D. Rate = K/n; K = number of inputs
   Answer: B. k input bits give n output bits so r = k/n; K is the constraint length of the shift register. (Key point: Code rate and constraint length)

3. A rate-1/2 encoder with K = 3 has how many states?
   A. 3
   B. 2
   C. 4
   D. 8
   Answer: C. The states are the contents of the K-1 = 2 memory elements, so 2^(K-1) = 4. (Key point: Number of states)

4. What does the Viterbi algorithm do?
   A. Finds the trellis path with minimum Hamming distance from the received sequence (maximum likelihood)
   B. Computes the syndrome of each block
   C. Divides the received polynomial by g(x)
   D. Maximises the code rate
   Answer: A. Viterbi decoding is maximum-likelihood: it picks the path in the trellis closest in Hamming distance to what was received. (Key point: Viterbi decoding)

## Related in Communication Systems

- [Convolutional vs block codes; (7,4) cyclic code for 1011](https://www.bctengineer.com/question.md?key=semester_6%2Fcommunication_systems%3Aconv-vs-block-cyclic-7-4-1011) — Communication Systems, chapter 8, asked 2×

## Related in other subjects

- [Convolutional codes and their uses](https://www.bctengineer.com/question.md?key=semester_5%2Fdata_communication%3Aconvolution-codes-explain) — Data Communication, chapter 8, asked 4×
