Sheets
Sheets
4- Determine the entropy for the source four symbols where all probabilities are equal to ¼
5- Evaluate the efficiency for the following source code where:
n= 4,
P( X1 ) = 1/4 , P( X2 ) = 1/8 , P( X3 ) = 1/8 , P( X4 ) = ½
x1= 1, x2= 10, x3=100, x4= 1000
the entropy of the source code was evaluated in problem 3 as 1.75 bits per symbol.
6- For the source given in table (6), classify each code according to the definitions and
evaluate the length for each instantaneously decodable code.
Table (6)
Source P(x) Code1 Code2 Code3 Code4
symbol
X1 5/8 0 0 00 0
X2 1/4 1 1 01 01
X3 1/16 11 00 011 110
X4 1/16 11 10 0111 1110
Sheet (2):
1- Design the Shannon- fan code for the following source
n= 6
P( X1 ) = 0.4 , P( X2 ) = 0.2, P( X3 ) = 0.15 , P( X4 ) = 0.15, P( X5 ) = 0.05 , P( X6 ) = 0.05
2- Derive the Huffman code for five messages with probabilities as follows. Find the
average code word length for each code.
a) 1/8, 1/8, 1/8, 1/8, ½
b) 0.1, 0.2, 0.3, 0.2, 0.2
3- Use the Huffman method to obtain the optimum code for problem (1)
Sheet (3):
c) Sketch the tree diagram and show the output sequence for the input 11011