FA-69116 / Tide and marine navigation tables / Open access
Tide table zone time to UTC: Zone description is subtracted · case 01
UTC times are off by twice the zone description.
ROOT CAUSE
The zone description is applied as UTC = local - zd.
VERIFIED REPAIR
Add zd (positive west) to zone time.
Unsuccessful approach: Negating zd but keeping the daylight hour subtraction still reverses the zone.
Case contract
Input [local "YYYY-MM-DD HH:MM", zd, dst]: zone description zd in hours (positive west, may be fractional); UTC = zone time + zd, and when the table is on daylight time the clock is one hour ahead so UTC = local + zd - 1. Return UTC as "YYYY-MM-DD HH:MM" (24-hour).
Why this case matters
Tide tables and passage plans turn published predictions into go/no-go decisions about depth, clearance and timing.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
import math
import datetime
N = 1
observations = []
def solve(x):
s,zd,dst=x
dt=datetime.datetime.strptime(s,'%Y-%m-%d %H:%M')
off=-zd-(1 if dst else 0)
u=dt+datetime.timedelta(minutes=round(off*60))
return u.strftime('%Y-%m-%d %H:%M')
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[('tide table zone time to utc ["2026-03-14 06:12", 5, false]', ['2026-03-14 06:12', 5, False], '2026-03-14 11:12'), ('tide table zone time to utc ["2026-03-14 21:40", 5, false]', ['2026-03-14 21:40', 5, False], '2026-03-15 02:40'), ('tide table zone time to utc ["2026-07-01 23:30", 4, true]', ['2026-07-01 23:30', 4, True], '2026-07-02 02:30'), ('tide table zone time to utc ["2026-07-01 00:20", -2, true]', ['2026-07-01 00:20', -2, True], '2026-06-30 21:20'), ('tide table zone time to utc ["2026-12-31 22:15", 3, false]', ['2026-12-31 22:15', 3, False], '2027-01-01 01:15'), ('tide table zone time to utc ["2026-01-01 01:05", -9.5, false]', ['2026-01-01 01:05', -9.5, False], '2025-12-31 15:35'), ('tide table zone time to utc ["2026-06-15 12:00", -5.5, false]', ['2026-06-15 12:00', -5.5, False], '2026-06-15 06:30')], [('tide table zone time to utc ["2026-03-14 21:40", 5, false]', ['2026-03-14 21:40', 5, False], '2026-03-15 02:40'), ('tide table zone time to utc ["2026-07-01 00:20", -2, true]', ['2026-07-01 00:20', -2, True], '2026-06-30 21:20'), ('tide table zone time to utc ["2026-12-31 22:15", 3, false]', ['2026-12-31 22:15', 3, False], '2027-01-01 01:15'), ('tide table zone time to utc ["2026-01-01 01:05", -9.5, false]', ['2026-01-01 01:05', -9.5, False], '2025-12-31 15:35'), ('tide table zone time to utc ["2026-06-15 12:00", -5.5, false]', ['2026-06-15 12:00', -5.5, False], '2026-06-15 06:30'), ('tide table zone time to utc ["2026-06-15 12:00", 0, true]', ['2026-06-15 12:00', 0, True], '2026-06-15 11:00'), ('tide table zone time to utc ["2028-02-28 23:50", 1, false]', ['2028-02-28 23:50', 1, False], '2028-02-29 00:50')], [('tide table zone time to utc ["2026-07-01 23:30", 4, true]', ['2026-07-01 23:30', 4, True], '2026-07-02 02:30'), ('tide table zone time to utc ["2026-06-15 12:00", -5.5, false]', ['2026-06-15 12:00', -5.5, False], '2026-06-15 06:30'), ('tide table zone time to utc ["2026-06-15 12:00", 0, true]', ['2026-06-15 12:00', 0, True], '2026-06-15 11:00'), ('tide table zone time to utc ["2028-02-28 23:50", 1, false]', ['2028-02-28 23:50', 1, False], '2028-02-29 00:50'), ('tide table zone time to utc ["2026-09-10 13:45", -10, false]', ['2026-09-10 13:45', -10, False], '2026-09-10 03:45'), ('tide table zone time to utc ["2026-09-10 10:45", 3.5, true]', ['2026-09-10 10:45', 3.5, True], '2026-09-10 13:15'), ('tide table zone time to utc ["2026-05-05 05:05", 0, false]', ['2026-05-05 05:05', 0, False], '2026-05-05 05:05')], [('tide table zone time to utc ["2026-07-01 00:20", -2, true]', ['2026-07-01 00:20', -2, True], '2026-06-30 21:20'), ('tide table zone time to utc ["2026-09-10 13:45", -10, false]', ['2026-09-10 13:45', -10, False], '2026-09-10 03:45'), ('tide table zone time to utc ["2026-09-10 10:45", 3.5, true]', ['2026-09-10 10:45', 3.5, True], '2026-09-10 13:15'), ('tide table zone time to utc ["2026-05-05 05:05", 0, false]', ['2026-05-05 05:05', 0, False], '2026-05-05 05:05'), ('tide table zone time to utc ["2026-03-14 06:12", 5, false]', ['2026-03-14 06:12', 5, False], '2026-03-14 11:12'), ('tide table zone time to utc ["2026-03-14 21:40", 5, false]', ['2026-03-14 21:40', 5, False], '2026-03-15 02:40'), ('tide table zone time to utc ["2026-07-01 23:30", 4, true]', ['2026-07-01 23:30', 4, True], '2026-07-02 02:30')], [('tide table zone time to utc ["2026-12-31 22:15", 3, false]', ['2026-12-31 22:15', 3, False], '2027-01-01 01:15'), ('tide table zone time to utc ["2026-03-14 06:12", 5, false]', ['2026-03-14 06:12', 5, False], '2026-03-14 11:12'), ('tide table zone time to utc ["2026-03-14 21:40", 5, false]', ['2026-03-14 21:40', 5, False], '2026-03-15 02:40'), ('tide table zone time to utc ["2026-07-01 23:30", 4, true]', ['2026-07-01 23:30', 4, True], '2026-07-02 02:30'), ('tide table zone time to utc ["2026-07-01 00:20", -2, true]', ['2026-07-01 00:20', -2, True], '2026-06-30 21:20'), ('tide table zone time to utc ["2026-01-01 01:05", -9.5, false]', ['2026-01-01 01:05', -9.5, False], '2025-12-31 15:35'), ('tide table zone time to utc ["2026-06-15 12:00", -5.5, false]', ['2026-06-15 12:00', -5.5, False], '2026-06-15 06:30')]]
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 |
|---|---|---|---|
| tide table zone time to utc ["2026-03-14 06:12", 5, false] | 2026-03-14 01:12 | 2026-03-14 11:12 | Failed |
| tide table zone time to utc ["2026-03-14 21:40", 5, false] | 2026-03-14 16:40 | 2026-03-15 02:40 | Failed |
| tide table zone time to utc ["2026-07-01 23:30", 4, true] | 2026-07-01 18:30 | 2026-07-02 02:30 | Failed |
| tide table zone time to utc ["2026-07-01 00:20", -2, true] | 2026-07-01 01:20 | 2026-06-30 21:20 | Failed |
| tide table zone time to utc ["2026-12-31 22:15", 3, false] | 2026-12-31 19:15 | 2027-01-01 01:15 | Failed |
| tide table zone time to utc ["2026-01-01 01:05", -9.5, false] | 2026-01-01 10:35 | 2025-12-31 15:35 | Failed |
| tide table zone time to utc ["2026-06-15 12:00", -5.5, false] | 2026-06-15 17:30 | 2026-06-15 06:30 | Failed |
SHA-256 / 0ec557ee8052e64a8c4b96f587d5b14d1d1364a59749ba5e892dcabf561adc7c
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
import math
import datetime
N = 1
observations = []
def solve(x):
s,zd,dst=x
dt=datetime.datetime.strptime(s,'%Y-%m-%d %H:%M')
off=-(zd-(1 if dst else 0))+ (2 if dst else 0)
u=dt+datetime.timedelta(minutes=round(off*60))
return u.strftime('%Y-%m-%d %H:%M')
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[('tide table zone time to utc ["2026-03-14 06:12", 5, false]', ['2026-03-14 06:12', 5, False], '2026-03-14 11:12'), ('tide table zone time to utc ["2026-03-14 21:40", 5, false]', ['2026-03-14 21:40', 5, False], '2026-03-15 02:40'), ('tide table zone time to utc ["2026-07-01 23:30", 4, true]', ['2026-07-01 23:30', 4, True], '2026-07-02 02:30'), ('tide table zone time to utc ["2026-07-01 00:20", -2, true]', ['2026-07-01 00:20', -2, True], '2026-06-30 21:20'), ('tide table zone time to utc ["2026-12-31 22:15", 3, false]', ['2026-12-31 22:15', 3, False], '2027-01-01 01:15'), ('tide table zone time to utc ["2026-01-01 01:05", -9.5, false]', ['2026-01-01 01:05', -9.5, False], '2025-12-31 15:35'), ('tide table zone time to utc ["2026-06-15 12:00", -5.5, false]', ['2026-06-15 12:00', -5.5, False], '2026-06-15 06:30')], [('tide table zone time to utc ["2026-03-14 21:40", 5, false]', ['2026-03-14 21:40', 5, False], '2026-03-15 02:40'), ('tide table zone time to utc ["2026-07-01 00:20", -2, true]', ['2026-07-01 00:20', -2, True], '2026-06-30 21:20'), ('tide table zone time to utc ["2026-12-31 22:15", 3, false]', ['2026-12-31 22:15', 3, False], '2027-01-01 01:15'), ('tide table zone time to utc ["2026-01-01 01:05", -9.5, false]', ['2026-01-01 01:05', -9.5, False], '2025-12-31 15:35'), ('tide table zone time to utc ["2026-06-15 12:00", -5.5, false]', ['2026-06-15 12:00', -5.5, False], '2026-06-15 06:30'), ('tide table zone time to utc ["2026-06-15 12:00", 0, true]', ['2026-06-15 12:00', 0, True], '2026-06-15 11:00'), ('tide table zone time to utc ["2028-02-28 23:50", 1, false]', ['2028-02-28 23:50', 1, False], '2028-02-29 00:50')], [('tide table zone time to utc ["2026-07-01 23:30", 4, true]', ['2026-07-01 23:30', 4, True], '2026-07-02 02:30'), ('tide table zone time to utc ["2026-06-15 12:00", -5.5, false]', ['2026-06-15 12:00', -5.5, False], '2026-06-15 06:30'), ('tide table zone time to utc ["2026-06-15 12:00", 0, true]', ['2026-06-15 12:00', 0, True], '2026-06-15 11:00'), ('tide table zone time to utc ["2028-02-28 23:50", 1, false]', ['2028-02-28 23:50', 1, False], '2028-02-29 00:50'), ('tide table zone time to utc ["2026-09-10 13:45", -10, false]', ['2026-09-10 13:45', -10, False], '2026-09-10 03:45'), ('tide table zone time to utc ["2026-09-10 10:45", 3.5, true]', ['2026-09-10 10:45', 3.5, True], '2026-09-10 13:15'), ('tide table zone time to utc ["2026-05-05 05:05", 0, false]', ['2026-05-05 05:05', 0, False], '2026-05-05 05:05')], [('tide table zone time to utc ["2026-07-01 00:20", -2, true]', ['2026-07-01 00:20', -2, True], '2026-06-30 21:20'), ('tide table zone time to utc ["2026-09-10 13:45", -10, false]', ['2026-09-10 13:45', -10, False], '2026-09-10 03:45'), ('tide table zone time to utc ["2026-09-10 10:45", 3.5, true]', ['2026-09-10 10:45', 3.5, True], '2026-09-10 13:15'), ('tide table zone time to utc ["2026-05-05 05:05", 0, false]', ['2026-05-05 05:05', 0, False], '2026-05-05 05:05'), ('tide table zone time to utc ["2026-03-14 06:12", 5, false]', ['2026-03-14 06:12', 5, False], '2026-03-14 11:12'), ('tide table zone time to utc ["2026-03-14 21:40", 5, false]', ['2026-03-14 21:40', 5, False], '2026-03-15 02:40'), ('tide table zone time to utc ["2026-07-01 23:30", 4, true]', ['2026-07-01 23:30', 4, True], '2026-07-02 02:30')], [('tide table zone time to utc ["2026-12-31 22:15", 3, false]', ['2026-12-31 22:15', 3, False], '2027-01-01 01:15'), ('tide table zone time to utc ["2026-03-14 06:12", 5, false]', ['2026-03-14 06:12', 5, False], '2026-03-14 11:12'), ('tide table zone time to utc ["2026-03-14 21:40", 5, false]', ['2026-03-14 21:40', 5, False], '2026-03-15 02:40'), ('tide table zone time to utc ["2026-07-01 23:30", 4, true]', ['2026-07-01 23:30', 4, True], '2026-07-02 02:30'), ('tide table zone time to utc ["2026-07-01 00:20", -2, true]', ['2026-07-01 00:20', -2, True], '2026-06-30 21:20'), ('tide table zone time to utc ["2026-01-01 01:05", -9.5, false]', ['2026-01-01 01:05', -9.5, False], '2025-12-31 15:35'), ('tide table zone time to utc ["2026-06-15 12:00", -5.5, false]', ['2026-06-15 12:00', -5.5, False], '2026-06-15 06:30')]]
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 |
|---|---|---|---|
| tide table zone time to utc ["2026-03-14 06:12", 5, false] | 2026-03-14 01:12 | 2026-03-14 11:12 | Failed |
| tide table zone time to utc ["2026-03-14 21:40", 5, false] | 2026-03-14 16:40 | 2026-03-15 02:40 | Failed |
| tide table zone time to utc ["2026-07-01 23:30", 4, true] | 2026-07-01 22:30 | 2026-07-02 02:30 | Failed |
| tide table zone time to utc ["2026-07-01 00:20", -2, true] | 2026-07-01 05:20 | 2026-06-30 21:20 | Failed |
| tide table zone time to utc ["2026-12-31 22:15", 3, false] | 2026-12-31 19:15 | 2027-01-01 01:15 | Failed |
| tide table zone time to utc ["2026-01-01 01:05", -9.5, false] | 2026-01-01 10:35 | 2025-12-31 15:35 | Failed |
| tide table zone time to utc ["2026-06-15 12:00", -5.5, false] | 2026-06-15 17:30 | 2026-06-15 06:30 | Failed |
SHA-256 / 2b5f38a9d440e881c2980a72fcfa290132634dcc385e2767485bd5c508615b3a
3 / The verified repair
Exit 0"""Failure Map reference implementation. Python standard library only."""
import json
import math
import datetime
N = 1
observations = []
def solve(x):
s,zd,dst=x
dt=datetime.datetime.strptime(s,'%Y-%m-%d %H:%M')
off=zd-(1 if dst else 0)
u=dt+datetime.timedelta(minutes=round(off*60))
return u.strftime('%Y-%m-%d %H:%M')
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[('tide table zone time to utc ["2026-03-14 06:12", 5, false]', ['2026-03-14 06:12', 5, False], '2026-03-14 11:12'), ('tide table zone time to utc ["2026-03-14 21:40", 5, false]', ['2026-03-14 21:40', 5, False], '2026-03-15 02:40'), ('tide table zone time to utc ["2026-07-01 23:30", 4, true]', ['2026-07-01 23:30', 4, True], '2026-07-02 02:30'), ('tide table zone time to utc ["2026-07-01 00:20", -2, true]', ['2026-07-01 00:20', -2, True], '2026-06-30 21:20'), ('tide table zone time to utc ["2026-12-31 22:15", 3, false]', ['2026-12-31 22:15', 3, False], '2027-01-01 01:15'), ('tide table zone time to utc ["2026-01-01 01:05", -9.5, false]', ['2026-01-01 01:05', -9.5, False], '2025-12-31 15:35'), ('tide table zone time to utc ["2026-06-15 12:00", -5.5, false]', ['2026-06-15 12:00', -5.5, False], '2026-06-15 06:30')], [('tide table zone time to utc ["2026-03-14 21:40", 5, false]', ['2026-03-14 21:40', 5, False], '2026-03-15 02:40'), ('tide table zone time to utc ["2026-07-01 00:20", -2, true]', ['2026-07-01 00:20', -2, True], '2026-06-30 21:20'), ('tide table zone time to utc ["2026-12-31 22:15", 3, false]', ['2026-12-31 22:15', 3, False], '2027-01-01 01:15'), ('tide table zone time to utc ["2026-01-01 01:05", -9.5, false]', ['2026-01-01 01:05', -9.5, False], '2025-12-31 15:35'), ('tide table zone time to utc ["2026-06-15 12:00", -5.5, false]', ['2026-06-15 12:00', -5.5, False], '2026-06-15 06:30'), ('tide table zone time to utc ["2026-06-15 12:00", 0, true]', ['2026-06-15 12:00', 0, True], '2026-06-15 11:00'), ('tide table zone time to utc ["2028-02-28 23:50", 1, false]', ['2028-02-28 23:50', 1, False], '2028-02-29 00:50')], [('tide table zone time to utc ["2026-07-01 23:30", 4, true]', ['2026-07-01 23:30', 4, True], '2026-07-02 02:30'), ('tide table zone time to utc ["2026-06-15 12:00", -5.5, false]', ['2026-06-15 12:00', -5.5, False], '2026-06-15 06:30'), ('tide table zone time to utc ["2026-06-15 12:00", 0, true]', ['2026-06-15 12:00', 0, True], '2026-06-15 11:00'), ('tide table zone time to utc ["2028-02-28 23:50", 1, false]', ['2028-02-28 23:50', 1, False], '2028-02-29 00:50'), ('tide table zone time to utc ["2026-09-10 13:45", -10, false]', ['2026-09-10 13:45', -10, False], '2026-09-10 03:45'), ('tide table zone time to utc ["2026-09-10 10:45", 3.5, true]', ['2026-09-10 10:45', 3.5, True], '2026-09-10 13:15'), ('tide table zone time to utc ["2026-05-05 05:05", 0, false]', ['2026-05-05 05:05', 0, False], '2026-05-05 05:05')], [('tide table zone time to utc ["2026-07-01 00:20", -2, true]', ['2026-07-01 00:20', -2, True], '2026-06-30 21:20'), ('tide table zone time to utc ["2026-09-10 13:45", -10, false]', ['2026-09-10 13:45', -10, False], '2026-09-10 03:45'), ('tide table zone time to utc ["2026-09-10 10:45", 3.5, true]', ['2026-09-10 10:45', 3.5, True], '2026-09-10 13:15'), ('tide table zone time to utc ["2026-05-05 05:05", 0, false]', ['2026-05-05 05:05', 0, False], '2026-05-05 05:05'), ('tide table zone time to utc ["2026-03-14 06:12", 5, false]', ['2026-03-14 06:12', 5, False], '2026-03-14 11:12'), ('tide table zone time to utc ["2026-03-14 21:40", 5, false]', ['2026-03-14 21:40', 5, False], '2026-03-15 02:40'), ('tide table zone time to utc ["2026-07-01 23:30", 4, true]', ['2026-07-01 23:30', 4, True], '2026-07-02 02:30')], [('tide table zone time to utc ["2026-12-31 22:15", 3, false]', ['2026-12-31 22:15', 3, False], '2027-01-01 01:15'), ('tide table zone time to utc ["2026-03-14 06:12", 5, false]', ['2026-03-14 06:12', 5, False], '2026-03-14 11:12'), ('tide table zone time to utc ["2026-03-14 21:40", 5, false]', ['2026-03-14 21:40', 5, False], '2026-03-15 02:40'), ('tide table zone time to utc ["2026-07-01 23:30", 4, true]', ['2026-07-01 23:30', 4, True], '2026-07-02 02:30'), ('tide table zone time to utc ["2026-07-01 00:20", -2, true]', ['2026-07-01 00:20', -2, True], '2026-06-30 21:20'), ('tide table zone time to utc ["2026-01-01 01:05", -9.5, false]', ['2026-01-01 01:05', -9.5, False], '2025-12-31 15:35'), ('tide table zone time to utc ["2026-06-15 12:00", -5.5, false]', ['2026-06-15 12:00', -5.5, False], '2026-06-15 06:30')]]
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 |
|---|---|---|---|
| tide table zone time to utc ["2026-03-14 06:12", 5, false] | 2026-03-14 11:12 | 2026-03-14 11:12 | Passed |
| tide table zone time to utc ["2026-03-14 21:40", 5, false] | 2026-03-15 02:40 | 2026-03-15 02:40 | Passed |
| tide table zone time to utc ["2026-07-01 23:30", 4, true] | 2026-07-02 02:30 | 2026-07-02 02:30 | Passed |
| tide table zone time to utc ["2026-07-01 00:20", -2, true] | 2026-06-30 21:20 | 2026-06-30 21:20 | Passed |
| tide table zone time to utc ["2026-12-31 22:15", 3, false] | 2027-01-01 01:15 | 2027-01-01 01:15 | Passed |
| tide table zone time to utc ["2026-01-01 01:05", -9.5, false] | 2025-12-31 15:35 | 2025-12-31 15:35 | Passed |
| tide table zone time to utc ["2026-06-15 12:00", -5.5, false] | 2026-06-15 06:30 | 2026-06-15 06:30 | Passed |
SHA-256 / 9565386d52398f9aa422c22fdd1e05329af495f64bfe939bddf80d4b3a63df2b
Verification & scope
A deterministic toy model with stipulated rules and constants; not certified hydrographic software or a substitute for official tide tables. 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:48:08.494484+00:00.
Case digest / ee858a530ab2984a254c9c0eaf4c2822a1bb73bd41769df36b11dd44924c01a4