Question

iid source has six letters a; b; c; d; e; f, with probabilities 0:20; 0:20; 0:10;...

iid source has six letters a; b; c; d; e; f, with probabilities 0:20; 0:20; 0:10; 0:08; 0:08; 0:34, respectively. calculate the codeword of an arithmetic code for encoding the sequence affd. Show all steps in your design

0 0
Add a comment Improve this question Transcribed image text
Answer #1
x cummulative prob. C(x)
a 0.20
b 0.40
c 0.50
d 0.58
e 0.66
f 1.00

for any x its range will be in CF(x) to C(x)

sequence given = a f f d

for a the range is 0.00 to 0.20 (range a = 0.20-0.00 ){refer cummulative freq table}

a f the range = 0.00 + R(a)*C(e) to 0.00 + R(a)*C(f) = 0.132 to 0.20

(R(af)=0.2-0.132 = 0.068)

a f f the range is = 0.132 + R(af)*C(e) to 0.132 + R(af)*C(f) = 0.17688 to 0.2

R(aff) = 0.2 - 0.17688 = 0.02312

a f f d = 0.17688 + R(aff)*C(c) to 0.17688 + R(af)f*C(d) = 0.18844 to 0.1902896

codeword

the range is 0.18844 to 0.1902896 for sequence 'affd'

P.S. (please upvote if you find the answer satisfactory)

Add a comment
Know the answer?
Add Answer to:
iid source has six letters a; b; c; d; e; f, with probabilities 0:20; 0:20; 0:10;...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • 3. (a) in a variable Length code, if the probabilities of a, b, c, d were...

    3. (a) in a variable Length code, if the probabilities of a, b, c, d were 1/4.112.1/8.1/8 respectively, what the expected number of bits can be used to represent a source symbol? We assume that the following codeword table is used. (10 points) Symbol Codeword 10 110 111 (b) How to efficiently encode the following bit stream using Run-length coding (RLC)? Please write the output. (10 points) “1001011000101001000111"

  • A long string consists of the six characters A, B, C, D, E, F, G; they...

    A long string consists of the six characters A, B, C, D, E, F, G; they appear with frequency 21%, 11%, 8%, 17%, 5%, 23%, and 15%, respectively. (a) Draw the Huffman encoding tree of these six characters. (b) What is the Huffman encoding of these six characters? (c) If this encoding is applied to a string consisting of one million characters with the given frequencies, what is the length of the encoded string in bits?

  • An alphabet contains symbols A, B, C, D, E, F. The frequencies of the symbols are...

    An alphabet contains symbols A, B, C, D, E, F. The frequencies of the symbols are 35%, 20%, 15%, 15%, 8%, and 7%, respectively. We know that the Huffman algorithm always outputs an optimal prefix code. However, this code is not always unique (obviously we can, e.g., switch 0’s and 1’s and get a different code - but, for some inputs, there are two optimal prefix codes that are more substantially different). For the purposes of this exercise, we consider...

  • 5. Eight letters {A, B, C, D, E, F,G,H} appear in a 100 letter length message...

    5. Eight letters {A, B, C, D, E, F,G,H} appear in a 100 letter length message with the following frequencies: 22, 6, 13, 19, 2, 9, 25, 4. (a) Use Huffman tree to design an optimal binary prefix code for the letters. (b) What is the average bit length of the message after apply codes designed in (a) to the message? [20 marks]

  • There are 10 letters - a, b, c, d, e, f, g, h, n, g. I...

    There are 10 letters - a, b, c, d, e, f, g, h, n, g. I have to arrange them in a way that "a" wouldn't be near "c" and also "a" wouldn't be near "g" How many possible combinations are possible? How to solve it mathematically?

  • Problem (A1) (20 points): Huffman Coding Consider a message having the 5 symbols (A,B,C,D,E) with probabilities...

    Problem (A1) (20 points): Huffman Coding Consider a message having the 5 symbols (A,B,C,D,E) with probabilities (0.1,0.1,0.2 ,0.2, 0.4), respectively. For such data, two different sets of Huffman codes can result from a different tie breaking during the construction of the Huffman trees. • Construct the two Huffman trees. (8 points) Construct the Huffman codes for the given symbols for each tree. (4 points) Show that both trees will produce the same average code length. (4 points) For data transmission...

  • Program is for an Arduino 1. Add the letters “A”, “b”, “c”, “d”, “E”, “F” to...

    Program is for an Arduino 1. Add the letters “A”, “b”, “c”, “d”, “E”, “F” to your homework program. Continually display “0123”, “4567”, “89Ab”, “cdEF” with a one second delay between each one. HINT: Expand pickNumber() to use numbers 10-15 (a-f in hex). Create new functions for a-f. (THIS IS THE CODE FROM THE HOMEWORK) /*************************************** name:Stopwatch function: you can see the number increases by one per second on the 4-digit 7-segment display. ***********************************/ //Email:support@sunfounder.com //Website:www.sunfounder.com /**************************************/ #include //the pins...

  • A B C D E F -- 28 ол -- A B с D E 20...

    A B C D E F -- 28 ол -- A B с D E 20 53 2757 34 51 46 49 38 44 39 28 20 53 51 27 57 34 -- 3 49 38 41 46 44 F 5 39 3 41 The weights of edges in a graph are shown in the table above. Apply the sorted edges algorithm to the graph. Give your answer as a list of vertices, starting and ending at vertex A. Example:...

  • Design a Shannon-Fano code and sketch the corresponding coding tree where the alphabet is {a,b,c,d,e,f} with...

    Design a Shannon-Fano code and sketch the corresponding coding tree where the alphabet is {a,b,c,d,e,f} with corresponding probabilities {0.5, 0.1, 0.05, 0.05, 0.25, 0.25}

  • 1. Consider the code sequence: C= A + B D= A-E F= C+ D Assume the...

    1. Consider the code sequence: C= A + B D= A-E F= C+ D Assume the values A, B, C, D, E, and F reside in memory. For each Architecture I. Accumulator Architecture II. Memory- Register Architecture III. Register-Register Architecture write the code assuming the instruction codes (opcode) are 8 bits, memory addresses are 32 bits, and register addresses are 6 bits and CPU has 64 Registers; and create a table which specifies: – The execution sequence – The variables...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT