Design of Convolutional Encoder and Viterbi Decoder Using MATLAB
Design of Convolutional Encoder and Viterbi Decoder Using MATLAB
net/publication/339375123
CITATIONS READS
5 3,651
1 author:
Kanchana Katta
2 PUBLICATIONS 6 CITATIONS
SEE PROFILE
Some of the authors of this publication are also working on these related projects:
All content following this page was uploaded by Kanchana Katta on 20 February 2020.
Dept. of Electronics and Communication Engineering, Don Bosco College of Engineering and Technology, Assam
Don Bosco University, Guwahati, India
kanch414@gmail.com
ABSTRACT
The main aim of any communication schemes is to provide error-free data transmission .Error control coding is a method to detect
and possibly correct errors by introducing redundancy to the stream of bits to be sent to the channel. This coding has the
usefulness that it allows us to increase the rate at which information may be transmitted over a channel while maintaining a fixed
error rate. The Convolution (Channel) Encoder will add bits to the message bits to be transmitted systematically. After passing
through the channel, at the receiver end the original message sequence is obtained from the received data using Viterbi decoder. It
implements Viterbi Algorithm, which is a maximum likelihood algorithm, based on the minimum cumulative hamming distance it
decides the optimal trellis path that is most likely followed at the encoder. Convolutional encoding and Viterbi decoding are error
correction techniques widely used in Communication systems to improve the bit error rate (BER) performance. In this paper, I
present the convolution encoder and Viterbi decoder for constraint length 4 and bit rate 1/2. In addition, a Viterbi decoder is
developed in MATLAB.
TABLE- I
b) Trellis Diagram:
Fig-4: Encoder trellis structure for C=4 and Thus, the metric entered on a decoder trellis branch
r=1/2 represents the difference between what was received
and what should have been received, had the branch
word been associated with that branch been transmitted.
In effect, these metrics describe a correlation like
Fig-4 shows the encoder trellis, the branch word seen on
measure between a received branch word and each of the
the encoder trellis branches characterize the
candidate branch words. We continue labeling the
convolutional encoder. These encoder branch words are
decoder trellis branches in this way as the symbols are
the code symbols that would expected to come from the
received at each time ti. Thus the most likely (minimum
encoder output as a result of each of the state transitions.
distance) path through the trellis can be found that gives
As the code symbols are received, each branch of the the decoded output.
decoder trellis is labeled with a metric of similarity
At each time ti, there are 2C-1 states in the trellis, where
between the received code symbol and each of the
C is the constraint length, and each state can be entered
branches for that time interval. Here we can see how the
by means of two paths. Viterbi decoding consists of
decoding of the surviving branch is facilitated by having
computing the metrics for the two paths entering each
drawn the trellis branches with solid lines for the input
state and eliminating one of them. This computation is
0’s and dashed lines for the input 1’s.
done for each of the 2C-1 states or nodes at time ti, and
then the decoder moves to time ti+1 and repeats the
a. Survivors at t2 b. Survivors at t3
stage of the Viterbi decoder where the input that was Pb(ε) is plotted versus ε of the hard decision BSC model
transmitted by using the convolution encoder is once where ε=1/2erfc√ (Ec/N0) .
again retrieved [4].
For soft decisions the expression Pw (ε) =1/2erfc√
When the convolutional code bits encoded from input (wEc/N0) is used for the probability that the ML encoder
bits are modulated in to respective waveforms for makes a detour with weight w from the correct path. The
transmission over a medium that introduces attenuation, advantage of using soft decision decoding is to provide
distortion, interference,noise,etc.the received waveforms decoder with more information, which decoder then use
become uncertain" in their shapes. One of the frequently for recovering the message sequence [5]. It provides
applied criteria is the maximum-likelihood decoding better error performance than hard decision type Viterbi
(MLD) rule under which the probability of code word decoding.
estimate error is minimized subject to an equiprobable
prior on the transmitted code words. The Viterbi 4. RESULTS
decoding flow chart is given in Fig-8. Fig-9 shows that the bit error rate (BER) as a function of
the signal to noise ratio (SNR), from this graph the
performance improvement of soft decision Viterbi as
compared with hard decision Viterbi is approximately
2db.
Fig-: 9 BER graph for hard decision (HD) and soft decision
(SD) Viterbi decoder with C=4 and R=1/2.
Fig-8: Flow chart of Viterbi Decoding
5. CONCLUSION
The design of a convolutional encoder with a Viterbi decoder
that can encode a bit stream of digital information and outputs
Soft Decisions versus Hard Decisions a code word that has a capability to be transmitted to the
destination and then decoded .The encoder was designed with
The primary difference between the hard decision and constraint length 4 and rate 1/2.The Viterbi decoder design had
soft decision Viterbi algorithm is that the soft decision been driven in such a way that it would calculate the decoding
algorithm cannot use hamming distance metric because path with the minimum metric to be passed to the decoder
output port.
of its limited resolution. A distance metric with needed
resolution is the Euclidean distance. Convolutional encoder and Viterbi decoder design has been
successfully done using MATLAB and results obtained in
To compare the performance of coded binary systems on terms of BER vs SNR.The motivation of this paper is to help
the beginners to understand working of Viterbi algorithm
a AWGN channel when the decoder performs either hard those who wants to works on Viterbi decoder.
or soft decisions, the energy Ec per coded bit is fixed and
REFERENCES
[1] Jinjin H, Zhongfeng Wang, Zhiqiang Cui, LiLi,
“Towards an Optimal Trade-off of Viterbi Decoder
Design”, Circuits and Systems, ISCAS-2009. IEEE
International Symposium, 24-27 May 2009 pp. 3030 –
3033.