Objets/Documentation
decalages19.py
Garantir des créneaux malgré une rupture de retard · decalages19.py
Télécharger ↓"""Minimax slot count with a single delay change per full joint cycle."""
import json
from itertools import accumulate
from math import lcm
LEFT={0,1,2,8,9,15,16}
def run(q,j):
if not 6<=q<=40 or not 0<=j<=5:
raise ValueError("unsupported period or jitter")
length=lcm(24,q)
right={a%q for a in (0,1,4,8,9)}
times=[t for t in range(length) if t%24 in LEFT]
floors=[]; constant=[]; witnesses=[]
for d in range(q):