FAILURE MAP
← Case archive

FA-71996 / Error-correcting codes / Open access

RS syndromes start at alpha to the first power · case 01

Codewords generated with roots alpha^0, alpha^1 fail the check.

Verified by executionVariant 1 · 8 checks per implementationDownload source bundle ↓JSON ↗

ROOT CAUSE

Syndromes are evaluated at alpha^(j+1), the fcr = 1 convention.

VERIFIED REPAIR

Evaluate S_j at alpha^j (first consecutive root 0).

Unsuccessful approach: Listing the correct roots in reverse order permutes the syndrome vector.

Case contract

Reed-Solomon syndromes over GF(2^8) (0x11D, alpha = 2, first consecutive root alpha^0). msg lists coefficients from the highest degree down. S_j = msg(alpha^j) for j = 0..nsym-1 by Horner evaluation. Return [syndromes, whether any syndrome is nonzero].

Why this case matters

Storage and broadcast decoders start every Reed-Solomon block with a syndrome check.

1 / The failure

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json

N = 1
observations = []
def solve(msg, nsym):
    EXP, LOG = [0] * 512, [0] * 256
    x = 1
    for i in range(255):
        EXP[i] = EXP[i + 255] = x
        LOG[x] = i
        x <<= 1
        if x & 0x100:
            x ^= 0x11D
    def mul(a, b):
        return 0 if a == 0 or b == 0 else EXP[LOG[a] + LOG[b]]
    
    synd = []
    for j in range(nsym):
        root = EXP[j + 1]
        v = 0
        for coef in msg:
            v = mul(v, root) ^ coef
        synd.append(v)
    return [synd, any(synd)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['regression [[23, 252, 61, 84, 130], 2]', [[23, 252, 61, 84, 130], 2], [[0, 0], False]], ['regression [[23, 252, 61, 64, 130], 2]', [[23, 252, 61, 64, 130], 2], [[20, 40], True]], ['partial-repair [[23, 252, 61, 64, 130], 4]', [[23, 252, 61, 64, 130], 4], [[20, 40, 7, 141], True]], ['control [[0, 0, 0, 0], 2]', [[0, 0, 0, 0], 2], [[0, 0], False]], ['control [[5], 1]', [[5], 1], [[5], True]], ['control [[0, 0, 7], 2]', [[0, 0, 7], 2], [[7, 7], True]], ['control [[176, 102, 222, 44, 125, 89], 2]', [[176, 102, 222, 44, 125, 89], 2], [[0, 0], False]], ['control [[176, 102, 222, 61, 125, 89], 2]', [[176, 102, 222, 61, 125, 89], 2], [[17, 68], True]]], [['regression [[176, 102, 222, 44, 125, 89], 2]', [[176, 102, 222, 44, 125, 89], 2], [[0, 0], False]], ['regression [[176, 102, 222, 61, 125, 89], 2]', [[176, 102, 222, 61, 125, 89], 2], [[17, 68], True]], ['partial-repair [[176, 102, 222, 61, 125, 89], 4]', [[176, 102, 222, 61, 125, 89], 4], [[17, 68, 169, 244], True]], ['partial-repair [[123, 214, 103, 174, 192, 161, 31], 2]', [[123, 214, 103, 174, 192, 161, 31], 2], [[26, 52], True]], ['control [[0, 0, 7], 2]', [[0, 0, 7], 2], [[7, 7], True]], ['control [[0, 0, 0, 0], 2]', [[0, 0, 0, 0], 2], [[0, 0], False]], ['control [[5], 1]', [[5], 1], [[5], True]], ['control [[123, 214, 103, 174, 192, 161, 31], 4]', [[123, 214, 103, 174, 192, 161, 31], 4], [[26, 52, 69, 105], True]]], [['regression [[123, 214, 103, 174, 192, 187, 31], 2]', [[123, 214, 103, 174, 192, 187, 31], 2], [[0, 0], False]], ['regression [[123, 214, 103, 174, 192, 161, 31], 2]', [[123, 214, 103, 174, 192, 161, 31], 2], [[26, 52], True]], ['partial-repair [[131, 154, 183, 135, 93, 136, 102, 233], 2]', [[131, 154, 183, 135, 93, 136, 102, 233], 2], [[115, 209], True]], ['partial-repair [[131, 154, 183, 135, 93, 136, 102, 233], 4]', [[131, 154, 183, 135, 93, 136, 102, 233], 4], [[115, 209, 164, 73], True]], ['control [[5], 1]', [[5], 1], [[5], True]], ['control [[0, 0, 7], 2]', [[0, 0, 7], 2], [[7, 7], True]], ['control [[0, 0, 0, 0], 2]', [[0, 0, 0, 0], 2], [[0, 0], False]], ['control [[70, 25, 237, 118, 90, 32, 35, 253, 93, 184], 2]', [[70, 25, 237, 118, 90, 32, 35, 253, 93, 184], 2], [[133, 184], True]]], [['regression [[131, 154, 183, 135, 93, 251, 102, 233], 2]', [[131, 154, 183, 135, 93, 251, 102, 233], 2], [[0, 0], False]], ['regression [[131, 154, 183, 135, 93, 136, 102, 233], 2]', [[131, 154, 183, 135, 93, 136, 102, 233], 2], [[115, 209], True]], ['partial-repair [[70, 25, 237, 118, 90, 32, 35, 253, 93, 184], 4]', [[70, 25, 237, 118, 90, 32, 35, 253, 93, 184], 4], [[133, 184, 215, 167], True]], ['partial-repair [[178, 65, 204, 132, 27, 119, 170, 156, 109, 21, 94, 12], 2]', [[178, 65, 204, 132, 27, 119, 170, 156, 109, 21, 94, 12], 2], [[203, 88], True]], ['control [[0, 0, 0, 0], 2]', [[0, 0, 0, 0], 2], [[0, 0], False]], ['control [[5], 1]', [[5], 1], [[5], True]], ['control [[0, 0, 7], 2]', [[0, 0, 7], 2], [[7, 7], True]], ['control [[1, 5, 4], 3]', [[1, 5, 4], 3], [[0, 10, 0], True]]], [['regression [[70, 25, 237, 118, 90, 165, 35, 253, 93, 184], 2]', [[70, 25, 237, 118, 90, 165, 35, 253, 93, 184], 2], [[0, 0], False]], ['regression [[70, 25, 237, 118, 90, 32, 35, 253, 93, 184], 2]', [[70, 25, 237, 118, 90, 32, 35, 253, 93, 184], 2], [[133, 184], True]], ['partial-repair [[1, 2, 3], 3]', [[1, 2, 3], 3], [[0, 3, 27], True]], ['partial-repair [[1, 0, 0, 0], 3]', [[1, 0, 0, 0], 3], [[1, 8, 64], True]], ['control [[0, 0, 7], 2]', [[0, 0, 7], 2], [[7, 7], True]], ['control [[0, 0, 0, 0], 2]', [[0, 0, 0, 0], 2], [[0, 0], False]], ['control [[5], 1]', [[5], 1], [[5], True]], ['control [[9, 9], 2]', [[9, 9], 2], [[0, 27], True]]]]
for label, args, expected in fixtures[N - 1]:
    check(label, solve(*args), expected)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
Boundary fixtureActualExpectedOutcome
regression [[23, 252, 61, 84, 130], 2][[0, 87], True][[0, 0], False]Failed
regression [[23, 252, 61, 64, 130], 2][[40, 7], True][[20, 40], True]Failed
partial-repair [[23, 252, 61, 64, 130], 4][[40, 7, 141, 230], True][[20, 40, 7, 141], True]Failed
control [[0, 0, 0, 0], 2][[0, 0], False][[0, 0], False]Passed
control [[5], 1][[5], True][[5], True]Passed
control [[0, 0, 7], 2][[7, 7], True][[7, 7], True]Passed
control [[176, 102, 222, 44, 125, 89], 2][[0, 164], True][[0, 0], False]Failed
control [[176, 102, 222, 61, 125, 89], 2][[68, 169], True][[17, 68], True]Failed

SHA-256 / 26b5c33db5a976cf98307612321b5e9bbda412014cd038ac9c4c4e4e092c66aa

2 / The unsuccessful fix

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json

N = 1
observations = []
def solve(msg, nsym):
    EXP, LOG = [0] * 512, [0] * 256
    x = 1
    for i in range(255):
        EXP[i] = EXP[i + 255] = x
        LOG[x] = i
        x <<= 1
        if x & 0x100:
            x ^= 0x11D
    def mul(a, b):
        return 0 if a == 0 or b == 0 else EXP[LOG[a] + LOG[b]]
    
    synd = []
    for j in range(nsym):
        root = EXP[nsym - 1 - j]
        v = 0
        for coef in msg:
            v = mul(v, root) ^ coef
        synd.append(v)
    return [synd, any(synd)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['regression [[23, 252, 61, 84, 130], 2]', [[23, 252, 61, 84, 130], 2], [[0, 0], False]], ['regression [[23, 252, 61, 64, 130], 2]', [[23, 252, 61, 64, 130], 2], [[20, 40], True]], ['partial-repair [[23, 252, 61, 64, 130], 4]', [[23, 252, 61, 64, 130], 4], [[20, 40, 7, 141], True]], ['control [[0, 0, 0, 0], 2]', [[0, 0, 0, 0], 2], [[0, 0], False]], ['control [[5], 1]', [[5], 1], [[5], True]], ['control [[0, 0, 7], 2]', [[0, 0, 7], 2], [[7, 7], True]], ['control [[176, 102, 222, 44, 125, 89], 2]', [[176, 102, 222, 44, 125, 89], 2], [[0, 0], False]], ['control [[176, 102, 222, 61, 125, 89], 2]', [[176, 102, 222, 61, 125, 89], 2], [[17, 68], True]]], [['regression [[176, 102, 222, 44, 125, 89], 2]', [[176, 102, 222, 44, 125, 89], 2], [[0, 0], False]], ['regression [[176, 102, 222, 61, 125, 89], 2]', [[176, 102, 222, 61, 125, 89], 2], [[17, 68], True]], ['partial-repair [[176, 102, 222, 61, 125, 89], 4]', [[176, 102, 222, 61, 125, 89], 4], [[17, 68, 169, 244], True]], ['partial-repair [[123, 214, 103, 174, 192, 161, 31], 2]', [[123, 214, 103, 174, 192, 161, 31], 2], [[26, 52], True]], ['control [[0, 0, 7], 2]', [[0, 0, 7], 2], [[7, 7], True]], ['control [[0, 0, 0, 0], 2]', [[0, 0, 0, 0], 2], [[0, 0], False]], ['control [[5], 1]', [[5], 1], [[5], True]], ['control [[123, 214, 103, 174, 192, 161, 31], 4]', [[123, 214, 103, 174, 192, 161, 31], 4], [[26, 52, 69, 105], True]]], [['regression [[123, 214, 103, 174, 192, 187, 31], 2]', [[123, 214, 103, 174, 192, 187, 31], 2], [[0, 0], False]], ['regression [[123, 214, 103, 174, 192, 161, 31], 2]', [[123, 214, 103, 174, 192, 161, 31], 2], [[26, 52], True]], ['partial-repair [[131, 154, 183, 135, 93, 136, 102, 233], 2]', [[131, 154, 183, 135, 93, 136, 102, 233], 2], [[115, 209], True]], ['partial-repair [[131, 154, 183, 135, 93, 136, 102, 233], 4]', [[131, 154, 183, 135, 93, 136, 102, 233], 4], [[115, 209, 164, 73], True]], ['control [[5], 1]', [[5], 1], [[5], True]], ['control [[0, 0, 7], 2]', [[0, 0, 7], 2], [[7, 7], True]], ['control [[0, 0, 0, 0], 2]', [[0, 0, 0, 0], 2], [[0, 0], False]], ['control [[70, 25, 237, 118, 90, 32, 35, 253, 93, 184], 2]', [[70, 25, 237, 118, 90, 32, 35, 253, 93, 184], 2], [[133, 184], True]]], [['regression [[131, 154, 183, 135, 93, 251, 102, 233], 2]', [[131, 154, 183, 135, 93, 251, 102, 233], 2], [[0, 0], False]], ['regression [[131, 154, 183, 135, 93, 136, 102, 233], 2]', [[131, 154, 183, 135, 93, 136, 102, 233], 2], [[115, 209], True]], ['partial-repair [[70, 25, 237, 118, 90, 32, 35, 253, 93, 184], 4]', [[70, 25, 237, 118, 90, 32, 35, 253, 93, 184], 4], [[133, 184, 215, 167], True]], ['partial-repair [[178, 65, 204, 132, 27, 119, 170, 156, 109, 21, 94, 12], 2]', [[178, 65, 204, 132, 27, 119, 170, 156, 109, 21, 94, 12], 2], [[203, 88], True]], ['control [[0, 0, 0, 0], 2]', [[0, 0, 0, 0], 2], [[0, 0], False]], ['control [[5], 1]', [[5], 1], [[5], True]], ['control [[0, 0, 7], 2]', [[0, 0, 7], 2], [[7, 7], True]], ['control [[1, 5, 4], 3]', [[1, 5, 4], 3], [[0, 10, 0], True]]], [['regression [[70, 25, 237, 118, 90, 165, 35, 253, 93, 184], 2]', [[70, 25, 237, 118, 90, 165, 35, 253, 93, 184], 2], [[0, 0], False]], ['regression [[70, 25, 237, 118, 90, 32, 35, 253, 93, 184], 2]', [[70, 25, 237, 118, 90, 32, 35, 253, 93, 184], 2], [[133, 184], True]], ['partial-repair [[1, 2, 3], 3]', [[1, 2, 3], 3], [[0, 3, 27], True]], ['partial-repair [[1, 0, 0, 0], 3]', [[1, 0, 0, 0], 3], [[1, 8, 64], True]], ['control [[0, 0, 7], 2]', [[0, 0, 7], 2], [[7, 7], True]], ['control [[0, 0, 0, 0], 2]', [[0, 0, 0, 0], 2], [[0, 0], False]], ['control [[5], 1]', [[5], 1], [[5], True]], ['control [[9, 9], 2]', [[9, 9], 2], [[0, 27], True]]]]
for label, args, expected in fixtures[N - 1]:
    check(label, solve(*args), expected)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
Boundary fixtureActualExpectedOutcome
regression [[23, 252, 61, 84, 130], 2][[0, 0], False][[0, 0], False]Passed
regression [[23, 252, 61, 64, 130], 2][[40, 20], True][[20, 40], True]Failed
partial-repair [[23, 252, 61, 64, 130], 4][[141, 7, 40, 20], True][[20, 40, 7, 141], True]Failed
control [[0, 0, 0, 0], 2][[0, 0], False][[0, 0], False]Passed
control [[5], 1][[5], True][[5], True]Passed
control [[0, 0, 7], 2][[7, 7], True][[7, 7], True]Passed
control [[176, 102, 222, 44, 125, 89], 2][[0, 0], False][[0, 0], False]Passed
control [[176, 102, 222, 61, 125, 89], 2][[68, 17], True][[17, 68], True]Failed

SHA-256 / 82a6d8b2a2bd5fe4a0745b10bd7d53cc9fc65db724c541419cc3e4be84364967

3 / The verified repair

Exit 0
"""Failure Map reference implementation. Python standard library only."""
import json

N = 1
observations = []
def solve(msg, nsym):
    EXP, LOG = [0] * 512, [0] * 256
    x = 1
    for i in range(255):
        EXP[i] = EXP[i + 255] = x
        LOG[x] = i
        x <<= 1
        if x & 0x100:
            x ^= 0x11D
    def mul(a, b):
        return 0 if a == 0 or b == 0 else EXP[LOG[a] + LOG[b]]
    
    synd = []
    for j in range(nsym):
        root = EXP[j]
        v = 0
        for coef in msg:
            v = mul(v, root) ^ coef
        synd.append(v)
    return [synd, any(synd)]
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['regression [[23, 252, 61, 84, 130], 2]', [[23, 252, 61, 84, 130], 2], [[0, 0], False]], ['regression [[23, 252, 61, 64, 130], 2]', [[23, 252, 61, 64, 130], 2], [[20, 40], True]], ['partial-repair [[23, 252, 61, 64, 130], 4]', [[23, 252, 61, 64, 130], 4], [[20, 40, 7, 141], True]], ['control [[0, 0, 0, 0], 2]', [[0, 0, 0, 0], 2], [[0, 0], False]], ['control [[5], 1]', [[5], 1], [[5], True]], ['control [[0, 0, 7], 2]', [[0, 0, 7], 2], [[7, 7], True]], ['control [[176, 102, 222, 44, 125, 89], 2]', [[176, 102, 222, 44, 125, 89], 2], [[0, 0], False]], ['control [[176, 102, 222, 61, 125, 89], 2]', [[176, 102, 222, 61, 125, 89], 2], [[17, 68], True]]], [['regression [[176, 102, 222, 44, 125, 89], 2]', [[176, 102, 222, 44, 125, 89], 2], [[0, 0], False]], ['regression [[176, 102, 222, 61, 125, 89], 2]', [[176, 102, 222, 61, 125, 89], 2], [[17, 68], True]], ['partial-repair [[176, 102, 222, 61, 125, 89], 4]', [[176, 102, 222, 61, 125, 89], 4], [[17, 68, 169, 244], True]], ['partial-repair [[123, 214, 103, 174, 192, 161, 31], 2]', [[123, 214, 103, 174, 192, 161, 31], 2], [[26, 52], True]], ['control [[0, 0, 7], 2]', [[0, 0, 7], 2], [[7, 7], True]], ['control [[0, 0, 0, 0], 2]', [[0, 0, 0, 0], 2], [[0, 0], False]], ['control [[5], 1]', [[5], 1], [[5], True]], ['control [[123, 214, 103, 174, 192, 161, 31], 4]', [[123, 214, 103, 174, 192, 161, 31], 4], [[26, 52, 69, 105], True]]], [['regression [[123, 214, 103, 174, 192, 187, 31], 2]', [[123, 214, 103, 174, 192, 187, 31], 2], [[0, 0], False]], ['regression [[123, 214, 103, 174, 192, 161, 31], 2]', [[123, 214, 103, 174, 192, 161, 31], 2], [[26, 52], True]], ['partial-repair [[131, 154, 183, 135, 93, 136, 102, 233], 2]', [[131, 154, 183, 135, 93, 136, 102, 233], 2], [[115, 209], True]], ['partial-repair [[131, 154, 183, 135, 93, 136, 102, 233], 4]', [[131, 154, 183, 135, 93, 136, 102, 233], 4], [[115, 209, 164, 73], True]], ['control [[5], 1]', [[5], 1], [[5], True]], ['control [[0, 0, 7], 2]', [[0, 0, 7], 2], [[7, 7], True]], ['control [[0, 0, 0, 0], 2]', [[0, 0, 0, 0], 2], [[0, 0], False]], ['control [[70, 25, 237, 118, 90, 32, 35, 253, 93, 184], 2]', [[70, 25, 237, 118, 90, 32, 35, 253, 93, 184], 2], [[133, 184], True]]], [['regression [[131, 154, 183, 135, 93, 251, 102, 233], 2]', [[131, 154, 183, 135, 93, 251, 102, 233], 2], [[0, 0], False]], ['regression [[131, 154, 183, 135, 93, 136, 102, 233], 2]', [[131, 154, 183, 135, 93, 136, 102, 233], 2], [[115, 209], True]], ['partial-repair [[70, 25, 237, 118, 90, 32, 35, 253, 93, 184], 4]', [[70, 25, 237, 118, 90, 32, 35, 253, 93, 184], 4], [[133, 184, 215, 167], True]], ['partial-repair [[178, 65, 204, 132, 27, 119, 170, 156, 109, 21, 94, 12], 2]', [[178, 65, 204, 132, 27, 119, 170, 156, 109, 21, 94, 12], 2], [[203, 88], True]], ['control [[0, 0, 0, 0], 2]', [[0, 0, 0, 0], 2], [[0, 0], False]], ['control [[5], 1]', [[5], 1], [[5], True]], ['control [[0, 0, 7], 2]', [[0, 0, 7], 2], [[7, 7], True]], ['control [[1, 5, 4], 3]', [[1, 5, 4], 3], [[0, 10, 0], True]]], [['regression [[70, 25, 237, 118, 90, 165, 35, 253, 93, 184], 2]', [[70, 25, 237, 118, 90, 165, 35, 253, 93, 184], 2], [[0, 0], False]], ['regression [[70, 25, 237, 118, 90, 32, 35, 253, 93, 184], 2]', [[70, 25, 237, 118, 90, 32, 35, 253, 93, 184], 2], [[133, 184], True]], ['partial-repair [[1, 2, 3], 3]', [[1, 2, 3], 3], [[0, 3, 27], True]], ['partial-repair [[1, 0, 0, 0], 3]', [[1, 0, 0, 0], 3], [[1, 8, 64], True]], ['control [[0, 0, 7], 2]', [[0, 0, 7], 2], [[7, 7], True]], ['control [[0, 0, 0, 0], 2]', [[0, 0, 0, 0], 2], [[0, 0], False]], ['control [[5], 1]', [[5], 1], [[5], True]], ['control [[9, 9], 2]', [[9, 9], 2], [[0, 27], True]]]]
for label, args, expected in fixtures[N - 1]:
    check(label, solve(*args), expected)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
Boundary fixtureActualExpectedOutcome
regression [[23, 252, 61, 84, 130], 2][[0, 0], False][[0, 0], False]Passed
regression [[23, 252, 61, 64, 130], 2][[20, 40], True][[20, 40], True]Passed
partial-repair [[23, 252, 61, 64, 130], 4][[20, 40, 7, 141], True][[20, 40, 7, 141], True]Passed
control [[0, 0, 0, 0], 2][[0, 0], False][[0, 0], False]Passed
control [[5], 1][[5], True][[5], True]Passed
control [[0, 0, 7], 2][[7, 7], True][[7, 7], True]Passed
control [[176, 102, 222, 44, 125, 89], 2][[0, 0], False][[0, 0], False]Passed
control [[176, 102, 222, 61, 125, 89], 2][[17, 68], True][[17, 68], True]Passed

SHA-256 / d74f96165ae9080342c4f67b63bd79b458738b0d1f5f6be5f763eff1a7307810

Verification & scope

A deterministic, bounded teaching model of the named code under the stated contract; not a production codec. This reproducer isolates one failure mechanism. Results cover the supplied fixtures. Variants within a family share a test contract and should remain grouped when constructing evaluation splits. Related mechanisms with a shared evaluation_group must also remain together; these controlled models are not independent production incidents.

Observations recorded using Python 3.12.14 at 2026-09-29T14:48:34.638772+00:00.

Case digest / 06951c065f3d8d42904b82e296d6c8d01b98cd2c20d14d743153955b2185c0a6