The Huffman code in practice suffers from two problems: the prior know
ledge of the probability distribution of the data source to be encoded
is necessary, and the encoded data propagate errors. The first proble
m can be solved by an adaptive coding, while the second problem can be
partly solved by segmenting data into segments. But the adaptive Huff
man code performs badly when segmenting data into relatively small seg
ments because of its relatively slow adaptability. This paper offers a
fast-adaptive coding algorithm which tracks the local data statistics
more quickly, thus yielding better compression efficiency.