FAILURE MAP
← Case archive

FA-12776 / Voting rule computation / Open access

A tied rank consumes only one scoring position · case 01

A tied rank consumes only one scoring position.

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

ROOT CAUSE

Tie groups advance rank by one instead of by group size.

THE FAILURE

Tie groups advance rank by one instead of by group size.

Unsuccessful approach: Assigning the highest occupied score to every tied candidate inflates tied scores.

Case contract

Groups partition all m candidates in rank order. Award each member the exact mean of Borda scores m-1-i for occupied positions, returned as strings in candidate order.

Why this case matters

A deterministic toy ballot model makes the stated counting convention executable.

1 / The failure

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(m, groups):
    out=['0']*m
    for pos,g in enumerate(groups):
        for c in g: out[c]=str(m-1-pos)
    return out
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('top tie consumes positions', solve(3,[[0,1],[2]]), ['3/2','3/2','0'])
check('bottom tie', solve(3,[[0],[1,2]]), ['2','1/2','1/2'])
check('all tied varied size', solve(N+1,[list(range(N+1))]), [str(Fraction(N,2))]*(N+1))
check('no ties', solve(3,[[2],[0],[1]]), ['1','0','2'])
check('one candidate', solve(1,[[0]]), ['0'])
check('two distinct ties', solve(4,[[0,2],[1,3]]), ['5/2','1/2','5/2','1/2'])
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
top tie consumes positions['2', '2', '1']['3/2', '3/2', '0']Failed
bottom tie['2', '1', '1']['2', '1/2', '1/2']Failed
all tied varied size['1', '1']['1/2', '1/2']Failed
no ties['1', '0', '2']['1', '0', '2']Passed
one candidate['0']['0']Passed
two distinct ties['3', '2', '3', '2']['5/2', '1/2', '5/2', '1/2']Failed

SHA-256 / 6e45e47fa16c2d06efce9b2b418c15f25391bb9ecf6e3a41ec6de228da96149e

2 / The unsuccessful fix

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json
from fractions import Fraction
N = 1
observations = []
def solve(m, groups):
    out=['0']*m; pos=0
    for g in groups:
        for c in g: out[c]=str(m-1-pos)
        pos+=len(g)
    return out
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('top tie consumes positions', solve(3,[[0,1],[2]]), ['3/2','3/2','0'])
check('bottom tie', solve(3,[[0],[1,2]]), ['2','1/2','1/2'])
check('all tied varied size', solve(N+1,[list(range(N+1))]), [str(Fraction(N,2))]*(N+1))
check('no ties', solve(3,[[2],[0],[1]]), ['1','0','2'])
check('one candidate', solve(1,[[0]]), ['0'])
check('two distinct ties', solve(4,[[0,2],[1,3]]), ['5/2','1/2','5/2','1/2'])
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
top tie consumes positions['2', '2', '0']['3/2', '3/2', '0']Failed
bottom tie['2', '1', '1']['2', '1/2', '1/2']Failed
all tied varied size['1', '1']['1/2', '1/2']Failed
no ties['1', '0', '2']['1', '0', '2']Passed
one candidate['0']['0']Passed
two distinct ties['3', '1', '3', '1']['5/2', '1/2', '5/2', '1/2']Failed

SHA-256 / f123264b7c6964212d0e8c18b4a819b791fa002b8c9408d8500b2b7bd0ad5ddb

HELD IN THE MEMBER ARCHIVE

The verified repair and its recorded checks are member-only.

This mechanism has 6 recorded checks per implementation. The open-access tier publishes the failure and the unsuccessful fix; the repaired source that passes every check, and the observations that prove it, are available to members.

Every case sharing this mechanism uses the same contract and the same repair, so this one record is held back for all of them.

Member access is invitation-based. Sign in with your invited account to inspect the repair.

Sign in to the archive ↗

Verification & scope

Abstract counting rules only; excludes jurisdictional law, ballot authentication and election operations. 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:39:00.129327+00:00.

Case digest / a6fcee379f1a6ec596176d1d532fadbc8dcfe8695da141080c006eb53da037e4