Shor's algorithm
{{Short description|Quantum algorithm for integer factorization}}Shor's algorithm is a quantum algorithm for finding the prime factors of an integer. It was developed in 1994 by the American mathematician Peter Shor.{{cite book |doi=10.1109/sfcs.1994.365700 |chapter=Algorithms for quantum computation: Discrete logarithms and factoring |title=Proceedings 35th Annual Symposium on Foundations of Computer Science |date=1994 |last1=Shor |first1=P.W. |pages=124–134 |isbn=978-0-8186-6580-6 }}{{Cite journal |last=Shor |first=Peter W. |date=October 1997 |title=Polynomial-Time Algorithms for Prime Factorization and Discrete Logarithms on a Quantum Computer |journal=SIAM Journal on Computing |volume=26 |issue=5 |pages=1484–1509 |arxiv=quant-ph/9508027 |doi=10.1137/S0097539795293172 |s2cid=2337707 }} It is one of the few known quantum algorithms with compelling potential applications and strong evidence of superpolynomial speedup compared to best known classical (non-quantum) algorithms. On the other hand, factoring numbers of practical significance requires far more qubits than available in the near future.{{cite journal|arxiv=1905.09749| title =
How to factor 2048 bit RSA integers in 8 hours using 20 million noisy qubits |
first1 = Craig | last1 = Gidney | first2 = Martin | last2 = Ekerå| journal=Quantum | year=2021 | volume=5 | page=433 | doi=10.22331/q-2021-04-15-433 | bibcode =
2021Quant...5..433G | s2cid=162183806 }}
Another concern is that noise in quantum circuits may undermine results, requiring additional qubits for quantum error correction.
Shor proposed multiple similar algorithms for solving the factoring problem, the discrete logarithm problem, and the period-finding problem. "Shor's algorithm" usually refers to the factoring algorithm, but may refer to any of the three algorithms. The discrete logarithm algorithm and the factoring algorithm are instances of the period-finding algorithm, and all three are instances of the hidden subgroup problem.
On a quantum computer, to factor an integer , Shor's algorithm runs in polynomial time, meaning the time taken is polynomial in .See also pseudo-polynomial time. It takes quantum gates of order using fast multiplication,{{cite journal |last1=Beckman |first1=David |last2=Chari |first2=Amalavoyal N. |last3=Devabhaktuni |first3=Srikrishna |last4=Preskill |first4=John |title=Efficient networks for quantum factoring |journal=Physical Review A |date=August 1996 |volume=54 |issue=2 |pages=1034–1063 |doi=10.1103/physreva.54.1034 |pmid=9913575 |arxiv=quant-ph/9602016 |bibcode=1996PhRvA..54.1034B }} or even utilizing the asymptotically fastest multiplication algorithm currently known due to Harvey and Van Der Hoven,{{cite journal |last1=Harvey |first1=David |last2=van der Hoeven |first2=Joris |title=Integer multiplication in time O (n log n) |journal=Annals of Mathematics |date=March 2021 |volume=193 |issue=2 |doi=10.4007/annals.2021.193.2.4 |url=https://hal.science/hal-02070778v2/file/nlogn.pdf }} thus demonstrating that the integer factorization problem can be efficiently solved on a quantum computer and is consequently in the complexity class BQP. This is significantly faster than the most efficient known classical factoring algorithm, the general number field sieve, which works in sub-exponential time: .{{cite web|url = http://mathworld.wolfram.com/NumberFieldSieve.html|title = Number Field Sieve|work = wolfram.com|access-date = 23 October 2015}}
Feasibility and impact
If a quantum computer with a sufficient number of qubits could operate without succumbing to quantum noise and other quantum-decoherence phenomena, then Shor's algorithm could be used to break public-key cryptography schemes, such as
- The RSA scheme
- The finite-field Diffie–Hellman key exchange
- The elliptic-curve Diffie–Hellman key exchange{{cite conference
| last1 = Roetteler | first1 = Martin
| last2 = Naehrig | first2 = Michael
| last3 = Svore | first3 = Krysta M. | author3-link = Krysta Svore
| last4 = Lauter | first4 = Kristin E. | author4-link = Kristin Lauter
| editor1-last = Takagi | editor1-first = Tsuyoshi
| editor2-last = Peyrin | editor2-first = Thomas
| arxiv = 1706.06752
| contribution = Quantum resource estimates for computing elliptic curve discrete logarithms
| doi = 10.1007/978-3-319-70697-9_9
| pages = 241–270
| publisher = Springer
| series = Lecture Notes in Computer Science
| title = Advances in Cryptology – ASIACRYPT 2017 – 23rd International Conference on the Theory and Applications of Cryptology and Information Security, Hong Kong, China, December 3–7, 2017, Proceedings, Part II
| volume = 10625
| year = 2017| isbn = 978-3-319-70696-2
}}
RSA can be broken if factoring large integers is computationally feasible. As far as is known, this is not possible using classical (non-quantum) computers; no classical algorithm is known that can factor integers in polynomial time. However, Shor's algorithm shows that factoring integers is efficient on an ideal quantum computer, so it may be feasible to defeat RSA by constructing a large quantum computer. It was also a powerful motivator for the design and construction of quantum computers, and for the study of new quantum-computer algorithms. It has also facilitated research on new cryptosystems that are secure from quantum computers, collectively called post-quantum cryptography.
= Physical implementation =
Given the high error rates of contemporary quantum computers and too few qubits to use quantum error correction, laboratory demonstrations obtain correct results only in a fraction of attempts.
In 2001, Shor's algorithm was demonstrated by a group at IBM, who factored into , using an NMR implementation of a quantum computer with seven qubits.{{cite journal |last1=Vandersypen |first1=Lieven M. K. |last2=Steffen |first2=Matthias |last3=Breyta |first3=Gregory |last4=Yannoni |first4=Costantino S. |last5=Sherwood |first5=Mark H. |last6=Chuang |first6=Isaac L. |title=Experimental realization of Shor's quantum factoring algorithm using nuclear magnetic resonance |journal=Nature |date=December 2001 |volume=414 |issue=6866 |pages=883–887 |doi=10.1038/414883a |pmid=11780055 |arxiv=quant-ph/0112176 |bibcode=2001Natur.414..883V }} After IBM's implementation, two independent groups implemented Shor's algorithm using photonic qubits, emphasizing that multi-qubit entanglement was observed when running the Shor's algorithm circuits.{{cite journal |last1=Lu |first1=Chao-Yang |last2=Browne |first2=Daniel E. |last3=Yang |first3=Tao |last4=Pan |first4=Jian-Wei |title=Demonstration of a Compiled Version of Shor's Quantum Factoring Algorithm Using Photonic Qubits |journal=Physical Review Letters |date=19 December 2007 |volume=99 |issue=25 |page=250504 |doi=10.1103/PhysRevLett.99.250504 |pmid=18233508 |arxiv=0705.1684 |bibcode=2007PhRvL..99y0504L }}{{cite journal |last1=Lanyon |first1=B. P. |last2=Weinhold |first2=T. J. |last3=Langford |first3=N. K. |last4=Barbieri |first4=M. |last5=James |first5=D. F. V. |last6=Gilchrist |first6=A. |last7=White |first7=A. G. |title=Experimental Demonstration of a Compiled Version of Shor's Algorithm with Quantum Entanglement |journal=Physical Review Letters |date=19 December 2007 |volume=99 |issue=25 |page=250505 |doi=10.1103/PhysRevLett.99.250505 |pmid=18233509 |arxiv=0705.1398 |bibcode=2007PhRvL..99y0505L }} In 2012, the factorization of was performed with solid-state qubits.{{Cite journal|last1 = Lucero|first1 = Erik|last2 = Barends|first2 = Rami|last3 = Chen|first3 = Yu|last4 = Kelly|first4 = Julian|last5 = Mariantoni|first5 = Matteo|last6 = Megrant|first6 = Anthony|last7 = O'Malley|first7 = Peter|last8 = Sank|first8 = Daniel|last9 = Vainsencher|first9 = Amit|last10 = Wenner|first10 = James|last11 = White|first11 = Ted|last12 = Yin|first12 = Yi|last13 = Cleland|first13 = Andrew N.|last14 = Martinis|first14 = John M.|title = Computing prime factors with a Josephson phase qubit quantum processor|journal = Nature Physics|volume = 8|issue = 10|pages = 719|year = 2012|doi = 10.1038/nphys2385|bibcode = 2012NatPh...8..719L|arxiv = 1202.5707|s2cid = 44055700}} Later, in 2012, the factorization of was achieved.{{cite journal|last1 = Martín-López|first1 = Enrique|last2 = Martín-López|first2 = Enrique|last3 = Laing|first3 = Anthony|last4 = Lawson|first4 = Thomas|last5 = Alvarez|first5 = Roberto|last6 = Zhou|first6 = Xiao-Qi|last7 = O'Brien|first7 = Jeremy L.|title = Experimental realization of Shor's quantum factoring algorithm using qubit recycling|journal = Nature Photonics|volume =6|issue = 11|pages = 773–776|date = 12 October 2012|doi = 10.1038/nphoton.2012.259|arxiv = 1111.4147|bibcode = 2012NaPho...6..773M|s2cid = 46546101}} In 2016, the factorization of was performed again using trapped-ion qubits with a recycling technique.{{cite journal|last1 = Monz|first1 = Thomas |last2 = Nigg|first2 = Daniel|last3 = Martinez|first3 = Esteban A.|last4 = Brandl|first4 = Matthias F.|last5 = Schindler|first5 = Philipp|last6 = Rines|first6 = Richard|last7 = Wang|first7 = Shannon X.|last8 = Chuang|first8 = Isaac L.|last9 = Blatt|first9 = Rainer|title = Realization of a scalable Shor algorithm|journal = Science|volume =351|issue = 6277|pages = 1068–1070|date = 4 March 2016|doi = 10.1126/science.aad9480|pmid = 26941315 |arxiv = 1507.08852|bibcode = 2016Sci...351.1068M|s2cid = 17426142}} In 2019, an attempt was made to factor the number using Shor's algorithm on an IBM Q System One, but the algorithm failed because of accumulating errors.{{cite journal |last1=Amico |first1=Mirko |last2=Saleem |first2=Zain H. |last3=Kumph |first3=Muir |title=Experimental study of Shor's factoring algorithm using the IBM Q Experience |journal=Physical Review A |date=8 July 2019 |volume=100 |issue=1 |page=012305 |doi=10.1103/PhysRevA.100.012305 |arxiv=1903.00768 |bibcode=2019PhRvA.100a2305A |s2cid=92987546 }} However, all these demonstrations have compiled the algorithm by making use of prior knowledge of the answer, and some have even oversimplified the algorithm in a way that makes it equivalent to coin flipping.{{cite journal |last1=Smolin |first1=John A. |last2=Smith |first2=Graeme |last3=Vargo |first3=Alexander |title=Oversimplifying quantum factoring |journal=Nature |date=July 2013 |volume=499 |issue=7457 |pages=163–165 |doi=10.1038/nature12290 |pmid=23846653 |arxiv=1301.7007 |bibcode=2013Natur.499..163S }} Furthermore, attempts using quantum computers with other algorithms have been made.{{cite journal |last1=Karamlou |first1=Amir H. |last2=Simon |first2=William A. |last3=Katabarwa |first3=Amara |last4=Scholten |first4=Travis L. |last5=Peropadre |first5=Borja |last6=Cao |first6=Yudong |title=Analyzing the performance of variational quantum factoring on a superconducting quantum processor |journal=npj Quantum Information |date=28 October 2021 |volume=7 |issue=1 |page=156 |doi=10.1038/s41534-021-00478-z |arxiv=2012.07825 |bibcode=2021npjQI...7..156K }} However, these algorithms are similar to classical brute-force checking of factors, so unlike Shor's algorithm, they are not expected to ever perform better than classical factoring algorithms.{{Cite web |date=2019-12-28 |title=Quantum computing motte-and-baileys |url=https://scottaaronson.blog/?p=4447 |access-date=2021-11-15 |website=Shtetl-Optimized |language=en-US}}
Theoretical analyses of Shor's algorithm assume a quantum computer free of noise and errors. However, near-term practical implementations will have to deal with such undesired phenomena (when more qubits are available, quantum error correction can help). In 2023, Jin-Yi Cai showed that in the presence of noise, Shor's algorithm fails asymptotically almost surely for large semiprimes that are products of two primes in {{OEIS el|A073024}}.{{cite journal |arxiv=2306.10072 |last1=Cai |first1=Jin-Yi |date=2024 |title=Shor's algorithm does not factor large integers in the presence of noise |journal=Science China Information Sciences |volume=67 |issue=7 |doi=10.1007/s11432-023-3961-3 }} These primes have the property that has a prime factor larger than , and have a positive density in the set of all primes. Hence error correction will be needed to be able to factor all numbers with Shor's algorithm.
Algorithm
The problem that we are trying to solve is: given an odd composite number , find its integer factors.
To achieve this, Shor's algorithm consists of two parts:
- A classical reduction of the factoring problem to the problem of order-finding. This reduction is similar to that used for other factoring algorithms, such as the quadratic sieve.
- A quantum algorithm to solve the order-finding problem.
= Classical reduction =
A complete factoring algorithm is possible if we're able to efficiently factor arbitrary into just two integers and greater than 1, since if either or are not prime, then the factoring algorithm can in turn be run on those until only primes remain.
A basic observation is that, using Euclid's algorithm, we can always compute the GCD between two integers efficiently. In particular, this means we can check efficiently whether is even, in which case 2 is trivially a factor. Let us thus assume that is odd for the remainder of this discussion. Afterwards, we can use efficient classical algorithms to check whether is a prime power.{{cite journal |last1=Bernstein |first1=Daniel |title=Detecting perfect powers in essentially linear time |journal=Mathematics of Computation |date=1998 |volume=67 |issue=223 |pages=1253–1283 |doi=10.1090/S0025-5718-98-00952-1 }} For prime powers, efficient classical factorization algorithms exist,For example, computing the first roots of , e.g., with the Newton method and checking each integer result for primality (AKS primality test). hence the rest of the quantum algorithm may assume that is not a prime power.
If those easy cases do not produce a nontrivial factor of , the algorithm proceeds to handle the remaining case. We pick a random integer . A possible nontrivial divisor of can be found by computing , which can be done classically and efficiently using the Euclidean algorithm. If this produces a nontrivial factor (meaning ), the algorithm is finished, and the other nontrivial factor is . If a nontrivial factor was not identified, then this means that and the choice of are coprime, so is contained in the multiplicative group of integers modulo , having a multiplicative inverse modulo . Thus, has a multiplicative order modulo , meaning
:
and is the smallest positive integer satisfying this congruence.
The quantum subroutine finds . It can be seen from the congruence that divides , written . This can be factored using difference of squares:
N \mid (a^{r/2} - 1)(a^{r/2} + 1).
Since we have factored the expression in this way, the algorithm doesn't work for odd (because must be an integer), meaning that the algorithm would have to restart with a new . Hereafter we can therefore assume that is even. It cannot be the case that , since this would imply , which would contradictorily imply that would be the order of , which was already . At this point, it may or may not be the case that . If does not divide , then this means that we are able to find a nontrivial factor of . We compute
d = \gcd(N, a^{r/2} - 1).
If , then was true, and a nontrivial factor of cannot be achieved from , and the algorithm must restart with a new . Otherwise, we have found a nontrivial factor of , with the other being , and the algorithm is finished. For this step, it is also equivalent to compute ; it will produce a nontrivial factor if is nontrivial, and will not if it's trivial (where ).
The algorithm restated shortly follows: let be odd, and not a prime power. We want to output two nontrivial factors of .
- Pick a random number .
- Compute , the greatest common divisor of and .
- If , then is a nontrivial factor of , with the other factor being , and we are done.
- Otherwise, use the quantum subroutine to find the order of .
- If is odd, then go back to step 1.
- Compute . If is nontrivial, the other factor is , and we're done. Otherwise, go back to step 1.
It has been shown that this will be likely to succeed after a few runs. In practice, a single call to the quantum order-finding subroutine is enough to completely factor with very high probability of success if one uses a more advanced reduction.{{cite journal |last1=Ekerå |first1=Martin |title=On completely factoring any integer efficiently in a single run of an order-finding algorithm |journal=Quantum Information Processing |date=June 2021 |volume=20 |issue=6 |page=205 |doi=10.1007/s11128-021-03069-1 |arxiv=2007.10044 |bibcode=2021QuIP...20..205E |doi-access=free }}
= Quantum order-finding subroutine =
The goal of the quantum subroutine of Shor's algorithm is, given coprime integers and
The algorithm consists of two main steps:
- Use quantum phase estimation with unitary
U representing the operation of multiplying bya (moduloN ), and input state|0\rangle^{\otimes 2 n}\otimes|1\rangle (where the second register is|1\rangle made fromn qubits). The eigenvalues of thisU encode information about the period, and|1\rangle can be seen to be writable as a sum of its eigenvectors. Thanks to these properties, the quantum phase estimation stage gives as output a random integer of the form\frac{j}{r} 2^{2n} for randomj=0,1,...,r-1 . - Use the continued fractions algorithm to extract the period
r from the measurement outcomes obtained in the previous stage. This is a procedure to post-process (with a classical computer) the measurement data obtained from measuring the output quantum states, and retrieve the period.
The connection with quantum phase estimation was not discussed in the original formulation of Shor's algorithm, but was later proposed by Kitaev.{{cite arXiv |eprint=quant-ph/9511026 |last1=Kitaev |first1=A. Yu |date=1995 |title=Quantum measurements and the Abelian Stabilizer Problem }}
== Quantum phase estimation ==
In general the quantum phase estimation algorithm, for any unitary
U|k\rangle = \begin{cases}
|ak \pmod N\rangle & 0 \le k < N, \\
|k\rangle & N \le k < 2^n.
\end{cases}
The action of
The gate thus defined satisfies
\frac{1}{\sqrt{r}} \sum_{j = 0}^{r - 1} |\psi_j\rangle &= \frac{1}{r} \sum_{j = 0}^{r - 1} \sum_{k = 0}^{r - 1} \omega_r^{jk}|a^k\rangle \\
&= |1\rangle + \frac{1}{r} \sum_{k = 1}^{r - 1} \left(\sum_{j = 0}^{r - 1} \omega_r^{jk} \right) |a^k\rangle =|1\rangle,
\end{align}
where the last identity follows from the geometric series formula, which implies
Using quantum phase estimation on an input state
Applying the above reasoning to the input
|0\rangle^{\otimes 2 n}|1\rangle =
\frac{1}{\sqrt{r}} \sum_{j = 0}^{r - 1} |0\rangle^{\otimes 2 n} |\psi_j\rangle \to
\frac{1}{\sqrt{r}} \sum_{j = 0}^{r - 1} |\phi_j\rangle|\psi_j\rangle.
Measuring the first register, we now have a balanced probability
== Continued-fraction algorithm to retrieve the period ==
Then, we apply the continued-fraction algorithm to find integers
\frac{b}{c} = \frac{j}{r},
given the best approximation from the superposition of
\frac{b_1}{c_1}, \frac{b_2}{c_2}, \ldots, \frac{b_s}{c_s},
where
\operatorname{lcm}(c_1, c_2, \ldots, c_s).
The least common multiple will be the order
== Choosing the size of the first register ==
Phase estimation requires choosing the size of the first register to determine the accuracy of the algorithm, and for the quantum subroutine of Shor's algorithm,
Each
{{Math theorem
| math_statement = If
then the continued fractions algorithm run on
}}
As
= The bottleneck =
The runtime bottleneck of Shor's algorithm is quantum modular exponentiation, which is by far slower than the quantum Fourier transform and classical pre-/post-processing. There are several approaches to constructing and optimizing circuits for modular exponentiation. The simplest and (currently) most practical approach is to mimic conventional arithmetic circuits with reversible gates, starting with ripple-carry adders. Knowing the base and the modulus of exponentiation facilitates further optimizations.{{cite journal |first1=Igor L. |last1=Markov |first2=Mehdi |last2=Saeedi |title=Constant-Optimized Quantum Circuits for Modular Multiplication and Exponentiation |journal=Quantum Information and Computation |volume=12 |issue=5–6 |pages=361–394 |year=2012 |doi=10.26421/QIC12.5-6-1 |arxiv=1202.6614 |bibcode = 2012arXiv1202.6614M |s2cid=16595181 }}{{cite journal |first1=Igor L. |last1=Markov |first2=Mehdi |last2=Saeedi |title=Faster Quantum Number Factoring via Circuit Synthesis |journal=Phys. Rev. A |volume=87 |issue= 1|pages=012310 |year=2013 |arxiv=1301.3210 |bibcode = 2013PhRvA..87a2310M |doi = 10.1103/PhysRevA.87.012310 |s2cid=2246117 }} Reversible circuits typically use on the order of
Period finding and discrete logarithms
Shor's algorithms for the discrete log and the order finding problems are instances of an algorithm solving the period finding problem.{{Citation needed|date=August 2023}} All three are instances of the hidden subgroup problem.
= Shor's algorithm for discrete logarithms =
Given a group
:
f \colon \mathbb{Z}_{p} \times \mathbb{Z}_{p} \to G \;;\; f(a,b) = g^{a} x^{- b} .
This gives us an abelian hidden subgroup problem, where
The order-finding problem can also be viewed as a hidden subgroup problem.{{cite book |last1=Nielsen |first1=Michael A. |url=http://mmrc.amss.cas.cn/tlb/201702/W020170224608149940643.pdf |archive-url=https://web.archive.org/web/20190711070716/http://mmrc.amss.cas.cn/tlb/201702/W020170224608149940643.pdf |archive-date=2019-07-11 |url-status=live |title=Quantum Computation and Quantum Information |last2=Chuang |first2=Isaac L. |date=9 December 2010 |publisher=Cambridge University Press |isbn=978-1-107-00217-3 |edition=7th |access-date=24 April 2022}} To see this, consider the group of integers under addition, and for a given
:
f \colon \mathbb{Z}\to \mathbb{Z} \;;\; f(x) = a^{x},\; f(x+r) = f(x) .
For any finite abelian group
See also
- GEECM, a factorization algorithm said to be "often much faster than Shor's"{{cite book |doi=10.1007/978-3-319-59879-6_18 |chapter=Post-quantum RSA |title=Post-Quantum Cryptography |series=Lecture Notes in Computer Science |date=2017 |last1=Bernstein |first1=Daniel J. |last2=Heninger |first2=Nadia |last3=Lou |first3=Paul |last4=Valenta |first4=Luke |volume=10346 |pages=311–329 |isbn=978-3-319-59878-9 }}
- Grover's algorithm
References
{{reflist}}
Further reading
- {{cite book |last1=Nielsen |first1=Michael A. |last2=Chuang |first2=Isaac L. |title=Quantum Computation and Quantum Information: 10th Anniversary Edition |date=2010 |publisher=Cambridge University Press |isbn=978-1-107-00217-3 }}
- {{cite book |doi=10.1093/oso/9780198570004.001.0001 |title=An Introduction to Quantum Computing |date=2006 |last1=Kaye |first1=Phillip |last2=Laflamme |first2=Raymond |last3=Mosca |first3=Michele |isbn=978-0-19-857000-4 }}
- [http://scottaaronson.com/blog/?p=208 "Explanation for the man in the street"] by Scott Aaronson, "[http://scottaaronson.com/blog/?p=208#comment-9958 approved]" by Peter Shor. (Shor wrote "Great article, Scott! That’s the best job of explaining quantum computing to the man on the street that I’ve seen."). An alternate metaphor for the QFT was presented in [http://www.scottaaronson.com/blog/?p=208#comment-5187 one of the comments]. Scott Aaronson suggests the following 12 references as further reading (out of "the 10105000 quantum algorithm tutorials that are already on the web."):
- {{Citation |last=Shor |first=Peter W. |year=1997 |title=Polynomial-Time Algorithms for Prime Factorization and Discrete Logarithms on a Quantum Computer |journal=SIAM J. Comput. |volume=26 |issue=5 |pages=1484–1509 |doi=10.1137/S0036144598347011 |arxiv=quant-ph/9508027v2|bibcode = 1999SIAMR..41..303S }}. Revised version of the original paper by Peter Shor ("28 pages, LaTeX. This is an expanded version of a paper that appeared in the Proceedings of the 35th Annual Symposium on Foundations of Computer Science, Santa Fe, NM, Nov. 20--22, 1994. Minor revisions made January, 1996").
- [https://quantum-algorithms.herokuapp.com/299/paper/index.html Quantum Computing and Shor's Algorithm], Matthew Hayward's [https://quantum-algorithms.herokuapp.com/ Quantum Algorithms Page], 2005-02-17, imsa.edu, LaTeX2HTML version of the original [https://quantum-algorithms.herokuapp.com/299/paper.tex LaTeX document], also available as [https://quantum-algorithms.herokuapp.com/299/paper.pdf PDF] or [https://quantum-algorithms.herokuapp.com/299/paper.ps postscript] document.
- [http://homepages.cwi.nl/~rdewolf/publ/qc/survey.ps Quantum Computation and Shor's Factoring Algorithm], Ronald de Wolf, CWI and University of Amsterdam, January 12, 1999, 9 page postscript document.
- [http://www.cs.berkeley.edu/~vazirani/f04quantum/notes/lec9.ps Shor's Factoring Algorithm], Notes from Lecture 9 of Berkeley CS 294–2, dated 4 Oct 2004, 7 page postscript document.
- [http://www.theory.caltech.edu/people/preskill/ph229/notes/chap6.ps Chapter 6 Quantum Computation] {{Webarchive|url=https://web.archive.org/web/20200430110523/http://www.theory.caltech.edu/people/preskill/ph229/notes/chap6.ps |date=2020-04-30 }}, 91 page postscript document, Caltech, Preskill, PH229.
- [http://www-users.cs.york.ac.uk/~schmuel/comp/comp.html Quantum computation: a tutorial] by [http://www.cs.york.ac.uk/~schmuel/ Samuel L. Braunstein].
- [http://www.cs.ucr.edu/~neal/1996/cosc185-S96/shor/high-level.html The Quantum States of Shor's Algorithm], by Neal Young, Last modified: Tue May 21 11:47:38 1996.
- [https://web.archive.org/web/20121115112940/http://people.ccmr.cornell.edu/~mermin/qcomp/chap3.pdf III. Breaking RSA Encryption with a Quantum Computer: Shor's Factoring Algorithm], Lecture notes on Quantum computation, Cornell University, Physics 481–681, CS 483; Spring, 2006 by N. David Mermin. Last revised 2006-03-28, 30 page PDF document.
- {{Cite arXiv|eprint=quant-ph/0303175|last1= Lavor|first1= C.|title= Shor's Algorithm for Factoring Large Integers|last2= Manssur|first2= L. R. U.|last3= Portugal|first3= R.|year= 2003}}
- {{Cite arXiv|eprint=quant-ph/0010034|last1=Lomonaco|first1=Jr|title=Shor's Quantum Factoring Algorithm|year=2000}} This paper is a written version of a one-hour lecture given on Peter Shor's quantum factoring algorithm. 22 pages.
- [http://www.cs.princeton.edu/theory/complexity/quantumchap.pdf Chapter 20 Quantum Computation], from Computational Complexity: A Modern Approach, Draft of a book: Dated January 2007, Sanjeev Arora and Boaz Barak, Princeton University. Published as Chapter 10 Quantum Computation of Sanjeev Arora, Boaz Barak, "Computational Complexity: A Modern Approach", Cambridge University Press, 2009, {{isbn|978-0-521-42426-4}}
- [http://blogs.discovermagazine.com/80beats/2011/01/19/a-step-towards-quantum-computing-entangling-10-billion-particles/ A Step Toward Quantum Computing: Entangling 10 Billion Particles] {{Webarchive|url=https://web.archive.org/web/20110120103006/http://blogs.discovermagazine.com/80beats/2011/01/19/a-step-towards-quantum-computing-entangling-10-billion-particles/ |date=2011-01-20 }}, from "Discover Magazine", Dated January 19, 2011.
- [http://www.fi.muni.cz/usr/gruska/survey1.ps Josef Gruska - Quantum Computing Challenges] also in [https://www.amazon.com/Mathematics-Unlimited-Bj%C3%B6rn-Engquist/dp/3540669132 Mathematics unlimited: 2001 and beyond], Editors Björn Engquist, Wilfried Schmid, Springer, 2001, {{isbn|978-3-540-66913-5}}
External links
- Version 1.0.0 of [http://www.libquantum.de/ libquantum]: contains a C language implementation of Shor's algorithm with their simulated quantum computer library, but the width variable in shor.c should be set to 1 to improve the runtime complexity.
- PBS Infinite Series created two videos explaining the math behind Shor's algorithm, "[http://www.pbs.org/video/how-to-break-cryptography-ahby1s/ How to Break Cryptography]" and "[http://www.pbs.org/video/hacking-at-quantum-speed-with-shors-algorithm-8jrjkq/ Hacking at Quantum Speed with Shor's Algorithm]".
- [https://short.classiq.io/shor Complete implementation of Shor's algorithm with Classiq]
{{Quantum computing}}
{{number theoretic algorithms}}
{{DEFAULTSORT:Shor's Algorithm}}
Category:Integer factorization algorithms