From e17980b2457bd1815d8ff37c0a3e2f47878f2ef6 Mon Sep 17 00:00:00 2001 From: Nick Petalas Date: Tue, 27 Oct 2026 11:22:07 +0000 Subject: [PATCH] feat(research): prove transported coframe optimization is NP-hard --- .../transported-coframe-hardness/PROOF.md | 156 +++++++++++ .../transported-coframe-hardness/README.md | 110 ++++++++ .../transported-coframe-hardness/SOURCES.json | 30 +++ .../transported-coframe-hardness/TASK.json | 86 +++++++ .../transported-coframe-hardness/VERIFY.json | 32 +++ .../transported-coframe-hardness/verify.py | 242 ++++++++++++++++++ 6 files changed, 656 insertions(+) create mode 100644 research/transported-coframe-hardness/PROOF.md create mode 100644 research/transported-coframe-hardness/README.md create mode 100644 research/transported-coframe-hardness/SOURCES.json create mode 100644 research/transported-coframe-hardness/TASK.json create mode 100644 research/transported-coframe-hardness/VERIFY.json create mode 100644 research/transported-coframe-hardness/verify.py diff --git a/research/transported-coframe-hardness/PROOF.md b/research/transported-coframe-hardness/PROOF.md new file mode 100644 index 0000000000..d46202e3f7 --- /dev/null +++ b/research/transported-coframe-hardness/PROOF.md @@ -0,0 +1,156 @@ +# A one-axis hardness obstruction for transported coframe optimization + +This scoped proof and construction were produced by Nick Petalas. Apache-2.0. + +## Statement and cost model + +For a fixed finite logical linear program, choose one coframe from a supplied +two-element menu at each field. Conjugate each logical instruction by the +chosen coframes. Charge the Gaussian rank power `r^t` of every resulting +transition, including entrance and exit adapters, with `0^t=0` and `0=1` vertices and +`m` edges. Each vertex is a distinct arbitrary main input in a two-coordinate +payload field. Orient each edge from its smaller vertex to its larger vertex. +Set `M=2n+1`. In lexicographic edge order, execute the logical shear +`z_v += F z_u` exactly `M` times per edge. This defines a fixed invertible +logical program `P_G`, independently of any coframe assignment. + +For a chosen vector `x`, apply `F^x_v` once on entrance to each field. Replace +each shear response by the literal `K(x_u,x_v)` above. On exit apply `F^-x_v` +to every field. At every instruction the physical field is `F^x_v` times its +logical field. Substitution proves this invariant and the fixed final endpoint +`P_G` by induction on chronology. In particular, every main input is arbitrary +and independent; none is silently zeroed or identified with another input. + +For the rank accounting, the source-preserving implementation of a response +shear is the ordinary owned copy, transform, add and clear construction of +#5693, coframe-cut.md. Here the transform is exactly one rank-one axis or the +explicit ordinary monomial map. Its ordinary work and storage remain separate +from the rank moment. The construction's correctness also follows directly +from the block shear matrix and does not need an optimizer's certificate. + +All main charts at the external boundary are identity. Both adapter charges +are retained. The endpoint, and hence any declared productive credit, is the +same for every `x`. A parent-grade legality rule can use any parent grade at +least two; all positive children have rank one. No actual selected recursive +caller or productive supplier is asserted here. + +## Recovery of Simple Max Cut + +Write `c_G(x)` for the number of graph edges whose endpoint bits differ, and +`|x|` for the number of one bits. The complete rank bill of the constructed +word is exactly + +```text +B_G(x) = M (m-c_G(x)) + 2|x|. +``` + +Every rank is zero or one, so raising ranks to `t` changes no term. There are +no other Gaussian transitions in this declared word. + +Let `c*` be the maximum cut size, and let `s*` be the smallest number of one +bits among assignments attaining `c*`. Since `0<=2|x|<=2n= k iff min_x B_G(x) <= M(m-k)+2n. +``` + +The forward implication uses a cut of size at least `k`. For the converse, +every assignment with `c_G(x)<=k-1` has bill at least `M(m-k+1)`, strictly +larger than the displayed threshold. This proves a many-one reduction of the +Simple Max Cut decision problem, whose NP-completeness is due to Garey, +Johnson and Stockmeyer. The emitted word has `M m` shears and at most `2n` +adapters, hence polynomial length. A bit assignment lets a verifier compute +its integer bill in polynomial time. This proves the stated hardness and +NP-completeness. No power comparison, numerical tolerance or algebraic-number +oracle occurs in this reduction. + +For `G=K3`, `M=7`, `c*=2`, and `s*=1`, so the minimum bill is nine. Dropping +both adapters would incorrectly give seven; dropping one gives eight. These +are different objectives. For `G=K5`, the minimum bill is 48. + +## Attribution, consequence and limits + +Ali Romman's [#5783](https://github.com/CrocSwap/integer-mult-bounds/pull/5783) +provides the exact submodular binary-table solver and explicitly leaves +unsupported pair laws outside it. David Ganz's +[#5693](https://github.com/CrocSwap/integer-mult-bounds/pull/5693), retained in +`research/joint-gaussian-coframe-search`, supplies the coframe-conjugation, +fixed-transport and signed-switching framework. Those results are cited as +predecessors. Their verifiers and actual source instances are not replayed. +The new step is this explicit one-axis reduction, with fixed main boundaries, +both adapter charges, phase-exact matrices and a common integer objective for +the full power interval. + +Classical complexity input: M. R. Garey, D. S. Johnson and L. Stockmeyer, +[Some simplified NP-complete graph problems](https://doi.org/10.1016/0304-3975(76)90059-1), +Theoretical Computer Science 1, 1976, 237-267, Simple Max Cut. Fourier Clifford +identities and graph-cut/signed-switching facts retain their classical credit. +No worldwide novelty is asserted for those components. + +The consequence is a worst-case obstruction to a polynomial exact extension +covering all transported binary menus, unless P=NP. Special source structure, +small exceptional deletion sets and branch-specific cuts remain valid routes. +The rank-one family here is deliberately constructed and does not establish +that any retained supplier has a hard optimization instance. It also gives no +runtime lower bound for executing its fixed linear map, no claim against +resynthesis of repeated shears, no complete paid physical invoice, no new +kappa and no change to the selected frontier. Formal proof-kernel and +independent human review remain unclaimed. diff --git a/research/transported-coframe-hardness/README.md b/research/transported-coframe-hardness/README.md new file mode 100644 index 0000000000..f9a8d76c67 --- /dev/null +++ b/research/transported-coframe-hardness/README.md @@ -0,0 +1,110 @@ +# One-axis transported coframe optimization is NP-hard + +This contribution was produced by Nick Petalas. Apache-2.0. + +## Result and scope + +**Claim type: scoped mathematical proof, with exact finite corroboration.** +The rank-moment optimization problem for transported binary coframe choices +can encode Simple Max Cut. The reduction uses one Gaussian axis per field, +the identical two-choice menu everywhere, rank-zero/rank-one transitions, +fixed external main charts, and both entrance and exit adapter charges. +Its constructed-family decision problem is NP-complete. All power tariffs +`r^t`, `0 largest_cut: + largest_cut, max_cut_small_side = crossing, sum(bits) + elif crossing == largest_cut: + max_cut_small_side = min(max_cut_small_side, sum(bits)) + counts["assignments"] += 1 + require(best // (2 * n + 1) == len(edges) - largest_cut, + "The rank optimum does not recover the maximum cut") + require(best % (2 * n + 1) == 2 * max_cut_small_side, + "Boundary-charge remainder disagrees") + for threshold in range(len(edges) + 2): + bound = (2 * n + 1) * (len(edges) - threshold) + 2 * n + require((best <= bound) == (largest_cut >= threshold), + "Decision reduction disagrees") + counts["decision_thresholds"] += 1 + counts["graphs"] += 1 + if len(edges) == len(possible): + examples[f"K{n}"] = {"maximum_cut": largest_cut, + "minimum_rank_bill": best} + return counts, examples + + +def run_word(n, edges, bits, column, physical, bad_inverse=False, + discard_scalar=False): + """Literal Gaussian-rational action on one arbitrary-input basis column.""" + state = [[ZERO, ZERO] for _ in range(n)] + state[column // 2][column % 2] = ONE + inverse = FOURIER if bad_inverse else scale(I, FOURIER) + if physical: + for v in range(n): + if bits[v]: + state[v] = list(apply(FOURIER, state[v])) + for u, v in edges: + for _ in range(2 * n + 1): + response = tuple(state[u]) + if physical and bits[u]: + response = apply(scale(I, FOURIER), response) + response = apply(FOURIER, response) + if physical and bits[v]: + response = apply(FOURIER, response) + if discard_scalar and physical and bits[v] and not bits[u]: + response = tuple(state[u]) + state[v] = [add(state[v][j], response[j]) for j in range(2)] + if physical: + for v in range(n): + if bits[v]: + state[v] = list(apply(inverse, state[v])) + return state + + +def endpoint_census(): + counts = {"complete_word_columns": 0, "scalar_output_equalities": 0} + for n in range(1, 4): + possible = tuple(combinations(range(n), 2)) + for mask in range(1 << len(possible)): + edges = tuple(e for j, e in enumerate(possible) if mask & (1 << j)) + reference = tuple(run_word(n, edges, (0,) * n, j, False) + for j in range(2 * n)) + for bits in product(range(2), repeat=n): + for j in range(2 * n): + require(run_word(n, edges, bits, j, True) == reference[j], + "The complete phase-exact endpoint changed") + counts["complete_word_columns"] += 1 + counts["scalar_output_equalities"] += 2 * n + return counts + + +def rejection_controls(ranks, boundary): + invalid = ((True, ()), (0, ()), (6, ()), (2, ((0, 0),)), + (2, ((1, 0),)), (2, ((0, 2),)), + (3, ((0, 1), (0, 1)))) + for n, edges in invalid: + try: + validate_graph(n, edges) + except ValueError: + continue + raise ValueError("An invalid graph was accepted") + triangle = ((0, 1), (0, 2), (1, 2)) + choices = tuple(product(range(2), repeat=3)) + correct = min(rank_bill(3, triangle, b, ranks, boundary) for b in choices) + require(correct == 9, "Triangle optimum") + for altered in ((0, 0), (0, 1)): + require(min(rank_bill(3, triangle, b, ranks, altered) for b in choices) + != correct, "Missing adapter was invisible") + untwisted = ((0, 1), (1, 0)) + require(min(rank_bill(3, triangle, b, untwisted, boundary) + for b in choices) != correct, "Missing logical transport") + too_small = min(rank_bill(3, triangle, b, ranks, boundary, 1) for b in choices) + require(too_small // 1 != 1, "Insufficient replication was invisible") + require(run_word(1, (), (1,), 0, True, bad_inverse=True) + != run_word(1, (), (0,), 0, False), "Wrong inverse was invisible") + require(run_word(2, ((0, 1),), (0, 1), 0, True, discard_scalar=True) + != run_word(2, ((0, 1),), (0, 0), 0, False), + "Discarded scalar phase was invisible") + for b in choices: + require(sum(b[u] == b[v] for u, v in triangle) % 2 == 1, + "A frustrated triangle became switchable") + return {"invalid_graphs_rejected": len(invalid), + "hypothesis_mutants_detected": 6, "triangle_complements": 8} + + +def main(): + _, ranks, boundary = transitions() + counts, examples = small_graph_census(ranks, boundary) + counts.update(endpoint_census()) + counts.update(rejection_controls(ranks, boundary)) + package = Path(__file__).resolve().parent + names = ("README.md", "PROOF.md", "TASK.json", "SOURCES.json", + "VERIFY.json", "verify.py") + hashes = {name: sha256((package / name).read_bytes()).hexdigest() + for name in names} + print(json.dumps({"status": "PASS_TRANSPORTED_COFRAME_HARDNESS", + "counts": counts, "complete_graphs": examples, + "rank_table": ranks, "boundary_table": boundary, + "package_sha256": hashes}, indent=2, sort_keys=True)) + + +if __name__ == "__main__": + main()