diff --git a/docs/weird_machine_conservation_law.md b/docs/weird_machine_conservation_law.md index 59ad831f..370f8146 100644 --- a/docs/weird_machine_conservation_law.md +++ b/docs/weird_machine_conservation_law.md @@ -222,3 +222,91 @@ doesn't matter whether the tape is stored, computed, or given by physics. The sparse structure you target must be genuinely sparse (low-rank, k-sparse, RIP-compliant), not just "looked up from a big table." Look-up = base conversion = no gain. + +## SLOS Direction: What the Pipeline Actually Needs + +### The Two Computation Paths + +| Path | What it computes | Cost | Gives | +|------|-----------------|------|-------| +| SLOS (Perceval, K=2) | Full output distribution, all M_n states | O(n × M_n) | Exact Omega | +| QR/spectral (numpy, K=1) | Eigenvalue spectrum → first column of U | O(n³) | Approximate Omega | + +K=2 (SLOS) gives the correct Sidon vs non-Sidon signal (4/4). +K=1 (spectral) gave an INVERTED signal initially. + +### What Each Pipeline Query Actually Needs + +| Query | Needs SLOS? | Why | +|-------|-------------|-----| +| Omega (exhaust mode probabilities) | YES (K=2) | K=1 approximation was wrong | +| Sidon property check | NO | is_sidon() = pure integer arithmetic | +| GCCL coherence gate | NO | IS the eigenvalue spectrum | +| QR rank/spectrum | NO | O(n³) eigendecomposition | +| Collision count | NO | Integer pairwise-sum check | + +The pipeline runs SLOS to compute ONE number (Omega) from the +full M_n-state distribution. Everything else is computed without SLOS. + +### The Conservation Law Applied to SLOS + +The K=2 interference pattern IS the "residual" — the part the K=1 +spectrum can't predict. This is the same conservation law: + + K=1 spectrum (program/model) + K=2 interference (residual) = full distribution + +The spectrum captures the sparse structure (block-diagonal modes, +dominant eigenvalues). The K=2 interference captures the dense +correlations (photon-photon interactions, Hong-Ouandel interference). + +You can't predict Omega from the spectrum alone because Omega depends +on the K=2 interference — which IS the incompressible residual. + +### The Honest Application + +The shortcut for the SLOS direction is NOT "skip SLOS using the spectrum." +The shortcut is: **don't run SLOS for queries that don't need it.** + +- Sidon check: run is_sidon() (O(n²) integer arithmetic, no SLOS) +- GCCL gate: compute eigenvalue spectrum (O(n³), no SLOS) +- QR rank: compute eigenvalue spectrum (O(n³), no SLOS) +- Collision count: integer pairwise-sum check (O(n²), no SLOS) +- Omega: MUST run SLOS (K=2 interference is irreducible) + +The pipeline was running SLOS for ALL queries when only Omega needed it. +The shortcut: skip SLOS for 4/5 queries, run it only for Omega. + +### What This Saves + +For an n=8, m=8 system: +- Full SLOS: O(8 × 6435) = O(51,480) operations +- Skip SLOS for 4/5 queries: save 4 × 51,480 = 205,920 operations +- Only run SLOS for Omega: 51,480 operations (1/5 of before) + +This is a real 5x speedup — not from compression, but from not +running expensive quantum simulations for queries that only need +integer arithmetic or eigenvalue decomposition. + +### What This Does NOT Save + +The Omega computation itself still needs full SLOS (K=2). The K=2 +interference pattern is the irreducible residual. The conservation +law says: you can't predict it from the K=1 spectrum. The spectrum +is the model; the K=2 interference is the tape. Both must be computed. + +### The Quandela SLOS as "Weird Machine" + +The SLOS IS a weird machine: a photonic quantum simulator repurposed +as a Sidon set classifier. The "weirdness" is that a quantum optics +experiment (designed for photon counting) is being used to detect +combinatorial properties (Sidon sets) of integer sets. + +But the conservation law applies: the quantum computation (K=2 SLOS) +gives information that the classical computation (K=1 spectrum) can't +recover. This IS the quantum advantage — not in computation speed, +but in information content. The K=2 interference pattern contains +genuinely new information (the residual) that the K=1 spectrum lacks. + +This is the honest quantum advantage: SLOS computes something the +spectrum can't predict. Not because of quantum speedup, but because +the K=2 correlations are fundamentally denser than the K=1 spectrum.