From b725be51349cce4e0a262c76233838992042dd62 Mon Sep 17 00:00:00 2001 From: Ali Romman <226877337+aliromman@users.noreply.github.com> Date: Wed, 18 Nov 2026 04:42:16 -0500 Subject: [PATCH] Prove the sharp no-edge total-image bound for every pattern dimension --- research/no-edge-total-image-bound/CREDITS.md | 44 + research/no-edge-total-image-bound/PROOF.md | 312 +++++ research/no-edge-total-image-bound/README.md | 55 + .../no-edge-total-image-bound/RESULT.json | 1056 +++++++++++++++++ .../no-edge-total-image-bound/SOURCES.json | 18 + research/no-edge-total-image-bound/TASK.json | 80 ++ .../no-edge-total-image-bound/VERIFY.json | 34 + research/no-edge-total-image-bound/verify.py | 364 ++++++ 8 files changed, 1963 insertions(+) create mode 100644 research/no-edge-total-image-bound/CREDITS.md create mode 100644 research/no-edge-total-image-bound/PROOF.md create mode 100644 research/no-edge-total-image-bound/README.md create mode 100644 research/no-edge-total-image-bound/RESULT.json create mode 100644 research/no-edge-total-image-bound/SOURCES.json create mode 100644 research/no-edge-total-image-bound/TASK.json create mode 100644 research/no-edge-total-image-bound/VERIFY.json create mode 100644 research/no-edge-total-image-bound/verify.py diff --git a/research/no-edge-total-image-bound/CREDITS.md b/research/no-edge-total-image-bound/CREDITS.md new file mode 100644 index 0000000000..3cd2af084b --- /dev/null +++ b/research/no-edge-total-image-bound/CREDITS.md @@ -0,0 +1,44 @@ +# Credit and source boundary + +Ali Romman prepared this package with substantial OpenAI Codex assistance. +New work is Apache-2.0. Independent human and formal-kernel review are +unclaimed. No predecessor package is needed at runtime. + +CubeJerry supplied the intersecting diagonal-dependency argument and the +sharp dimension-three total bound in +[PR #6838](https://github.com/CrocSwap/integer-mult-bounds/pull/6838), +[exact proof](https://github.com/CubeJerry/integer-mult-bounds/blob/f177c4f27e63dfa2e886033bb6a4e2dcd91f40b6/research/bit-zero-edge-image-bound/PROOF.md). +The new proof extends the coordinate-column method to every diagonal +relation at once. + +unpaidmoon supplied the normal/column triple classification, the sharp +dimension-four bound in +[PR #7139](https://github.com/CrocSwap/integer-mult-bounds/pull/7139), +[exact proof](https://github.com/unpaidmoon/integer-mult-bounds/blob/007869ccdc22ee591b5a88d99a35f02511bffbee/research/no-edge-dim4-image-at-most-six/PROOF.md), +and the seven-image construction in +[PR #7237](https://github.com/CrocSwap/integer-mult-bounds/pull/7237) and +[PR #7281](https://github.com/CrocSwap/integer-mult-bounds/pull/7281), +[exact source](https://github.com/unpaidmoon/integer-mult-bounds/blob/0cd5324c41490b856d0e94daa8b011683fc153f6/research/no-edge-dim5-fresh-link/PROOF.md). +The seven-image witness is rechecked as prior sharpness evidence. + +Nick Petalas supplied the binary fiber lemma in +[PR #5921](https://github.com/CrocSwap/integer-mult-bounds/pull/5921), +as credited in the exact proofs of PR #6838 and PR #7139. A short proof is +included here. The new total bound does not require the fiber lemma; it is +used for the irreducible equality boundary and complete sharp pools. + +Ali Romman's image-basis theorem in +[PR #7686](https://github.com/CrocSwap/integer-mult-bounds/pull/7686), +[exact proof](https://github.com/aliromman/integer-mult-bounds/blob/9da06cbe0b888293cbb249cb29eef0f37addaa4f/research/no-edge-image-basis-bound/PROOF.md), +and extraction counterexample in +[PR #7688](https://github.com/CrocSwap/integer-mult-bounds/pull/7688), +[exact proof](https://github.com/aliromman/integer-mult-bounds/blob/d9aba79eaed566640353efcb0a27b0d5649f705a/research/no-edge-basis-extraction-failure/PROOF.md), +supplied the immediate scope question. Their exact verifiers supply the +reused binary matrix, span, lift, orbit and subspace-enumeration primitives: +[PR #7686 verifier](https://github.com/aliromman/integer-mult-bounds/blob/9da06cbe0b888293cbb249cb29eef0f37addaa4f/research/no-edge-image-basis-bound/verify.py), +[PR #7688 verifier](https://github.com/aliromman/integer-mult-bounds/blob/d9aba79eaed566640353efcb0a27b0d5649f705a/research/no-edge-basis-extraction-failure/verify.py). + +The disjoint-circuit structure, the sharp total bound for every k, and the +general irreducible consequence are the new result. Earlier examples, +dimension-specific bounds and normal-form classifications retain their +source credit. diff --git a/research/no-edge-total-image-bound/PROOF.md b/research/no-edge-total-image-bound/PROOF.md new file mode 100644 index 0000000000..9c6fb0bd7f --- /dev/null +++ b/research/no-edge-total-image-bound/PROOF.md @@ -0,0 +1,312 @@ +# A sharp total-image bound for every no-edge pattern dimension + +Ali Romman, with substantial OpenAI Codex assistance. Apache-2.0. + +## 1. Statement + +Work over F2 in a fixed ambient coordinate space. Let C be any collection +of rank-one idempotents `P=u v^T`, with `v^T u=1`. Assume that every +off-diagonal pattern off(P) is nonzero. Let H be their pattern span and V +their joint image. Write `k=dim H` and `n=dim V`. Assume that H contains no +off-diagonal matrix unit. + +**Total-image theorem.** `2n <= 3k`. Thus `n <= floor(3k/2)`. The bound is +sharp for every positive integer k, even when C is the complete pool of H. + +**Irreducible consequence.** If `n>0` and C acts irreducibly on V, then +`2n <= 3k-1`. The total-bound equality at even k is always reducible. + +The theorem applies to incomplete collections and does not assume that an +image-basis subcollection is irreducible. The proof uses the whole space of +diagonal relations among any independent image subcollection. It also proves +that the pattern relations of such a subcollection are generated by disjoint +circuits, each of size at least three. A circuit is a nonempty relation +support that contains no smaller nonempty relation support. + +**At pattern dimension five, the maximum total image is seven.** The existing +seven-dimensional irreducible example also attains the irreducible maximum. +This answers the open upper-bound question in +[PR #7281](https://github.com/CrocSwap/integer-mult-bounds/pull/7281), +[exact source](https://github.com/unpaidmoon/integer-mult-bounds/blob/0cd5324c41490b856d0e94daa8b011683fc153f6/research/no-edge-dim5-fresh-link/PROOF.md). +It does not classify every attaining pool up to coordinate permutation. + +The dimension-four bound in +[PR #7139](https://github.com/CrocSwap/integer-mult-bounds/pull/7139), +[exact proof](https://github.com/unpaidmoon/integer-mult-bounds/blob/007869ccdc22ee591b5a88d99a35f02511bffbee/research/no-edge-dim4-image-at-most-six/PROOF.md), +uses finite pattern cases and support arguments. The present proof extends +the column-support argument to all diagonal relations at once. It uses no +finite classification step. The two-block construction, the small normal +triple and the earlier dimension-three/four bounds are prior work. + +CubeJerry's intersecting-dependency argument in +[PR #6838](https://github.com/CrocSwap/integer-mult-bounds/pull/6838), +[exact proof](https://github.com/CubeJerry/integer-mult-bounds/blob/f177c4f27e63dfa2e886033bb6a4e2dcd91f40b6/research/bit-zero-edge-image-bound/PROOF.md), +is the earlier column-support method. The present argument applies it to +the full diagonal-relation space rather than two selected triples. + +## 2. Select an image basis, with no irreducibility premise + +Choose n members `P_i=u_i v_i^T` whose images are a basis of V. The matrices +P_i are independent: in a relation among them, compare each column and use +independence of the u_i and the fact that each v_i is nonzero. + +Let A be their n-dimensional span, let `k0=dim off(A)`, and let K be the +space of diagonal matrices in A. Then + +```text +d = dim K = n-k0, k0 <= k. +``` + +Choose a basis `D_1,...,D_d` of K. Write each D_j in the P_i basis. For each +projector i, let `r_i in F2^d` contain its coefficients in these d expressions. +For `s in F2^d`, the corresponding diagonal matrix is + +```text +D(s) = sum_i (s dot r_i) P_i. +``` + +The vectors r_i span F2^d; otherwise a nonzero combination of the D_j would +vanish. Group the projectors by equal nonzero r_i. Put those with r_i zero +in a separate free group. No covector independence is assumed. + +## 3. Each nonzero group has its own diagonal sum + +Fix an ambient column b. Its value in D(s) is + +```text +sum_i (s dot r_i) v_i(b) u_i. +``` + +Since D(s) is diagonal, all these vectors lie in the one-dimensional space +spanned by e_b. The u_i are independent. Thus the map from s to the +coefficient vector `((s dot r_i) v_i(b))_i` has rank at most one. It follows +that all nonzero r_i with `v_i(b)=1` are equal: over F2, two different +nonzero linear functionals are independent and would give rank at least two. + +For a nonzero group label lambda, define + +```text +Q_lambda = sum_(r_i=lambda) P_i. +``` + +If this sum has a nonzero column b, that column receives no contribution +from any other nonzero group. Choose s with `s dot lambda=1`. Column b of +Q_lambda is then column b of D(s), so it is diagonal. All columns of +Q_lambda are therefore diagonal. The sum is nonzero because the P_i are +independent. + +The indicator vector of each group is now a relation among the patterns. +These indicators have disjoint supports and are independent. If there are +t nonzero groups, this gives `t<=d`. The r_i span F2^d, so `t>=d`. +Consequently **there are exactly d groups**, their labels are a basis of +F2^d, and their indicators generate the entire relation code. Every circuit +is one of these disjoint groups. The zero group consists of points in no +relation. + +Let S_lambda be the coordinate support of the diagonal Q_lambda. Every +covector in that group is supported on S_lambda: a zero column of the sum +would force all its covector entries to be zero by independence of the +images. Conversely a nonzero covector entry gives a nonzero sum column. +Distinct S_lambda are disjoint, by the column argument above. + +If a group has m members, then + +```text +1 <= rank(Q_lambda) = |S_lambda| <= m, +|S_lambda| = m modulo 2. +``` + +The rank bound follows from its m-dimensional image span. The parity identity +is its trace: each rank-one idempotent has trace one over F2. + +## 4. Every relation group has at least three members + +A group of size one would make its sole projector diagonal, contrary to the +nonzero-pattern assumption. + +For a group of size two, its diagonal sum has nonzero even rank at most two, +so it has rank two. Its two-dimensional image span is exactly the coordinate +space S_lambda. Both covectors are also supported there. A noncoordinate +rank-one idempotent on two binary coordinates has exactly one off-diagonal +one: if both off-diagonal entries were one, both factors would be `(1,1)` +and their pairing would be zero. Its pattern would therefore be a matrix +unit, contrary to the hypothesis. + +There are d disjoint groups of size at least three. Hence + +```text +n >= 3d = 3(n-k0), +2n <= 3k0 <= 3k. +``` + +This proves the total-image theorem. For an empty collection the same bound +is `0<=0`. Completeness and irreducibility were not used. + +## 5. Equality at even pattern dimension is reducible + +Suppose `2n=3k` and `n>0`. The preceding inequalities force `k0=k`, no free +group, and exactly d groups of size three, where `n=3d` and `k=2d`. The +chosen image basis therefore spans the full pattern space H. The complete +pool of H has the same joint image V: it contains the basis, while the +total-image bound prevents it from adding a dimension. It is enough to show +that this complete pool is reducible on V. + +For a size-three group, the active support S has odd size at most three. +There are two possibilities. + +If `|S|=1`, every covector equals the same coordinate covector e_c. Each +image has the form `e_c+t_i`, and the diagonal-sum identity gives +`t_1+t_2+t_3=0`. The three t_i are distinct and nonzero; they are the three +nonzero vectors of a two-dimensional space T. No vector of T has weight +one, because its column-c pattern would be a matrix unit. Call this a +column triple. + +If `|S|=3`, the independent images span that coordinate three-space. Their +sum is its identity projection. Expanding this identity in the image basis +shows that the covectors are its dual basis. The three projectors are +therefore mutually orthogonal and supported entirely within S. No choice +of a normal form is required here. + +Let S_all be the union of these pairwise disjoint active supports. Every +pattern in H has zero columns outside S_all. Suppose a complete-pool +projector has a covector bit at a coordinate b outside S_all. Its zero +off-diagonal column forces its image to be e_b. Its pattern would be a +single row outside S_all. In the columns of a three-coordinate group, +patterns are supported within that group's own block, so this row is zero. +At a column-triple coordinate c, its column would be zero or e_b. The latter +is forbidden because T contains no weight-one vector. Thus the whole +pattern would be zero, a contradiction. Every complete-pool covector is +supported on S_all. + +If at least one group is a column triple, then `|S_all|<3d=n`. The covectors +have a nonzero common kernel on V. The kernel is proper, since each +projector fixes its image. It is an invariant subspace, so the pool is +reducible. + +If every group has three active coordinates, H is supported on disjoint +coordinate blocks. A noncoordinate rank-one idempotent whose pattern lies +in H must be supported in one block. Indeed, idempotence gives a coordinate +where both factors are one; the forbidden cross-block entries then force +both factors into that block. Each block has only three nonzero patterns, +and each has just one idempotent lift by the lemma in Section 6. Thus the +complete pool is precisely the original `3d` orthogonal projectors. Every +image line is invariant. It is reducible again. + +Every member of the original collection belongs to this complete pool, and +both have image V. Its proper invariant subspace is therefore invariant for +the original collection as well. This rules out total-bound equality for +irreducible action. For odd k, the integer total bound already gives +`2n<=3k-1`; for even k the strict inequality does so. This proves the +irreducible consequence. + +## 6. Nonunit patterns have a unique idempotent lift + +This is the binary fiber lemma due to Nick Petalas, cited in the exact +source of PR #7139. A short proof is included to make the argument +self-contained. + +Choose an off-diagonal one at `(a,b)` in a realized pattern p. In a lift +`x y^T`, it forces `x_a=y_b=1`. Column b fixes every x bit except x_b; +row a fixes every y bit except y_a. Call the two unknown bits alpha and beta. +Idempotence gives + +```text +alpha + beta + sum_(j outside {a,b}) x_j y_j = 1. +``` + +If some known x bit outside `{a,b}` is one, its column-a entry fixes beta. +If some known y bit outside `{a,b}` is one, its row-b entry fixes alpha. +In either case, idempotence fixes the other bit. If there are no such bits, +both factors are supported on `{a,b}`. Idempotence then gives +`alpha+beta=1`, so the reverse off-diagonal entry `alpha beta` is zero. +The pattern is exactly the matrix unit at `(a,b)`. Thus every realized +nonzero pattern other than a matrix unit has exactly one idempotent lift. + +## 7. Sharpness and the dimension-five endpoint + +The standard normal triple on three coordinates is + +```text +(e_1+e_2)(e_0+e_2)^T, +(e_0+e_2)(e_1+e_2)^T, +(e_0+e_1+e_2)(e_0+e_1+e_2)^T. +``` + +Its images are independent, its pattern space has dimension two, its three +nonzero patterns have weights three, three and six, and its complete pool +is the stated triple. This construction and its classification are prior +work, recorded in the exact source of PR #7139. + +For `k=2d`, take d disjoint normal triples. For `k=2d+1`, add on three fresh +coordinates the single projector `e_0(e_0+e_1+e_2)^T`. This last pattern has +weight two and dimension one. Disjoint blocks have independent pattern +spaces and independent images. The complete pool is the union of the block +pools: a rank-one idempotent with nonzero pattern cannot cross the blocks, +by the argument in Section 5. The total image is respectively `3d` or +`3d+1`, which is `floor(3k/2)`. These prove sharpness for every k. + +For the irreducible dimension-five endpoint, the prior two-block family in +[PR #7237](https://github.com/CrocSwap/integer-mult-bounds/pull/7237) and +[PR #7281](https://github.com/CrocSwap/integer-mult-bounds/pull/7281) adds the +link `x x^T`, with `x=e_2+e_5+e_6`, to normal triples on coordinates 0..2 +and 3..5. Its complete pool has seven projectors, pattern dimension five +and irreducible image dimension seven. The verifier rechecks all 31 nonzero +patterns and all 127 nonzero vector orbits of this exact witness. It is +used as prior sharpness evidence, not claimed as a new construction. + +The new upper bound is seven, so both the total and irreducible maxima at +pattern dimension five are now seven. The coordinate classification of all +attaining pools remains open. + +## 8. Verification and limitations + +The verifier checks every image-basis collection with at most three +projectors at widths three and four: 224036 collections in total. Exactly +95046 have nonzero unit-free pattern spans. Each passes the complete +diagonal-relation certificate, including the disjoint active supports and +the full relation code. Larger odd column circuits, even orthogonal circuits +and a mixed circuit collection check that the proof is not specific to +triples or to independent covectors. + +It also enumerates all 2825 off-diagonal pattern subspaces at width three. +Of these, 1330 are unit-free, 336 have empty pools and 595 have irreducible +nonempty pools. Every complete pool passes both applicable bounds. All three +nonempty total-bound equality spaces occur at k=2 and are reducible. + +Complete-pool checks cover the sharp families for `1<=k<=12`, with 8178 +nonzero patterns in total. Five even-equality fixtures include column, +orthogonal, mixed and overlapping-support cases. The prior seven-image +irreducible witness supplies the dimension-five endpoint. + +Three controls violate the total bound after a hypothesis is removed. +The idempotents with factors `(1,3)` and `(3,2)` at width two have image +dimension two and pattern dimension one, but their pattern is a matrix unit. +The factors `(6,1)` and `(7,1)` at width three also have image dimension two +and unit-free pattern dimension one, but the first matrix is nilpotent. +A coordinate projector has image dimension one and zero pattern dimension. +Integers encode binary supports with coordinate zero in the low bit. + +The all-width proof does not depend on the finite checks or an unproved +basis-extraction step. In particular, it is consistent with the extraction +counterexamples in +[PR #7688](https://github.com/CrocSwap/integer-mult-bounds/pull/7688), +[exact proof](https://github.com/aliromman/integer-mult-bounds/blob/d9aba79eaed566640353efcb0a27b0d5649f705a/research/no-edge-basis-extraction-failure/PROOF.md). +The independent-image theorem and equality classification of +[PR #7686](https://github.com/CrocSwap/integer-mult-bounds/pull/7686), +[exact proof](https://github.com/aliromman/integer-mult-bounds/blob/9da06cbe0b888293cbb249cb29eef0f37addaa4f/research/no-edge-image-basis-bound/PROOF.md), +retain credit; the present bound applies without that extra irreducibility +premise. The small exact matrix and lift routines are reused from those +packages, as recorded in CREDITS.md. + +No new kappa, paid BIT word, native conversion or full invoice is supplied. +The selected frontier and all five assumptions remain unchanged. Independent +human and formal-kernel review are unclaimed. + +## Open next questions + +Classify the complete pattern-dimension-five pools that act irreducibly on +a seven-dimensional image. An arbitrary image basis has two disjoint +diagonal-relation groups and one remaining projector, or one group of size +four and one of size three. Analyze these two structures without assuming +that the selected basis is irreducible. The total-image bound is no longer +the missing step; the attaining geometry is. diff --git a/research/no-edge-total-image-bound/README.md b/research/no-edge-total-image-bound/README.md new file mode 100644 index 0000000000..ada37978c5 --- /dev/null +++ b/research/no-edge-total-image-bound/README.md @@ -0,0 +1,55 @@ +# Sharp total image at every no-edge pattern dimension + +For any binary rank-one idempotent collection with nonzero patterns and a +k-dimensional pattern span that contains no matrix unit, the joint image +has dimension at most `floor(3k/2)`. The bound is sharp for every positive k. +If the action on a nonzero joint image is irreducible, its dimension is at +most `floor((3k-1)/2)`. + +In particular, pattern dimension five has maximum total image seven. The +existing seven-dimensional irreducible example attains the irreducible +maximum as well. This closes the upper-bound question left open in +[PR #7281](https://github.com/CrocSwap/integer-mult-bounds/pull/7281). +The coordinate classification of all attaining pools remains open. + +Read [PROOF.md](PROOF.md), [RESULT.json](RESULT.json), and +[TASK.json](TASK.json). The proof selects any independent image subcollection +and shows that its diagonal relations are generated by disjoint circuits of +at least three members. It does not require an irreducible basis or a finite +classification step. Incomplete collections are included. + +With CPython 3.12 and its standard library, from the repository root: + +```sh +python3.12 -I -W error -B research/no-edge-total-image-bound/verify.py +python3.12 -I -W error -B -O research/no-edge-total-image-bound/verify.py +python3.12 -B scripts/research_package.py --package research/no-edge-total-image-bound +``` + +Expected markers: + +```text +PASS_NO_EDGE_TOTAL_IMAGE_BOUND +PASS_REGISTERED_RESEARCH_PACKAGE +``` + +The exact checks cover 224036 small image-basis collections, all 2825 +width-three pattern spaces, complete sharp pools for `1<=k<=12`, larger +relation circuits, five equality controls and the prior irreducible +seven-image witness. The controls show why nonzero patterns, idempotence +and exclusion of matrix units are required. + +No new kappa, paid BIT word, native operation or complete invoice is supplied. +The selected frontier and all five assumptions remain unchanged. Predecessor +scientific replays, the selected cold replay, Lean and Docker were not run. +Independent human and formal-kernel review are unclaimed. + +## Open next questions + +Classify the irreducible seven-dimensional pools at pattern dimension five. +An image basis has two diagonal-relation groups: sizes three and three with +one free member, or sizes three and four. These are the next structural +cases. The total-image upper bound is now proved. + +Prepared by Ali Romman with substantial OpenAI Codex assistance. New work is +Apache-2.0. See [CREDITS.md](CREDITS.md). diff --git a/research/no-edge-total-image-bound/RESULT.json b/research/no-edge-total-image-bound/RESULT.json new file mode 100644 index 0000000000..dbf5ef1982 --- /dev/null +++ b/research/no-edge-total-image-bound/RESULT.json @@ -0,0 +1,1056 @@ +{ + "statement": "For every binary rank-one idempotent collection with nonzero unit-free pattern span H, 2 dim(V) <= 3 dim(H). The total bound is sharp for each k. Irreducible action gives 2 dim(V) <= 3 dim(H)-1.", + "small_image_basis_censuses": [ + { + "width": 3, + "maximum_n": 3, + "counts": { + "collections": 2156, + "nonzero_unit_free": 146 + }, + "diagonal_dimension_counts": { + "0": 143, + "1": 3 + } + }, + { + "width": 4, + "maximum_n": 3, + "counts": { + "collections": 221880, + "nonzero_unit_free": 94900 + }, + "diagonal_dimension_counts": { + "0": 94884, + "1": 16 + } + } + ], + "complete_width_three_pattern_census": { + "all_pattern_spaces": 2825, + "counts": { + "empty_pools": 336, + "irreducible_pools": 595, + "unit_free_spaces": 1330 + }, + "nonempty_total_equality_by_k": { + "2": 3 + } + }, + "sharp_total_families": [ + { + "k": 1, + "width": 3, + "pairs": [ + [ + 1, + 7 + ] + ], + "certificate": { + "n": 1, + "k": 1, + "diagonal_dimension": 0, + "circuit_sizes": [], + "active_supports": [], + "free_projectors": 1 + }, + "patterns_checked": 1 + }, + { + "k": 2, + "width": 3, + "pairs": [ + [ + 6, + 5 + ], + [ + 5, + 6 + ], + [ + 7, + 7 + ] + ], + "certificate": { + "n": 3, + "k": 2, + "diagonal_dimension": 1, + "circuit_sizes": [ + 3 + ], + "active_supports": [ + 7 + ], + "free_projectors": 0 + }, + "patterns_checked": 3 + }, + { + "k": 3, + "width": 6, + "pairs": [ + [ + 6, + 5 + ], + [ + 5, + 6 + ], + [ + 7, + 7 + ], + [ + 8, + 56 + ] + ], + "certificate": { + "n": 4, + "k": 3, + "diagonal_dimension": 1, + "circuit_sizes": [ + 3 + ], + "active_supports": [ + 7 + ], + "free_projectors": 1 + }, + "patterns_checked": 7 + }, + { + "k": 4, + "width": 6, + "pairs": [ + [ + 6, + 5 + ], + [ + 5, + 6 + ], + [ + 7, + 7 + ], + [ + 48, + 40 + ], + [ + 40, + 48 + ], + [ + 56, + 56 + ] + ], + "certificate": { + "n": 6, + "k": 4, + "diagonal_dimension": 2, + "circuit_sizes": [ + 3, + 3 + ], + "active_supports": [ + 7, + 56 + ], + "free_projectors": 0 + }, + "patterns_checked": 15 + }, + { + "k": 5, + "width": 9, + "pairs": [ + [ + 6, + 5 + ], + [ + 5, + 6 + ], + [ + 7, + 7 + ], + [ + 48, + 40 + ], + [ + 40, + 48 + ], + [ + 56, + 56 + ], + [ + 64, + 448 + ] + ], + "certificate": { + "n": 7, + "k": 5, + "diagonal_dimension": 2, + "circuit_sizes": [ + 3, + 3 + ], + "active_supports": [ + 7, + 56 + ], + "free_projectors": 1 + }, + "patterns_checked": 31 + }, + { + "k": 6, + "width": 9, + "pairs": [ + [ + 6, + 5 + ], + [ + 5, + 6 + ], + [ + 7, + 7 + ], + [ + 48, + 40 + ], + [ + 40, + 48 + ], + [ + 56, + 56 + ], + [ + 384, + 320 + ], + [ + 320, + 384 + ], + [ + 448, + 448 + ] + ], + "certificate": { + "n": 9, + "k": 6, + "diagonal_dimension": 3, + "circuit_sizes": [ + 3, + 3, + 3 + ], + "active_supports": [ + 7, + 56, + 448 + ], + "free_projectors": 0 + }, + "patterns_checked": 63 + }, + { + "k": 7, + "width": 12, + "pairs": [ + [ + 6, + 5 + ], + [ + 5, + 6 + ], + [ + 7, + 7 + ], + [ + 48, + 40 + ], + [ + 40, + 48 + ], + [ + 56, + 56 + ], + [ + 384, + 320 + ], + [ + 320, + 384 + ], + [ + 448, + 448 + ], + [ + 512, + 3584 + ] + ], + "certificate": { + "n": 10, + "k": 7, + "diagonal_dimension": 3, + "circuit_sizes": [ + 3, + 3, + 3 + ], + "active_supports": [ + 7, + 56, + 448 + ], + "free_projectors": 1 + }, + "patterns_checked": 127 + }, + { + "k": 8, + "width": 12, + "pairs": [ + [ + 6, + 5 + ], + [ + 5, + 6 + ], + [ + 7, + 7 + ], + [ + 48, + 40 + ], + [ + 40, + 48 + ], + [ + 56, + 56 + ], + [ + 384, + 320 + ], + [ + 320, + 384 + ], + [ + 448, + 448 + ], + [ + 3072, + 2560 + ], + [ + 2560, + 3072 + ], + [ + 3584, + 3584 + ] + ], + "certificate": { + "n": 12, + "k": 8, + "diagonal_dimension": 4, + "circuit_sizes": [ + 3, + 3, + 3, + 3 + ], + "active_supports": [ + 7, + 56, + 448, + 3584 + ], + "free_projectors": 0 + }, + "patterns_checked": 255 + }, + { + "k": 9, + "width": 15, + "pairs": [ + [ + 6, + 5 + ], + [ + 5, + 6 + ], + [ + 7, + 7 + ], + [ + 48, + 40 + ], + [ + 40, + 48 + ], + [ + 56, + 56 + ], + [ + 384, + 320 + ], + [ + 320, + 384 + ], + [ + 448, + 448 + ], + [ + 3072, + 2560 + ], + [ + 2560, + 3072 + ], + [ + 3584, + 3584 + ], + [ + 4096, + 28672 + ] + ], + "certificate": { + "n": 13, + "k": 9, + "diagonal_dimension": 4, + "circuit_sizes": [ + 3, + 3, + 3, + 3 + ], + "active_supports": [ + 7, + 56, + 448, + 3584 + ], + "free_projectors": 1 + }, + "patterns_checked": 511 + }, + { + "k": 10, + "width": 15, + "pairs": [ + [ + 6, + 5 + ], + [ + 5, + 6 + ], + [ + 7, + 7 + ], + [ + 48, + 40 + ], + [ + 40, + 48 + ], + [ + 56, + 56 + ], + [ + 384, + 320 + ], + [ + 320, + 384 + ], + [ + 448, + 448 + ], + [ + 3072, + 2560 + ], + [ + 2560, + 3072 + ], + [ + 3584, + 3584 + ], + [ + 24576, + 20480 + ], + [ + 20480, + 24576 + ], + [ + 28672, + 28672 + ] + ], + "certificate": { + "n": 15, + "k": 10, + "diagonal_dimension": 5, + "circuit_sizes": [ + 3, + 3, + 3, + 3, + 3 + ], + "active_supports": [ + 7, + 56, + 448, + 3584, + 28672 + ], + "free_projectors": 0 + }, + "patterns_checked": 1023 + }, + { + "k": 11, + "width": 18, + "pairs": [ + [ + 6, + 5 + ], + [ + 5, + 6 + ], + [ + 7, + 7 + ], + [ + 48, + 40 + ], + [ + 40, + 48 + ], + [ + 56, + 56 + ], + [ + 384, + 320 + ], + [ + 320, + 384 + ], + [ + 448, + 448 + ], + [ + 3072, + 2560 + ], + [ + 2560, + 3072 + ], + [ + 3584, + 3584 + ], + [ + 24576, + 20480 + ], + [ + 20480, + 24576 + ], + [ + 28672, + 28672 + ], + [ + 32768, + 229376 + ] + ], + "certificate": { + "n": 16, + "k": 11, + "diagonal_dimension": 5, + "circuit_sizes": [ + 3, + 3, + 3, + 3, + 3 + ], + "active_supports": [ + 7, + 56, + 448, + 3584, + 28672 + ], + "free_projectors": 1 + }, + "patterns_checked": 2047 + }, + { + "k": 12, + "width": 18, + "pairs": [ + [ + 6, + 5 + ], + [ + 5, + 6 + ], + [ + 7, + 7 + ], + [ + 48, + 40 + ], + [ + 40, + 48 + ], + [ + 56, + 56 + ], + [ + 384, + 320 + ], + [ + 320, + 384 + ], + [ + 448, + 448 + ], + [ + 3072, + 2560 + ], + [ + 2560, + 3072 + ], + [ + 3584, + 3584 + ], + [ + 24576, + 20480 + ], + [ + 20480, + 24576 + ], + [ + 28672, + 28672 + ], + [ + 196608, + 163840 + ], + [ + 163840, + 196608 + ], + [ + 229376, + 229376 + ] + ], + "certificate": { + "n": 18, + "k": 12, + "diagonal_dimension": 6, + "circuit_sizes": [ + 3, + 3, + 3, + 3, + 3, + 3 + ], + "active_supports": [ + 7, + 56, + 448, + 3584, + 28672, + 229376 + ], + "free_projectors": 0 + }, + "patterns_checked": 4095 + } + ], + "larger_circuit_controls": [ + { + "kind": "column", + "m": 3, + "certificate": { + "n": 3, + "k": 2, + "diagonal_dimension": 1, + "circuit_sizes": [ + 3 + ], + "active_supports": [ + 1 + ], + "free_projectors": 0 + } + }, + { + "kind": "column", + "m": 5, + "certificate": { + "n": 5, + "k": 4, + "diagonal_dimension": 1, + "circuit_sizes": [ + 5 + ], + "active_supports": [ + 1 + ], + "free_projectors": 0 + } + }, + { + "kind": "column", + "m": 7, + "certificate": { + "n": 7, + "k": 6, + "diagonal_dimension": 1, + "circuit_sizes": [ + 7 + ], + "active_supports": [ + 1 + ], + "free_projectors": 0 + } + }, + { + "kind": "orthogonal", + "m": 4, + "certificate": { + "n": 4, + "k": 3, + "diagonal_dimension": 1, + "circuit_sizes": [ + 4 + ], + "active_supports": [ + 15 + ], + "free_projectors": 0 + } + }, + { + "kind": "orthogonal", + "m": 6, + "certificate": { + "n": 6, + "k": 5, + "diagonal_dimension": 1, + "circuit_sizes": [ + 6 + ], + "active_supports": [ + 63 + ], + "free_projectors": 0 + } + }, + { + "kind": "orthogonal", + "m": 8, + "certificate": { + "n": 8, + "k": 7, + "diagonal_dimension": 1, + "circuit_sizes": [ + 8 + ], + "active_supports": [ + 255 + ], + "free_projectors": 0 + } + }, + { + "kind": "mixed", + "certificate": { + "n": 13, + "k": 10, + "diagonal_dimension": 3, + "circuit_sizes": [ + 3, + 4, + 5 + ], + "active_supports": [ + 1, + 240, + 256 + ], + "free_projectors": 1 + } + } + ], + "even_equality_controls": [ + { + "kinds": [ + "column", + "column" + ], + "certificate": { + "n": 6, + "k": 4, + "diagonal_dimension": 2, + "circuit_sizes": [ + 3, + 3 + ], + "active_supports": [ + 1, + 16 + ], + "free_projectors": 0 + }, + "covector_rank": 2 + }, + { + "kinds": [ + "normal", + "column" + ], + "certificate": { + "n": 6, + "k": 4, + "diagonal_dimension": 2, + "circuit_sizes": [ + 3, + 3 + ], + "active_supports": [ + 7, + 8 + ], + "free_projectors": 0 + }, + "covector_rank": 4 + }, + { + "kinds": [ + "normal", + "normal" + ], + "certificate": { + "n": 6, + "k": 4, + "diagonal_dimension": 2, + "circuit_sizes": [ + 3, + 3 + ], + "active_supports": [ + 7, + 56 + ], + "free_projectors": 0 + }, + "covector_rank": 6 + }, + { + "kinds": [ + "overlapping_columns" + ], + "certificate": { + "n": 6, + "k": 4, + "diagonal_dimension": 2, + "circuit_sizes": [ + 3, + 3 + ], + "active_supports": [ + 1, + 2 + ], + "free_projectors": 0 + }, + "covector_rank": 2 + }, + { + "kinds": [ + "overlapping_mixed" + ], + "certificate": { + "n": 6, + "k": 4, + "diagonal_dimension": 2, + "circuit_sizes": [ + 3, + 3 + ], + "active_supports": [ + 7, + 8 + ], + "free_projectors": 0 + }, + "covector_rank": 4 + } + ], + "prior_irreducible_seven_witness": { + "pairs": [ + [ + 6, + 5 + ], + [ + 5, + 6 + ], + [ + 7, + 7 + ], + [ + 48, + 40 + ], + [ + 40, + 48 + ], + [ + 56, + 56 + ], + [ + 100, + 100 + ] + ], + "certificate": { + "n": 7, + "k": 5, + "diagonal_dimension": 2, + "circuit_sizes": [ + 3, + 3 + ], + "active_supports": [ + 7, + 56 + ], + "free_projectors": 1 + } + }, + "hypothesis_controls": { + "with_matrix_unit": { + "n": 2, + "k": 1 + }, + "without_idempotence": { + "n": 2, + "k": 1 + }, + "with_zero_pattern": { + "n": 1, + "k": 0 + } + }, + "scope": "The k=5 maximum is seven; coordinate classification of all attaining pools and paid-word consequences remain open.", + "kappa_change": null +} diff --git a/research/no-edge-total-image-bound/SOURCES.json b/research/no-edge-total-image-bound/SOURCES.json new file mode 100644 index 0000000000..5335fa97d9 --- /dev/null +++ b/research/no-edge-total-image-bound/SOURCES.json @@ -0,0 +1,18 @@ +{ + "schema_version": 1, + "base_commit": "e54523517d0f03e58352e647c403a5af3e525a57", + "files": [ + { + "path": "certificates/selected-result.json", + "usage": "provenance", + "git_blob": "75d77b328ea02ded535e7f23aee5b1e55d0bb1a8", + "sha256": "154c3d30455d778fd3343b6b4851f0fa4665f0f7625b0adb3675e2bafbbf6bf1" + }, + { + "path": "docs/research/agent-task-catalog.json", + "usage": "provenance", + "git_blob": "3404fbdd5e7529a0674eef26114b5071e4586cec", + "sha256": "ead6cdc9d0af6d58e8a49744d8ec8c7c15e13d2ba93c276c434bcf9b51b93a81" + } + ] +} diff --git a/research/no-edge-total-image-bound/TASK.json b/research/no-edge-total-image-bound/TASK.json new file mode 100644 index 0000000000..99f85f5ad7 --- /dev/null +++ b/research/no-edge-total-image-bound/TASK.json @@ -0,0 +1,80 @@ +{ + "schema_version": 1, + "task_id": "bit-new-register-model", + "priority_revision": 8, + "base_commit": "e54523517d0f03e58352e647c403a5af3e525a57", + "original_card": { + "id": "bit-new-register-model", + "question": "Can an explicitly larger or nonabelian register model escape the scoped three-register obstruction?", + "starting_points": [ + "docs/research/research-family-status.md", + "research/bit-three-register-lower-bound/README.md", + "certificates/selected-result.json", + "research/bit-gl3-mixed-targets-length10/README.md", + "docs/research/community-efficient1000-review.md" + ], + "methods": [ + "Construct the smallest exact identity in a newly specified legal operation alphabet.", + "Derive a target-specific relaxation bound for that same explicit alphabet." + ], + "acceptance_gate": "Name the changed hypothesis, all counted roles and a uniform identity; finite column tests alone do not certify it. A scoped local result may be retained without a complete supplier. Expanding it into further construction rounds requires the family-level budget and obligation gate in research-family-status.md; an optimistic passing relaxation alone is not acceptance.", + "first_step": { + "command": [ + "python3", + "-B", + "scripts/research_selected_baseline.py" + ], + "expected": "PASS_RESEARCH_BASELINE_BINDINGS_ONLY", + "inspect": "Resolve the current selected review, separate complex/ordinary BIT/admitted BIT/outer budgets, and compare the card against live handoffs before starting. Historical ceilings require exact source/model equivalence.", + "scope": "Source-binding orientation only; not a scientific replay or all-size proof. Materialize selected inputs if this checkout is sparse." + }, + "first_experiment": "First compare the alphabet, role count and length with the fully replayed #1974 census and #2027 mixed-root tariff. Identify a changed premise and a legal native implementation; then price one smallest completed instance before searching larger words.", + "bottleneck_link": "A small-width completed saving changes the bit primitive; a finite-address identity alone is insufficient.", + "allowed_variations": [ + "Choose a fixed larger register count or a specified nonabelian operation family." + ], + "scope_change_triggers": [ + "Remaining inside the already-excluded three-register abelian model.", + "Repeating the two-register GL3 census or a covered three-register length without changing a hypothesis; a formal group-algebra word without native conversion is a partial result." + ], + "overlap_terms": [ + "three-register", + "nonabelian", + "group algebra" + ] + }, + "scope_status": "changed", + "actual_scope": "Sharp total-image bound floor(3k/2) for every binary unit-free pattern dimension, with disjoint diagonal-relation circuits and the irreducible bound floor((3k-1)/2).", + "scope_change_reason": "Close the open pattern-dimension-five upper bound with a general column-support theorem. No irreducible basis extraction or new register alphabet is assumed.", + "bottleneck_link": "Replace the dimension-five cardinality ceiling by the exact image maximum seven and give structural constraints for the remaining attaining-pool classification.", + "budget_minutes": 60, + "stop_rule": "Stop at the general bound, equality boundary, sharpness and exact controls. Full coordinate classification and paid-word consequences remain separate.", + "outcome": "completed", + "evidence": "PROOF.md; RESULT.json; 224036 image-basis collections, all 2825 width-three pattern spaces, complete sharp pools for k=1..12 and hypothesis controls.", + "author": "Ali Romman", + "ai_assistance": "Substantial OpenAI Codex assistance; no independent human or formal-kernel review claimed.", + "open_questions": [ + { + "question": "Classify all irreducible seven-dimensional complete pools at pattern dimension five.", + "why_it_matters": "The maximum is now seven, but different attaining geometries may have different word-level uses.", + "first_step": "Analyze two diagonal-relation triples plus one free member, and the alternative triple-plus-quad case.", + "blocked_by": "The upper bound does not classify all complete attaining pools." + } + ], + "family_decision": { + "decision": "Narrow to the open total-image bound through a general support proof.", + "sources": "7139@007869ccdc22ee591b5a88d99a35f02511bffbee; 7281@0cd5324c41490b856d0e94daa8b011683fc153f6; 6838@f177c4f27e63dfa2e886033bb6a4e2dcd91f40b6; 7686@9da06cbe0b888293cbb249cb29eef0f37addaa4f; 7688@d9aba79eaed566640353efcb0a27b0d5649f705a", + "evidence_status": "Author-checked all-width proof and exact finite corroboration.", + "boundary": "Binary rank-one idempotent collections with nonzero unit-free patterns; no physical word or state.", + "obligations": { + "total_bound_and_sharpness": "proved in the written argument", + "irreducible_even_boundary": "proved in the written argument", + "coordinate_classification": "unknown", + "paid_word": "unknown", + "native_conversion": "unknown", + "complete_invoice": "unknown" + }, + "alternative": "A pattern-dimension-five census would need a new completeness reduction. The diagonal-relation proof avoids that search.", + "construction_gate": "Unmet. No native alphabet, paid identity or full invoice is supplied." + } +} diff --git a/research/no-edge-total-image-bound/VERIFY.json b/research/no-edge-total-image-bound/VERIFY.json new file mode 100644 index 0000000000..0e6abb5889 --- /dev/null +++ b/research/no-edge-total-image-bound/VERIFY.json @@ -0,0 +1,34 @@ +{ + "schema_version": 1, + "status": "ready", + "python": "3.12", + "requirements": [], + "inputs": [], + "commands": [ + { + "argv": [ + "{python}", + "-I", + "-W", + "error", + "-B", + "{package}/verify.py" + ], + "timeout_seconds": 120, + "checks": "Complete small independent-image and pattern-space censuses, disjoint relation certificates, complete sharp pools, equality and premise controls." + }, + { + "argv": [ + "{python}", + "-I", + "-W", + "error", + "-B", + "-O", + "{package}/verify.py" + ], + "timeout_seconds": 120, + "checks": "Complete small independent-image and pattern-space censuses, disjoint relation certificates, complete sharp pools, equality and premise controls." + } + ] +} diff --git a/research/no-edge-total-image-bound/verify.py b/research/no-edge-total-image-bound/verify.py new file mode 100644 index 0000000000..85877847ed --- /dev/null +++ b/research/no-edge-total-image-bound/verify.py @@ -0,0 +1,364 @@ +"""Exact checks for the general no-edge total-image bound. + +Ali Romman, with substantial OpenAI Codex assistance. Apache-2.0. +Matrix, lift and orbit primitives are reused from PR7686 and PR7688. +See CREDITS.md for exact sources and predecessor support arguments. +""" + +import itertools +import json +from collections import Counter +from pathlib import Path + + +def require(value, message): + if not value: + raise ValueError(message) + + + +def parity(value): + return value.bit_count() & 1 + + + +def basis(values): + pivots = {} + for value in values: + while value: + pivot = value.bit_length() - 1 + if pivot in pivots: + value ^= pivots[pivot] + else: + pivots[pivot] = value + break + return tuple(pivots.values()) + + + +def span(values): + result = [0] + for value in basis(values): + result += [old ^ value for old in result] + return result + + + +def outer(x, y, width): + result = 0 + while x: + bit = x & -x + result |= y << ((bit.bit_length() - 1) * width) + x ^= bit + return result + + + +def off(matrix, width): + for i in range(width): + matrix &= ~(1 << (i * width + i)) + return matrix + + + +def patterns(pairs, width): + return [off(outer(x, y, width), width) for x, y in pairs] + + + +def lifts(pattern, width): + """An off-diagonal one fixes all factor bits except two.""" + require(pattern != 0, 'zero pattern is outside the pool') + i, j = divmod((pattern & -pattern).bit_length() - 1, width) + require(i != j, 'diagonal pattern entry') + x = sum(((pattern >> (r * width + j)) & 1) << r for r in range(width)) + y = (pattern >> (i * width)) & ((1 << width) - 1) + result = [] + for xj, yi in itertools.product((0, 1), repeat=2): + xx, yy = x | (xj << j), y | (yi << i) + if parity(xx & yy) and off(outer(xx, yy, width), width) == pattern: + result.append((xx, yy)) + return result + + + +def pool(pattern_basis, width): + return sorted(pair for pattern in span(pattern_basis) if pattern + for pair in lifts(pattern, width)) + + + +def orbit_irreducible(pairs): + """Check all nonzero vectors for small fixtures by direct closure.""" + image_space = span(x for x, _ in pairs) + n = len(basis(image_space)) + for value in image_space[1:]: + vectors = basis([value]) + while True: + expanded = basis((*vectors, *(x for x, y in pairs + if any(parity(y & v) for v in vectors)))) + if len(expanded) == len(vectors): + break + vectors = expanded + if len(vectors) != n: + return False + return True + + + +def all_subspaces(width): + spaces = {frozenset({0})} + frontier = list(spaces) + while frontier: + old = frontier.pop() + for value in range(1, 1 << width): + if value not in old: + new = frozenset(old | {x ^ value for x in old}) + if new not in spaces: + spaces.add(new) + frontier.append(new) + return sorted(spaces, key=lambda x: (len(x), sorted(x))) + + +def unit_free(values): + return all(x.bit_count() != 1 for x in span(values)) + + +def relation_structure(pairs, width): + n = len(pairs) + require(len(basis(x for x, _ in pairs)) == n, 'independent images') + ps = patterns(pairs, width) + require(all(ps) and unit_free(ps), 'nonzero unit-free patterns') + require(all(parity(x & y) for x, y in pairs), 'idempotence') + pivots, relations = {}, [] + for i, value in enumerate(ps): + label = 1 << i + while value: + pivot = value.bit_length() - 1 + if pivot in pivots: + old, old_label = pivots[pivot] + value ^= old + label ^= old_label + else: + pivots[pivot] = value, label + break + if not value: + relations.append(label) + groups = {} + for i in range(n): + character = sum(((r >> i) & 1) << j for j, r in enumerate(relations)) + groups.setdefault(character, []).append(i) + nonzero = {c: indices for c, indices in groups.items() if c} + d, k = len(relations), len(pivots) + require(len(nonzero) == d and len(basis(nonzero)) == d, 'independent nonzero characters') + class_relations, supports, sizes = [], [], [] + for indices in nonzero.values(): + require(len(indices) >= 3, 'minimum class size') + label = sum(1 << i for i in indices) + matrix = 0 + for i in indices: + matrix ^= outer(*pairs[i], width) + require(matrix and off(matrix, width) == 0, 'class has its own diagonal sum') + support = sum(((matrix >> (i * width + i)) & 1) << i for i in range(width)) + require(all(not support & other for other in supports), 'disjoint active coordinates') + require(all(not pairs[i][1] & ~support for i in indices), 'class covector support') + require(support.bit_count() <= len(indices), 'diagonal rank') + require((support.bit_count() - len(indices)) % 2 == 0, 'trace parity') + supports.append(support) + sizes.append(len(indices)) + class_relations.append(label) + require(set(span(class_relations)) == set(span(relations)), 'entire relation code') + require(2 * n <= 3 * k, 'total-image bound') + return {'n': n, 'k': k, 'diagonal_dimension': d, + 'circuit_sizes': sorted(sizes), 'active_supports': supports, + 'free_projectors': len(groups.get(0, []))} + + +def small_image_basis_census(width, maximum_n): + counts = Counter() + circuits = Counter() + for n in range(1, maximum_n + 1): + for images in itertools.combinations(range(1, 1 << width), n): + if len(basis(images)) != n: + continue + choices = [[y for y in range(1, 1 << width) if parity(x & y)] for x in images] + for covectors in itertools.product(*choices): + counts['collections'] += 1 + pairs = list(zip(images, covectors)) + ps = patterns(pairs, width) + if not all(ps) or not unit_free(ps): + continue + counts['nonzero_unit_free'] += 1 + row = relation_structure(pairs, width) + circuits[str(row['diagonal_dimension'])] += 1 + return {'width': width, 'maximum_n': maximum_n, + 'counts': dict(sorted(counts.items())), 'diagonal_dimension_counts': dict(sorted(circuits.items()))} + + +def three_width_pattern_census(): + positions = [i * 3 + j for i in range(3) for j in range(3) if i != j] + def encode(matrix): + return sum(((matrix >> bit) & 1) << i for i, bit in enumerate(positions)) + candidates = [(x, y, encode(off(outer(x, y, 3), 3))) + for x, y in itertools.product(range(1, 8), repeat=2) + if parity(x & y) and off(outer(x, y, 3), 3)] + spaces = all_subspaces(6) + require(len(spaces) == 2825, 'all width-three pattern spaces') + counts = Counter() + equality = Counter() + for space in spaces: + if any(x.bit_count() == 1 for x in space): + continue + counts['unit_free_spaces'] += 1 + k = len(basis(space)) + pairs = [(x, y) for x, y, pattern in candidates if pattern in space] + n = len(basis(x for x, _ in pairs)) + require(2 * n <= 3 * k, 'complete-pool total bound') + if not n: + counts['empty_pools'] += 1 + continue + action = orbit_irreducible(pairs) + if action: + counts['irreducible_pools'] += 1 + require(2 * n <= 3 * k - 1, 'irreducible full-pool bound') + if 2 * n == 3 * k: + require(not action, 'even equality must be reducible') + equality[str(k)] += 1 + return {'all_pattern_spaces': len(spaces), 'counts': dict(sorted(counts.items())), + 'nonempty_total_equality_by_k': dict(sorted(equality.items()))} + + +def normal_block(shift): + return [(x << shift, y << shift) for x, y in ((6, 5), (5, 6), (7, 7))] + + +def sharp_family(k): + pairs = [p for j in range(k // 2) for p in normal_block(3 * j)] + width = 3 * (k // 2) + if k % 2: + pairs.append((1 << width, 7 << width)) + width += 3 + ps = patterns(pairs, width) + row = relation_structure(pairs, width) + require(row['n'] == (3 * k) // 2 and row['k'] == k, 'sharp dimensions') + require(pool(ps, width) == sorted(pairs), 'sharp complete pool') + if k > 1: + # A normal-block image line is invariant under every pool member. + line = pairs[0][0] + require(all(not parity(y & line) or x == line for x, y in pairs), 'sharp reducibility witness') + return {'k': k, 'width': width, 'pairs': pairs, 'certificate': row, + 'patterns_checked': (1 << k) - 1} + + +def odd_column_circuit(m, shift=0): + require(m >= 3 and m % 2 == 1, 'odd circuit length') + t = [(1 << i) | (1 << m) for i in range(1, m)] + last = 0 + for value in t: + last ^= value + t.append(last) + return [((1 | value) << shift, 1 << shift) for value in t], m + 1 + + +def even_orthogonal_circuit(m, shift=0): + require(m >= 4 and m % 2 == 0, 'even circuit length') + ones = (1 << m) - 1 + return [((ones ^ (1 << i)) << shift, (ones ^ (1 << i)) << shift) + for i in range(m)], m + + +def compute(): + small = [small_image_basis_census(3, 3), small_image_basis_census(4, 3)] + pattern_census = three_width_pattern_census() + sharp = [sharp_family(k) for k in range(1, 13)] + varied = [] + for m in (3, 5, 7): + pairs, width = odd_column_circuit(m) + varied.append({'kind': 'column', 'm': m, 'certificate': relation_structure(pairs, width)}) + for m in (4, 6, 8): + pairs, width = even_orthogonal_circuit(m) + varied.append({'kind': 'orthogonal', 'm': m, 'certificate': relation_structure(pairs, width)}) + mixed, width = odd_column_circuit(3) + part, size = even_orthogonal_circuit(4, width) + mixed += part + width += size + part, size = odd_column_circuit(5, width) + mixed += part + width += size + mixed.append((1 << width, 7 << width)) + width += 3 + varied.append({'kind': 'mixed', 'certificate': relation_structure(mixed, width)}) + + # Three equality geometries from the prior dimension-four analysis. + equality_controls = [] + for kinds in (('column', 'column'), ('normal', 'column'), ('normal', 'normal')): + pairs, width = [], 0 + for kind in kinds: + if kind == 'column': + part, size = odd_column_circuit(3, width) + else: + part, size = normal_block(width), 3 + pairs += part + width += size + require(pool(patterns(pairs, width), width) == sorted(pairs), 'mixed equality complete pool') + require(not orbit_irreducible(pairs), 'mixed equality reducible') + equality_controls.append({'kinds': kinds, 'certificate': relation_structure(pairs, width), + 'covector_rank': len(basis(y for _, y in pairs))}) + + for kind in ('overlapping_columns', 'overlapping_mixed'): + if kind == 'overlapping_columns': + pairs = [] + for anchor, a, b in ((0, 2, 3), (1, 4, 5)): + t, u = (1 << a) | 64, (1 << b) | 64 + pairs += [((1 << anchor) | v, 1 << anchor) for v in (t, u, t ^ u)] + width = 7 + else: + pairs = normal_block(0) + t, u = 1 | 16, 2 | 32 + pairs += [(8 | v, 8) for v in (t, u, t ^ u)] + width = 6 + require(pool(patterns(pairs, width), width) == sorted(pairs), 'overlapping-support complete pool') + require(not orbit_irreducible(pairs), 'overlapping-support reducibility') + equality_controls.append({'kinds': [kind], 'certificate': relation_structure(pairs, width), + 'covector_rank': len(basis(y for _, y in pairs))}) + + seven = normal_block(0) + normal_block(3) + [(100, 100)] + seven_ps = patterns(seven, 7) + require(pool(seven_ps, 7) == sorted(seven) and orbit_irreducible(seven), 'prior sharp seven-image witness') + require(len(basis(seven_ps)) == 5, 'seven-image pattern dimension') + seven_certificate = relation_structure(seven, 7) + + with_unit = [(1, 3), (3, 2)] + require(len(basis(x for x, _ in with_unit)) == 2, 'unit control image rank') + require(len(basis(patterns(with_unit, 2))) == 1, 'unit control pattern rank') + require(not unit_free(patterns(with_unit, 2)), 'unit control outside hypothesis') + non_idempotent = [(6, 1), (7, 1)] + require(len(basis(x for x, _ in non_idempotent)) == 2, 'nilpotent control image rank') + require(len(basis(patterns(non_idempotent, 3))) == 1 and unit_free(patterns(non_idempotent, 3)), 'nilpotent unit-free control') + require(not parity(6 & 1) and parity(7 & 1), 'nilpotent premise failure') + require(patterns([(1, 1)], 1) == [0], 'coordinate projector control') + + return {'statement': 'For every binary rank-one idempotent collection with nonzero unit-free pattern span H, 2 dim(V) <= 3 dim(H). The total bound is sharp for each k. Irreducible action gives 2 dim(V) <= 3 dim(H)-1.', + 'small_image_basis_censuses': small, 'complete_width_three_pattern_census': pattern_census, + 'sharp_total_families': sharp, 'larger_circuit_controls': varied, + 'even_equality_controls': equality_controls, + 'prior_irreducible_seven_witness': {'pairs': seven, 'certificate': seven_certificate}, + 'hypothesis_controls': {'with_matrix_unit': {'n': 2, 'k': 1}, + 'without_idempotence': {'n': 2, 'k': 1}, + 'with_zero_pattern': {'n': 1, 'k': 0}}, + 'scope': 'The k=5 maximum is seven; coordinate classification of all attaining pools and paid-word consequences remain open.', + 'kappa_change': None} + + +def main(): + actual = json.loads(json.dumps(compute())) + expected = json.loads(Path(__file__).with_name('RESULT.json').read_text()) + require(actual == expected, 'receipt mismatch') + print('PASS_NO_EDGE_TOTAL_IMAGE_BOUND') + print(json.dumps({'small_collections': sum(x['counts']['collections'] for x in actual['small_image_basis_censuses']), + 'pattern_spaces': 2825, 'sharp_k_values': 12, + 'sharp_patterns': sum(x['patterns_checked'] for x in actual['sharp_total_families'])}, sort_keys=True)) + + +if __name__ == '__main__': + main()