FA-67869 / Traffic signal timing plans / Member archive
Webster cycle length: the cycle is not capped at the controller maximum · case 04
Webster cycle length returns a wrong result when the cycle is not capped at the controller maximum.
Case contract
Input {phases: per-phase lists of lane-group flows veh/h, sat: saturation flow per lane group, lost: lost seconds per phase, allred: extra all-red seconds per cycle, cmin, cmax}. Y is the sum over phases of the critical (largest) flow ratio; L = lost*phases + allred. If Y >= 0.9 return 'oversaturated'. Otherwise C0 = (1.5L + 5)/(1 - Y), rounded UP to a multiple of 5 s and clamped to [cmin, cmax]. Return {cycle, lost: L, y_milli: floor(1000Y)}.
Why this case matters
Signal timing arithmetic is exact and integer or rational; a wrong rule silently produces unsafe or inefficient timing plans.
One recorded failure
Sample boundary fixtureThis sample comes from the broken implementation of a controlled reproducer.
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| timing oracle 2 | {"cycle": 60, "lost": 16, "y_milli": 765} | {"cycle": 90, "lost": 16, "y_milli": 765} | Failed |
MEMBER ARCHIVE
The complete case is available to members.
This record includes three runnable implementations, regression fixtures, execution results, and source hashes.
Member access is invitation-based. Sign in with your invited account to inspect the sources.
Sign in to the archive ↗