HOME

TheInfoList



OR:

In
computational complexity theory In theoretical computer science and mathematics, computational complexity theory focuses on classifying computational problems according to their resource usage, and relating these classes to each other. A computational problem is a task solved ...
and
quantum computing Quantum computing is a type of computation whose operations can harness the phenomena of quantum mechanics, such as superposition, interference, and entanglement. Devices that perform quantum computations are known as quantum computers. Thou ...
, Simon's problem is a
computational problem In theoretical computer science, a computational problem is a problem that may be solved by an algorithm. For example, the problem of factoring :"Given a positive integer ''n'', find a nontrivial prime factor of ''n''." is a computational probl ...
that is proven to be solved exponentially faster on a
quantum computer Quantum computing is a type of computation whose operations can harness the phenomena of quantum mechanics, such as superposition, interference, and entanglement. Devices that perform quantum computations are known as quantum computers. Thoug ...
than on a classical (that is, traditional) computer. The quantum algorithm solving Simon's problem, usually called Simon's algorithm, served as the inspiration for
Shor's algorithm Shor's algorithm is a quantum computer algorithm for finding the prime factors of an integer. It was developed in 1994 by the American mathematician Peter Shor. On a quantum computer, to factor an integer N , Shor's algorithm runs in polynomial ...
. Both problems are special cases of the abelian
hidden subgroup problem The hidden subgroup problem (HSP) is a topic of research in mathematics and theoretical computer science. The framework captures problems such as factoring, discrete logarithm, graph isomorphism, and the shortest vector problem. This makes it esp ...
, which is now known to have efficient quantum algorithms. The problem is set in the model of
decision tree complexity In computational complexity the decision tree model is the model of computation in which an algorithm is considered to be basically a decision tree, i.e., a sequence of ''queries'' or ''tests'' that are done adaptively, so the outcome of the previ ...
or query complexity and was conceived by Daniel Simon in 1994. Simon exhibited a
quantum algorithm In quantum computing, a quantum algorithm is an algorithm which runs on a realistic model of quantum computation, the most commonly used model being the quantum circuit model of computation. A classical (or non-quantum) algorithm is a finite seq ...
that solves Simon's problem exponentially faster and with exponentially fewer queries than the best
probabilistic Probability is the branch of mathematics concerning numerical descriptions of how likely an event is to occur, or how likely it is that a proposition is true. The probability of an event is a number between 0 and 1, where, roughly speaking, ...
(or deterministic) classical algorithm. In particular, Simon's algorithm uses a linear number of queries and any classical probabilistic algorithm must use an exponential number of queries. This problem yields an
oracle separation An oracle is a person or agency considered to provide wise and insightful counsel or prophetic predictions, most notably including precognition of the future, inspired by deities. As such, it is a form of divination. Description The word ''or ...
between the complexity classes BPP (bounded-error classical query complexity) and BQP (bounded-error quantum query complexity). This is the same separation that the Bernstein–Vazirani algorithm achieves, and different from the separation provided by the
Deutsch–Jozsa algorithm The Deutsch–Jozsa algorithm is a deterministic quantum algorithm proposed by David Deutsch and Richard Jozsa in 1992 with improvements by Richard Cleve, Artur Ekert, Chiara Macchiavello, and Michele Mosca in 1998. Although of little current ...
, which separates P and EQP. Unlike the Bernstein–Vazirani algorithm, Simon's algorithm's separation is ''exponential''. Because this problem assumes the existence of a highly-structured "black box" oracle to achieve its speedup, this problem has little practical value. However, without such an oracle, exponential speedups cannot easily be proven, since this would prove that P is different from
PSPACE In computational complexity theory, PSPACE is the set of all decision problems that can be solved by a Turing machine using a polynomial amount of space. Formal definition If we denote by SPACE(''t''(''n'')), the set of all problems that can b ...
.


Problem description

Given a function (implemented by a
black box In science, computing, and engineering, a black box is a system which can be viewed in terms of its inputs and outputs (or transfer characteristics), without any knowledge of its internal workings. Its implementation is "opaque" (black). The te ...
or oracle) f:\^n\rightarrow \^n with the promise that, for some unknown s\in \^n, for all x, y\in\^n , : f(x)=f(y) if and only if x \oplus y \in \, where \oplus denotes bitwise XOR. The goal is to identify s by making as few queries to f(x) as possible. Note that : a \oplus b = 0^n if and only if a = b Furthermore, for some x and s in x \oplus y = s, y is unique (not equal to x) if and only if s \neq 0^n. This means that f is two-to-one when s \neq 0^n, and one-to-one when s = 0^n. It is also the case that x \oplus y = s implies y = s \oplus x, meaning thatf(x) = f(y) = f(x \oplus )which shows how f is periodic. The associated
decision problem In computability theory and computational complexity theory, a decision problem is a computational problem that can be posed as a yes–no question of the input values. An example of a decision problem is deciding by means of an algorithm whethe ...
formulation of Simon's problem is to distinguish when s = 0^n (f is one-to-one), and when s \neq 0^n (f is two-to-one).


Example

For example, if n = 3, then the following function is an example of a function that satisfies the required and just mentioned property: In this case, s = 110 (i.e. the solution). It can easily be verified that every output of f occurs twice, and the two input strings corresponding to any one given output have bitwise XOR equal to s = 110. For example, the input strings 010 and 100 are both mapped (by f) to the same output string 000. and . If we apply XOR to 010 and 100 we obtain 110, that is . s=110 can also be verified using input strings 001 and 111 that are both mapped (by f) to the same output string 010. If we apply XOR to 001 and 111, we obtain 110, that is 001\oplus111=110=s. This gives the same solution s=110 we solved for before. In this example the function ''f'' is indeed a two-to-one function where .


Problem hardness

Intuitively, this is a very hard problem to solve in a "classical" way, even if one uses randomness and accepts a small probability of error. The intuition behind the hardness is reasonably simple: if you want to solve the problem classically, you need to find two different inputs x and y for which f(x)=f(y). There is not necessarily any structure in the function f that would help us to find two such inputs: more specifically, we can discover something about f (or what it does) only when, for two different inputs, we obtain the same output. In any case, we would need to guess different inputs before being likely to find a pair on which f takes the same output, as per the
birthday problem In probability theory, the birthday problem asks for the probability that, in a set of randomly chosen people, at least two will share a birthday. The birthday paradox is that, counterintuitively, the probability of a shared birthday exceeds 5 ...
. Since, classically to find ''s'' with a 100% certainty it would require checking up to 2^+1 inputs, Simon's problem seeks to find ''s'' using fewer queries than this classical method.


Simon's algorithm

The algorithm as a whole uses this subroutine in the following two steps: # Run the quantum subroutine an expected O(n) times to get a list of
linearly independent In the theory of vector spaces, a set of vectors is said to be if there is a nontrivial linear combination of the vectors that equals the zero vector. If no such linear combination exists, then the vectors are said to be . These concepts ...
bitstrings y_1, ..., y_. # Each y_k satisfies y_k \cdot s = 0, so we can solve the system of equations this produces to get s.


Quantum subroutine

The quantum circuit (see the picture) is the implementation of the quantum part of Simon's algorithm. The quantum subroutine of the algorithm makes use of the
Hadamard transform The Hadamard transform (also known as the Walsh–Hadamard transform, Hadamard–Rademacher–Walsh transform, Walsh transform, or Walsh–Fourier transform) is an example of a generalized class of Fourier transforms. It performs an orthogonal ...
H^, k\rangle = \frac \sum_^ (-1)^ , j\ranglewhere k \cdot j = k_1 j_1 \oplus \ldots \oplus k_n j_n, where \oplus denotes
XOR Exclusive or or exclusive disjunction is a logical operation that is true if and only if its arguments differ (one is true, the other is false). It is symbolized by the prefix operator J and by the infix operators XOR ( or ), EOR, EXOR, , , ...
. First, the algorithm starts with two registers, initialized to , 0\rangle^, 0\rangle^. Then, we apply the Hadamard transform to the first register, which gives the state : \frac \sum_^ , k\rangle , 0\rangle^ Query the oracle U_f to get the state : \frac \sum_^ , k\rangle , f(k)\rangle. Apply another Hadamard transform to the first register. This will produce the state : \frac \sum_^ \left j\rangle \right, f(k)\rangle = \sum_^ , j\rangle \left f(k)\rangle \right/math> Finally, we measure the first register (the algorithm also works if the second register is measured before the first, but this is unnecessary). The probability of measuring a state , j\rangle is\left, \left, \frac \sum_^ (-1)^ , f(k)\rangle \\^2This is due to the fact that taking the magnitude of this vector and squaring it sums up all the probabilities of all the possible measurements of the second register that must have the first register as , j\rangle. There are two cases for our measurement: # s = 0^n and f is one-to-one. # s \neq 0^n and f is two-to-one. For the first case, since\left, \left, \frac \sum_^ (-1)^ , f(k)\rangle \\^2 = \fracsince in this case, f is one-to-one, implying that the range of f is \^n, meaning that the summation is over every basis vector. For the second case, note that there exist two strings, x_1 and x_2, such that f(x_1) = f(x_2) = z, where z \in \mathrm(f). We can thus write\left, \left, \frac \sum_^ (-1)^ , f(k)\rangle \\^2 = \left, \left, \frac \sum_ ((-1)^ + (-1)^) , z\rangle \\^2Furthermore, since we know that x_1 \oplus x_2 = s, we know that x_2 = x_1 \oplus s, and so\begin \left, \left, \frac \sum_ ((-1)^ + (-1)^) , z\rangle \\^2 &= \left, \left, \frac \sum_ ((-1)^ + (-1)^) , z\rangle \\^2 \\ &= \left, \left, \frac \sum_ ((-1)^ + (-1)^) , z\rangle \\^2 \\ &= \left, \left, \frac \sum_ (-1)^(1 + (-1)^) , z\rangle \\^2 \endThis expression is now easy to evaluate. Recall that we are measuring j. When j \cdot s = 1, then this expression will evaluate to 0, and when j \cdot s = 0, then this expression will be 2^. Thus, both when s = 0^n and when s \neq 0^n, our measured j satisfies j \cdot s = 0.


Classical post-processing

We run the quantum part of the algorithm until we have a linearly independent list of bitstrings y_1, \ldots, y_, and each y_k satisfies y_k \cdot s = 0. Thus, we can efficiently solve this system of equations classically to find s. The probability that y_1, y_2, \dots, y_ are linearly independent is at least \prod_^\infty \left( 1 - \frac \right) = 0.288788\dots Once we solve the system of equations, and produce a solution s', we can test if f(0^n) = f(s'). If this is true, then we know s' = s, since f(0^n) = f(0^n \oplus s) = f(s). If it is the case that f(0^n) \neq f(s'), then that means that s = 0^n, and f(0^n) \neq f(s') since f is one-to-one. We can repeat Simon's algorithm a constant number of times to up the probabilities of success arbitrarily, while still having the same time complexity.


Explicit examples of Simon's algorithm for few qubits


n=1

Consider the simplest instance of the algorithm, with n=1. In this case evolving the input state through an Hadamard gate and the oracle results in the state (up to renormalization): : , 0\rangle , f(0)\rangle + , 1\rangle, f(1)\rangle. If s=1, that is, f(0)=f(1), then measuring the second register always gives the outcome , f(0)\rangle, and always results in the first register collapsing to the state (up to renormalization): : , 0\rangle+ , 1\rangle. Thus applying an Hadamard and measuring the first register always gives the outcome , 0\rangle. On the other hand, if f is one-to-one, that is, s=0, then measuring the first register after the second Hadamard can result in both , 0\rangle and , 1\rangle, with equal probability. We recover s from the measurement outcomes by looking at whether we measured always , 0\rangle, in which case s=1, or we measured both , 0\rangle and , 1\rangle with equal probability, in which case we infer that s=0. This scheme will fail if s=0 but we nonetheless always found the outcome , 0\rangle, but the probability of this event is 2^ with N the number of performed measurements, and can thus be made exponentially small by increasing the statistics.


n=2

Consider now the case with n=2. The initial part of the algorithm results in the state (up to renormalization):,, 00\rangle, f(00)\rangle + , 01\rangle, f(01)\rangle + , 10\rangle, f(10)\rangle + , 11\rangle, f(11)\rangle.If s=(00), meaning f is injective, then finding , f(x)\rangle on the second register always collapses the first register to , x\rangle, for all x\in\^2. In other words, applying Hadamard gates and measuring the first register the four outcomes 00,01,10,11 are thus found with equal probability. Suppose on the other hand s\neq(00), for example, s=(01). Then measuring , f(00)\rangle on the second register collapses the first register to the state , 00\rangle+, 10\rangle. And more generally, measuring , f(xy)\rangle gives , x,y\rangle+, x,y\oplus1\rangle=, x\rangle(, 0\rangle+, 1\rangle) on the first register. Applying Hadamad gates and measuring on the first register can thus result in the outcomes 00 and 10 with equal probabilities. Similar reasoning applies to the other cases: if s=(10) then the possible outcomes are 00 and 01, while if s=(11) the possible outcomes are 00 and 11, compatibly with the j\cdot s=0 rule discussed in the general case. To recover s we thus only need to distinguishe between these four cases, collecting enough statistics to ensure that the probability of mistaking one outcome probability distribution for another is sufficiently small.


Complexity

Simon's algorithm requires O(n) queries to the black box, whereas a classical algorithm would need at least \Omega(2^) queries. It is also known that Simon's algorithm is optimal in the sense that ''any'' quantum algorithm to solve this problem requires \Omega(n) queries.


See also

*
Deutsch–Jozsa algorithm The Deutsch–Jozsa algorithm is a deterministic quantum algorithm proposed by David Deutsch and Richard Jozsa in 1992 with improvements by Richard Cleve, Artur Ekert, Chiara Macchiavello, and Michele Mosca in 1998. Although of little current ...


References

{{Quantum computing Quantum algorithms