FAILURE MAP
← Case archive

FA-94801 / Exam timetabling constraints / Open access

Any split exam reported as spanning buildings · case 01

Exams split across two rooms of one building are flagged.

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

ROOT CAUSE

The test counts rooms rather than buildings.

THE FAILURE

The test counts rooms rather than buildings.

Unsuccessful approach: Counting distinct rooms still flags same-building splits.

Case contract

assign [exam, room, period] (rows may repeat); building room -> building; k = maximum distinct exams per room-period. Findings per exam (by id): multi_period if it occupies more than one period, split_buildings if its rooms span more than one building; then room_load for room-periods hosting more than k distinct exams.

Why this case matters

Split exams must stay in one building and rooms have limits on concurrent exams.

1 / The failure

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

N = 1
observations = []
def solve(assign, building, k):
    rooms_of = {}
    periods_of = {}
    load = {}
    for ex, r, p in assign:
        rooms_of.setdefault(ex, []).append(r)
        periods_of.setdefault(ex, set()).add(p)
        load.setdefault((r, p), set()).add(ex)
    out = []
    for ex in sorted(rooms_of):
        if len(periods_of[ex]) > 1:
            out.append(['multi_period', ex])
        if len(rooms_of[ex]) > 1:
            out.append(['split_buildings', ex])
    for (r, p) in sorted(load):
        if len(load[(r, p)]) > k:
            out.append(['room_load', r, p])
    return out
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[('regression: building count 1',
   [[['A', 'R1', 0], ['A', 'R2', 0]], {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1], []),
  ('regression variant: building count 2',
   [[['MATH101', 'R2', 1], ['PHYS110', 'R2', 0], ['PHYS110', 'R2', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'PHYS110']]),
  ('partial repair guard 3',
   [[['MATH101H', 'R1', 1], ['MATH101', 'R4', 1], ['CHEM120', 'R1', 0], ['CHEM120', 'R2', 0],
     ['CHEM120', 'R1', 2], ['CHEM120', 'R2', 1], ['PHYS110', 'R2', 2], ['MATH101', 'R2', 0],
     ['CHEM120', 'R2', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'CHEM120'], ['multi_period', 'MATH101'], ['split_buildings', 'MATH101']]),
  ('boundary control 4',
   [[['A', 'R1', 0], ['A', 'R1', 1]], {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'A']]),
  ('normal control 5',
   [[['CHEM120', 'R2', 2], ['CHEM120', 'R3', 1], ['MATH101H', 'R3', 2], ['CHEM120', 'R2', 0],
     ['CHEM120', 'R4', 0], ['MATH101', 'R4', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'CHEM120'], ['split_buildings', 'CHEM120']]),
  ('normal control 6',
   [[['PHYS110', 'R4', 2], ['MATH101H', 'R2', 1], ['PHYS110', 'R1', 2], ['CHEM120', 'R1', 0],
     ['MATH101H', 'R1', 0], ['MATH101H', 'R2', 1], ['PHYS110', 'R1', 2]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'MATH101H'], ['split_buildings', 'PHYS110']]),
  ('normal control 7',
   [[['CHEM120', 'R1', 1], ['MATH101', 'R1', 2], ['MATH101H', 'R2', 2]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   []),
  ('normal control 8',
   [[['PHYS110', 'R1', 1], ['MATH101H', 'R4', 1], ['MATH101H', 'R3', 1], ['MATH101H', 'R2', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['split_buildings', 'MATH101H']])],
 [('regression: building count 1',
   [[['A', 'R1', 0], ['A', 'R1', 0], ['B', 'R1', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   []),
  ('regression variant: building count 2',
   [[['CHEM120', 'R1', 2], ['MATH101H', 'R3', 2], ['MATH101H', 'R4', 2], ['MATH101H', 'R4', 2]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   []),
  ('partial repair guard 3',
   [[['CHEM120', 'R4', 1], ['CHEM120', 'R2', 0], ['MATH101H', 'R3', 2], ['MATH101H', 'R4', 2],
     ['PHYS110', 'R2', 2], ['CHEM120', 'R4', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'CHEM120'], ['split_buildings', 'CHEM120']]),
  ('boundary control 4',
   [[['A', 'R1', 0], ['A', 'R3', 0]], {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['split_buildings', 'A']]),
  ('normal control 5',
   [[['MATH101H', 'R4', 1], ['MATH101H', 'R2', 2], ['MATH101', 'R2', 1], ['MATH101', 'R1', 2],
     ['PHYS110', 'R1', 1], ['MATH101H', 'R2', 2], ['PHYS110', 'R2', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'MATH101'], ['multi_period', 'MATH101H'], ['split_buildings', 'MATH101H'],
    ['room_load', 'R2', 1]]),
  ('normal control 6',
   [[['MATH101H', 'R2', 1], ['MATH101H', 'R3', 0], ['CHEM120', 'R4', 2], ['MATH101H', 'R2', 0],
     ['CHEM120', 'R3', 1], ['CHEM120', 'R2', 0], ['PHYS110', 'R3', 0], ['CHEM120', 'R2', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'CHEM120'], ['split_buildings', 'CHEM120'], ['multi_period', 'MATH101H'],
    ['split_buildings', 'MATH101H'], ['room_load', 'R2', 0], ['room_load', 'R3', 0]]),
  ('normal control 7',
   [[['MATH101', 'R1', 0], ['MATH101H', 'R1', 1], ['MATH101', 'R4', 0], ['MATH101', 'R1', 0],
     ['MATH101H', 'R2', 0], ['MATH101', 'R4', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['split_buildings', 'MATH101'], ['multi_period', 'MATH101H']]),
  ('normal control 8',
   [[['MATH101H', 'R2', 1], ['CHEM120', 'R4', 0], ['CHEM120', 'R4', 0], ['PHYS110', 'R3', 0],
     ['MATH101', 'R1', 0], ['MATH101', 'R3', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'MATH101'], ['split_buildings', 'MATH101']])],
 [('regression: building count 1',
   [[['A', 'R1', 0], ['A', 'R1', 1]], {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'A']]),
  ('regression variant: building count 2',
   [[['MATH101', 'R2', 2], ['PHYS110', 'R3', 2], ['MATH101', 'R2', 2]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   []),
  ('partial repair guard 3',
   [[['CHEM120', 'R2', 0], ['MATH101', 'R1', 1], ['PHYS110', 'R2', 1], ['MATH101', 'R4', 1],
     ['PHYS110', 'R1', 2], ['MATH101', 'R4', 1], ['MATH101H', 'R2', 1], ['CHEM120', 'R2', 2],
     ['CHEM120', 'R2', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'CHEM120'], ['split_buildings', 'MATH101'], ['multi_period', 'PHYS110']]),
  ('boundary control 4',
   [[['A', 'R1', 0], ['A', 'R1', 2]], {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'A']]),
  ('normal control 5',
   [[['PHYS110', 'R4', 2], ['MATH101H', 'R2', 1], ['PHYS110', 'R1', 2], ['CHEM120', 'R1', 0],
     ['MATH101H', 'R1', 0], ['MATH101H', 'R2', 1], ['PHYS110', 'R1', 2]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'MATH101H'], ['split_buildings', 'PHYS110']]),
  ('normal control 6',
   [[['PHYS110', 'R2', 0], ['MATH101', 'R1', 2], ['PHYS110', 'R3', 2], ['MATH101', 'R1', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'MATH101'], ['multi_period', 'PHYS110'], ['split_buildings', 'PHYS110']]),
  ('normal control 7',
   [[['MATH101', 'R1', 2], ['CHEM120', 'R4', 2], ['CHEM120', 'R2', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'CHEM120'], ['split_buildings', 'CHEM120']]),
  ('normal control 8',
   [[['PHYS110', 'R4', 0], ['MATH101H', 'R2', 0], ['MATH101H', 'R1', 0], ['MATH101', 'R2', 1],
     ['MATH101', 'R3', 1], ['CHEM120', 'R1', 0], ['MATH101', 'R3', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['split_buildings', 'MATH101'], ['room_load', 'R1', 0]])],
 [('regression: building count 1',
   [[['A', 'R1', 0], ['A', 'R1', 2]], {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'A']]),
  ('regression variant: building count 2',
   [[['CHEM120', 'R1', 1], ['MATH101H', 'R2', 1], ['MATH101', 'R3', 0], ['MATH101H', 'R3', 0],
     ['CHEM120', 'R1', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'MATH101H'], ['split_buildings', 'MATH101H']]),
  ('partial repair guard 3',
   [[['PHYS110', 'R3', 0], ['MATH101H', 'R3', 1], ['MATH101H', 'R4', 2], ['MATH101H', 'R4', 2]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'MATH101H']]),
  ('boundary control 4',
   [[['A', 'R1', 0], ['A', 'R1', 0], ['B', 'R1', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   []),
  ('normal control 5',
   [[['MATH101H', 'R3', 1], ['MATH101H', 'R1', 0], ['MATH101H', 'R2', 2], ['CHEM120', 'R3', 1],
     ['MATH101H', 'R3', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'MATH101H'], ['split_buildings', 'MATH101H']]),
  ('normal control 6',
   [[['CHEM120', 'R4', 1], ['MATH101H', 'R1', 0], ['CHEM120', 'R1', 2], ['MATH101H', 'R4', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'CHEM120'], ['split_buildings', 'CHEM120'], ['split_buildings', 'MATH101H']]),
  ('normal control 7',
   [[['MATH101H', 'R4', 0], ['CHEM120', 'R4', 1], ['MATH101H', 'R4', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   []),
  ('normal control 8',
   [[['MATH101H', 'R3', 1], ['MATH101', 'R4', 2], ['MATH101', 'R4', 0], ['MATH101H', 'R2', 0],
     ['CHEM120', 'R2', 2], ['MATH101', 'R1', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'MATH101'], ['split_buildings', 'MATH101'], ['multi_period', 'MATH101H'],
    ['split_buildings', 'MATH101H']])],
 [('regression: building count 1',
   [[['PHYS110', 'R3', 0], ['CHEM120', 'R4', 2], ['CHEM120', 'R4', 2], ['PHYS110', 'R4', 1],
     ['CHEM120', 'R4', 0], ['MATH101', 'R3', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'CHEM120'], ['multi_period', 'PHYS110']]),
  ('regression variant: building count 2',
   [[['PHYS110', 'R3', 2], ['MATH101', 'R4', 2], ['MATH101H', 'R1', 2], ['CHEM120', 'R2', 2],
     ['PHYS110', 'R3', 1], ['MATH101', 'R4', 2], ['PHYS110', 'R2', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'PHYS110'], ['split_buildings', 'PHYS110']]),
  ('partial repair guard 3',
   [[['MATH101', 'R3', 2], ['PHYS110', 'R4', 0], ['CHEM120', 'R4', 1], ['MATH101', 'R4', 2]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   []),
  ('boundary control 4',
   [[['A', 'R1', 0], ['A', 'R2', 0]], {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1], []),
  ('normal control 5',
   [[['PHYS110', 'R4', 0], ['CHEM120', 'R4', 0], ['MATH101', 'R2', 0], ['PHYS110', 'R4', 2],
     ['MATH101H', 'R4', 1], ['PHYS110', 'R4', 0], ['MATH101', 'R3', 2], ['PHYS110', 'R3', 2],
     ['PHYS110', 'R4', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'MATH101'], ['split_buildings', 'MATH101'], ['multi_period', 'PHYS110']]),
  ('normal control 6',
   [[['MATH101H', 'R4', 0], ['PHYS110', 'R2', 2], ['MATH101', 'R2', 2], ['MATH101', 'R2', 2]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   []),
  ('normal control 7',
   [[['PHYS110', 'R4', 2], ['CHEM120', 'R1', 2], ['PHYS110', 'R2', 0], ['CHEM120', 'R1', 0],
     ['MATH101', 'R1', 0], ['MATH101H', 'R1', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'CHEM120'], ['multi_period', 'PHYS110'], ['split_buildings', 'PHYS110'],
    ['room_load', 'R1', 0]]),
  ('normal control 8',
   [[['PHYS110', 'R3', 2], ['MATH101H', 'R4', 2], ['CHEM120', 'R4', 1], ['PHYS110', 'R3', 0],
     ['PHYS110', 'R2', 0], ['CHEM120', 'R4', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'PHYS110'], ['split_buildings', 'PHYS110']])]]
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: building count 1[['split_buildings', 'A']][]Failed
regression variant: building count 2[['multi_period', 'PHYS110'], ['split_buildings', 'PHYS110']][['multi_period', 'PHYS110']]Failed
partial repair guard 3[['multi_period', 'CHEM120'], ['split_buildings', 'CHEM120'], ['multi_period', 'MATH101'], ['split_buildings', 'MATH101']][['multi_period', 'CHEM120'], ['multi_period', 'MATH101'], ['split_buildings', 'MATH101']]Failed
boundary control 4[['multi_period', 'A'], ['split_buildings', 'A']][['multi_period', 'A']]Failed
normal control 5[['multi_period', 'CHEM120'], ['split_buildings', 'CHEM120']][['multi_period', 'CHEM120'], ['split_buildings', 'CHEM120']]Passed
normal control 6[['multi_period', 'MATH101H'], ['split_buildings', 'MATH101H'], ['split_buildings', 'PHYS110']][['multi_period', 'MATH101H'], ['split_buildings', 'PHYS110']]Failed
normal control 7[][]Passed
normal control 8[['split_buildings', 'MATH101H']][['split_buildings', 'MATH101H']]Passed

SHA-256 / 5736f2be6caf7b03e1a4b64f6ea90309b01228b245f1ea24ed83a1fc9b764f5c

2 / The unsuccessful fix

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

N = 1
observations = []
def solve(assign, building, k):
    rooms_of = {}
    periods_of = {}
    load = {}
    for ex, r, p in assign:
        rooms_of.setdefault(ex, []).append(r)
        periods_of.setdefault(ex, set()).add(p)
        load.setdefault((r, p), set()).add(ex)
    out = []
    for ex in sorted(rooms_of):
        if len(periods_of[ex]) > 1:
            out.append(['multi_period', ex])
        if len(set(rooms_of[ex])) > 1:
            out.append(['split_buildings', ex])
    for (r, p) in sorted(load):
        if len(load[(r, p)]) > k:
            out.append(['room_load', r, p])
    return out
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[('regression: building count 1',
   [[['A', 'R1', 0], ['A', 'R2', 0]], {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1], []),
  ('regression variant: building count 2',
   [[['MATH101', 'R2', 1], ['PHYS110', 'R2', 0], ['PHYS110', 'R2', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'PHYS110']]),
  ('partial repair guard 3',
   [[['MATH101H', 'R1', 1], ['MATH101', 'R4', 1], ['CHEM120', 'R1', 0], ['CHEM120', 'R2', 0],
     ['CHEM120', 'R1', 2], ['CHEM120', 'R2', 1], ['PHYS110', 'R2', 2], ['MATH101', 'R2', 0],
     ['CHEM120', 'R2', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'CHEM120'], ['multi_period', 'MATH101'], ['split_buildings', 'MATH101']]),
  ('boundary control 4',
   [[['A', 'R1', 0], ['A', 'R1', 1]], {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'A']]),
  ('normal control 5',
   [[['CHEM120', 'R2', 2], ['CHEM120', 'R3', 1], ['MATH101H', 'R3', 2], ['CHEM120', 'R2', 0],
     ['CHEM120', 'R4', 0], ['MATH101', 'R4', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'CHEM120'], ['split_buildings', 'CHEM120']]),
  ('normal control 6',
   [[['PHYS110', 'R4', 2], ['MATH101H', 'R2', 1], ['PHYS110', 'R1', 2], ['CHEM120', 'R1', 0],
     ['MATH101H', 'R1', 0], ['MATH101H', 'R2', 1], ['PHYS110', 'R1', 2]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'MATH101H'], ['split_buildings', 'PHYS110']]),
  ('normal control 7',
   [[['CHEM120', 'R1', 1], ['MATH101', 'R1', 2], ['MATH101H', 'R2', 2]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   []),
  ('normal control 8',
   [[['PHYS110', 'R1', 1], ['MATH101H', 'R4', 1], ['MATH101H', 'R3', 1], ['MATH101H', 'R2', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['split_buildings', 'MATH101H']])],
 [('regression: building count 1',
   [[['A', 'R1', 0], ['A', 'R1', 0], ['B', 'R1', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   []),
  ('regression variant: building count 2',
   [[['CHEM120', 'R1', 2], ['MATH101H', 'R3', 2], ['MATH101H', 'R4', 2], ['MATH101H', 'R4', 2]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   []),
  ('partial repair guard 3',
   [[['CHEM120', 'R4', 1], ['CHEM120', 'R2', 0], ['MATH101H', 'R3', 2], ['MATH101H', 'R4', 2],
     ['PHYS110', 'R2', 2], ['CHEM120', 'R4', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'CHEM120'], ['split_buildings', 'CHEM120']]),
  ('boundary control 4',
   [[['A', 'R1', 0], ['A', 'R3', 0]], {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['split_buildings', 'A']]),
  ('normal control 5',
   [[['MATH101H', 'R4', 1], ['MATH101H', 'R2', 2], ['MATH101', 'R2', 1], ['MATH101', 'R1', 2],
     ['PHYS110', 'R1', 1], ['MATH101H', 'R2', 2], ['PHYS110', 'R2', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'MATH101'], ['multi_period', 'MATH101H'], ['split_buildings', 'MATH101H'],
    ['room_load', 'R2', 1]]),
  ('normal control 6',
   [[['MATH101H', 'R2', 1], ['MATH101H', 'R3', 0], ['CHEM120', 'R4', 2], ['MATH101H', 'R2', 0],
     ['CHEM120', 'R3', 1], ['CHEM120', 'R2', 0], ['PHYS110', 'R3', 0], ['CHEM120', 'R2', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'CHEM120'], ['split_buildings', 'CHEM120'], ['multi_period', 'MATH101H'],
    ['split_buildings', 'MATH101H'], ['room_load', 'R2', 0], ['room_load', 'R3', 0]]),
  ('normal control 7',
   [[['MATH101', 'R1', 0], ['MATH101H', 'R1', 1], ['MATH101', 'R4', 0], ['MATH101', 'R1', 0],
     ['MATH101H', 'R2', 0], ['MATH101', 'R4', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['split_buildings', 'MATH101'], ['multi_period', 'MATH101H']]),
  ('normal control 8',
   [[['MATH101H', 'R2', 1], ['CHEM120', 'R4', 0], ['CHEM120', 'R4', 0], ['PHYS110', 'R3', 0],
     ['MATH101', 'R1', 0], ['MATH101', 'R3', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'MATH101'], ['split_buildings', 'MATH101']])],
 [('regression: building count 1',
   [[['A', 'R1', 0], ['A', 'R1', 1]], {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'A']]),
  ('regression variant: building count 2',
   [[['MATH101', 'R2', 2], ['PHYS110', 'R3', 2], ['MATH101', 'R2', 2]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   []),
  ('partial repair guard 3',
   [[['CHEM120', 'R2', 0], ['MATH101', 'R1', 1], ['PHYS110', 'R2', 1], ['MATH101', 'R4', 1],
     ['PHYS110', 'R1', 2], ['MATH101', 'R4', 1], ['MATH101H', 'R2', 1], ['CHEM120', 'R2', 2],
     ['CHEM120', 'R2', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'CHEM120'], ['split_buildings', 'MATH101'], ['multi_period', 'PHYS110']]),
  ('boundary control 4',
   [[['A', 'R1', 0], ['A', 'R1', 2]], {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'A']]),
  ('normal control 5',
   [[['PHYS110', 'R4', 2], ['MATH101H', 'R2', 1], ['PHYS110', 'R1', 2], ['CHEM120', 'R1', 0],
     ['MATH101H', 'R1', 0], ['MATH101H', 'R2', 1], ['PHYS110', 'R1', 2]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'MATH101H'], ['split_buildings', 'PHYS110']]),
  ('normal control 6',
   [[['PHYS110', 'R2', 0], ['MATH101', 'R1', 2], ['PHYS110', 'R3', 2], ['MATH101', 'R1', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'MATH101'], ['multi_period', 'PHYS110'], ['split_buildings', 'PHYS110']]),
  ('normal control 7',
   [[['MATH101', 'R1', 2], ['CHEM120', 'R4', 2], ['CHEM120', 'R2', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'CHEM120'], ['split_buildings', 'CHEM120']]),
  ('normal control 8',
   [[['PHYS110', 'R4', 0], ['MATH101H', 'R2', 0], ['MATH101H', 'R1', 0], ['MATH101', 'R2', 1],
     ['MATH101', 'R3', 1], ['CHEM120', 'R1', 0], ['MATH101', 'R3', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['split_buildings', 'MATH101'], ['room_load', 'R1', 0]])],
 [('regression: building count 1',
   [[['A', 'R1', 0], ['A', 'R1', 2]], {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'A']]),
  ('regression variant: building count 2',
   [[['CHEM120', 'R1', 1], ['MATH101H', 'R2', 1], ['MATH101', 'R3', 0], ['MATH101H', 'R3', 0],
     ['CHEM120', 'R1', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'MATH101H'], ['split_buildings', 'MATH101H']]),
  ('partial repair guard 3',
   [[['PHYS110', 'R3', 0], ['MATH101H', 'R3', 1], ['MATH101H', 'R4', 2], ['MATH101H', 'R4', 2]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'MATH101H']]),
  ('boundary control 4',
   [[['A', 'R1', 0], ['A', 'R1', 0], ['B', 'R1', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   []),
  ('normal control 5',
   [[['MATH101H', 'R3', 1], ['MATH101H', 'R1', 0], ['MATH101H', 'R2', 2], ['CHEM120', 'R3', 1],
     ['MATH101H', 'R3', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'MATH101H'], ['split_buildings', 'MATH101H']]),
  ('normal control 6',
   [[['CHEM120', 'R4', 1], ['MATH101H', 'R1', 0], ['CHEM120', 'R1', 2], ['MATH101H', 'R4', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'CHEM120'], ['split_buildings', 'CHEM120'], ['split_buildings', 'MATH101H']]),
  ('normal control 7',
   [[['MATH101H', 'R4', 0], ['CHEM120', 'R4', 1], ['MATH101H', 'R4', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   []),
  ('normal control 8',
   [[['MATH101H', 'R3', 1], ['MATH101', 'R4', 2], ['MATH101', 'R4', 0], ['MATH101H', 'R2', 0],
     ['CHEM120', 'R2', 2], ['MATH101', 'R1', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'MATH101'], ['split_buildings', 'MATH101'], ['multi_period', 'MATH101H'],
    ['split_buildings', 'MATH101H']])],
 [('regression: building count 1',
   [[['PHYS110', 'R3', 0], ['CHEM120', 'R4', 2], ['CHEM120', 'R4', 2], ['PHYS110', 'R4', 1],
     ['CHEM120', 'R4', 0], ['MATH101', 'R3', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'CHEM120'], ['multi_period', 'PHYS110']]),
  ('regression variant: building count 2',
   [[['PHYS110', 'R3', 2], ['MATH101', 'R4', 2], ['MATH101H', 'R1', 2], ['CHEM120', 'R2', 2],
     ['PHYS110', 'R3', 1], ['MATH101', 'R4', 2], ['PHYS110', 'R2', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'PHYS110'], ['split_buildings', 'PHYS110']]),
  ('partial repair guard 3',
   [[['MATH101', 'R3', 2], ['PHYS110', 'R4', 0], ['CHEM120', 'R4', 1], ['MATH101', 'R4', 2]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   []),
  ('boundary control 4',
   [[['A', 'R1', 0], ['A', 'R2', 0]], {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1], []),
  ('normal control 5',
   [[['PHYS110', 'R4', 0], ['CHEM120', 'R4', 0], ['MATH101', 'R2', 0], ['PHYS110', 'R4', 2],
     ['MATH101H', 'R4', 1], ['PHYS110', 'R4', 0], ['MATH101', 'R3', 2], ['PHYS110', 'R3', 2],
     ['PHYS110', 'R4', 0]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'MATH101'], ['split_buildings', 'MATH101'], ['multi_period', 'PHYS110']]),
  ('normal control 6',
   [[['MATH101H', 'R4', 0], ['PHYS110', 'R2', 2], ['MATH101', 'R2', 2], ['MATH101', 'R2', 2]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   []),
  ('normal control 7',
   [[['PHYS110', 'R4', 2], ['CHEM120', 'R1', 2], ['PHYS110', 'R2', 0], ['CHEM120', 'R1', 0],
     ['MATH101', 'R1', 0], ['MATH101H', 'R1', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 1],
   [['multi_period', 'CHEM120'], ['multi_period', 'PHYS110'], ['split_buildings', 'PHYS110'],
    ['room_load', 'R1', 0]]),
  ('normal control 8',
   [[['PHYS110', 'R3', 2], ['MATH101H', 'R4', 2], ['CHEM120', 'R4', 1], ['PHYS110', 'R3', 0],
     ['PHYS110', 'R2', 0], ['CHEM120', 'R4', 1]],
    {'R1': 'north', 'R2': 'north', 'R3': 'south', 'R4': 'south'}, 2],
   [['multi_period', 'PHYS110'], ['split_buildings', 'PHYS110']])]]
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: building count 1[['split_buildings', 'A']][]Failed
regression variant: building count 2[['multi_period', 'PHYS110']][['multi_period', 'PHYS110']]Passed
partial repair guard 3[['multi_period', 'CHEM120'], ['split_buildings', 'CHEM120'], ['multi_period', 'MATH101'], ['split_buildings', 'MATH101']][['multi_period', 'CHEM120'], ['multi_period', 'MATH101'], ['split_buildings', 'MATH101']]Failed
boundary control 4[['multi_period', 'A']][['multi_period', 'A']]Passed
normal control 5[['multi_period', 'CHEM120'], ['split_buildings', 'CHEM120']][['multi_period', 'CHEM120'], ['split_buildings', 'CHEM120']]Passed
normal control 6[['multi_period', 'MATH101H'], ['split_buildings', 'MATH101H'], ['split_buildings', 'PHYS110']][['multi_period', 'MATH101H'], ['split_buildings', 'PHYS110']]Failed
normal control 7[][]Passed
normal control 8[['split_buildings', 'MATH101H']][['split_buildings', 'MATH101H']]Passed

SHA-256 / 0c716426fd5ab5561d37a42b245837f4b2f4186598701976e5cd22ab3d7fef0e

HELD IN THE MEMBER ARCHIVE

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

This mechanism has 8 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

Stipulated toy exam-timetabling rule set for a bounded model; it does not claim conformance with any institution's regulations or a benchmark specification, and it performs no search or optimisation. 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:52:07.798524+00:00.

Case digest / f18e2621c012f3ba38311c65b54b235b39e5d4ebd0d09be8be6e38688feba72d