Architecture & Methodology¶
Patent notice: The underlying methods are covered by pending patent applications.
Overview¶
This repository implements and validates quantum error suppression via post-selection conditioning on Bell-pair subsystems. The approach uses mid-circuit measurements to monitor subsystem fidelity and applies decision rules to accept or reject quantum computation outcomes — thereby suppressing errors without full quantum error correction.
Core Concept¶
┌─────────────────────────────────────────────────────────┐
│ Quantum Circuit │
│ │
│ ┌──────────┐ ┌───────────┐ ┌─────────────┐ │
│ │ Bell-pair │──▶│ Scramble │──▶│ Mid-circuit │──┐ │
│ │ prep ×N │ │ layers ×D │ │ Z-parity │ │ │
│ └──────────┘ └───────────┘ │ measure │ │ │
│ └─────────────┘ │ │
│ ▼ │ │
│ ┌───────────────┐ │ │
│ │ Conditioning │◀──┘ │
│ │ Decision Rule │ │
│ └───────┬───────┘ │
│ │ │
│ ┌────────┴────────┐ │
│ │ │ │
│ ACCEPT REJECT │
│ (keep shot) (discard shot) │
└─────────────────────────────────────────────────────────┘
Bell-Pair Subsystems¶
Each subsystem is a 2-qubit Bell pair \((\lvert00\rangle + \lvert11\rangle)/\sqrt{2}\). Under noise, the pair's parity may flip. Mid-circuit Z-parity measurements detect these flips without collapsing the computational state.
Multi-Rate Monitoring¶
- HF (high-frequency): Z-parity measured every monitoring cycle
- LF (low-frequency): Z-parity measured every 2nd cycle (0, 2, 4, …)
- The two rates provide complementary signal: LF captures slow drift, HF catches fast errors
Conditioning Strategies¶
1. Global Conditioning¶
All N subsystems must pass all W monitoring cycles.
Limitation
Exponential decay with N — unusable at N ≥ 2 under real noise.
2. Hierarchical k-of-N Conditioning¶
Accept if at least ⌈k·N⌉ subsystems pass each cycle:
Advantage
O(1) scaling — maintains high acceptance from N = 1 to N = 64.
3. Score Fusion Conditioning¶
Continuous metric combining LF and HF scores:
Accept if \(S_{\text{combined}} \ge \theta\).
Advantage
Soft decision boundary absorbs noise spikes that break logical (hard) fusion. The most robust strategy on real IBM hardware.
Simulation Backends¶
QuTiP (Master-Equation Simulation)¶
The simulation module models a driven qubit with pure dephasing:
Fidelity is computed as \(F(t) = \langle\psi_0\lvert\rho(t)\lvert\psi_0\rangle\) and evaluated within a trailing time window.
Qiskit (IBM Quantum Hardware)¶
Dynamic circuits with mid-circuit measurements on real IBM processors. Bell pairs are prepared, scrambled with random rotations, and measured via ancilla-based Z-parity checks with reset and reuse.
Project Structure¶
qgate-shots-filter/
├── packages/
│ └── qgate/ # Pip-installable developer toolkit
│ ├── src/qgate/ # Core library (conditioning + monitors)
│ │ └── adapters/ # Mock, Qiskit, Grover, QAOA, VQE, QPE
│ ├── tests/ # 376 unit tests
│ └── pyproject.toml # Build configuration
│
├── simulations/
│ ├── qutip_sims/ # QuTiP master-equation simulations
│ ├── ibm_hardware/ # IBM Quantum conditioning experiments
│ ├── grover_tsvf/ # Grover vs TSVF-Grover (IBM Fez)
│ ├── qaoa_tsvf/ # QAOA vs TSVF-QAOA MaxCut (IBM Torino)
│ ├── vqe_tsvf/ # VQE vs TSVF-VQE TFIM (IBM Fez)
│ └── qpe_tsvf/ # QPE vs TSVF-QPE Phase Est. (IBM Fez)
│
├── examples/ # Usage examples
├── docs/ # Documentation
└── src/sim.py # Core QuTiP simulation engine
Validation Chain¶
The research follows a progression from theory to hardware:
QuTiP Simulations IBM Quantum Hardware
═══════════════════ ════════════════════════
1. High-noise sweep ──▶ 5. IBM Marrakesh experiment
(300 configs, 405K (120 rows, 5000 shots each,
trials) ≈ 6 min on real hardware)
│
2. k-of-N follow-up ──▶ Both confirm:
(216 configs, N=1-32) • Global collapses at N≥2
• Hierarchical scales to N=64
3. Incremental N=64 • Score fusion is most robust
(6 new configs) on real hardware
│
4. Multi-frequency sweep ──▶ Score fusion absorbs HF noise
(54 configs, 3 variants) that destroys logical fusion
Empirical Validation¶
| Result | Evidence |
|---|---|
| Global conditioning collapses exponentially | High-noise sweep: 0% acceptance at N ≥ 2 |
| Hierarchical conditioning scales O(1) | Follow-up + incremental: 100% acceptance N = 1–64 |
| Multi-rate monitoring improves detection | Multi-freq sweep: score fusion at γ = 10 |
| Score fusion outperforms logical fusion | Multi-freq: 50% vs 0% acceptance at extreme noise |
| Hardware validation on IBM Quantum | IBM Marrakesh: score fusion best on real device |
TSVF Algorithm Extensions¶
Beyond Bell-pair conditioning, qgate extends trajectory filtering to canonical quantum algorithms via the TSVF (Two-State Vector Formalism) approach. See Hardware Experiments for full results.
| Algorithm | Backend | Advantage |
|---|---|---|
| Grover | IBM Fez | 7.3× at iteration 4 |
| QAOA | IBM Torino | 1.88× at p=1 |
| VQE | IBM Fez | 1.86× closer (barren plateau avoidance) |
| QPE | IBM Fez | N/A (phase-coherence incompatible) |