Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo


#201 Systematic Reed-Solomon decoding behaves incorrectly

Laurent Schmalen

The Reed-Solomon decoder behaves incorrectly in the case of systematic codes and bad SNRs. The reason is the following:

If the received code word cannot be decoded (e.g, because there are too many errors), then decoderfailure is set to "false". In this case, always the all zero decoded information vector is returned (as mbit.clear() on line 216 and then decoded_bits is filled with mbit). In the case of a systematic code and a decoderfailure, all the received information should be used). The current implementation givdes BER of 0.5 in bad to medium channel conditions).


  • Stephan Ludwig
    Stephan Ludwig

    See Open Discussions Forum for a first discussion of the topic...

  • Stephan Ludwig
    Stephan Ludwig


    after no discussion at all but still being confident about my solution, I commited a patch to SVN (rev.1888) for BCH codes and RS codes that solves the mentioned problem as given in the discussion forum and also solves another bug:

    in line 208 of http://itpp.sourceforge.net/current/reedsolomon_8cpp_source.html the syndrome should be calculated from variable cx and not rx. The syndrome of the received block rx has been already calculated in l. 142 and rx has never been changed ever since. But in l. 204 cx was calculated as the corrected (rx + error ex) block and the following check of l. 208 should check if the corrected one is a valid code word - and that is on cx, and not rx. In the BCH.cpp code (line 275) this is already correct and in the same way as proposed for the RS code.

    I also adapted the test files accordingly.

    Additionally to being marked as fixed, the previous bug #2993430 should now be marked as a duplicate of this one.

  • Bogdan Cristea
    Bogdan Cristea

    • status: open --> accepted
    • assigned_to: Bogdan Cristea
  • Bogdan Cristea
    Bogdan Cristea

    • status: accepted --> closed