FA-92521 / HVAC thermostat control / Open access
Fahrenheit press steps from a truncated whole degree · case 01
Pressing up from a stored 72.5 F shows 73 instead of 74.
ROOT CAUSE
The whole-degree base floors the stored tenths.
THE FAILURE
The whole-degree base floors the stored tenths.
Unsuccessful approach: Banker's rounding still steps from 72 for a stored 72.5.
Case contract
Thermostat setpoint keypad. The setpoint is stored in tenths F. In C mode the display shows the stored value converted to C and rounded half up to 0.5 C; a press moves the displayed value by 0.5 C and stores exactly 320 + half_degrees*9 tenths F. In F mode the display rounds half up to whole F and a press moves the whole-degree value by 1 F. After each press the stored value is clamped to 45.0-90.0 F. Return [display, stored_tenths_F] per press.
Why this case matters
Residential and light-commercial thermostats make these decisions sample by sample; each defect changes equipment calls in a way that shows up as short cycling, comfort complaints or equipment stress.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(unit, presses, start_f10):
f10 = start_f10
out = []
for p in presses:
step = 1 if p == 'up' else -1
if unit == 'C':
c_half = (2 * (f10 - 320) + 9) // 18
f10 = 320 + (c_half + step) * 9
else:
f_whole = f10 // 10
f10 = (f_whole + step) * 10
f10 = max(450, min(900, f10))
if unit == 'C':
c_half = (2 * (f10 - 320) + 9) // 18
out.append(['%d.%d' % (c_half // 2, 5 * (c_half % 2)), f10])
else:
out.append([str((f10 + 5) // 10), f10])
return out
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['regression: fahrenheit half value',
['F', ['up', 'down', 'down'], 725],
[['74', 740], ['73', 730], ['72', 720]]],
['regression: scenario 7',
['F', ['down', 'up', 'down', 'up'], 905],
[['90', 900], ['90', 900], ['89', 890], ['90', 900]]],
['control: celsius steps', ['C', ['up', 'up', 'down'], 720], [['22.5', 725], ['23.0', 734], ['22.5', 725]]],
['control: upper clamp', ['F', ['up'], 895], [['90', 900]]],
['control: celsius off-grid start', ['C', ['down', 'up'], 716], [['21.5', 707], ['22.0', 716]]],
['control: celsius lower clamp',
['C', ['down', 'down', 'up'], 452],
[['7.0', 450], ['7.0', 450], ['7.5', 455]]],
['control: celsius half-step display', ['C', ['up'], 707], [['22.0', 716]]],
['regression: scenario 1',
['F', ['down', 'down', 'up', 'up', 'up', 'down', 'down', 'up'], 716],
[['71', 710], ['70', 700], ['71', 710], ['72', 720], ['73', 730], ['72', 720], ['71', 710], ['72', 720]]]],
[['regression: scenario 2',
['F', ['down', 'down', 'up', 'down', 'up', 'down', 'up', 'up'], 725],
[['72', 720], ['71', 710], ['72', 720], ['71', 710], ['72', 720], ['71', 710], ['72', 720], ['73', 730]]],
['regression: scenario 3',
['F', ['down', 'up', 'up', 'up', 'up', 'down', 'up', 'down', 'up'], 725],
[['72', 720],
['73', 730],
['74', 740],
['75', 750],
['76', 760],
['75', 750],
['76', 760],
['75', 750],
['76', 760]]],
['control: celsius steps', ['C', ['up', 'up', 'down'], 720], [['22.5', 725], ['23.0', 734], ['22.5', 725]]],
['regression: fahrenheit half value',
['F', ['up', 'down', 'down'], 725],
[['74', 740], ['73', 730], ['72', 720]]],
['control: upper clamp', ['F', ['up'], 895], [['90', 900]]],
['control: celsius off-grid start', ['C', ['down', 'up'], 716], [['21.5', 707], ['22.0', 716]]],
['control: celsius lower clamp',
['C', ['down', 'down', 'up'], 452],
[['7.0', 450], ['7.0', 450], ['7.5', 455]]],
['control: celsius half-step display', ['C', ['up'], 707], [['22.0', 716]]]],
[['regression: scenario 3',
['F', ['down', 'down', 'up', 'up', 'up', 'up', 'down', 'up', 'down'], 725],
[['72', 720],
['71', 710],
['72', 720],
['73', 730],
['74', 740],
['75', 750],
['74', 740],
['75', 750],
['74', 740]]],
['regression: scenario 14',
['F', ['up', 'up', 'down', 'up', 'up', 'down'], 725],
[['74', 740], ['75', 750], ['74', 740], ['75', 750], ['76', 760], ['75', 750]]],
['control: celsius steps', ['C', ['up', 'up', 'down'], 720], [['22.5', 725], ['23.0', 734], ['22.5', 725]]],
['regression: fahrenheit half value',
['F', ['up', 'down', 'down'], 725],
[['74', 740], ['73', 730], ['72', 720]]],
['control: upper clamp', ['F', ['up'], 895], [['90', 900]]],
['control: celsius off-grid start', ['C', ['down', 'up'], 716], [['21.5', 707], ['22.0', 716]]],
['control: celsius lower clamp',
['C', ['down', 'down', 'up'], 452],
[['7.0', 450], ['7.0', 450], ['7.5', 455]]],
['control: celsius half-step display', ['C', ['up'], 707], [['22.0', 716]]]],
[['regression: scenario 3',
['F', ['down', 'down', 'down', 'up', 'down', 'up'], 716],
[['71', 710], ['70', 700], ['69', 690], ['70', 700], ['69', 690], ['70', 700]]],
['regression: scenario 14',
['F', ['down', 'down', 'up', 'down', 'down', 'down', 'up', 'down', 'down'], 905],
[['90', 900],
['89', 890],
['90', 900],
['89', 890],
['88', 880],
['87', 870],
['88', 880],
['87', 870],
['86', 860]]],
['control: celsius steps', ['C', ['up', 'up', 'down'], 720], [['22.5', 725], ['23.0', 734], ['22.5', 725]]],
['regression: fahrenheit half value',
['F', ['up', 'down', 'down'], 725],
[['74', 740], ['73', 730], ['72', 720]]],
['control: upper clamp', ['F', ['up'], 895], [['90', 900]]],
['control: celsius off-grid start', ['C', ['down', 'up'], 716], [['21.5', 707], ['22.0', 716]]],
['control: celsius lower clamp',
['C', ['down', 'down', 'up'], 452],
[['7.0', 450], ['7.0', 450], ['7.5', 455]]],
['control: celsius half-step display', ['C', ['up'], 707], [['22.0', 716]]]],
[['regression: scenario 5',
['F', ['down', 'up', 'down', 'up', 'up', 'up'], 905],
[['90', 900], ['90', 900], ['89', 890], ['90', 900], ['90', 900], ['90', 900]]],
['regression: scenario 43',
['F', ['up', 'up', 'down', 'up', 'up', 'down', 'down', 'down'], 725],
[['74', 740], ['75', 750], ['74', 740], ['75', 750], ['76', 760], ['75', 750], ['74', 740], ['73', 730]]],
['control: celsius steps', ['C', ['up', 'up', 'down'], 720], [['22.5', 725], ['23.0', 734], ['22.5', 725]]],
['regression: fahrenheit half value',
['F', ['up', 'down', 'down'], 725],
[['74', 740], ['73', 730], ['72', 720]]],
['control: upper clamp', ['F', ['up'], 895], [['90', 900]]],
['control: celsius off-grid start', ['C', ['down', 'up'], 716], [['21.5', 707], ['22.0', 716]]],
['control: celsius lower clamp',
['C', ['down', 'down', 'up'], 452],
[['7.0', 450], ['7.0', 450], ['7.5', 455]]],
['control: celsius half-step display', ['C', ['up'], 707], [['22.0', 716]]]]]
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: fahrenheit half value | [['73', 730], ['72', 720], ['71', 710]] | [['74', 740], ['73', 730], ['72', 720]] | Failed |
| regression: scenario 7 | [['89', 890], ['90', 900], ['89', 890], ['90', 900]] | [['90', 900], ['90', 900], ['89', 890], ['90', 900]] | Failed |
| control: celsius steps | [['22.5', 725], ['23.0', 734], ['22.5', 725]] | [['22.5', 725], ['23.0', 734], ['22.5', 725]] | Passed |
| control: upper clamp | [['90', 900]] | [['90', 900]] | Passed |
| control: celsius off-grid start | [['21.5', 707], ['22.0', 716]] | [['21.5', 707], ['22.0', 716]] | Passed |
| control: celsius lower clamp | [['7.0', 450], ['7.0', 450], ['7.5', 455]] | [['7.0', 450], ['7.0', 450], ['7.5', 455]] | Passed |
| control: celsius half-step display | [['22.0', 716]] | [['22.0', 716]] | Passed |
| regression: scenario 1 | [['70', 700], ['69', 690], ['70', 700], ['71', 710], ['72', 720], ['71', 710], ['70', 700], ['71', 710]] | [['71', 710], ['70', 700], ['71', 710], ['72', 720], ['73', 730], ['72', 720], ['71', 710], ['72', 720]] | Failed |
SHA-256 / f58b53cae079fd84d517fd3900cea4c81ad1ce6505c1d0e7938b5bd21f6083e9
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(unit, presses, start_f10):
f10 = start_f10
out = []
for p in presses:
step = 1 if p == 'up' else -1
if unit == 'C':
c_half = (2 * (f10 - 320) + 9) // 18
f10 = 320 + (c_half + step) * 9
else:
f_whole = round(f10 / 10)
f10 = (f_whole + step) * 10
f10 = max(450, min(900, f10))
if unit == 'C':
c_half = (2 * (f10 - 320) + 9) // 18
out.append(['%d.%d' % (c_half // 2, 5 * (c_half % 2)), f10])
else:
out.append([str((f10 + 5) // 10), f10])
return out
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['regression: fahrenheit half value',
['F', ['up', 'down', 'down'], 725],
[['74', 740], ['73', 730], ['72', 720]]],
['regression: scenario 7',
['F', ['down', 'up', 'down', 'up'], 905],
[['90', 900], ['90', 900], ['89', 890], ['90', 900]]],
['control: celsius steps', ['C', ['up', 'up', 'down'], 720], [['22.5', 725], ['23.0', 734], ['22.5', 725]]],
['control: upper clamp', ['F', ['up'], 895], [['90', 900]]],
['control: celsius off-grid start', ['C', ['down', 'up'], 716], [['21.5', 707], ['22.0', 716]]],
['control: celsius lower clamp',
['C', ['down', 'down', 'up'], 452],
[['7.0', 450], ['7.0', 450], ['7.5', 455]]],
['control: celsius half-step display', ['C', ['up'], 707], [['22.0', 716]]],
['regression: scenario 1',
['F', ['down', 'down', 'up', 'up', 'up', 'down', 'down', 'up'], 716],
[['71', 710], ['70', 700], ['71', 710], ['72', 720], ['73', 730], ['72', 720], ['71', 710], ['72', 720]]]],
[['regression: scenario 2',
['F', ['down', 'down', 'up', 'down', 'up', 'down', 'up', 'up'], 725],
[['72', 720], ['71', 710], ['72', 720], ['71', 710], ['72', 720], ['71', 710], ['72', 720], ['73', 730]]],
['regression: scenario 3',
['F', ['down', 'up', 'up', 'up', 'up', 'down', 'up', 'down', 'up'], 725],
[['72', 720],
['73', 730],
['74', 740],
['75', 750],
['76', 760],
['75', 750],
['76', 760],
['75', 750],
['76', 760]]],
['control: celsius steps', ['C', ['up', 'up', 'down'], 720], [['22.5', 725], ['23.0', 734], ['22.5', 725]]],
['regression: fahrenheit half value',
['F', ['up', 'down', 'down'], 725],
[['74', 740], ['73', 730], ['72', 720]]],
['control: upper clamp', ['F', ['up'], 895], [['90', 900]]],
['control: celsius off-grid start', ['C', ['down', 'up'], 716], [['21.5', 707], ['22.0', 716]]],
['control: celsius lower clamp',
['C', ['down', 'down', 'up'], 452],
[['7.0', 450], ['7.0', 450], ['7.5', 455]]],
['control: celsius half-step display', ['C', ['up'], 707], [['22.0', 716]]]],
[['regression: scenario 3',
['F', ['down', 'down', 'up', 'up', 'up', 'up', 'down', 'up', 'down'], 725],
[['72', 720],
['71', 710],
['72', 720],
['73', 730],
['74', 740],
['75', 750],
['74', 740],
['75', 750],
['74', 740]]],
['regression: scenario 14',
['F', ['up', 'up', 'down', 'up', 'up', 'down'], 725],
[['74', 740], ['75', 750], ['74', 740], ['75', 750], ['76', 760], ['75', 750]]],
['control: celsius steps', ['C', ['up', 'up', 'down'], 720], [['22.5', 725], ['23.0', 734], ['22.5', 725]]],
['regression: fahrenheit half value',
['F', ['up', 'down', 'down'], 725],
[['74', 740], ['73', 730], ['72', 720]]],
['control: upper clamp', ['F', ['up'], 895], [['90', 900]]],
['control: celsius off-grid start', ['C', ['down', 'up'], 716], [['21.5', 707], ['22.0', 716]]],
['control: celsius lower clamp',
['C', ['down', 'down', 'up'], 452],
[['7.0', 450], ['7.0', 450], ['7.5', 455]]],
['control: celsius half-step display', ['C', ['up'], 707], [['22.0', 716]]]],
[['regression: scenario 3',
['F', ['down', 'down', 'down', 'up', 'down', 'up'], 716],
[['71', 710], ['70', 700], ['69', 690], ['70', 700], ['69', 690], ['70', 700]]],
['regression: scenario 14',
['F', ['down', 'down', 'up', 'down', 'down', 'down', 'up', 'down', 'down'], 905],
[['90', 900],
['89', 890],
['90', 900],
['89', 890],
['88', 880],
['87', 870],
['88', 880],
['87', 870],
['86', 860]]],
['control: celsius steps', ['C', ['up', 'up', 'down'], 720], [['22.5', 725], ['23.0', 734], ['22.5', 725]]],
['regression: fahrenheit half value',
['F', ['up', 'down', 'down'], 725],
[['74', 740], ['73', 730], ['72', 720]]],
['control: upper clamp', ['F', ['up'], 895], [['90', 900]]],
['control: celsius off-grid start', ['C', ['down', 'up'], 716], [['21.5', 707], ['22.0', 716]]],
['control: celsius lower clamp',
['C', ['down', 'down', 'up'], 452],
[['7.0', 450], ['7.0', 450], ['7.5', 455]]],
['control: celsius half-step display', ['C', ['up'], 707], [['22.0', 716]]]],
[['regression: scenario 5',
['F', ['down', 'up', 'down', 'up', 'up', 'up'], 905],
[['90', 900], ['90', 900], ['89', 890], ['90', 900], ['90', 900], ['90', 900]]],
['regression: scenario 43',
['F', ['up', 'up', 'down', 'up', 'up', 'down', 'down', 'down'], 725],
[['74', 740], ['75', 750], ['74', 740], ['75', 750], ['76', 760], ['75', 750], ['74', 740], ['73', 730]]],
['control: celsius steps', ['C', ['up', 'up', 'down'], 720], [['22.5', 725], ['23.0', 734], ['22.5', 725]]],
['regression: fahrenheit half value',
['F', ['up', 'down', 'down'], 725],
[['74', 740], ['73', 730], ['72', 720]]],
['control: upper clamp', ['F', ['up'], 895], [['90', 900]]],
['control: celsius off-grid start', ['C', ['down', 'up'], 716], [['21.5', 707], ['22.0', 716]]],
['control: celsius lower clamp',
['C', ['down', 'down', 'up'], 452],
[['7.0', 450], ['7.0', 450], ['7.5', 455]]],
['control: celsius half-step display', ['C', ['up'], 707], [['22.0', 716]]]]]
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: fahrenheit half value | [['73', 730], ['72', 720], ['71', 710]] | [['74', 740], ['73', 730], ['72', 720]] | Failed |
| regression: scenario 7 | [['89', 890], ['90', 900], ['89', 890], ['90', 900]] | [['90', 900], ['90', 900], ['89', 890], ['90', 900]] | Failed |
| control: celsius steps | [['22.5', 725], ['23.0', 734], ['22.5', 725]] | [['22.5', 725], ['23.0', 734], ['22.5', 725]] | Passed |
| control: upper clamp | [['90', 900]] | [['90', 900]] | Passed |
| control: celsius off-grid start | [['21.5', 707], ['22.0', 716]] | [['21.5', 707], ['22.0', 716]] | Passed |
| control: celsius lower clamp | [['7.0', 450], ['7.0', 450], ['7.5', 455]] | [['7.0', 450], ['7.0', 450], ['7.5', 455]] | Passed |
| control: celsius half-step display | [['22.0', 716]] | [['22.0', 716]] | Passed |
| regression: scenario 1 | [['71', 710], ['70', 700], ['71', 710], ['72', 720], ['73', 730], ['72', 720], ['71', 710], ['72', 720]] | [['71', 710], ['70', 700], ['71', 710], ['72', 720], ['73', 730], ['72', 720], ['71', 710], ['72', 720]] | Passed |
SHA-256 / 63cdb64dbd19f72b9b3cc957586dde03e1438894c34234eb3568b8803e4be710
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
A deterministic bounded teaching model of one thermostat or HVAC controller decision evaluated per sample. Temperatures are integer tenths of a degree Fahrenheit unless stated otherwise. The contract is a stipulated toy convention, not a claim of conformance to any manufacturer, ASHRAE guideline or code. 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:51:46.492944+00:00.
Case digest / 5af8879ea9963dd904c0d9b03f719c5b83d3a1dde15919b95c0eb4e3b7750c0b