Repository navigation
Releases: Hashevolution/shor
Release list
v0.5.1 — Marker-set coding-theory + oracle/T-cost + JAMES-DISCOVER (D3)
Release notes — v0.5.1 (2026-06-19)
DOI: pending (Zenodo upon release)
Summary
v0.5.1 extends the magic (nonstabilizerness) direction of v0.5.0 (DOI
10.5281/zenodo.20725965) with a
coding-theory of marker sets, an oracle-hiding = T-cost identification with a
fault-tolerant resource estimate, and — most importantly — a full-text prior-art audit of all
four code↔magic literatures that led us to honestly credit the flat-state closed form to prior
work. The order-finding results (Theorems 1–6) are unchanged; the magic direction is now
integrated into the canonical paper.md as §9.
What's new
Coding-theory of marker sets (Props 4, 5, 5′)
For a flat marker state $|{\rm flat}W\rangle=|W|^{-1/2}\sum{x\in W}|x\rangle$:
-
Prop 4 (closed form = additive energy):
$M_2=-\log_2\big(M^{-4}\sum_x E(W\cap(W{\oplus}x))\big)$ ,$E$ = additive energy. Reduces to$0$ for
$M=1$ and affine$W$ ; exact zero-test$M_2=0\iff A_W\in{0,M}$ . Credited to prior work (see below). -
Prop 5 (Sidon law): generic (Sidon) marker sets give
$M_2=\log_2\frac{M^3}{7M-6}\to 2\log_2M-\log_27$ . -
Prop 5′ (exact random expectation):
$\mathbb E[\xi]M^4=(7M^2-6M)+\frac{7(M)_4}{N-3}+\frac{N(N-1)(N-2)(N-4)(M)_8}{(N)_8}$ (closed form
vs Monte Carlo$\le1.4\times10^{-2}$ ). -
Metric correction: minimum Hamming distance does not determine magic (
${0,1,2,3}$ vs
${0,1,2,4}$ : same$d_{\min}=1$ ,$M_2=0$ vs$1.54$ ).
Oracle-hiding = T-cost (Prop 6) + FTQC estimate
-
$M_2(|\psi_f\rangle)>0\iff f$ nonlinear (degree-$\ge2$ ANF)$\iff U_f$ needs non-Clifford ($T$ )
gates; all zero iff$f$ affine. -
FTQC concretization (
oracle_ftqc_estimate.py): degree-$d$ monomial$\to(2d{-}3)$ Toffolis
$\to7T$ (or$4T$ ).$T_{\rm est}=0\iff M_2=0$ ; Shor modexp ANF-synthesis upper bound$N{=}15\to4$
Toffolis$\sim N{=}35\to4171$ .
Grover ladder (carried from v0.5.0, now in paper.md §9)
Simon
Honest novelty audit (the headline of this release)
We obtained and full-text compared the four nearest code↔magic literatures:
| group | prior work | verdict |
|---|---|---|
| (D) flat/SMF SRE closed form | Tarabunga–Castelnovo, Quantum 8, 1347 (2024), Eq. 8 | Prop 4 is its uniform-support specialization — credited, not new |
| (B) hypergraph-state magic | Chen–Yan–Zhou (Quantum 8, 1351); Kagamihara–Tsuchiya (2602.23687) | phase-encoded / RM(2) ≠ our support / RM(1) — differentiated |
| (A) weight-enumerator SRE | Quantum Lego (2308.05152) | tensor-network SRE tool, not marker-set coding-theory |
| (C) Dicke/permutation-invariant | Passarelli–Fazio–Lucignano (2402.08551) | symmetric-support only |
Also: the "$2\log_2 M$" growth is the saturation of the standard bound
magic↔period law is Paviglianiti et al. (2605.05347). Surviving defensible novelty: the Grover
3-bit ladder, the coding-theoretic specialization (zero-test, exact Sidon constant, exact random
expectation,
What changed
New files
-
experiments/marker_code_magic.py— autocorrelation/$\tau$ indicator,$d_{\min}$ refutation. -
experiments/marker_code_closed_form.py— Prop 4 (additive energy), Prop 5 (Sidon law). -
experiments/marker_code_expected.py— Prop 5′ (exact$\mathbb E[\xi]$ ). -
experiments/oracle_tcount_magic.py— Prop 6 (state magic ⟺ oracle$T$ -cost). -
experiments/oracle_ftqc_estimate.py— Prop 6 FTQC$T$ -count estimate (honest upper bound). -
magic-paper-draft.md— standalone draft (contributions box + practical implications). -
magic-program-overview.md— integrated overview + M1–M5 roadmap. -
HISTORY.md,HISTORY-쉬운설명.md,M5-쉬운설명.md— chronology + lay explanations.
Updated
magic-results.md— Props 4, 5, 5′, 6 (with prior-work credits).magic-prior-art.md— §5c: full-text audit of (A)(B)(C)(D), novelty table, citations.paper.md— new §9 "Companion direction: magic across the speedup ladder" + abstract pointer +
references [15]–[22];paper.texremains frozen at v0.2.1. §9 also includes the D3 finding
paragraph (asymptotic tightness of Prop 5′, see below).
Added late in v0.5.1 (post-initial-draft, before Zenodo mint): JAMES-DISCOVER + D3
-
ai-discovery-engine-design.md— design + feasibility review for an automated discovery loop
(Generator → Probe → Miner → Adversary → Promoter) layered on the existing magic infrastructure.
numpy-only; no LLM in the core loop (kept as optional D3+ extension). -
experiments/discover_poc.py— D1 sanity gate. Re-discovers the Sidon constant
$M_2=\log_2(M^3/(7M-6))$ and the additive-energy closed form (Props 4/5) from scratch. -
experiments/discover_d3_jensen.py— D3 result, closing one of v0.5.1's listed open items.
Defines the Jensen gap$J(M,N):=\mathbb E[M_2]+\log_2\mathbb E[\xi]\ge 0$ (Prop 5′ closes only
$\mathbb E[\xi]$ , leaving$J$ uncontrolled) and finds$J\propto 1/N$ in the sparse regime
$M^2\ll N$ (measured slope$-0.96$ across$M\in{6,8,10}$ ,$n\in{10,\dots,13}$ ). Consequence:
$-\log_2\mathbb E[\xi]$ is not merely a Jensen lower bound but an asymptotically tight estimate
of$\mathbb E[M_2]$ , with absolute error$O(1/N)$ . Also records the saturation boundary
$M^2/N\to 1$ where the$1/N$ law breaks (additive-collision saturation), and reports
$\kappa(M):=J\cdot N$ as having no simple closed form in the elementary dictionary
${M,M^2,M(M-1),M^3,M\log_2 M,1}$ — kept as an open sub-question rather than over-fit.
Verification
- Regression suite
magic_proofs_check.py: 42 assertions pass. - SRE tool cross-checked to
$10^{-15}$ ; closed forms (Props 4/5/5′) verified to$\le1.4\times10^{-2}$
(Monte Carlo) /$10^{-15}$ (deterministic).
What this is NOT
- Not a new quantum speedup, algorithm, or cryptographic result.
- Not a production FTQC estimator —
oracle_ftqc_estimate.pyis an explicit upper bound (arithmetic
oracles are far cheaper via windowed synthesis; cf. Gidney–Ekerå 2021). - Prop 4's closed form is not claimed as new (credited to Tarabunga–Castelnovo).
Honest scope / remaining
- (A) full-text checked for 2308.05152 only; the distillation refs (2510.10852, 1702.06990,
2501.10163) are distillation-side and do not affect our claims. -
Open: the(D3 partial closure: in the sparse regime$M^2\gtrsim N$ regime of$\mathbb E[\xi]$ is exact in closed form but its asymptotics are
characterized only to leading order.$M^2\ll N$ ,
Prop 5′ is shown asymptotically tight with absolute error$O(1/N)$ . The$M^2/N\to 1$ saturation
boundary remains open, and the prefactor$\kappa(M)=J\cdot N$ remains open in closed form.)
Citing
Cite v0.5.1 for the marker-set coding-theory + oracle/T-cost, alongside v0.5.0 (magic direction +
ladder) and the order-finding releases (v0.2.1 theorems, v0.4.0 Theorem 6). Prior work credited
in-text: Tarabunga–Castelnovo (Quantum 8, 1347), Paviglianiti et al. (2605.05347),
Leone–Oliviero–Hamma (PRL 128, 050402).
v0.5.0 — Magic (nonstabilizerness) across quantum speedups
Release notes — v0.5.0 (2026-06-17)
DOI: minted by Zenodo on release (backfilled after archival).
Summary
v0.5.0 is a new-direction release on top of v0.4.0 (DOI 10.5281/zenodo.20688069): nonstabilizerness ("magic") across quantum speedups. It leaves the order-finding theorems (T1–T6) unchanged and adds a measured + proven account of how the type of quantum speedup is tied to the amount/density of magic, directly on this repo's statevector simulation.
Key result — the speedup ladder
| Algorithm | Speedup | M₂ behaviour | Density M₂/n |
|---|---|---|---|
| Simon / BV | exponential (query) | 0 (affine oracle = Clifford) | 0 |
| Grover | quadratic | peak → 3 bits, 0 at the answer | → 0 |
| Shor (comb) | exponential | ∝ t (grows) | ~0.4–0.55 |
| Shor (in-circuit) | exponential | → L (maximal) | → 1 |
The amount/density of nonstabilizerness separates the type of speedup. Magic lives not on the circuit surface but in the nonlinearity of the problem, and a black box (oracle / FFT) can hide it.
Propositions (magic-results.md)
- Lemma 1. A flat (uniform-amplitude, equal-phase) state has
M₂ = 0 ⟺ its support is an 𝔽₂-affine subspace. - Corollary 1. Graph state
(1/√N)Σ|x⟩|f(x)⟩hasM₂ = 0 ⟺ f is affine. ⟹ Simon is solvable with a linear (Clifford) oracle, soM₂ ≡ 0despite an exponential query speedup; Shor'saˣ mod Nis nonlinear, so the oracle forces magic — formalizing oracle-hiding. - Propositions 2–3. Closed form for the single-marked Grover state; its peak
−log₂(a⁸+(1−a²)⁴)is maximized ata²=1/2, giving exactly 3 bits, with densityM₂/n → 0. - Proposition 2′ (general M).
|ψ⟩ = b√N|+⟩ⁿ + (a−b)|W̃⟩: affine marked set W ⟹ bounded magic (superposition of two stabilizers); non-affine W ⟹ extra magic from the marked-set state itself. - Correction. "comb magic = 0 ⟺ period is a power of two" is almost true; the exact criterion is Lemma 1 (affine support), with accidental exceptions (e.g. t=10, r=33).
What changed
New files
magic.py— stabilizer 2-Rényi entropy tool (XOR-FWHT, exact O(n·4ⁿ)).experiments/grover_magic.py— Grover magic trajectory, peak saturation, general M.experiments/shor_comb_magic.py— comb magic, corrected T1, self-contained Shor contrast.experiments/oracle_magic.py— oracle-hiding (affine ⟺ M₂=0).experiments/magic_proofs_check.py— proposition regression checker (42 assertions).magic-results.md(propositions + proofs),magic-쉬운설명.md(elementary-level explanation),magic-and-quantum-speedup.md(research note),magic-prior-art.md(prior-art survey + DOI review).
Verification
- The SRE tool is cross-checked against three independent implementations (XOR-FWHT ↔ Pauli-permutation ↔ kron matrices) agreeing to 10⁻¹⁵.
- Bound 0 ≤ M₂ ≤ n confirmed. The proposition checker's 42 assertions all pass.
- Peak convergence: n=10 → 2.815, 20 → 2.994, 30 → 3.000.
- Reproduce:
python -u -m experiments.magic_proofs_check(fast), and eachpython -u -m experiments.<name>.
Relation to prior work (full-text / journal-side review)
- arXiv:2605.05347 (Paviglianiti et al.): Shor magic ↔ period — cited as the preempting result. Still a preprint (pre-peer-review), so the novelty window stays open.
- Quantum-walk magic (published nearest neighbours): Phys. Rev. Research 10.1103/7rwg-lhpv (2506.17783), Phys. Rev. B 113, 075142 (2026) 10.1103/nzrp-49mr (2504.19750) — both 1D-lattice transport, so they do not treat Grover / complete-graph / search (verified in full text). Grover's 3-bit saturation fills that gap.
- Algorithm-magic comparisons (2505.17185, 2507.16543): variational / QFT circuits, not the Grover·Simon·Shor ladder.
Scope / limits
- The Prop 2–3 closed form is for a single marked item (M=1); general affine M has guaranteed boundedness via Prop 2′ but no explicit closed form yet.
- Comb magic is a property of the post-measurement marginal, distinct from the in-circuit
→ L(2605.05347). - This release does not change the order-finding results (T1–T6) — magic is an additional direction.
Citing
Cite v0.5.0 for the magic results alongside v0.4.0 (Theorem 6) and v0.3.0 (closed-form framework). The Zenodo DOI is backfilled into CITATION.cff / README.md after archival.
v0.4.0 — Theorem 6 SR no-go + cryptographic N-scaling
Release notes — v0.4.0 (2026-06-14)
DOI: minted by Zenodo on release (backfilled after archival).
Summary
v0.4.0 is a formalization + honesty release on top of v0.3.0 (DOI
10.5281/zenodo.20685015).
It adds Theorem 6, a sign-agnostic no-go result that closes the
stochastic-resonance (SR) factoring question raised in §3.6, backs it with a
cryptographic-regime N-scaling measurement, and downgrades the Yang-Markidis
positioning from "analytical complement / gap-filling" to the honest
"numerical verification + boundary mapping."
What changed
Theorem 6 — SR no-go (paper §3.3.ter, new)
For any noise in the coherence-loss class (★), g(ε) = (1−ε)·g_0 + ε·g_∞
with 0 < g_0, g_∞ ≤ 1, without assuming the sign of g_0 − g_∞:
- No tuned resonance.
E[K(ε)]is monotone inε; the optimum sits at an
endpoint, never an interiorε*. There is no noise level to "tune into." - Closed-form swing.
|ΔK| = E[K_λ^ideal] · |1/g_∞ − 1/g_0|, fixed by the
two endpoint probabilities alone, independent of the σ-profile. - No asymptotic advantage. If the reciprocal gap is
O(1), the swing is
O(log log N)— a constant multiplicative factor, never a speedup.
The earlier draft wrongly assumed g_∞ ≤ g_0 ("noise always hurts"). Live
N-scaling data falsified that: the smallest-order setup at each N is a genuine
positive-SR cell (g_∞ > g_0). Theorem 6 is therefore stated sign-agnostically.
N-scaling measurement (paper §3.6.bis, new table)
|Δ| = |p_0 − ρ| over 12 setups (3 per N, 300–1,000 MC samples,
shor_n_scaling.py):
| N | mean p_0 | mean ρ | mean |Δ| | min |Δ| | max |Δ| |
|---|---|---|---|---|---|
| 437 | 0.741 | 0.410 | 0.446 | 0.173 | 0.607 |
| 1147 | 0.443 | 0.402 | 0.211 | 0.118 | 0.260 |
| 2491 | 0.486 | 0.287 | 0.372 | 0.260 | 0.483 |
| 4087 | 0.476 | 0.390 | 0.259 | 0.220 | 0.297 |
Across a 9× range in N the gap stays in [0.12, 0.61] with no monotone growth
toward 1 — the empirical regularity behind Theorem 6's O(1) reciprocal-gap
assumption. The result is reproducible to the digit under fixed seeds.
Honest reframing of Yang-Markidis positioning
- Their two-stage model is their Eq. (3), §5; the mixing weight
εis a
conceptual parameter ("total weight transferred out of the intended
family"), left unspecified — neither fitted nor given asε(σ). Full text
(incl. appendix) verified 2026-06-14. - The
exp(−σ²)decay is the standard dephasing result (Nielsen–Chuang §8.3).
We claim no new mechanism. Our contribution is narrow and verificational:
(i) verify their qualitative weight equals the standard-dephasing factor
(R²=0.95 at N=437); (ii) map the boundary (breaks for amplitude damping,
R²=0.03); (iii) confirm across five algorithm classes. - README / arxiv_draft / sr_sigma_curve_model wording corrected accordingly.
- We do not position this as filling an analytical gap they could not close.
Canonical source declaration
paper.mdis now the single canonical source of truth.paper.texis deprecated / frozen at v0.2.1 — to be regenerated wholesale
frompaper.mdonly at arXiv-submission time (banner added; see
compile-notes.md).
Retained (unchanged)
- Theorems 1–5 and all raw measurement data.
- The v0.3.0 closed-form σ-curve and five-algorithm verification.
- The conclusion that SR-based factoring acceleration is precluded — now
formalized as Theorem 6 rather than asserted.
What this is NOT
- Not a new quantum advantage, not a new mechanism.
- Not an unconditional impossibility result — Theorem 6 is a no-go within the
framework and under its measured regularities (see its "Scope and honest
caveats").
Citing
If you use this work, cite v0.4.0 for Theorem 6 + N-scaling + honest framing,
alongside v0.3.0 (closed-form framework) and v0.2.1 (theorems 1–5 + raw data):
@misc{shor_v0_4_0,
title = {A noise-invariant determinism theorem for multi-base post-processing
in Shor's order finding (v0.4.0, Theorem 6 SR no-go)},
author = {{Hashevolution}},
year = {2026},
doi = {10.5281/zenodo.XXXXXXXX},
url = {https://doi.org/10.5281/zenodo.XXXXXXXX},
note = {v0.4.0 adds Theorem 6 and N-scaling to v0.3.0
(10.5281/zenodo.20685015)}
}
(DOI backfilled once Zenodo archives the release.)
v0.3.0: closed-form sigma-curve + 5-algorithm verification + 3.6 self-correction
v0.3.0 — closed-form σ-curve framework + §3.6 self-correction (2026-06-14)
Errata + extension of v0.2.1 (DOI 10.5281/zenodo.20681847).
Summary
The §3.6 boundary-flip + universal direction stochasticity + plateau/overload framework of v0.2.1 is replaced by a single closed form derived from standard phase-noise dephasing of the FFT:
p(σ) = ρ + (p_0 - ρ) · exp(-σ²)
E[K(σ)] = (1 - (1-p)^M) / p
derived from E[|FFT(a·e^{iε})_k|²] = (1-e^{-σ²})/Q + e^{-σ²}·P_0(k).
Cross-algorithm verification (5 classes)
| Algorithm | R² |
|---|---|
| Grover (k iter) | +0.88 |
| Shor pure (b-trick) | +0.95 |
| QPE isolated (no b-trick) | +0.96 |
| Simon (Hadamard + XOR) | +0.99 |
| Hybrid (C)+b-trick (paper §3.6 setup) | +0.91 |
Positioning
Analytical complement to Yang-Markidis (arXiv:2605.16074, ICS Workshops '26) — their empirical noise-propagation model (1-ε)·P_s + ε·distractors has the same structural form; we provide the analytical foundation ε = 1 - exp(-σ²).
Self-correction (§3.6.bis in paper.md)
Retracted within §3.6:
- "Boundary flip" lexicon as a distinct mechanism.
- "Deterministic flip set within plateau" reading (statistical, not structural).
- "Universal direction stochasticity" as unexplainable —
sign(p_0 - ρ)explains it.
Retained:
- All 31,200 raw K-measurements.
- 5/5 regime-map cross-cell predictions.
- The conclusion that SR-based factoring acceleration is precluded (now with closed-form bound).
- Theorems 1–5 (independent of §3.6).
What this is NOT
- Not a new mechanism (exp(-σ²) is standard dephasing).
- Not a refutation of v0.2.1 — data retained, only §3.6 interpretation corrected.
What this IS
- Honest scientific cycle: claim → cross-verification → self-correction.
- Small bridge: Shor-class SR claims ↔ standard dephasing literature.
- Cross-algorithm organizing result.
Citation
Cite both v0.2.1 (theorems 1-5 + raw data) and v0.3.0 (§3.6 self-correction + closed-form framework).
Related work
- Yang-Markidis (arXiv:2605.16074) — empirical recoverability via ML features.
- Tight success bounds (arXiv:2506.20527) — noise-free bounds.
- Coherence/decoherence in noisy Shor (arXiv:2508.11962) — lower bounds.
Files
paper.md§3.6.bis (self-correction)sr_sigma_curve_model.md(unified framework)sr_generalization.md(SR generalization scoping)release_notes_v0.3.0.mdarxiv_draft.md(short paper draft, ICS Workshops '27 target)experiments/{grover,shor,qpe_isolated,simon,hybrid,shor_n_scaling}_*.py
Companion code
numpy + Python stdlib only. ~3,500 LOC added in this release. Total compute for all 5 R² fits ~1 CPU-hour on 2025 laptop.
python -m experiments.grover_sigma_curve_model # R²=0.88
python -m experiments.shor_sigma_curve_model # R²=0.95
python -m experiments.qpe_isolated_sigma # R²=0.96
python -m experiments.simon_sigma_curve # R²=0.99
python -m experiments.hybrid_sigma_curve # R²=0.91v0.2.1 - Regime map 5/5 validated + Universal direction stochasticity
v0.2.1 — Regime map empirically validated (5/5 measured) + Universal direction stochasticity
Date: 2026-06-14
This patch release validates the Algorithm-structure regime map from v0.2.0 through direct measurement of all five entries, including new measurements of Pure Shor SR, Pure Regev SR with a faithful LLL implementation, (2491, 2) cross-cell verification, and (1147, 2) extended scan. A new main finding emerges: universal direction stochasticity across algorithm structures.
What's new
★ Algorithm-structure regime map (5/5 measured)
All five entries are now empirically measured:
| Algorithm structure | Per-seed |SR| | Mean SR | K_base | Source |
|---|---|---|---|---|
| Single-base Shor (1994) | 0–1.10% | −0.04% (3+/2−) | 10.38 | measured (5 seeds × 100 trials × 3 σ) |
| Multi-base Regev (LLL) | 1.27–3.95% | −0.31% (2+/3−) | 2.44 | measured (5 seeds × 50 trials × 3 σ, faithful LLL) |
| Hybrid full at (437, 4) | 0–1.93% | +0.14% (8+/5−) | 1.82 | measured (13 seeds × 200 trials × 12 σ) |
| Hybrid mild-thinned | 4.03–4.44% | −1.43% (1+/2−) | 2.92 | measured (3 seeds × 100 trials × 3 σ) |
| Hybrid over-thinned | 0% | 0% | 19.87 | measured (3 seeds × 100 trials × 3 σ) |
★ Universal direction stochasticity across algorithm structures
The 5-algorithm regime map measurement reveals an unexpected unifying pattern: cross-seed direction is base-set-stochastic (not algorithm-determined) in every tested algorithm structure. Mean SR magnitudes are all small (|mean SR| ≤ 1.5%) and none reach statistical significance at our sample sizes. The regime map's original directional predictions (Shor "small", Regev "negative") are qualitatively confirmed but with smaller magnitudes than the naive "LLL is fragile" picture suggested.
Pure Shor σ-scan (regime map verification)
Single-base Shor (d = 1, no (C) accumulation) at N = 437:
- K_baseline = 10.38 (~50% trials reach max_runs = 20, dominated by failed b-trick conditions)
- Mean SR at σ = 0.050: −0.04% (sd 0.85%, SE 0.38%, t = −0.11, p ≈ 0.46)
- Per-seed |SR| range: 0–1.10%
- Sign test: 3 positive / 2 negative
→ Regime map prediction "Shor: small SR" confirmed.
Pure Regev σ-scan (faithful LLL implementation)
Implementation: self-contained LLL reduction (δ = 0.75), Regev-style (d+1)-dimensional embedding lattice, multi-S scaling (S ∈ {Q, Q/2, 2Q}), enumerated short vector search (basis + small linear combinations), multi-measurement accumulation over K runs.
Results at N = 437, d = 4:
- K_baseline = 2.44 (matches c ≥ 1/2 from Lemma 5.1 — implementation is faithful)
- Mean SR at σ = 0.050: −0.31% (sd 2.91%, SE 1.30%, t = −0.24, p ≈ 0.60)
- Per-seed |SR| range: 1.27–3.95%
- Sign test: 2 positive / 3 negative
→ Regime map prediction "Regev: negative SR" qualitatively confirmed (weakly negative direction), but smaller magnitude than the simple "LLL is fragile" picture.
Caveat: Our LLL implementation does not use BKZ reduction or the exact lattice basis from Regev (2023/JACM 2025) Algorithm B.1. A full Regev implementation might show different per-seed magnitudes, but the qualitative direction-stochasticity finding should persist.
Cross-cell verification at (2491, 2) — outlier regression confirmed ★
5 seeds × 100 trials × 5 σ at (N, d) = (2491, 2) with K_baseline ≈ 2.30:
- Per-seed SR (σ=0.05): [+2.67%, -3.38%, -7.43%, +2.16%, +7.48%]
- Mean SR = +0.30% (sd 5.79%, SE 2.59%, t = 0.12, p = 0.45)
- Sign test: 3 positive / 2 negative
- The earlier single-seed measurement of −4.89% regresses to small mean, confirming the "single-seed outliers regress under multi-seed" claim.
(1147, 2) extended scan (seeds 2, 3, 6 × 7 σ × 100 trials)
Additional measurements at (1147, 2):
- Seeds 2, 3 reproduce exactly from compact scan (deterministic per seed): seed 3 again shows +9.44% high-K rescue (K=15→K=5, K=11→K=5, K=20→K=6)
- New seed 6 (K_base=3.04): +2.63% with wide plateau (σ=0.025–0.150 all identical K)
- 6-seed combined mean SR at σ=0.050: +3.23% (sd 4.82, SE 1.97, t = 1.64, p ≈ 0.08)
Reproducibility (new scripts)
python -m experiments.pure_shor_sr # Pure Shor SR (regime map verification)
python -m experiments.pure_regev_sr # Pure Regev SR (faithful LLL v2)
python -m experiments.sigma_scan_general 2491 2 5 100 minimal # (2491, 2) cross-cell
python -m experiments.sigma_scan_N1147_d2_extended # (1147, 2) extended (seeds 2, 3, 6 × 7 σ)
New data files:
experiments/pure_shor_sr_results.txt+_histograms.txtexperiments/pure_regev_sr_results.txt+_histograms.txtexperiments/sigma_scan_N2491_d2_minimal_results.txt+_histograms.txtexperiments/sigma_scan_N1147_d2_extended_results.txt+_histograms.txt
Unchanged from v0.2.0
- Theorems 1–5 (paper §3.1–3.5) with proofs and empirical verification
- Lemma 5.1 (per-
bnontrivial-sqrt probability ≥ 1/2 for any semiprime) - 17,700 measurements across 6 composite sizes verifying Theorem 1
- §3.6 multi-boundary mechanism observation foundation (13 seeds at (437, 4))
- 6 retractions of v0.1.0 → v0.2.0 claims
What's not in this release
- BKZ-based Regev implementation (LLL only)
- Hardware verification on real quantum devices
- Theoretical proof of universal direction stochasticity (currently empirical observation)
Refined understanding
The combination of all measurements suggests a refined picture:
Noise-as-resource in quantum factoring is a mechanism-level phenomenon (K-bin boundary flips) that operates across all multi-base algorithm structures with stochastic direction. The differences between algorithms are in per-seed magnitude distribution rather than systematic direction bias.
This is a STRONGER finding than the original regime map: rather than "different algorithms have different SR magnitudes/directions", the unifying observation is "direction is universally stochastic, magnitude varies by algorithm structure".
How to cite
Hashevolution. (2026). A Noise-Invariant Determinism Theorem for Multi-Base
Post-Processing in Shor's Order Finding (Version 0.2.1). Zenodo.
https://doi.org/10.5281/zenodo.20679807
See CITATION.cff (GitHub will auto-format BibTeX from this file).
License
MIT (see LICENSE)
Companion code
~1,500 lines of numpy. No quantum libraries required. Verified on Python 3.13.
🤖 Generated with Claude Code
v0.2.0 - Multi-boundary mechanism + amplification + regime map
v0.2.0 — Multi-boundary mechanism observation
Date: 2026-06-13
This release upgrades the §3.6 stochastic-resonance observation from a single-cell "Goldilocks" framing to a universal trial-level mechanism observation based on 13-seed × 12-σ high-statistics measurement at (N, d) = (437, 4).
The main theoretical contribution — Theorems 1–5 on noise-invariant determinism, logarithmic coverage time, exact noise scaling, conditional Regev compatibility, and a hybrid (C) + Regev b-trick factoring algorithm — is unchanged. The mechanism observation has been substantially deepened.
What's new
§3.6 — Universal trial-level boundary-flip mechanism
- 13 independent base sets × 200 trials × 12 σ values = 31,200 trial-measurements at (N, d) = (437, 4)
- 13/13 seeds exhibit boundary-flip mechanism — universal at the base-set level
- K-bin boundary distribution: 76.9% K=1/K=2, 15.4% K=2/K=3, 7.7% K=3↔K=1 long-jump
- σ-curve direction asymmetry identified: positive-direction seeds saturate + decline, negative-direction seeds monotonically worsen (consequence of K-distribution skew at this cell)
- Direction independence from K_baseline: seeds with identical K_baseline = 1.720 can show opposite SR directions, confirming that direction is determined by base-set-specific K-distribution structure, not by aggregate K_mean
- Mechanism follows the classical Benzi–Buchleitner stochastic resonance shape: sub-threshold + saturation plateau + overload decline
- Cross-cell verification: ceiling cells (4) and noise-floor cell (1, multi-seed) and active-boundary cell (1, multi-seed) are all consistent with regime predictions
★ Mechanism diversification at higher K_baseline (new — (1147, 2))
A 5-seed σ-scan at (N, d) = (1147, 2) with K_baseline ≈ 2.92 reveals a richer mechanism than the K = 1 / K = 2 boundary flip at (437, 4):
- High-K rescue ★ : trials at very high K bins (K = 8, 11, 15, even K = 20) move to moderate K bins (K = 4, 5) under noise (seed 3: K = 15 → K = 5, SR = +9.44%; seed 4: 3 × (K = 8 → K = 4), SR = +8.56%)
- Per-seed |SR| amplifies with K_baseline: max +9.44% at (1147, 2) vs +1.93% at (437, 4)
- Boundary distribution shifts: only 40% K = 1 / K = 2 at (1147, 2) vs 77% at (437, 4); the remainder includes K = 8 → K = 4, K = 15 → K = 5, etc.
- Cross-seed mean: +3.35% (sd 5.37, SE 2.40, t = 1.39, p ≈ 0.12 with t-distribution / 0.082 normal approx) — borderline at 5-seed sample, dominated by high-K-rescue seeds
★ Engineered amplification — (C) augmentation as a noise buffer
Two thinned variants of the hybrid test the structural prediction that SR magnitude is bounded by the borderline-trial population:
- Over-thinned (smallest convergent only + no (C)): K_baseline = 19.87 (9.55× sub-functional), SR = 0.00% — sub-functional alone does not amplify (no borderlines left)
- Mild thinned (all convergents + no (C) augmentation): K_baseline = 2.92 (1.4× sub-functional), per-seed |SR| amplifies to 4.03–4.44% (~5× larger than full hybrid)
The (C) augmentation acts as a noise buffer: its removal exposes the underlying boundary-flip mechanism in amplified form, while leaving the direction stochastic.
★ Algorithm-structure regime map for noise-as-resource (testable conjecture)
| Algorithm structure | SR magnitude | Source |
|---|---|---|
| Single-base Shor (1994) | small (≤ 1%) | predicted |
| Multi-base Regev (LLL) | negative SR | predicted |
| Hybrid full (this work) | +0.14% at (437, 4) | measured |
| Hybrid mild-thinned | ~5× amplified | measured |
| Hybrid over-thinned | zero | measured |
The regime map predicts that noise-as-resource in quantum factoring is naturally maximized in a multi-base + per-coordinate independent recovery + no buffer variant. Standalone Shor and Regev predictions remain testable with the same protocol; we leave their verification to follow-up work.
Statistical caveat
- Net SR direction across 13 seeds at (437, 4): mean = +0.144%, t = 0.51, p = 0.31 — not statistically significant
- Sign test: 8/13 positive (p = 0.29)
- The mechanism is universal; the net direction is base-set-stochastic at our sample size
- (1147, 2) 5-seed mean +3.35% (p ≈ 0.12 t-dist / 0.082 normal approx) is marginal; high-K-rescue seeds dominate
Retractions
Six earlier claims have been retracted with explicit footnotes:
- 17.86% peak at (1147, 2, σ=0.01) — single-seed direction fluctuation
- Polynomial scaling SR ∝ N^α — rejected when N=2491 cells gave near-zero or negative SR
- σ_opt ∝ N^α ("small lock, small wiggle" intuition) — rejected by σ-scan finding σ_opt ≈ 0.010 independent of N
- Anti-Optimization Principle (d=1 universal positive SR) — undermined by multi-seed re-measurement at (1147, 1) giving −0.53% ± 4.28%
- V3 sign-test p = 0.03 as significance — invalid because σ values within the saturation plateau are perfectly correlated (same boundary trials flip in all)
- Goldilocks single-cell robust — refined: K_baseline ≈ 2 marks the regime where mechanism is detectable, but direction is stochastic, not systematically positive
Reproducibility
New scripts to reproduce §3.6 results:
python -m experiments.sigma_scan_437 # (437, 4) baseline σ-scan (3 seeds × 12 σ × 200 trials)
python -m experiments.sigma_scan_437_extend # (437, 4) extended seeds 4-13 + K-histogram backfill
python -m experiments.analyze_histograms # per-seed K-bin flip identification
python -m experiments.sigma_scan_general 1147 2 5 100 compact # (1147, 2) cross-cell σ-scan
python -m experiments.sr_amplification # over-thinned (null amplification result)
python -m experiments.sr_mild_amplification # mild thinned (5× amplification)
Raw measurement data is committed:
experiments/sigma_scan_437_d4_results.txt— K_mean at (437, 4)experiments/sigma_scan_437_d4_extended.txt— extended seeds K_meanexperiments/sigma_scan_437_d4_histograms.txt— per-seed K-histograms at (437, 4)experiments/sigma_scan_N1147_d2_compact_results.txt— (1147, 2) K_meanexperiments/sigma_scan_N1147_d2_compact_histograms.txt— (1147, 2) K-histogramsexperiments/sr_mild_amplification_results.txt— mild thinned amplification data
All scripts are resumable (immediate per-cell save, skip-existing on re-run).
Unchanged from v0.1.0
- Theorems 1–5 (paper §3.1–3.5) with proofs and empirical verification
- Lemma 5.1 (per-
bnontrivial-sqrt probability ≥ 1/2 for any semiprime) - 17,700 measurements across 6 composite sizes verifying Theorem 1
- Cross-cell verification of Theorem 5 hybrid algorithm at N ∈ {437, 1147, 2491, 4087}
- Hardware-calibrated noise simulation (Appendix E)
Connection to noise-as-resource literature
The mechanism we identify is the discrete analog of stochastic resonance in continuous systems. It provides the first explicit, mechanism-level bridge between integer factoring quantum algorithms and the noise-as-resource paradigm (Benzi et al. 1981 on classical SR; Wellens–Buchleitner 2004 on quantum SR; Plenio–Huelga 2008 on ENAQT).
The effect magnitude (1–7 trial flips per 200 trials, ±0.3–2% K change per seed, no statistically significant cross-seed net direction) is too small to enable cryptographic advantage; the contribution is conceptual.
Open questions / future work (v0.3 candidates)
- Direction bias at larger sample sizes (30+ seeds) — would a small net positive bias emerge?
- Active-boundary determinants at the base-set level — what predicts which K-boundary flips?
- Extended (1147, 2) verification — script
sigma_scan_N1147_d2_extended.py(3 seeds × 7 σ × 100 trials, ~2 hours) tests high-K rescue universality at seeds 2, 3, 6 - Algorithm-structure regime map verification — measure SR at standalone Shor and Regev with LLL post-processing; confirms or refines the predictions in §3.6
- Universality across N — verification at (1147, 3), (4087, 4) at V3-style scale
- Long-jump events — true noise-induced trajectory divergence or cascade through adjacent boundaries?
- Hardware verification — survives structured (non-iid) phase noise?
How to cite
See CITATION.cff (GitHub will auto-format BibTeX from this file).
Hashevolution. (2026). A Noise-Invariant Determinism Theorem for Multi-Base
Post-Processing in Shor's Order Finding (Version 0.2.0). Zenodo.
https://doi.org/[TO BE ADDED]
License
MIT (see LICENSE)
Companion code
~1,000 lines of numpy. No quantum libraries required. Verified on Python 3.13.
Acknowledgements
This work benefited from extensive iteration: initial single-seed observations gave way to multi-seed validations that overturned several over-claims (see Retractions above). The published narrative reflects the corrections, not the original mistakes.
🤖 Generated with Claude Code