FAILURE MAP
← Case archive

FA-49281 / PCM sample encoding / Open access

Pcm mid side lifting: parity source · case 01

A residual parity sideband is derived from midpoint amplitude.

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

ROOT CAUSE

A residual parity sideband is derived from midpoint amplitude.

VERIFIED REPAIR

Use the stated conversion contract at parity source.

Unsuccessful approach: Left parity alone cannot indicate odd stereo differences.

Case contract

Encode stereo integer PCM through reversible floor lifting: side=L-R, mid=R+floor(side/2), with an explicit odd-side parity sideband.

Why this case matters

Offline PCM interchange uses these exact bounded packet and sample representation decisions.

1 / The failure

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

N = 1
observations = []
def solve(pairs):
    out=[]
    for left,right in pairs:
        side=left-right
        half=side//2
        mid=right+half
        parity=mid&1
        out.append([mid,side,parity])
    return out
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('oracle 1', solve(*([[5, 2], [2, 5]],)), [[3, 3, 1], [3, -3, 1]])
check('oracle 2', solve(*([[0, 0], [1, 1]],)), [[0, 0, 0], [1, 0, 0]])
check('oracle 3', solve(*([[-3, 2], [4, -1]],)), [[-1, -5, 1], [1, 5, 1]])
check('oracle 4', solve(*([],)), [])
check('oracle 5', solve(*([[1, 0], [0, 1]],)), [[0, 1, 1], [0, -1, 1]])
check('oracle 6', solve(*([[7, 7], [-7, -7]],)), [[7, 0, 0], [-7, 0, 0]])
check('oracle 7', solve(*([[3, 1], [-3, -1]],)), [[2, 2, 0], [-2, -2, 0]])
if N == 1: check('variant packet 1', solve(*[[[5, 2], [2, 5], [5, 2], [2, 5]]]), [[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]])
if N == 2: check('variant packet 2', solve(*[[[5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5]]]), [[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]])
if N == 3: check('variant packet 3', solve(*[[[5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5]]]), [[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]])
if N == 4: check('variant packet 4', solve(*[[[5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5]]]), [[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]])
if N == 5: check('variant packet 5', solve(*[[[5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5]]]), [[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]])
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
oracle 1[[3, 3, 1], [3, -3, 1]][[3, 3, 1], [3, -3, 1]]Passed
oracle 2[[0, 0, 0], [1, 0, 1]][[0, 0, 0], [1, 0, 0]]Failed
oracle 3[[-1, -5, 1], [1, 5, 1]][[-1, -5, 1], [1, 5, 1]]Passed
oracle 4[][]Passed
oracle 5[[0, 1, 0], [0, -1, 0]][[0, 1, 1], [0, -1, 1]]Failed
oracle 6[[7, 0, 1], [-7, 0, 1]][[7, 0, 0], [-7, 0, 0]]Failed
oracle 7[[2, 2, 0], [-2, -2, 0]][[2, 2, 0], [-2, -2, 0]]Passed
variant packet 1[[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]][[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]]Passed

SHA-256 / 7ffc323d75a8fe0c87b3a4159faa26f97d6c2acb6bb02443c6bd27d0c818ea58

2 / The unsuccessful fix

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

N = 1
observations = []
def solve(pairs):
    out=[]
    for left,right in pairs:
        side=left-right
        half=side//2
        mid=right+half
        parity=left&1
        out.append([mid,side,parity])
    return out
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('oracle 1', solve(*([[5, 2], [2, 5]],)), [[3, 3, 1], [3, -3, 1]])
check('oracle 2', solve(*([[0, 0], [1, 1]],)), [[0, 0, 0], [1, 0, 0]])
check('oracle 3', solve(*([[-3, 2], [4, -1]],)), [[-1, -5, 1], [1, 5, 1]])
check('oracle 4', solve(*([],)), [])
check('oracle 5', solve(*([[1, 0], [0, 1]],)), [[0, 1, 1], [0, -1, 1]])
check('oracle 6', solve(*([[7, 7], [-7, -7]],)), [[7, 0, 0], [-7, 0, 0]])
check('oracle 7', solve(*([[3, 1], [-3, -1]],)), [[2, 2, 0], [-2, -2, 0]])
if N == 1: check('variant packet 1', solve(*[[[5, 2], [2, 5], [5, 2], [2, 5]]]), [[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]])
if N == 2: check('variant packet 2', solve(*[[[5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5]]]), [[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]])
if N == 3: check('variant packet 3', solve(*[[[5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5]]]), [[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]])
if N == 4: check('variant packet 4', solve(*[[[5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5]]]), [[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]])
if N == 5: check('variant packet 5', solve(*[[[5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5]]]), [[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]])
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
oracle 1[[3, 3, 1], [3, -3, 0]][[3, 3, 1], [3, -3, 1]]Failed
oracle 2[[0, 0, 0], [1, 0, 1]][[0, 0, 0], [1, 0, 0]]Failed
oracle 3[[-1, -5, 1], [1, 5, 0]][[-1, -5, 1], [1, 5, 1]]Failed
oracle 4[][]Passed
oracle 5[[0, 1, 1], [0, -1, 0]][[0, 1, 1], [0, -1, 1]]Failed
oracle 6[[7, 0, 1], [-7, 0, 1]][[7, 0, 0], [-7, 0, 0]]Failed
oracle 7[[2, 2, 1], [-2, -2, 1]][[2, 2, 0], [-2, -2, 0]]Failed
variant packet 1[[3, 3, 1], [3, -3, 0], [3, 3, 1], [3, -3, 0]][[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]]Failed

SHA-256 / 539871179f2b22152e772372d3b7ff22b1aa518f4d7d7605613358d019bc7089

3 / The verified repair

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

N = 1
observations = []
def solve(pairs):
    out=[]
    for left,right in pairs:
        side=left-right
        half=side//2
        mid=right+half
        parity=side&1
        out.append([mid,side,parity])
    return out
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('oracle 1', solve(*([[5, 2], [2, 5]],)), [[3, 3, 1], [3, -3, 1]])
check('oracle 2', solve(*([[0, 0], [1, 1]],)), [[0, 0, 0], [1, 0, 0]])
check('oracle 3', solve(*([[-3, 2], [4, -1]],)), [[-1, -5, 1], [1, 5, 1]])
check('oracle 4', solve(*([],)), [])
check('oracle 5', solve(*([[1, 0], [0, 1]],)), [[0, 1, 1], [0, -1, 1]])
check('oracle 6', solve(*([[7, 7], [-7, -7]],)), [[7, 0, 0], [-7, 0, 0]])
check('oracle 7', solve(*([[3, 1], [-3, -1]],)), [[2, 2, 0], [-2, -2, 0]])
if N == 1: check('variant packet 1', solve(*[[[5, 2], [2, 5], [5, 2], [2, 5]]]), [[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]])
if N == 2: check('variant packet 2', solve(*[[[5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5]]]), [[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]])
if N == 3: check('variant packet 3', solve(*[[[5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5]]]), [[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]])
if N == 4: check('variant packet 4', solve(*[[[5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5]]]), [[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]])
if N == 5: check('variant packet 5', solve(*[[[5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5], [5, 2], [2, 5]]]), [[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]])
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
oracle 1[[3, 3, 1], [3, -3, 1]][[3, 3, 1], [3, -3, 1]]Passed
oracle 2[[0, 0, 0], [1, 0, 0]][[0, 0, 0], [1, 0, 0]]Passed
oracle 3[[-1, -5, 1], [1, 5, 1]][[-1, -5, 1], [1, 5, 1]]Passed
oracle 4[][]Passed
oracle 5[[0, 1, 1], [0, -1, 1]][[0, 1, 1], [0, -1, 1]]Passed
oracle 6[[7, 0, 0], [-7, 0, 0]][[7, 0, 0], [-7, 0, 0]]Passed
oracle 7[[2, 2, 0], [-2, -2, 0]][[2, 2, 0], [-2, -2, 0]]Passed
variant packet 1[[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]][[3, 3, 1], [3, -3, 1], [3, 3, 1], [3, -3, 1]]Passed

SHA-256 / 79123109381cb1475989bf579dedc52eb22a62f4a4a76e3ca0d1b674ae109999

Verification & scope

Stipulated finite model; no claim of hardware timing or full file-format conformance. 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:44:58.591113+00:00.

Case digest / 24c6332a953799b94b33ed9084dcaf833c9be919efb1aaf7bc3e36936d69133b