Prefix code: Difference between revisions

Content deleted Content added
added constraint for Huffman generating fixed length code
m spelling correction
Line 95:
There are occasional a single bit errors (toggling a bit, losing a bit, or gaining a bit).
 
With [[fixed-length code]]s, an error toggling a bit causes just that one code to be recievedreceived in error,
but all other codes are recievedreceived OK. However, losing or gaining a bit turns the rest of the message into gibberish.
(This is why most communication protocols periodically re-synchronize.
ASCII over RS-232 uses 20% of its bandwidth re-synchronizing after each character).
Line 104:
 
With [[Fibonacci code]]s and [[unary code]]s, all single-bit errors cause one or two erroneous codes,
but all other codes are recievedreceived OK. (These codes are "self-synchronizing").
 
With most other variable-length codes, any kind of single-bit error turns the rest of the message into gibberish.