Decoding ConvolutionalCodes
Decoding ConvolutionalCodes
L+m
x!
r ∈{0,1} r(t)
Viterbi BPSK
decoder detector
estimates of estimates
data bits of code bits
⎛ 2rE b ⎞
r = c⊕e Error indicator: Binary Symmetric Channel p = Q ⎜ ⎟
e = 0 no error (prob. 1-p) ⎝ N o ⎠
e = 1 error (prob. p)
Prof. D. Tseng 國立台灣科技大學電機工程研究所 8
Example Sequence
Z2∞
(0) Z2(1) Z2(2) Z2(3) Z2(4) Z2(5) Z2(6)
Z1∞
(0) Z1(1) Z1(2) Z1(3) Z1(4) Z1(5) Z1(6)
r = [ 1 1 1 1 1 0 0 1 0 1 1 0 ]
Prof. D. Tseng 國立台灣科技大學電機工程研究所 11
Step 1(a):
Branch Metric Calculation
n Compute a metric for each branch connecting
states at time 0 to states at time 1.
l There will be 2k branches.
n The metric is the Hamming distance
between the received bits and the code bits
assigned to that branch.
l i.e. if the bits associated with that branch were
transmitted, then how many errors would have
occurred in the BSC?
n Label every branch with its metric
Prof. D. Tseng 國立台灣科技大學電機工程研究所 12
Branch Metric Calculation at
time 1
∞ 01
1 Z3(1) Z3(2) Z3(3) Z3(4) Z3(5) Z3(6)
1
10
1
10
∞ Z2(1) Z2(2) Z2(3) Z2(4) Z2(5) Z2(6)
1
01
2
00
∞ 11
0 Z1(1) Z1(2) Z1(3) Z1(4) Z1(5) Z1(6)
0
11
2
00
0 Z0(1) Z0(2) Z0(3) Z0(4) Z0(5) Z0(6)
r = [ 1 1 1 1 1 0 0 1 0 1 1 0 ]
Prof. D. Tseng 國立台灣科技大學電機工程研究所 13
Step 1(b):
Path Metric Calculation
1∞
∞
1
∞ Z2(1) Z2(2) Z2(3) Z2(4) Z2(5) Z2(6)
1∞
2
∞
∞ ∞
0 Z1(1) Z1(2) Z1(3) Z1(4) Z1(5) Z1(6)
r = [ 1 1 1 1 1 0 0 1 0 1 1 0 ]
Prof. D. Tseng 國立台灣科技大學電機工程研究所 15
Step 1(c):
Trellis Update
n Each node has two branches entering it.
n Pick the most probable branch.
l The most probable path leading into a node is the one with
the lowest metric.
n Maintain the path with the smaller metric.
l Delete the path with the larger metric.
l If there is a tie, randomly pick between the two paths.
n Update the trellis at time 1 with the lower of the two
path metrics.
1∞
∞
1
∞ Z∞
2(1) Z2(2) Z2(3) Z2(4) Z2(5) Z2(6)
1∞
2
∞
∞ ∞
0 Z10(1) Z1(2) Z1(3) Z1(4) Z1(5) Z1(6)
r = [ 1 1 1 1 1 0 0 1 0 1 1 0 ]
Prof. D. Tseng 國立台灣科技大學電機工程研究所 17
Forward Sweep Through
Trellis
1∞ 1∞
10 0
1
10 10
42 2
4
10 10
∞
1 10
1 2
10
0 2
4
10 10 10
∞ Z∞
2(1) 1 1 2 2
1∞ 01
1 4
2
01 0
2
01 2
01
0 01
00 01
2
∞ 2
00∞ 1
2
00 21 00 00
00
∞ Z10(1) 11∞
0 1
2
11 11
1
2 1
3
11 11
1
3
11
∞ 0 2 2 2
0
11 2
0
11 11
15 1
3
11 11 11
0 2 Z02(1) 00
24 5 2 1
3 2 3 1
4 3
4 00
1 00 1
3
00 00
r = [ 1 1 1 1 1 0 0 1 0 1 1 0 ]
Prof. D. Tseng 國立台灣科技大學電機工程研究所 19
Traceback