FA-67601 / Elevator dispatch scheduling / Open access
Up-peak round trip time: passenger load · case 01
Round trip times assume every car leaves the lobby full.
ROOT CAUSE
The 80 percent average load factor is not applied.
VERIFIED REPAIR
Use 0.8 of the rated capacity, keeping the fraction.
Unsuccessful approach: Truncating the load to whole passengers biases every derived figure.
Case contract
Up-peak analysis with N floors above the lobby, P = 0.8*capacity passengers per trip (fractional), probable stops S = N(1-(1-1/N)^P), highest reversal floor H = N - sum_{i=1}^{N-1}(i/N)^P, RTT = 2*H*tv + (S+1)*ts + 2*P*tp, interval = RTT/cars and 5-minute handling capacity HC5 = 300*P*cars/RTT. Values rounded to 2 decimals.
Why this case matters
Lift group controllers make these decisions many times per minute; a wrong answer strands passengers, wastes trips or overrides a safety rule.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(x):
N = x['floors_above']
P = x['capacity']
S = N * (1 - (1 - 1 / N) ** P)
H = N - sum((i / N) ** P for i in range(1, N))
rtt = 2 * H * x['tv_s'] + (S + 1) * x['ts_s'] + 2 * P * x['tp_s']
return {'S': round(S, 2), 'H': round(H, 2), 'rtt': round(rtt, 2), 'interval': round(rtt / x['cars'], 2), 'hc5': round(300 * P * x['cars'] / rtt, 2)}
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[('regression: small office', {'floors_above': 5, 'capacity': 8, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 3.8, 'H': 4.72, 'rtt': 82.25, 'interval': 41.12, 'hc5': 46.69}), ('sampled regression 1', {'floors_above': 17, 'capacity': 8, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 5.47, 'H': 15.17, 'rtt': 140.72, 'interval': 70.36, 'hc5': 27.29}), ('regression: tall office', {'floors_above': 20, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 9.63, 'H': 19.0, 'rtt': 188.87, 'interval': 31.48, 'hc5': 121.99}), ('regression: fractional passenger load', {'floors_above': 12, 'capacity': 13, 'cars': 4, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 7.15, 'H': 11.38, 'rtt': 151.91, 'interval': 37.98, 'hc5': 82.15}), ('sampled regression 4', {'floors_above': 21, 'capacity': 13, 'cars': 2, 'tv_s': 1.5, 'ts_s': 8.0, 'tp_s': 1.0}, {'S': 8.36, 'H': 19.62, 'rtt': 154.51, 'interval': 77.25, 'hc5': 40.39}), ('sampled regression 7', {'floors_above': 24, 'capacity': 13, 'cars': 5, 'tv_s': 1.5, 'ts_s': 12.0, 'tp_s': 1.0}, {'S': 8.58, 'H': 22.36, 'rtt': 202.88, 'interval': 40.58, 'hc5': 76.89}), ('sampled regression 10', {'floors_above': 5, 'capacity': 8, 'cars': 5, 'tv_s': 1.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 3.8, 'H': 4.72, 'rtt': 74.97, 'interval': 14.99, 'hc5': 128.05}), ('sampled regression 13', {'floors_above': 8, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 8.0, 'tp_s': 1.2}, {'S': 6.55, 'H': 7.79, 'rtt': 114.51, 'interval': 19.08, 'hc5': 201.21})], [('regression: tall office', {'floors_above': 20, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 9.63, 'H': 19.0, 'rtt': 188.87, 'interval': 31.48, 'hc5': 121.99}), ('sampled regression 8', {'floors_above': 25, 'capacity': 13, 'cars': 3, 'tv_s': 2.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 8.65, 'H': 23.27, 'rtt': 233.65, 'interval': 77.88, 'hc5': 40.06}), ('sampled regression 4', {'floors_above': 21, 'capacity': 13, 'cars': 2, 'tv_s': 1.5, 'ts_s': 8.0, 'tp_s': 1.0}, {'S': 8.36, 'H': 19.62, 'rtt': 154.51, 'interval': 77.25, 'hc5': 40.39}), ('regression: fractional passenger load', {'floors_above': 12, 'capacity': 13, 'cars': 4, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 7.15, 'H': 11.38, 'rtt': 151.91, 'interval': 37.98, 'hc5': 82.15}), ('regression: small office', {'floors_above': 5, 'capacity': 8, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 3.8, 'H': 4.72, 'rtt': 82.25, 'interval': 41.12, 'hc5': 46.69}), ('sampled regression 12', {'floors_above': 24, 'capacity': 21, 'cars': 4, 'tv_s': 1.5, 'ts_s': 8.0, 'tp_s': 1.2}, {'S': 12.26, 'H': 23.09, 'rtt': 215.68, 'interval': 53.92, 'hc5': 93.47}), ('sampled regression 15', {'floors_above': 19, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 12.0, 'tp_s': 1.0}, {'S': 9.49, 'H': 18.07, 'rtt': 205.68, 'interval': 34.28, 'hc5': 112.02}), ('sampled regression 18', {'floors_above': 24, 'capacity': 13, 'cars': 3, 'tv_s': 2.0, 'ts_s': 8.0, 'tp_s': 1.0}, {'S': 8.58, 'H': 22.36, 'rtt': 186.9, 'interval': 62.3, 'hc5': 50.08})], [('regression: fractional passenger load', {'floors_above': 12, 'capacity': 13, 'cars': 4, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 7.15, 'H': 11.38, 'rtt': 151.91, 'interval': 37.98, 'hc5': 82.15}), ('sampled regression 15', {'floors_above': 19, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 12.0, 'tp_s': 1.0}, {'S': 9.49, 'H': 18.07, 'rtt': 205.68, 'interval': 34.28, 'hc5': 112.02}), ('sampled regression 9', {'floors_above': 23, 'capacity': 21, 'cars': 3, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 12.1, 'H': 22.15, 'rtt': 253.2, 'interval': 84.4, 'hc5': 59.72}), ('regression: tall office', {'floors_above': 20, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 9.63, 'H': 19.0, 'rtt': 188.87, 'interval': 31.48, 'hc5': 121.99}), ('regression: small office', {'floors_above': 5, 'capacity': 8, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 3.8, 'H': 4.72, 'rtt': 82.25, 'interval': 41.12, 'hc5': 46.69}), ('sampled regression 23', {'floors_above': 7, 'capacity': 16, 'cars': 4, 'tv_s': 2.0, 'ts_s': 12.0, 'tp_s': 1.0}, {'S': 6.03, 'H': 6.85, 'rtt': 137.31, 'interval': 34.33, 'hc5': 111.86}), ('sampled regression 26', {'floors_above': 18, 'capacity': 16, 'cars': 7, 'tv_s': 2.0, 'ts_s': 8.0, 'tp_s': 1.2}, {'S': 9.34, 'H': 17.14, 'rtt': 181.99, 'interval': 26.0, 'hc5': 147.7}), ('sampled regression 29', {'floors_above': 23, 'capacity': 16, 'cars': 3, 'tv_s': 2.5, 'ts_s': 12.0, 'tp_s': 1.2}, {'S': 9.98, 'H': 21.79, 'rtt': 271.41, 'interval': 90.47, 'hc5': 42.44})], [('regression: small office', {'floors_above': 5, 'capacity': 8, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 3.8, 'H': 4.72, 'rtt': 82.25, 'interval': 41.12, 'hc5': 46.69}), ('sampled regression 22', {'floors_above': 18, 'capacity': 21, 'cars': 7, 'tv_s': 2.5, 'ts_s': 12.0, 'tp_s': 1.2}, {'S': 11.11, 'H': 17.41, 'rtt': 272.7, 'interval': 38.96, 'hc5': 129.37}), ('sampled regression 14', {'floors_above': 7, 'capacity': 16, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 6.03, 'H': 6.85, 'rtt': 123.26, 'interval': 61.63, 'hc5': 62.31}), ('regression: tall office', {'floors_above': 20, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 9.63, 'H': 19.0, 'rtt': 188.87, 'interval': 31.48, 'hc5': 121.99}), ('regression: fractional passenger load', {'floors_above': 12, 'capacity': 13, 'cars': 4, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 7.15, 'H': 11.38, 'rtt': 151.91, 'interval': 37.98, 'hc5': 82.15}), ('sampled regression 34', {'floors_above': 16, 'capacity': 8, 'cars': 8, 'tv_s': 2.5, 'ts_s': 8.0, 'tp_s': 1.0}, {'S': 5.41, 'H': 14.3, 'rtt': 135.63, 'interval': 16.95, 'hc5': 113.25}), ('sampled regression 37', {'floors_above': 14, 'capacity': 13, 'cars': 2, 'tv_s': 2.5, 'ts_s': 12.0, 'tp_s': 1.2}, {'S': 7.52, 'H': 13.21, 'rtt': 193.28, 'interval': 96.64, 'hc5': 32.28}), ('sampled regression 40', {'floors_above': 9, 'capacity': 21, 'cars': 2, 'tv_s': 2.5, 'ts_s': 12.0, 'tp_s': 1.0}, {'S': 7.76, 'H': 8.85, 'rtt': 182.9, 'interval': 91.45, 'hc5': 55.11})], [('regression: tall office', {'floors_above': 20, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 9.63, 'H': 19.0, 'rtt': 188.87, 'interval': 31.48, 'hc5': 121.99}), ('sampled regression 29', {'floors_above': 23, 'capacity': 16, 'cars': 3, 'tv_s': 2.5, 'ts_s': 12.0, 'tp_s': 1.2}, {'S': 9.98, 'H': 21.79, 'rtt': 271.41, 'interval': 90.47, 'hc5': 42.44}), ('sampled regression 19', {'floors_above': 18, 'capacity': 16, 'cars': 7, 'tv_s': 2.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 9.34, 'H': 17.14, 'rtt': 214.68, 'interval': 30.67, 'hc5': 125.21}), ('regression: fractional passenger load', {'floors_above': 12, 'capacity': 13, 'cars': 4, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 7.15, 'H': 11.38, 'rtt': 151.91, 'interval': 37.98, 'hc5': 82.15}), ('regression: small office', {'floors_above': 5, 'capacity': 8, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 3.8, 'H': 4.72, 'rtt': 82.25, 'interval': 41.12, 'hc5': 46.69}), ('sampled regression 45', {'floors_above': 14, 'capacity': 13, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 7.52, 'H': 13.21, 'rtt': 163.03, 'interval': 81.51, 'hc5': 38.28}), ('sampled regression 48', {'floors_above': 19, 'capacity': 8, 'cars': 7, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 5.56, 'H': 16.9, 'rtt': 145.99, 'interval': 20.86, 'hc5': 92.06}), ('sampled regression 51', {'floors_above': 16, 'capacity': 8, 'cars': 8, 'tv_s': 2.5, 'ts_s': 8.0, 'tp_s': 1.0}, {'S': 5.41, 'H': 14.3, 'rtt': 135.63, 'interval': 16.95, 'hc5': 113.25})]]
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 fixture | Actual | Expected | Outcome |
|---|---|---|---|
| regression: small office | {'H': 4.81, 'S': 4.16, 'hc5': 53.29, 'interval': 45.04, 'rtt': 90.07} | {'H': 4.72, 'S': 3.8, 'hc5': 46.69, 'interval': 41.12, 'rtt': 82.25} | Failed |
| sampled regression 1 | {'H': 15.57, 'S': 6.53, 'hc5': 30.61, 'interval': 78.41, 'rtt': 156.82} | {'H': 15.17, 'S': 5.47, 'hc5': 27.29, 'interval': 70.36, 'rtt': 140.72} | Failed |
| regression: tall office | {'H': 19.26, 'S': 11.2, 'hc5': 136.01, 'interval': 35.29, 'rtt': 211.75} | {'H': 19.0, 'S': 9.63, 'hc5': 121.99, 'interval': 31.48, 'rtt': 188.87} | Failed |
| regression: fractional passenger load | {'H': 11.55, 'S': 8.13, 'hc5': 92.47, 'interval': 42.17, 'rtt': 168.7} | {'H': 11.38, 'S': 7.15, 'hc5': 82.15, 'interval': 37.98, 'rtt': 151.91} | Failed |
| sampled regression 4 | {'H': 19.95, 'S': 9.86, 'hc5': 45.15, 'interval': 86.38, 'rtt': 172.75} | {'H': 19.62, 'S': 8.36, 'hc5': 40.39, 'interval': 77.25, 'rtt': 154.51} | Failed |
| sampled regression 7 | {'H': 22.74, 'S': 10.2, 'hc5': 85.3, 'interval': 45.72, 'rtt': 228.6} | {'H': 22.36, 'S': 8.58, 'hc5': 76.89, 'interval': 40.58, 'rtt': 202.88} | Failed |
| sampled regression 10 | {'H': 4.81, 'S': 4.16, 'hc5': 146.24, 'interval': 16.41, 'rtt': 82.06} | {'H': 4.72, 'S': 3.8, 'hc5': 128.05, 'interval': 14.99, 'rtt': 74.97} | Failed |
| sampled regression 13 | {'H': 7.87, 'S': 7.06, 'hc5': 227.74, 'interval': 21.08, 'rtt': 126.46} | {'H': 7.79, 'S': 6.55, 'hc5': 201.21, 'interval': 19.08, 'rtt': 114.51} | Failed |
SHA-256 / bd82f624b2434593b2d356605c13a9e9c58d95b1adadb55617c7f6035fddeba7
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(x):
N = x['floors_above']
P = int(0.8 * x['capacity'])
S = N * (1 - (1 - 1 / N) ** P)
H = N - sum((i / N) ** P for i in range(1, N))
rtt = 2 * H * x['tv_s'] + (S + 1) * x['ts_s'] + 2 * P * x['tp_s']
return {'S': round(S, 2), 'H': round(H, 2), 'rtt': round(rtt, 2), 'interval': round(rtt / x['cars'], 2), 'hc5': round(300 * P * x['cars'] / rtt, 2)}
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[('regression: small office', {'floors_above': 5, 'capacity': 8, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 3.8, 'H': 4.72, 'rtt': 82.25, 'interval': 41.12, 'hc5': 46.69}), ('sampled regression 1', {'floors_above': 17, 'capacity': 8, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 5.47, 'H': 15.17, 'rtt': 140.72, 'interval': 70.36, 'hc5': 27.29}), ('regression: tall office', {'floors_above': 20, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 9.63, 'H': 19.0, 'rtt': 188.87, 'interval': 31.48, 'hc5': 121.99}), ('regression: fractional passenger load', {'floors_above': 12, 'capacity': 13, 'cars': 4, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 7.15, 'H': 11.38, 'rtt': 151.91, 'interval': 37.98, 'hc5': 82.15}), ('sampled regression 4', {'floors_above': 21, 'capacity': 13, 'cars': 2, 'tv_s': 1.5, 'ts_s': 8.0, 'tp_s': 1.0}, {'S': 8.36, 'H': 19.62, 'rtt': 154.51, 'interval': 77.25, 'hc5': 40.39}), ('sampled regression 7', {'floors_above': 24, 'capacity': 13, 'cars': 5, 'tv_s': 1.5, 'ts_s': 12.0, 'tp_s': 1.0}, {'S': 8.58, 'H': 22.36, 'rtt': 202.88, 'interval': 40.58, 'hc5': 76.89}), ('sampled regression 10', {'floors_above': 5, 'capacity': 8, 'cars': 5, 'tv_s': 1.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 3.8, 'H': 4.72, 'rtt': 74.97, 'interval': 14.99, 'hc5': 128.05}), ('sampled regression 13', {'floors_above': 8, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 8.0, 'tp_s': 1.2}, {'S': 6.55, 'H': 7.79, 'rtt': 114.51, 'interval': 19.08, 'hc5': 201.21})], [('regression: tall office', {'floors_above': 20, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 9.63, 'H': 19.0, 'rtt': 188.87, 'interval': 31.48, 'hc5': 121.99}), ('sampled regression 8', {'floors_above': 25, 'capacity': 13, 'cars': 3, 'tv_s': 2.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 8.65, 'H': 23.27, 'rtt': 233.65, 'interval': 77.88, 'hc5': 40.06}), ('sampled regression 4', {'floors_above': 21, 'capacity': 13, 'cars': 2, 'tv_s': 1.5, 'ts_s': 8.0, 'tp_s': 1.0}, {'S': 8.36, 'H': 19.62, 'rtt': 154.51, 'interval': 77.25, 'hc5': 40.39}), ('regression: fractional passenger load', {'floors_above': 12, 'capacity': 13, 'cars': 4, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 7.15, 'H': 11.38, 'rtt': 151.91, 'interval': 37.98, 'hc5': 82.15}), ('regression: small office', {'floors_above': 5, 'capacity': 8, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 3.8, 'H': 4.72, 'rtt': 82.25, 'interval': 41.12, 'hc5': 46.69}), ('sampled regression 12', {'floors_above': 24, 'capacity': 21, 'cars': 4, 'tv_s': 1.5, 'ts_s': 8.0, 'tp_s': 1.2}, {'S': 12.26, 'H': 23.09, 'rtt': 215.68, 'interval': 53.92, 'hc5': 93.47}), ('sampled regression 15', {'floors_above': 19, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 12.0, 'tp_s': 1.0}, {'S': 9.49, 'H': 18.07, 'rtt': 205.68, 'interval': 34.28, 'hc5': 112.02}), ('sampled regression 18', {'floors_above': 24, 'capacity': 13, 'cars': 3, 'tv_s': 2.0, 'ts_s': 8.0, 'tp_s': 1.0}, {'S': 8.58, 'H': 22.36, 'rtt': 186.9, 'interval': 62.3, 'hc5': 50.08})], [('regression: fractional passenger load', {'floors_above': 12, 'capacity': 13, 'cars': 4, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 7.15, 'H': 11.38, 'rtt': 151.91, 'interval': 37.98, 'hc5': 82.15}), ('sampled regression 15', {'floors_above': 19, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 12.0, 'tp_s': 1.0}, {'S': 9.49, 'H': 18.07, 'rtt': 205.68, 'interval': 34.28, 'hc5': 112.02}), ('sampled regression 9', {'floors_above': 23, 'capacity': 21, 'cars': 3, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 12.1, 'H': 22.15, 'rtt': 253.2, 'interval': 84.4, 'hc5': 59.72}), ('regression: tall office', {'floors_above': 20, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 9.63, 'H': 19.0, 'rtt': 188.87, 'interval': 31.48, 'hc5': 121.99}), ('regression: small office', {'floors_above': 5, 'capacity': 8, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 3.8, 'H': 4.72, 'rtt': 82.25, 'interval': 41.12, 'hc5': 46.69}), ('sampled regression 23', {'floors_above': 7, 'capacity': 16, 'cars': 4, 'tv_s': 2.0, 'ts_s': 12.0, 'tp_s': 1.0}, {'S': 6.03, 'H': 6.85, 'rtt': 137.31, 'interval': 34.33, 'hc5': 111.86}), ('sampled regression 26', {'floors_above': 18, 'capacity': 16, 'cars': 7, 'tv_s': 2.0, 'ts_s': 8.0, 'tp_s': 1.2}, {'S': 9.34, 'H': 17.14, 'rtt': 181.99, 'interval': 26.0, 'hc5': 147.7}), ('sampled regression 29', {'floors_above': 23, 'capacity': 16, 'cars': 3, 'tv_s': 2.5, 'ts_s': 12.0, 'tp_s': 1.2}, {'S': 9.98, 'H': 21.79, 'rtt': 271.41, 'interval': 90.47, 'hc5': 42.44})], [('regression: small office', {'floors_above': 5, 'capacity': 8, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 3.8, 'H': 4.72, 'rtt': 82.25, 'interval': 41.12, 'hc5': 46.69}), ('sampled regression 22', {'floors_above': 18, 'capacity': 21, 'cars': 7, 'tv_s': 2.5, 'ts_s': 12.0, 'tp_s': 1.2}, {'S': 11.11, 'H': 17.41, 'rtt': 272.7, 'interval': 38.96, 'hc5': 129.37}), ('sampled regression 14', {'floors_above': 7, 'capacity': 16, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 6.03, 'H': 6.85, 'rtt': 123.26, 'interval': 61.63, 'hc5': 62.31}), ('regression: tall office', {'floors_above': 20, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 9.63, 'H': 19.0, 'rtt': 188.87, 'interval': 31.48, 'hc5': 121.99}), ('regression: fractional passenger load', {'floors_above': 12, 'capacity': 13, 'cars': 4, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 7.15, 'H': 11.38, 'rtt': 151.91, 'interval': 37.98, 'hc5': 82.15}), ('sampled regression 34', {'floors_above': 16, 'capacity': 8, 'cars': 8, 'tv_s': 2.5, 'ts_s': 8.0, 'tp_s': 1.0}, {'S': 5.41, 'H': 14.3, 'rtt': 135.63, 'interval': 16.95, 'hc5': 113.25}), ('sampled regression 37', {'floors_above': 14, 'capacity': 13, 'cars': 2, 'tv_s': 2.5, 'ts_s': 12.0, 'tp_s': 1.2}, {'S': 7.52, 'H': 13.21, 'rtt': 193.28, 'interval': 96.64, 'hc5': 32.28}), ('sampled regression 40', {'floors_above': 9, 'capacity': 21, 'cars': 2, 'tv_s': 2.5, 'ts_s': 12.0, 'tp_s': 1.0}, {'S': 7.76, 'H': 8.85, 'rtt': 182.9, 'interval': 91.45, 'hc5': 55.11})], [('regression: tall office', {'floors_above': 20, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 9.63, 'H': 19.0, 'rtt': 188.87, 'interval': 31.48, 'hc5': 121.99}), ('sampled regression 29', {'floors_above': 23, 'capacity': 16, 'cars': 3, 'tv_s': 2.5, 'ts_s': 12.0, 'tp_s': 1.2}, {'S': 9.98, 'H': 21.79, 'rtt': 271.41, 'interval': 90.47, 'hc5': 42.44}), ('sampled regression 19', {'floors_above': 18, 'capacity': 16, 'cars': 7, 'tv_s': 2.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 9.34, 'H': 17.14, 'rtt': 214.68, 'interval': 30.67, 'hc5': 125.21}), ('regression: fractional passenger load', {'floors_above': 12, 'capacity': 13, 'cars': 4, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 7.15, 'H': 11.38, 'rtt': 151.91, 'interval': 37.98, 'hc5': 82.15}), ('regression: small office', {'floors_above': 5, 'capacity': 8, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 3.8, 'H': 4.72, 'rtt': 82.25, 'interval': 41.12, 'hc5': 46.69}), ('sampled regression 45', {'floors_above': 14, 'capacity': 13, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 7.52, 'H': 13.21, 'rtt': 163.03, 'interval': 81.51, 'hc5': 38.28}), ('sampled regression 48', {'floors_above': 19, 'capacity': 8, 'cars': 7, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 5.56, 'H': 16.9, 'rtt': 145.99, 'interval': 20.86, 'hc5': 92.06}), ('sampled regression 51', {'floors_above': 16, 'capacity': 8, 'cars': 8, 'tv_s': 2.5, 'ts_s': 8.0, 'tp_s': 1.0}, {'S': 5.41, 'H': 14.3, 'rtt': 135.63, 'interval': 16.95, 'hc5': 113.25})]]
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 fixture | Actual | Expected | Outcome |
|---|---|---|---|
| regression: small office | {'H': 4.69, 'S': 3.69, 'hc5': 44.98, 'interval': 40.02, 'rtt': 80.04} | {'H': 4.72, 'S': 3.8, 'hc5': 46.69, 'interval': 41.12, 'rtt': 82.25} | Failed |
| sampled regression 1 | {'H': 15.04, 'S': 5.18, 'hc5': 26.39, 'interval': 68.2, 'rtt': 136.41} | {'H': 15.17, 'S': 5.47, 'hc5': 27.29, 'interval': 70.36, 'rtt': 140.72} | Failed |
| regression: tall office | {'H': 18.91, 'S': 9.19, 'hc5': 118.25, 'interval': 30.44, 'rtt': 182.66} | {'H': 19.0, 'S': 9.63, 'hc5': 121.99, 'interval': 31.48, 'rtt': 188.87} | Failed |
| regression: fractional passenger load | {'H': 11.34, 'S': 6.97, 'hc5': 80.49, 'interval': 37.27, 'rtt': 149.09} | {'H': 11.38, 'S': 7.15, 'hc5': 82.15, 'interval': 37.98, 'rtt': 151.91} | Failed |
| sampled regression 4 | {'H': 19.55, 'S': 8.11, 'hc5': 39.6, 'interval': 75.76, 'rtt': 151.52} | {'H': 19.62, 'S': 8.36, 'hc5': 40.39, 'interval': 77.25, 'rtt': 154.51} | Failed |
| sampled regression 7 | {'H': 22.28, 'S': 8.32, 'hc5': 75.5, 'interval': 39.74, 'rtt': 198.68} | {'H': 22.36, 'S': 8.58, 'hc5': 76.89, 'interval': 40.58, 'rtt': 202.88} | Failed |
| sampled regression 10 | {'H': 4.69, 'S': 3.69, 'hc5': 123.37, 'interval': 14.59, 'rtt': 72.95} | {'H': 4.72, 'S': 3.8, 'hc5': 128.05, 'interval': 14.99, 'rtt': 74.97} | Failed |
| sampled regression 13 | {'H': 7.76, 'S': 6.39, 'hc5': 194.25, 'interval': 18.53, 'rtt': 111.2} | {'H': 7.79, 'S': 6.55, 'hc5': 201.21, 'interval': 19.08, 'rtt': 114.51} | Failed |
SHA-256 / 2c25862624a6498c1d066238f80c3210ed5b1af78be8a9ccd632607b45ca563e
3 / The verified repair
Exit 0"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(x):
N = x['floors_above']
P = 0.8 * x['capacity']
S = N * (1 - (1 - 1 / N) ** P)
H = N - sum((i / N) ** P for i in range(1, N))
rtt = 2 * H * x['tv_s'] + (S + 1) * x['ts_s'] + 2 * P * x['tp_s']
return {'S': round(S, 2), 'H': round(H, 2), 'rtt': round(rtt, 2), 'interval': round(rtt / x['cars'], 2), 'hc5': round(300 * P * x['cars'] / rtt, 2)}
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[('regression: small office', {'floors_above': 5, 'capacity': 8, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 3.8, 'H': 4.72, 'rtt': 82.25, 'interval': 41.12, 'hc5': 46.69}), ('sampled regression 1', {'floors_above': 17, 'capacity': 8, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 5.47, 'H': 15.17, 'rtt': 140.72, 'interval': 70.36, 'hc5': 27.29}), ('regression: tall office', {'floors_above': 20, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 9.63, 'H': 19.0, 'rtt': 188.87, 'interval': 31.48, 'hc5': 121.99}), ('regression: fractional passenger load', {'floors_above': 12, 'capacity': 13, 'cars': 4, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 7.15, 'H': 11.38, 'rtt': 151.91, 'interval': 37.98, 'hc5': 82.15}), ('sampled regression 4', {'floors_above': 21, 'capacity': 13, 'cars': 2, 'tv_s': 1.5, 'ts_s': 8.0, 'tp_s': 1.0}, {'S': 8.36, 'H': 19.62, 'rtt': 154.51, 'interval': 77.25, 'hc5': 40.39}), ('sampled regression 7', {'floors_above': 24, 'capacity': 13, 'cars': 5, 'tv_s': 1.5, 'ts_s': 12.0, 'tp_s': 1.0}, {'S': 8.58, 'H': 22.36, 'rtt': 202.88, 'interval': 40.58, 'hc5': 76.89}), ('sampled regression 10', {'floors_above': 5, 'capacity': 8, 'cars': 5, 'tv_s': 1.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 3.8, 'H': 4.72, 'rtt': 74.97, 'interval': 14.99, 'hc5': 128.05}), ('sampled regression 13', {'floors_above': 8, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 8.0, 'tp_s': 1.2}, {'S': 6.55, 'H': 7.79, 'rtt': 114.51, 'interval': 19.08, 'hc5': 201.21})], [('regression: tall office', {'floors_above': 20, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 9.63, 'H': 19.0, 'rtt': 188.87, 'interval': 31.48, 'hc5': 121.99}), ('sampled regression 8', {'floors_above': 25, 'capacity': 13, 'cars': 3, 'tv_s': 2.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 8.65, 'H': 23.27, 'rtt': 233.65, 'interval': 77.88, 'hc5': 40.06}), ('sampled regression 4', {'floors_above': 21, 'capacity': 13, 'cars': 2, 'tv_s': 1.5, 'ts_s': 8.0, 'tp_s': 1.0}, {'S': 8.36, 'H': 19.62, 'rtt': 154.51, 'interval': 77.25, 'hc5': 40.39}), ('regression: fractional passenger load', {'floors_above': 12, 'capacity': 13, 'cars': 4, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 7.15, 'H': 11.38, 'rtt': 151.91, 'interval': 37.98, 'hc5': 82.15}), ('regression: small office', {'floors_above': 5, 'capacity': 8, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 3.8, 'H': 4.72, 'rtt': 82.25, 'interval': 41.12, 'hc5': 46.69}), ('sampled regression 12', {'floors_above': 24, 'capacity': 21, 'cars': 4, 'tv_s': 1.5, 'ts_s': 8.0, 'tp_s': 1.2}, {'S': 12.26, 'H': 23.09, 'rtt': 215.68, 'interval': 53.92, 'hc5': 93.47}), ('sampled regression 15', {'floors_above': 19, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 12.0, 'tp_s': 1.0}, {'S': 9.49, 'H': 18.07, 'rtt': 205.68, 'interval': 34.28, 'hc5': 112.02}), ('sampled regression 18', {'floors_above': 24, 'capacity': 13, 'cars': 3, 'tv_s': 2.0, 'ts_s': 8.0, 'tp_s': 1.0}, {'S': 8.58, 'H': 22.36, 'rtt': 186.9, 'interval': 62.3, 'hc5': 50.08})], [('regression: fractional passenger load', {'floors_above': 12, 'capacity': 13, 'cars': 4, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 7.15, 'H': 11.38, 'rtt': 151.91, 'interval': 37.98, 'hc5': 82.15}), ('sampled regression 15', {'floors_above': 19, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 12.0, 'tp_s': 1.0}, {'S': 9.49, 'H': 18.07, 'rtt': 205.68, 'interval': 34.28, 'hc5': 112.02}), ('sampled regression 9', {'floors_above': 23, 'capacity': 21, 'cars': 3, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 12.1, 'H': 22.15, 'rtt': 253.2, 'interval': 84.4, 'hc5': 59.72}), ('regression: tall office', {'floors_above': 20, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 9.63, 'H': 19.0, 'rtt': 188.87, 'interval': 31.48, 'hc5': 121.99}), ('regression: small office', {'floors_above': 5, 'capacity': 8, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 3.8, 'H': 4.72, 'rtt': 82.25, 'interval': 41.12, 'hc5': 46.69}), ('sampled regression 23', {'floors_above': 7, 'capacity': 16, 'cars': 4, 'tv_s': 2.0, 'ts_s': 12.0, 'tp_s': 1.0}, {'S': 6.03, 'H': 6.85, 'rtt': 137.31, 'interval': 34.33, 'hc5': 111.86}), ('sampled regression 26', {'floors_above': 18, 'capacity': 16, 'cars': 7, 'tv_s': 2.0, 'ts_s': 8.0, 'tp_s': 1.2}, {'S': 9.34, 'H': 17.14, 'rtt': 181.99, 'interval': 26.0, 'hc5': 147.7}), ('sampled regression 29', {'floors_above': 23, 'capacity': 16, 'cars': 3, 'tv_s': 2.5, 'ts_s': 12.0, 'tp_s': 1.2}, {'S': 9.98, 'H': 21.79, 'rtt': 271.41, 'interval': 90.47, 'hc5': 42.44})], [('regression: small office', {'floors_above': 5, 'capacity': 8, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 3.8, 'H': 4.72, 'rtt': 82.25, 'interval': 41.12, 'hc5': 46.69}), ('sampled regression 22', {'floors_above': 18, 'capacity': 21, 'cars': 7, 'tv_s': 2.5, 'ts_s': 12.0, 'tp_s': 1.2}, {'S': 11.11, 'H': 17.41, 'rtt': 272.7, 'interval': 38.96, 'hc5': 129.37}), ('sampled regression 14', {'floors_above': 7, 'capacity': 16, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 6.03, 'H': 6.85, 'rtt': 123.26, 'interval': 61.63, 'hc5': 62.31}), ('regression: tall office', {'floors_above': 20, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 9.63, 'H': 19.0, 'rtt': 188.87, 'interval': 31.48, 'hc5': 121.99}), ('regression: fractional passenger load', {'floors_above': 12, 'capacity': 13, 'cars': 4, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 7.15, 'H': 11.38, 'rtt': 151.91, 'interval': 37.98, 'hc5': 82.15}), ('sampled regression 34', {'floors_above': 16, 'capacity': 8, 'cars': 8, 'tv_s': 2.5, 'ts_s': 8.0, 'tp_s': 1.0}, {'S': 5.41, 'H': 14.3, 'rtt': 135.63, 'interval': 16.95, 'hc5': 113.25}), ('sampled regression 37', {'floors_above': 14, 'capacity': 13, 'cars': 2, 'tv_s': 2.5, 'ts_s': 12.0, 'tp_s': 1.2}, {'S': 7.52, 'H': 13.21, 'rtt': 193.28, 'interval': 96.64, 'hc5': 32.28}), ('sampled regression 40', {'floors_above': 9, 'capacity': 21, 'cars': 2, 'tv_s': 2.5, 'ts_s': 12.0, 'tp_s': 1.0}, {'S': 7.76, 'H': 8.85, 'rtt': 182.9, 'interval': 91.45, 'hc5': 55.11})], [('regression: tall office', {'floors_above': 20, 'capacity': 16, 'cars': 6, 'tv_s': 1.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 9.63, 'H': 19.0, 'rtt': 188.87, 'interval': 31.48, 'hc5': 121.99}), ('sampled regression 29', {'floors_above': 23, 'capacity': 16, 'cars': 3, 'tv_s': 2.5, 'ts_s': 12.0, 'tp_s': 1.2}, {'S': 9.98, 'H': 21.79, 'rtt': 271.41, 'interval': 90.47, 'hc5': 42.44}), ('sampled regression 19', {'floors_above': 18, 'capacity': 16, 'cars': 7, 'tv_s': 2.5, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 9.34, 'H': 17.14, 'rtt': 214.68, 'interval': 30.67, 'hc5': 125.21}), ('regression: fractional passenger load', {'floors_above': 12, 'capacity': 13, 'cars': 4, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 7.15, 'H': 11.38, 'rtt': 151.91, 'interval': 37.98, 'hc5': 82.15}), ('regression: small office', {'floors_above': 5, 'capacity': 8, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 3.8, 'H': 4.72, 'rtt': 82.25, 'interval': 41.12, 'hc5': 46.69}), ('sampled regression 45', {'floors_above': 14, 'capacity': 13, 'cars': 2, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.2}, {'S': 7.52, 'H': 13.21, 'rtt': 163.03, 'interval': 81.51, 'hc5': 38.28}), ('sampled regression 48', {'floors_above': 19, 'capacity': 8, 'cars': 7, 'tv_s': 2.0, 'ts_s': 10.0, 'tp_s': 1.0}, {'S': 5.56, 'H': 16.9, 'rtt': 145.99, 'interval': 20.86, 'hc5': 92.06}), ('sampled regression 51', {'floors_above': 16, 'capacity': 8, 'cars': 8, 'tv_s': 2.5, 'ts_s': 8.0, 'tp_s': 1.0}, {'S': 5.41, 'H': 14.3, 'rtt': 135.63, 'interval': 16.95, 'hc5': 113.25})]]
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 fixture | Actual | Expected | Outcome |
|---|---|---|---|
| regression: small office | {'H': 4.72, 'S': 3.8, 'hc5': 46.69, 'interval': 41.12, 'rtt': 82.25} | {'H': 4.72, 'S': 3.8, 'hc5': 46.69, 'interval': 41.12, 'rtt': 82.25} | Passed |
| sampled regression 1 | {'H': 15.17, 'S': 5.47, 'hc5': 27.29, 'interval': 70.36, 'rtt': 140.72} | {'H': 15.17, 'S': 5.47, 'hc5': 27.29, 'interval': 70.36, 'rtt': 140.72} | Passed |
| regression: tall office | {'H': 19.0, 'S': 9.63, 'hc5': 121.99, 'interval': 31.48, 'rtt': 188.87} | {'H': 19.0, 'S': 9.63, 'hc5': 121.99, 'interval': 31.48, 'rtt': 188.87} | Passed |
| regression: fractional passenger load | {'H': 11.38, 'S': 7.15, 'hc5': 82.15, 'interval': 37.98, 'rtt': 151.91} | {'H': 11.38, 'S': 7.15, 'hc5': 82.15, 'interval': 37.98, 'rtt': 151.91} | Passed |
| sampled regression 4 | {'H': 19.62, 'S': 8.36, 'hc5': 40.39, 'interval': 77.25, 'rtt': 154.51} | {'H': 19.62, 'S': 8.36, 'hc5': 40.39, 'interval': 77.25, 'rtt': 154.51} | Passed |
| sampled regression 7 | {'H': 22.36, 'S': 8.58, 'hc5': 76.89, 'interval': 40.58, 'rtt': 202.88} | {'H': 22.36, 'S': 8.58, 'hc5': 76.89, 'interval': 40.58, 'rtt': 202.88} | Passed |
| sampled regression 10 | {'H': 4.72, 'S': 3.8, 'hc5': 128.05, 'interval': 14.99, 'rtt': 74.97} | {'H': 4.72, 'S': 3.8, 'hc5': 128.05, 'interval': 14.99, 'rtt': 74.97} | Passed |
| sampled regression 13 | {'H': 7.79, 'S': 6.55, 'hc5': 201.21, 'interval': 19.08, 'rtt': 114.51} | {'H': 7.79, 'S': 6.55, 'hc5': 201.21, 'interval': 19.08, 'rtt': 114.51} | Passed |
SHA-256 / 5d2890cbec13be8afca410469c2815c230bbd7edf7ac419bb1e037d982675fdb
Verification & scope
Stipulated toy lift-control contract for a bounded teaching model; it makes no claim of conformance to any lift code or vendor dispatcher and omits real safety cases. 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:47:54.449076+00:00.
Case digest / 33f8ffadc21cde50850a1cff441cb537bf4755088bf95c20e8119893e3fe36af