Challenges
Datasets
Workspaces
Papers
Discussions
Leaderboard
Log inSign up
Challenges
Datasets
Workspaces
Papers
Discussions
Leaderboard
Blog
Job Board
Q3AS

© 2026 Aqora Quantum S.A.S.

TermsPrivacyLegal Notice

arXiv:1605.02756 · Physical Review A

Factoring with qutrits: Shor's algorithm on ternary and metaplectic quantum architectures

Alex Bocharov, Martin Roetteler, Krysta M. Svore

Published Jul 5, 2017• 114 citations
arXivHTMLPDF

Abstract

We determine the cost of performing Shor's algorithm for integer factorization on a ternary quantum computer, using two natural models of universal fault-tolerant computing: (i) a model based on magic state distillation that assumes the availability of the ternary Clifford gates, projective measurements, classical control as its natural instrumentation set; (ii) a model based on a metaplectic topological quantum computer (MTQC). A natural choice to implement Shor's algorithm on a ternary quantum computer is to translate the entire arithmetic into a ternary form. However, it is also possible to emulate the standard binary version of the algorithm by encoding each qubit in a three-level system. We compare the two approaches and analyze the complexity of implementing Shor's period-finding function in the two models. We also highlight the fact that the cost of achieving universality through magic states in MTQC architecture is asymptotically lower than in generic ternary case.

DOI
10.1103/physreva.96.012306

Related papers

Improved quantum ternary arithmetic

Alex Bocharov, Shawn Xingshan Cui, Martin Roetteler +1 more

Qutrit (or ternary) structures arise naturally in many quantum systems, notably in certain non-abelian anyon systems. We present efficient circuits for ternary reversible and quantum arithmetics. Our main result is the derivation of circuits for two families of ternary quantum adders. The main distinction from the binary adders is a richer ternary carry which leads potentially to higher resource counts in universal ternary bases. Our ternary ripple adder circuit has a circuit depth of O(n) and uses only 1 ancilla, making it more efficient in both, circuit depth and width, when compared with previous constructions. Our ternary carry lookahead circuit has a circuit depth of only O(log n), while using O(n) ancillas. Our approach works on two levels of abstraction: at the first level, descriptions of arithmetic circuits are given in terms of gates sequences that use various types of non-Clifford reflections. At the second level, we break down these reflections further by deriving them either from the two-qutrit Clifford gates and the non-Clifford gate C(X) : |i, ji 7→ |i, j + δi,2 mod 3i or from the two-qutrit Clifford gates and the non-Clifford gate P9 = diag(e −2π i/9 , 1, e 2π i/9 ). The two choices of elementary gate sets correspond to two possible mappings onto two different prospective quantum computing architectures which we call the metaplectic and the supermetaplectic basis, respectively. Finally, we develop a method to factor diagonal unitaries using multi-variate polynomials over the ternary finite field which allows to characterize classes of gates that can be implemented exactly over the supermetaplectic basis.

Quantum Information and Computation•Jul 1, 2016•9 citations

The true cost of factoring: Linking magic and number-theoretic complexity in Shor's algorithm

Alessio Paviglianiti, Matteo Seclì, Emanuele Tirrito +1 more

The execution cost of quantum algorithms is typically quantified through asymptotic gate counts and qubit register sizes, yet these metrics do not directly capture which genuinely quantum resources, and in what amount, must be created and maintained for the computation to succeed. The systematic quantification of such information-theoretic requirements in quantum computing protocols remains an extremely challenging open problem, despite their direct role in establishing quantum advantage. To address this gap, we investigate the generation of non-stabilizerness (or magic), one of the key resources, in the paradigmatic Shor's factoring algorithm, revealing a deep connection between intrinsic quantum complexity and the computational hardness of the underlying number-theoretic problem. By developing an explicit analytic theory, we demonstrate the fundamental role of magic in the successful execution of the algorithm, and show that Shor's routine maximally exploits the quantum resource in practically relevant regimes. Our findings create a concise conceptual link between the classical algorithmic difficulty of a task and the non-stabilizer price to solve it on quantum hardware, complementing standard circuit-cost analyses with a resource-based metric that is naturally aligned with the real bottlenecks of fault-tolerant quantum computing.

quant-pharXiv:2605.05347•May 8, 2026•0 citations

Improved Quantum Ternary Arithmetics

Alex Bocharov, Shawn Xingshan Cui, Martin Roetteler +1 more

Qutrit (or ternary) structures arise naturally in many quantum systems, particularly in certain non-abelian anyon systems. We present efficient circuits for ternary reversible and quantum arithmetics. Our main result is the derivation of circuits for two families of ternary quantum adders, namely ripple carry adders and carry look-ahead adders. The main difference to the binary case is the more complicated form of the ternary carry, which leads to higher resource counts for implementations over a universal ternary gate set. Our ternary ripple adder circuit has a circuit depth of $O(n)$ and uses only $1$ ancilla, making it more efficient in both, circuit depth and width than previous constructions. Our ternary carry lookahead circuit has a circuit depth of only $O(\log\,n)$, while using with $O(n)$ ancillas. Our approach works on two levels of abstraction: at the first level, descriptions of arithmetic circuits are given in terms of gates sequences that use various types of non-Clifford reflections. At the second level, we break down these reflections further by deriving them either from the two-qutrit Clifford gates and the non-Clifford gate $C(X): |i,j\rangle \mapsto |i, j + δ_{i,2} \mod 3\rangle$ or from the two-qutrit Clifford gates and the non-Clifford gate $P_9=\mbox{diag}(e^{-2 π\, i/9},1,e^{2 π\, i/9})$. The two choices of elementary gate sets correspond to two possible mappings onto two different prospective quantum computing architectures which we call the metaplectic and the supermetaplectic basis, respectively. Finally, we develop a method to factor diagonal unitaries using multi-variate polynomial over the ternary finite field which allows to characterize classes of gates that can be implemented exactly over the supermetaplectic basis.

arXiv:1512.03824•Dec 11, 2015•9 citations

An Evaluation of Computational Complexity of Shor’s Algorithm on Surface Codes for Factorization

Kento Oonishi, Noboru Kunihiro

Shor’s algorithm is a quantum algorithm that can efficiently solve the problems of integer factorization and discrete logarithms, which potentially break currently used public-key cryptosystems such as RSA and elliptic curve cryptography. However, a significant challenge in solving these problems is the noise inherent in quantum computers. Previous research advanced fault-tolerant techniques such as surface codes to mitigate this noise in quantum computers. Analyzing the security of currently used public-key cryptosystems on fault-tolerant quantum computers is essential. In this paper, we estimate the computational cost required to solve integer factorization using Shor’s algorithm on surface codes. We evaluated computational resources required for surface codes and magic state distillation and derived the computational cost of Shor’s algorithm based on these evaluations. Our computational complexity analysis indicates that there is no significant difference in the order of complexity. However, it underscores the paramount importance of optimizing the coefficient part for future efficiency improvements.

IEEE Access•Jan 1, 2026•2 citations

Implementation of ternary Shor’s algorithm based on vibrational states of an ion in anharmonic potential

Wei Liu, Shuming Chen, Jian Zhang +3 more

It is widely believed that Shor’s factoring algorithm provides a driving force to boost the quantum computing research. However, a serious obstacle to its binary implementation is the large number of quantum gates. Non-binary quantum computing is an efficient way to reduce the required number of elemental gates. Here, we propose optimization schemes for Shor’s algorithm implementation and take a ternary version for factorizing 21 as an example. The optimized factorization is achieved by a two-qutrit quantum circuit, which consists of only two single qutrit gates and one ternary controlled-NOT gate. This two-qutrit quantum circuit is then encoded into the nine lower vibrational states of an ion trapped in a weakly anharmonic potential. Optimal control theory (OCT) is employed to derive the manipulation electric field for transferring the encoded states. The ternary Shor’s algorithm can be implemented in one single step. Numerical simulation results show that the accuracy of the state transformations is about 0.9919.

Chinese Physics B•Feb 26, 2015•2 citations

Quantum Integer Factorization by 3 Different Methods, Their Implementations and Results

Jiří Tomčala

The content of this poster is a description of the implementation of two well-known quantum integer factorization methods and, in addition, a proposal of a new, third way along with some examples of its use. For all three methods, the measured results of their circuits will be shown.The first method is Shor's algorithm, where a quantum circuit is used only to find the period of a specially assembled modular exponentiating function. The rest of the algorithm is preprocessing and postprocessing that can be done on a classical computer, so one could say that this is a hybrid algorithm. New results of the successful factorization of the number 119, performed by this algorithm on a real 7-qubit quantum computer, will be presented. It is worth mentioning here that the highest number successfully factorized by this algorithm on a real quantum computer so far was 35.The second method is variational quantum factorization (VQF). In this method, preprocessing builds a system of equations based on the classical binary multiplication procedure of two numbers, resulting in a factorized number. This system of equations is then used to form a Hamiltonian in such a way that its ground state corresponds to the solution of this equation system. Only now the hybrid quantum optimization comes into play to iteratively find this ground state. The advantage over Shor's algorithm is that this method does not require a fault-tolerant quantum computer, but on the other hand it approaches the solution iteratively using a classical computer, which reduces the potential quantum advantage.The new, third method employs Grover's search algorithm in an unusual way to create a quantum factorization circuit. A key part of this approach is the quantum implementation of a multiplying oracle. The main advantage of this method over the previous ones is that it can be used to assemble a relatively simple universal factorization circuit. Moreover, there is almost no preprocessing and postprocessing required. This method is still under development, but this poster will present the first results.

•Dec 18, 2025•0 citations
We determine the cost of performing Shor's algorithm for integer factorization on a ternary quantum computer, using two natural models of universal fault-tolerant computing: (i) a model based on magic state distillation that assumes the availability of the ternary Clifford gates, projective measurements, classical control as its natural instrumentation set; (ii) a model based on a metaplectic topological quantum computer (MTQC). A natural choice to implement Shor's algorithm on a ternary quantum computer is to translate the entire arithmetic into a ternary form. However, it is also possible to emulate the standard binary version of the algorithm by encoding each qubit in a three-level system. We compare the two approaches and analyze the complexity of implementing Shor's period-finding function in the two models. We also highlight the fact that the cost of achieving universality through magic states in MTQC architecture is asymptotically lower than in generic ternary case.
Qutrit (or ternary) structures arise naturally in many quantum systems, notably in certain non-abelian anyon systems. We present efficient circuits for ternary reversible and quantum arithmetics. Our main result is the derivation of circuits for two families of ternary quantum adders. The main distinction from the binary adders is a richer ternary carry which leads potentially to higher resource counts in universal ternary bases. Our ternary ripple adder circuit has a circuit depth of O(n) and uses only 1 ancilla, making it more efficient in both, circuit depth and width, when compared with previous constructions. Our ternary carry lookahead circuit has a circuit depth of only O(log n), while using O(n) ancillas. Our approach works on two levels of abstraction: at the first level, descriptions of arithmetic circuits are given in terms of gates sequences that use various types of non-Clifford reflections. At the second level, we break down these reflections further by deriving them either from the two-qutrit Clifford gates and the non-Clifford gate C(X) : |i, ji 7→ |i, j + δi,2 mod 3i or from the two-qutrit Clifford gates and the non-Clifford gate P9 = diag(e −2π i/9 , 1, e 2π i/9 ). The two choices of elementary gate sets correspond to two possible mappings onto two different prospective quantum computing architectures which we call the metaplectic and the supermetaplectic basis, respectively. Finally, we develop a method to factor diagonal unitaries using multi-variate polynomials over the ternary finite field which allows to characterize classes of gates that can be implemented exactly over the supermetaplectic basis.
The execution cost of quantum algorithms is typically quantified through asymptotic gate counts and qubit register sizes, yet these metrics do not directly capture which genuinely quantum resources, and in what amount, must be created and maintained for the computation to succeed. The systematic quantification of such information-theoretic requirements in quantum computing protocols remains an extremely challenging open problem, despite their direct role in establishing quantum advantage. To address this gap, we investigate the generation of non-stabilizerness (or magic), one of the key resources, in the paradigmatic Shor's factoring algorithm, revealing a deep connection between intrinsic quantum complexity and the computational hardness of the underlying number-theoretic problem. By developing an explicit analytic theory, we demonstrate the fundamental role of magic in the successful execution of the algorithm, and show that Shor's routine maximally exploits the quantum resource in practically relevant regimes. Our findings create a concise conceptual link between the classical algorithmic difficulty of a task and the non-stabilizer price to solve it on quantum hardware, complementing standard circuit-cost analyses with a resource-based metric that is naturally aligned with the real bottlenecks of fault-tolerant quantum computing.
Qutrit (or ternary) structures arise naturally in many quantum systems, particularly in certain non-abelian anyon systems. We present efficient circuits for ternary reversible and quantum arithmetics. Our main result is the derivation of circuits for two families of ternary quantum adders, namely ripple carry adders and carry look-ahead adders. The main difference to the binary case is the more complicated form of the ternary carry, which leads to higher resource counts for implementations over a universal ternary gate set. Our ternary ripple adder circuit has a circuit depth of O(n)O(n)O(n) and uses only 111 ancilla, making it more efficient in both, circuit depth and width than previous constructions. Our ternary carry lookahead circuit has a circuit depth of only O(log⁡ n)O(\log\,n)O(logn), while using with O(n)O(n)O(n) ancillas. Our approach works on two levels of abstraction: at the first level, descriptions of arithmetic circuits are given in terms of gates sequences that use various types of non-Clifford reflections. At the second level, we break down these reflections further by deriving them either from the two-qutrit Clifford gates and the non-Clifford gate C(X):∣i,j⟩↦∣i,j+δi,2mod  3⟩C(X): |i,j\rangle \mapsto |i, j + δ_{i,2} \mod 3\rangleC(X):∣i,j⟩↦∣i,j+δi,2​mod3⟩ or from the two-qutrit Clifford gates and the non-Clifford gate $P_9=\mbox{diag}(e^{-2 π\, i/9},1,e^{2 π\, i/9})$. The two choices of elementary gate sets correspond to two possible mappings onto two different prospective quantum computing architectures which we call the metaplectic and the supermetaplectic basis, respectively. Finally, we develop a method to factor diagonal unitaries using multi-variate polynomial over the ternary finite field which allows to characterize classes of gates that can be implemented exactly over the supermetaplectic basis.
Shor’s algorithm is a quantum algorithm that can efficiently solve the problems of integer factorization and discrete logarithms, which potentially break currently used public-key cryptosystems such as RSA and elliptic curve cryptography. However, a significant challenge in solving these problems is the noise inherent in quantum computers. Previous research advanced fault-tolerant techniques such as surface codes to mitigate this noise in quantum computers. Analyzing the security of currently used public-key cryptosystems on fault-tolerant quantum computers is essential. In this paper, we estimate the computational cost required to solve integer factorization using Shor’s algorithm on surface codes. We evaluated computational resources required for surface codes and magic state distillation and derived the computational cost of Shor’s algorithm based on these evaluations. Our computational complexity analysis indicates that there is no significant difference in the order of complexity. However, it underscores the paramount importance of optimizing the coefficient part for future efficiency improvements.
It is widely believed that Shor’s factoring algorithm provides a driving force to boost the quantum computing research. However, a serious obstacle to its binary implementation is the large number of quantum gates. Non-binary quantum computing is an efficient way to reduce the required number of elemental gates. Here, we propose optimization schemes for Shor’s algorithm implementation and take a ternary version for factorizing 21 as an example. The optimized factorization is achieved by a two-qutrit quantum circuit, which consists of only two single qutrit gates and one ternary controlled-NOT gate. This two-qutrit quantum circuit is then encoded into the nine lower vibrational states of an ion trapped in a weakly anharmonic potential. Optimal control theory (OCT) is employed to derive the manipulation electric field for transferring the encoded states. The ternary Shor’s algorithm can be implemented in one single step. Numerical simulation results show that the accuracy of the state transformations is about 0.9919.
The content of this poster is a description of the implementation of two well-known quantum integer factorization methods and, in addition, a proposal of a new, third way along with some examples of its use. For all three methods, the measured results of their circuits will be shown.The first method is Shor's algorithm, where a quantum circuit is used only to find the period of a specially assembled modular exponentiating function. The rest of the algorithm is preprocessing and postprocessing that can be done on a classical computer, so one could say that this is a hybrid algorithm. New results of the successful factorization of the number 119, performed by this algorithm on a real 7-qubit quantum computer, will be presented. It is worth mentioning here that the highest number successfully factorized by this algorithm on a real quantum computer so far was 35.The second method is variational quantum factorization (VQF). In this method, preprocessing builds a system of equations based on the classical binary multiplication procedure of two numbers, resulting in a factorized number. This system of equations is then used to form a Hamiltonian in such a way that its ground state corresponds to the solution of this equation system. Only now the hybrid quantum optimization comes into play to iteratively find this ground state. The advantage over Shor's algorithm is that this method does not require a fault-tolerant quantum computer, but on the other hand it approaches the solution iteratively using a classical computer, which reduces the potential quantum advantage.The new, third method employs Grover's search algorithm in an unusual way to create a quantum factorization circuit. A key part of this approach is the quantum implementation of a multiplying oracle. The main advantage of this method over the previous ones is that it can be used to assemble a relatively simple universal factorization circuit. Moreover, there is almost no preprocessing and postprocessing required. This method is still under development, but this poster will present the first results.