FA-92917 / EV charging session scheduling / Member archive
Shared circuit current allocation: priority ordering · case 02
Low-priority vehicles charge while high-priority vehicles are paused.
Case contract
evs is a list of [id, max_a, priority]. An EV with max_a < 6 cannot be served. Eligible EVs are ordered by priority descending then id; each is admitted while 6*(admitted+1) <= limit_a. Admitted EVs are water-filled: repeatedly give floor(remaining/open) amps, fixing EVs whose max_a <= share at their max. Leftover amps go one each in admission order to EVs below max. Return [[id, amps]] for every EV sorted by id (0 = paused).
Why this case matters
Depot, workplace and public EV chargers schedule sessions against prices, circuit limits and departure deadlines; a wrong decision silently strands a driver or overloads a feeder.
One recorded failure
Sample boundary fixtureThis sample comes from the broken implementation of a controlled reproducer.
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| regression: priority ordering | [["EV0", 0], ["EV1", 6], ["EV2", 7], ["EV3", 6], ["EV4", 7], ["EV5", 6]] | [["EV0", 7], ["EV1", 7], ["EV2", 6], ["EV3", 6], ["EV4", 0], ["EV5", 6]] | 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 ↗