0% found this document useful (0 votes)
85 views2 pages

U (K 2) ) - Matlab Code That Initiates The Viterbi Algorithm, Runs An Outer Loop For Dif-/n

This document contains instructions for three homework problems on digital communication and convolutional codes. The first problem asks students to implement a Viterbi decoder for a (1/2) binary convolutional code and plot bit error rate versus Eb/N0. The second problem modifies this to a different (1/2) convolutional code and asks students to extend the trellis, modify their code, and plot five curves. The third problem considers another (1/2) convolutional code with memory 4, asks students to label the trellis, modify their code, and plot five curves. Tables are provided to help initialize the Viterbi algorithm.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
85 views2 pages

U (K 2) ) - Matlab Code That Initiates The Viterbi Algorithm, Runs An Outer Loop For Dif-/n

This document contains instructions for three homework problems on digital communication and convolutional codes. The first problem asks students to implement a Viterbi decoder for a (1/2) binary convolutional code and plot bit error rate versus Eb/N0. The second problem modifies this to a different (1/2) convolutional code and asks students to extend the trellis, modify their code, and plot five curves. The third problem considers another (1/2) convolutional code with memory 4, asks students to label the trellis, modify their code, and plot five curves. Tables are provided to help initialize the Viterbi algorithm.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

EE 5501

Digital Communication

Prof. N. Jindal
Oct. 23, 2009
Homework 5
Due: Friday, Oct. 30, 5:00 PM

1. In this problem you will implement a Viterbi decoder for the running example R = 1/2
binary convolutional code we have been studying in class (u[k]+u[k1]+u[k2], u[k]+
u[k 2]). Matlab code that initiates the Viterbi algorithm, runs an outer loop for different Eb /N0 values, and that computes the probability of bit error is provided. Your
job is to fill in the main portion of the Viterbi decoding algorithm, and to add expressions for the uncoded bit error probability and for the nearest neighbor approximation.
Use your code to generate a plot of bit error (actual bit error, uncoded bit error, and
nearest neighbor approximation) vs. Eb /N0 . Turn in your completed Matlab code and
the numerical plot.
Note: When you are writing the code, you may want to reduce the number of iterations
while you are testing and debugging. When you make the final bit error plot, choose a
large enough number of iterations so that the curves are smooth (this will likely require
you to run the iteration for some time).
2. We now consider a slightly different R = 1/2 code, also with memory 2: (u[k] + u[k
1] + u[k 2], u[k] + u[k 1]).
(a) Draw the trellis diagram for this code.
(b) By extending the trellis for a suitable number of states, verify that dfree = 4 for
this code and that there is only a single such simple error event.
(c) Modify your Matlab code to work for this code, and generate a plot that contains
5 curves: the actual bit error and the nearest neighbor approximation for this
code, the actual bit error and the nearest neighbor approximation for the code
in the previous question, and the uncoded bit error rate. Explain why this code
performs worse than the one in the previous question.
3. We now consider a different R = 1/2 code, this time with memory 4:
y1 [k] = u[k] + u[k 3] + u[k 4]
y2 [k] = u[k] + u[k 1] + u[k 2] + u[k 4]
(a) Label the branches of the provided trellis diagram.
(b) Verify that dfree = 7 for this code, and that there are two simple error events
with this distance.
(c) Modify your Matlab code to work for this code, and generate a plot that contains
5 curves: the actual bit error and the nearest neighbor approximation for this
code, the actual bit error and the nearest neighbor approximation for the code in
1

the first question, and the uncoded bit error rate.


Note: To simplify this process, below is a table that tells you the codewords
corresponding to all possible starting 4 info bit sequences. This table should be
helpful in initializing the Viterbi algorithm.
Info Bits
0000
0001
0010
0011
0100
0101
0110
0111
1000
1001
1010
1011
1100
1101
1110
1111

Codeword
00 00 00 00
00 00 00 11
00 00 11 01
00 00 11 10
00 11 01 01
00 11 01 10
00 11 10 00
00 11 10 11
11 01 01 10
11 01 01 01
11 01 10 11
11 01 10 00
11 10 00 11
11 10 00 00
11 10 11 10
11 10 11 01

Also, when writing the code for Viterbi algorithm, try to identify patterns - if you
do so, in some places you will be able to cut and paste different portions of the
code and will only have to flip a few signs.

You might also like