Description Usage Arguments Value Author(s) Examples
This functions takes a message and encode it with the turbo-code procedure. The message will be encoded in 2 identical systematic encoder, but before the message will be encoded in the encoder 2 the message will be permutated with an interleaver. To increase the minimal distance between 2 code words the interleaver is needed. The systematic encoder must have 2 exists and it must be an systematic encoder which means that the input is redirected directly to the output. Because of the systematic encoders the original message must be transmitted only once, so this procedure reduces the code rate of the whole encoder. After the 2 encoders the resulting encoded messages are interleaved into one stream and transmitted to the exit. Only one exit of the systematic encoder will be used, so the index of the output can be determined. The punctuation matrix removes all bits where the matrix is zero, so the code rate is increased.
1 2 3 |
message |
Message which will be encoded. |
permutation.vector |
Permutation vector which will be created with |
coder.info |
Coder which will be created with |
parity.index |
Index to decide which exit of the coder will be used for the encoding (>1). Default value is always the last exit of the coder. |
punctuation.matrix |
Punctuation matrix to puncture the output, will be created with |
visualize |
Flag to decide whether to create a visualization pdf or not. |
Encoded message, will be a list if the output was punctured (list with original and punctured).
Witsch Daniel
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | input <- c(1,0,1,1,0)
#default coder and permutation vector
message.encoded <- TurboEncode(input)
print(message.encoded)
#custom coder and permutation vector
coder <- ConvGenerateRscEncoder(2, 2, c(5, 7))
perm <- TurboGetPermutation(length(input), coder, "RANDOM")
message.encoded <- TurboEncode(input, perm, coder)
print(message.encoded)
#encoding with punctuation matrix
punct <- TurboGetPunctuationMatrix(c(1,1,0,1,0,1))
message.encoded.punct <- TurboEncode(input, perm, coder, punctuation.matrix = punct)
print(message.encoded.punct$original)
print(message.encoded.punct$punctured)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.