10th February 2021, 23:41
Example 1 :
codewords {0,01,11}
0 is prefix of 01 -> dangling suffix is 1.
List {0,01,11,1}
1 is a prefix of 11 -> dangling suffix is 1 - already there
-> The code is ud
Example 2:
codewords {0,01,10}
0 is prefix of 01 -> dangling suffix is 1
List {0,01,10,1}
1 is a prefix of 10 -> dangling suffix is 0 - which is an original codeword!
the code is not ud.
These 2 examples are clear to me, but I have this specfic case where it is not clear to me. In case I add 2 dangling suffixes to my list, and one is prefix of the other, thus getting another dangling suffix. This new dangling suffix is an original codeword does it mean the code is not ud?
Example :
codewrods {0,01,110}
0 is prefix of 01 -> dangling suffix is 1
List {0,01,110,1}
1 is a prefix of 110 -> dangling suffix is 10
List {0,01,110,1,10} (this is where the misconception happens...) I have in this list 2 dangling suffixes {1,10} which are not an original codewords. and 1 is prefix of 10 -> 0 is a dangling suffix. 0 is also an original codeword thus code is not ud. Is it conventional by sardinas patterson algorithm rules to produce a dangling suffix from 2 other dangling suffixes?