Sparse quantum state preparation with improved Toffoli cost
Felix Rupprecht, Sabine Wölk
TL;DR
The paper tackles sparse quantum state preparation on $n$ qubits with $s$ nonzero amplitudes, a task whose fault-tolerant cost is dominated by Toffoli gates. It proposes a two-step approach: first prepare a dense state in a $\lceil\log(s)\rceil$-qubit subspace, then apply an isometry to map to the target sparse state, with a batched, batched unary-iteration-based isometry that replaces many multi-controlled-X gates. The main theoretical contribution is a tight worst-case Toffoli bound for the isometry, $\left\lceil \frac{s}{m} \right\rceil \left(2m + \frac{1}{2}\log\left(\frac{\tilde{s}}{m}\right) - 3\right) + \log\left(\frac{\tilde{s}^2}{m}\right)$, together with an ancilla budget of $\lceil\log(s)\rceil - 1$, where $m$ is the largest power of two not exceeding $n - \lceil\log(s)\rceil$ and $\tilde{s}=2^{\lceil\log(s)\rceil}$. The authors implement and analyze a classical algorithm to construct the isometry and demonstrate substantial empirical savings, including potential real-state optimizations, and discuss density-prep trade-offs via QROM/QROAM loading. Overall, the work provides the most resource-efficient sparse-state preparation circuits to date, with practical open-source tooling and clear pathways to further reductions in Toffoli cost for fault-tolerant quantum computing.
Abstract
The preparation of quantum states is one of the most fundamental tasks in quantum computing, and a key primitive in many quantum algorithms. Of particular interest to areas such as quantum simulation and linear-system solvers are sparse quantum states, which contain only a small number $s$ of non-zero computational basis states compared to a generic state. In this work, we present an approach that prepares $s$-sparse states on $n$ qubits, reducing the number of Toffoli gates required compared to prior art. We work in the established framework of first preparing a dense state on a $\lceil{\log(s)}\rceil$-qubit sub-register, and then mapping this state to the target state via an isometry, with the latter step dominating the cost of the full algorithm. The speed-up is achieved by designing an efficient algorithm for finding and implementing the isometry. The worst-case Toffoli cost of our isometry circuit, which may be viewed as a batched version of an approach by Malvetti et al., is essentially $2s$ for sufficiently large values of $n$, yielding roughly a $\log(s)/2$ improvement factor over the state-of-the-art. In numerical benchmarks on randomly chosen states, the cost is closer to $s$. With the improved isometry circuit, we examine the dense-state preparation step and present ways to optimize the joint cost of both steps, particularly in the case of target states with purely real coefficients, by outsourcing some sub-tasks from the dense-state preparation to the isometry.
