A method
decodes a soft-input cost function for an [N,k]q linear
block error- correcting code that has a fast sparse transform
factor graph (FSTFG) representation, such as Reed-Solomon codes. First, the code is selected and its FSTFG representation is constructed. The representation is simplified and is
made redundant if the
improved performance is more important than the increased decoding complexity. An encoding method consistent with the representation is selected. A set of message-update and belief-update rules are selected. The messages are initialized according to a soft-input cost function. An iterative decoding cycle is then begun, in which the first step consists of updating the messages according to the pre-selected message-update rules. In the second step of the decoding cycle, a trial
code word is determined from the messages, the pre- selected message-update rules, and the encoding method. In the third step of the decoding cycle, the tentative output
code word of the decoding method is replaced with the trial
code word if the trial code word has lower cost. Finally, the decoding cycle terminates if a termination condition is true, and outputs the tentative code word, and otherwise repeats the decoding cycle. The decoding method can be combined or concatenated with other
decoding methods for FSTFG codes.