The displayed prefix code has expected codeword length ternary digits per source symbol. Instead assign
This is a ternary prefix code: the first two codewords end at distinct tree children of the tree root, and the other two start with and end at distinct tree children below it. No codeword is a prefix of another. Its expected codeword length is
The reduction is trit per source symbol, which already disproves optimality of the displayed code. The ternary Huffman coding construction below will produce this same improved code tree.
Figure 1.
An original ternary prefix tree with expected length 1.25 ternary digits per source symbol
. Details.

Articles by others on the same topic (0)

There are currently no matching articles.