[Paper Review] Factoring with n+2 clean qubits and n-1 dirty qubits
This paper presents a reversible classical circuit design that reduces the number of clean qubits required for Shor’s integer factorization algorithm from 1.5n + O(1) to n + 2 by leveraging n−1 dirty qubits (qubits in unknown states that must be restored). The approach uses optimized arithmetic operations—such as modular addition and scaling—implemented with minimal clean ancillae, achieving the same asymptotic circuit depth and size while enabling significant qubit savings under space-constrained quantum architectures.
We present reversible classical circuits for performing various arithmetic operations aided by dirty ancillae (i.e. extra qubits in an unknown state that must be restored before the circuit ends). We improve the number of clean qubits needed to factor an n-bit number with Shor's algorithm from 1.5n+O(1) to n+2, assisted by n-1 dirty qubits, without increasing the asymptotic size or depth of the circuit.
Motivation & Objective
- Reduce the number of clean qubits required for Shor’s algorithm from 1.5n + O(1) to n + 2.
- Demonstrate that dirty ancillae can be used effectively to replace clean ancillae in reversible arithmetic circuits.
- Explore the theoretical implications of minimizing clean qubit count as a design metric, even if it increases gate count or depth.
- Enable more compact implementations of period-finding in Shor’s algorithm under tight qubit space constraints.
- Provide a foundation for future constructions aiming at n + O(1) total qubit usage in Shor’s algorithm.
Proposed method
- Design reversible classical circuits for modular arithmetic operations (e.g., modular addition, offset operations) using only n+2 clean qubits and n−1 dirty qubits.
- Implement arithmetic operations via controlled decomposition, using pivot flipping and toggle controlling to manage control logic efficiently.
- Use commutator controlling techniques to restructure control dependencies, enabling reuse of ancilla qubits across subroutines.
- Construct modular multiplication as a sequence of scaled modular additions, each implemented with minimal clean ancillae and relying on available dirty qubits.
- Apply circuit diagram conventions with explicit labeling of clean and dirty ancilla requirements (e.g., triangles with "3 dirty"), ensuring traceability of resource usage.
- Use two’s complement representation and modular arithmetic modulo 2^n to simplify circuit design, assuming all operations wrap within n-bit registers.
Experimental results
Research questions
- RQ1Can the number of clean qubits required for Shor’s algorithm be reduced below 1.5n + O(1) by utilizing dirty ancillae?
- RQ2What are the trade-offs in circuit depth and gate count when replacing clean ancillae with dirty ones in reversible arithmetic circuits?
- RQ3How can modular multiplication be decomposed into smaller operations that require fewer clean qubits but still use available dirty qubits?
- RQ4What circuit techniques enable efficient use of dirty qubits without increasing the asymptotic complexity of the overall algorithm?
- RQ5Is it possible to achieve n + O(1) total qubit usage in Shor’s algorithm through strategic use of dirty ancillae and modular decomposition?
Key findings
- The number of clean qubits required to factor an n-bit number using Shor’s algorithm is reduced from 1.5n + O(1) to n + 2, using n−1 dirty qubits.
- The asymptotic circuit depth and size remain unchanged compared to prior constructions, preserving scalability despite increased ancilla management complexity.
- The construction uses only two or fewer dirty ancillae per arithmetic operation, except for modular multiplication, which requires more but still operates within the n−1 dirty qubit limit.
- The overall circuit uses 2n + 1 qubits: 1 for phase estimation, n for the work register, and n for ancillae used in modular multiplication.
- The method demonstrates that dirty ancillae can be used effectively in reversible arithmetic, enabling compact circuit designs under tight space constraints.
- Future improvements such as the Chinese remainder theorem or commutator control could further reduce ancilla usage, though they are not applied here due to circular dependency in factorization.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.