(My problem concerns matlab, but I guess any general programming viewpoint is also okay)
I have a question regarding Hamming(7,4) encoder where generator matrix is used.
Let's assume that I have already created the generator matrix, code word and encoded that with the error control bits, giving me a variable encoded_sequence
for example. This encoded_sequence
is of length 1x7000
double, where 500 of random error control coding bits are encoded with the codeword c
, with the help of the Generator matrix. Let's assume that a random codeword is [0,0,0,1,0,1,1]
.
Now, How do I "implement" the encoded_sequence
with the actual data bits that I want to simulate?
(Keep in mind that at the end of the program a decoding is also implemented, doing the reverse, so please only tips which can be translated back to d the reverse at the decoder)
I have tried padding the transmitted bits with zeros but I do now know how to make it so it makes sense functionality wise.
I have also tried concentrating the matrixes [encoded_sequence; databits]
but I know you the idea is not to add them together without "mixing up".