Quantum Backtracking in Qrisp Applied to Sudoku Problems
Open Access
- 11 July 2026
- journal article
- Published by Association for Computing Machinery (ACM) in ACM Transactions on Quantum Computing
- Vol. 7 (3) , 1-32
Abstract
The quantum backtracking algorithm proposed by Ashley Montanaro raised considerable interest, as it provides a quantum speed-up for a large class of classical optimization algorithms. It does not suffer from Barren-Plateaus, that affect variational quantum algorithms, and transfers well into the fault-tolerant era, as it requires only a limited number of arbitrary angle gates. Despite its potential, the algorithm has seen limited implementation efforts, presumably due to its abstract formulation. In this work, we provide a detailed instruction on implementing the quantum step operator for arbitrary backtracking instances. For a single controlled diffuser of a binary backtracking tree with depth n , our implementation requires only 6 n +14 CX gates. We detail the process of constructing accept and reject oracles for Sudoku problems using our interface to quantum backtracking. The presented code is written using Qrisp, a high-level quantum programming language, making it executable on most current physical backends and simulators. Subsequently, we perform several simulator based experiments and demonstrate solving 4× 4 Sudoku instances with up to nine empty fields. This is, to the best of our knowledge, the first instance of a compilable implementation of this generality, marking a significant and exciting step forward in quantum software engineering.Keywords
All Related Versions
Funding Information
- Bundesministerium für Wirtschaft und Klimaschutz (01MQ22007A)
- European Commission (101092702)
This publication has 37 references indexed in Scilit:
- Uncomputation in the Qrisp High-Level Quantum Programming Framework2023
- Automatic generation of Grover quantum oracles for arbitrary data structuresQuantum Science and Technology, 2023
- Efficient Constructions for Simulating Multi Controlled Quantum Gates2022
- Local, expressive, quantum-number-preserving VQE ansätze for fermionic systemsNew Journal of Physics, 2021
- t|ket⟩: a retargetable compiler for NISQ devicesQuantum Science and Technology, 2020
- Practical Implementation of a Quantum Backtracking Algorithm2020
- On the controlled-NOT complexity of controlled-NOT–phase circuitsQuantum Science and Technology, 2018
- Quantum speedup of the traveling-salesman problem for bounded-degree graphsPhysical Review A, 2017
- Faster than classical quantum algorithm for dense formulas of exact satisfiability and occupation problemsNew Journal of Physics, 2016
- Advantages of using relative-phase Toffoli gates with an application to multiple control Toffoli optimizationPhysical Review A, 2016