Question

In: Other

Find the shortest encoded bit string of the following source sequence: Source sequence: ABCCDEAFABCBEDFABCBBAEFFEBCEFF (a) using...

Find the shortest encoded bit string of the following source sequence: Source sequence: ABCCDEAFABCBEDFABCBBAEFFEBCEFF

(a) using extended Huffman coding to encode the string where k=2


(b) using arithmetic coding.
For this case, you can ignore the termination issue ina a decoder, and output the shortestbit string of the first 5 symbols only, while the probability distribution is based on the whole sequence.


(c) Using adaptive Huffman coding to encode the first 10 symbols of the string. The initial code assignment is given below

  • New : 0

  • A : 00001

  • B : 00010

  • C : 00011

  • D : 00100

  • E : 00101

  • F : 00110

Solutions

Expert Solution

Answer: Following are the LT properties

a) \(P=\varnothing^{\emptyset}\)

b) \(\mathrm{P}=\left\{A O, A 1, A 2 \ldots \in 2 A P w / x O \in A O^{A_{0}}, A_{1}, A_{2} \ldots \in\left(2^{A P}\right)^{w} \mid x_{0} \in A_{0}\right\}\)

c) \(\mathrm{P}=\left\{A O, A 1, A 2 \ldots \in 2 A P w / x O \notin A C A_{0}, A_{1}, A_{2} \ldots \in\left(2^{A P}\right)^{w} \mid x_{0} \notin A_{0}\right\}\)

d) \(P=\left\{A O, A 1, A 2 \ldots \in 2 A P w / x O \notin A O \wedge \exists A_{0}, A_{1}, A_{2} \ldots \in\left(2^{A P}\right)^{w} \mid x_{0} \notin A_{0} \wedge \exists_{i}:(x>i) \in A_{i} \wedge i>0\right\}\)

e) \(\mathrm{P}=\left\{A O, A 1, A 2 \ldots \in 2 A P_{W} A_{0}, A_{1}, A_{2} \ldots \in\left(2^{A^{p}}\right)^{w} \mid \exists_{i} \geq \geq 0: \forall j \geq i,(x>i) \notin A_{j}\right\}\)

f) \(P=\left\{A O, A 1, A 2 \ldots \in 2 A P w^{A_{0}}, A_{1}, A_{2} \ldots . \in\left(2^{A P}\right)^{w} \mid \forall i \geq 0: \exists_{j} \geq 1,(x>i) \in A_{j}\right\}\)

g) \(P=\left\{A O, A 1, A 2 \ldots \in 2 A P w^{A}_{0}, A_{1}, A_{2} \ldots . \in\left(2^{A P}\right)^{w} \mid \forall(x=0)^{\forall}(x=0) \in^{\epsilon} A_{1} A_{i} \wedge^{\wedge}(x>1) \in^{\epsilon} A i+1^{A}_{i+1} \wedge^{\wedge} i m o d z^{m o d}_{2}\right.\)

\(=0\) ) \(v\)

h) \(\mathrm{P}=2 \mathrm{APW}^{\left(2^{A P}\right)^{w}}\)

Safety property is a behavior in which "nothing bad happens".

Here, \(d, g\) is a safety property, as a bad prefix is for instance.


Related Solutions

Recall that a 5-bit string is a bit strings of length 5, and a bit string...
Recall that a 5-bit string is a bit strings of length 5, and a bit string of weight 3, say, is one with exactly three 1’s. a. How many 5-bit strings are there? b. How many 5-bit strings have weight 0? c. How many 5-bit strings have weight 1? d. How many 5-bit strings have weight 2? e. How many 5-bit strings have weight 4? f. How many 5-bit strings have weight 5? g. How many 5-bit strings have weight...
Stream Cipher. A message is encoded by exclusive-or’ing each bit with a random bit stream. (In...
Stream Cipher. A message is encoded by exclusive-or’ing each bit with a random bit stream. (In exclusive or, 0⊕0 = 0, 1⊕0 = 1, 0⊕1 = 1, and 1⊕1 = 0.) a. Recover the original message from the random stream and encrypted stream, by filling in the blanks in the “Recovered” and “ASCII” rows. (In the ASCII column, interpret the byte as an ASCII character and write the value in that row.) Message: ? ? ? ? ? ? ?...
perfrome bit destuffing for the following sequence: 11101111101111100111110
perfrome bit destuffing for the following sequence: 11101111101111100111110
An n-bit binary string is a sequence of length n over the alphabet {0,1}. How many...
An n-bit binary string is a sequence of length n over the alphabet {0,1}. How many n-bit binary strings are there? How many n-bit binary strings b1,…,bn are there such that b1b2≠00? In other words, how many n-bit binary strings don't begin with 00? How many n-bit binary strings b1,…,bn are there such that b1b2≠00 and b2b3≠11? How many n-bit binary strings b1,…,bn are there such that b1b2≠00 and such that b2b3≠01?
Write an essay in which you explain how the sequence of proteins is encoded in the...
Write an essay in which you explain how the sequence of proteins is encoded in the mRNA and how it is translated at the ribosome. Also using a drawing give a detailed description of how initiation, elongation and termination occur in bacteria. explain how the sequence of proteins is encoded in the mRNA and how it is translated at the ribosome. using a drawing give a detailed description of how initiation, elongation and termination occur in bacteria.
In c++, using stack structure, write a program that will take a sequence of characters (string)...
In c++, using stack structure, write a program that will take a sequence of characters (string) and determine whether it is a palindrome. Use the linked version of the stack.
Find sequences that satisfy the following or explain why no such sequence exists: a) A sequence...
Find sequences that satisfy the following or explain why no such sequence exists: a) A sequence with subsequences converging to 1, 2, and 3. b) A sequence that is bounded above, but has no convergent subsequence. c) A sequence that has a convergent subsequence but is unbounded (note: unbounded means not bounded below or not bounded above. d) A sequence that is monotonic and bounded, but does not converge.
Find 4 examples from an outside source of a real-world scenario that involves a sequence. Define...
Find 4 examples from an outside source of a real-world scenario that involves a sequence. Define the sequence in three different ways. Determine if the sequence is arithmetic, geometric, or neither. Discuss which representation of the sequence is best in this real-world scenario, and why.
Design a transducer to convert a binary string into octal. For example the bit string 001101110...
Design a transducer to convert a binary string into octal. For example the bit string 001101110 should produce 156. Please complete the code to account for the 7 cases of 3 digit binary strings. //Function binaryToOctal takes a char array digits of length 3 //Pre: digits contains 3 binary digits. //Post: function returns the octal number equivalent to the 3 binary digits int binaryToOctal( char digits[], int 3){ int number; if(digits[0]=='0') if (digits[1]=='1') if (digits[2]=='0') return 2;//found "010" else return...
Describe and analyze an algorithm to determine the number of shortest paths from a source vertex...
Describe and analyze an algorithm to determine the number of shortest paths from a source vertex s to a target vertex t in an arbitrary directed graph G with weighted edges. You may assume that all edge weights are positive and that all necessary arithmetic operations can be performed in O(1) time. [Hint: Compute shortest path distances from s to every other vertex. Throw away all edges that cannot be part of a shortest path from s to another vertex....
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT