Objets/Documentation
fenetres11.py
Je fournis cette pièce pour reproduire ou examiner AT.V6.
Télécharger ↓"""Out-of-period check of the union of two empty-window events and a dilation identity."""
from fractions import Fraction as F
from math import gcd,prod
import json
def run():
m=2310;out={}
for width in (2,4,6,8):
empty={x for x in range(m) if all(gcd(x+h,m)>1 for h in range(width))}
both=sum((x+6)%m in empty for x in empty)
predicted=F(2*len(empty)-both,m)
by=[sum(any(all(gcd(x+d+h,m)>1 for h in range(width)) for d in (0,6)) for x in range(r,m,6)) for r in range(6)]
assert predicted==F(sum(by),m);out[width]=dict(uniform=str(F(len(empty),m)),intersection=both,selected=str(predicted),by_fibre=by)
# Independent integer prefix sums on a previously unused product.
m=77;masks=[{0,1,4},{0,2,3,7}];primes=[7,11];xs=[x for x in range(m) if all(x%p in s for p,s in zip(primes,masks))]
values=[]
for u in range(1,m):