Atelier des rouesLab FR
Objects/Documentation

temoin_xiv.py

Code, data or reproducible check for the lots dossier.

Download ↓
"""A shared exact prefix anchors a batch. Fall back when an estimated window misses."""
from math import gcd
import json


def experiment():
    period=210
    reference=[x for x in range(period) if gcd(x,period)==1]
    def count(stop):return sum(gcd(x,period)==1 for x in range(stop))
    queries=[1,2,3,12,15,22,31,44]
    results=[]
    for a,b in ((0,32),(90,103),(206,210)):
        start=count(a)
        segment=[x for x in range(a,b) if gcd(x,period)==1]
        fallback=0
        for k in queries:

Read in context

Comments

Comments from both language editions appear here.

The discussion is open for reading. I’ll enable submissions once spam protection is configured.