BCH decoding with erasures results in nonbinary vector

7 次查看(过去 30 天)
I'm testing the performance of BCH codes with erasures and errors and occasionally the decoder will give me strange values. Take the following code, where I am sending the all zeros message with some errors and erasures.
bch_dec = fec.bchdec(31,16);
errors = [0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 1 0]';
erasures=[0 0 0 0 0 1 1 1 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0]';
decoded = decode(bch_dec, errors, erasures)'
ans = [0 0 0 0 0 28 29 20 0 0 0 14 0 0 0 0]
I was expecting to always receive a binary vector so I'm not sure how to interpret these results.

回答(2 个)

Suneesh
Suneesh 2011-12-7
How did you generate the 'error' vector? For a BCH Decoder with N=31 and K = 16, decoding your 'error' vector without any erasures would result in DECODE reporting 3 errors corrected. So any erasures, even a single one, would result in a failed decoding and hence the garbage value. Try: [decoded,cnumerr] = decode(bch_dec, errors);
A 'cnumerr' value of -1 indicates a failed decoding.
  1 个评论
Jacques
Jacques 2011-12-7
I'm just doing a monte carlo simulation with an error and erasure model. I'm usually not checking cnumerr but in this case it is 1. I'm trying to gather information on such things as BER so I would like the decoding algorithm to output a binary vector even when it isn't possible to correctly decode the input.

请先登录,再进行评论。


Suneesh
Suneesh 2011-12-7
For BER calculations I would suggest using an example message, encoding it, then introducing errors and erasures within the capabilities of the BCH decoder that you are using, then decoding and comparing with the original data for bit errors.
Also cnumerr = 1 indicates that 1 error has been corrected. cnumerr = -1 indicates failed decoding
HTH Suneesh

类别

Help CenterFile Exchange 中查找有关 Error Detection and Correction 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by