Atelier des rouesLab FR
Objects/Documentation

graphe18.py

Share two multiplications · Reproducible Python implementation.

Download ↓
"""Exact shared modular multipliers on four-bit words with free left shifts."""
import json
from collections import deque
from functools import lru_cache
from itertools import combinations_with_replacement


def closure(values):
    return frozenset((v<<s)%16 for v in values for s in range(5))


@lru_cache(maxsize=1)
def search():
    start=closure([1])
    paths={start:()}
    queue=deque([start])

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.