Incoding theory, especially intelecommunications, aself-synchronizing code is auniquely decodable code in which thesymbol stream formed by a portion of onecode word, or by the overlapped portion of any two adjacent code words, is not a valid code word.[1] Put another way, a set of strings (called "code words") over an alphabet is called a self-synchronizing code if for each string obtained by concatenating two code words, the substring starting at the second symbol and ending at the second-last symbol does not contain any code word as substring. Every self-synchronizing code is aprefix code, but not all prefix codes are self-synchronizing.
Other terms for self-synchronizing code aresynchronized code[2] or, ambiguously,comma-free code.[3] A self-synchronizing code permits the properframing of transmitted code words provided that no uncorrected errors occur in thesymbol stream; externalsynchronization is not required. Self-synchronizing codes also allow recovery from uncorrected errors in the stream; with most prefix codes, an uncorrected error in a singlebit may propagate errors further in the stream and make the subsequent datacorrupted.
Importance of self-synchronizing codes is not limited todata transmission. Self-synchronization also facilitates some cases ofdata recovery, for example of adigitally encoded text.
11xxxxxx) and subsequent bytes (10xxxxxx) of a multi-byte code point have different bit patterns.Counterexamples: