Introduction to Quantum Information Processing Lecture 6 Richard Cleve
Overview of Lecture 6 Continuation of teleportation Computation and some basic complexity classes Simple quantum algorithms in the query scenario (Deutsch) 2
computation and basic complexity classes 8
Classical (boolean ( logic) gates AND gate a b old notation new notation a b a b a b NOT gate a a a a Note: an OR gate can be simulated by one AND gate and three NOT gates 9
Models of computation Models of computation Classical circuits: Quantum circuits:
Multiplication problem Input: two n-bit numbers (e.g. and ) Output: their product (e.g. ) Grade school algorithm costs O(n 2 ) Best currently-known classical algorithm costs O(n log n loglog n) Best currently-known quantum method: same
Factoring problem Input: an n-bit number (e.g. ) Output: their product (e.g., ) Trial division costs 2 n /2 Best currently-known classical algorithm costs 2 n ⅓ Hardness of factoring is the basis of the security of many cryptosystems (e.g. RSA) Shor s quantum algorithm costs n 2 Implementation would break RSA and many other cryptosystems 2
Quantum vs. classical circuits Theorem: a classical circuit of size s can be simulated by a quantum circuit of size O(s) Idea: using Toffoli gates, one can simulate: AND gates NOT gates a a b b a b a a 3
Some complexity classes P (polynomial time): problems solved by O(n c )-size classical circuits (decision problems and uniform circuit families) BPP (bounded error probabilistic polynomial time): problems solved by O(n c )-size probabilistic circuits that err with probability ¼ BQP (bounded error quantum polynomial time): problems solved by O(n c )-size probabilistic circuits that err with probability ¼ EXP (exponential time): problems solved by O(2 n c)-size circuits. 4
BPP BQP Since quantum gates can simulate classical gates, the only outstanding issue is how to simulate randomness To simulate coin flips, one can use the circuit: H random bit It can also be done without intermediate measurements: isolate this qubit use in place of coin flip H 5
BQP EXP Theorem: a quantum circuit of size s can be simulated by a classical circuit of size O(n cs ) Idea: to simulate an n-qubit state, use an array of size 2 n containing values of all 2 n amplitudes within precision 2 n α Can adjust this state vector whenever a unitary operation is performed α α α... α From the final amplitudes, can determine how to set each output bit Exercise: show how to do the simulation using only a polynomial amount of space (memory) 6
Summary of basic containments P BPP BQP PSPACE EXP EXP PSPACE BQP This picture will be fleshed out further in due course BPP P 7
simple quantum algorithms in the query scenario 8
Query scenario Input: a function f, given as x f f(x) a black box (a.k.a. oracle) Goal: determine some information about f making as few queries to f (and other operations) as possible Example: polynomial interpolation Let: f(x) = c + c x + c 2 x 2 +... + c d x d Goal: determine c, c, c 2,..., c d Question: How many f-queries does this take? 9
Deutsch s problem Let f : {,}! {,} f There are four possibilities: x f (x) x f 2 (x) x f 3 (x) x f 4 (x) Goal: determine whether or not f() = f() (i.e. f() f()) Any classical method requires two queries What about a quantum method? 2
Reversible black box for f a b U f a b f(a) alternate notation: f A classical algorithm: (still requires 2 queries) f f f() f() 2 queries + auxiliary operation 2
Quantum algorithm for Deutsch 2 3 H f H f() f() H query + 4 auxiliary operations H = 2 How does this algorithm work? Each of the three H operations plays a different role... 22
Quantum algorithm () ( 2 3 H f H H. Creates the state, which is an eigenvector of NOT with eigenvalue I with eigenvalue + This causes f to induce a phase shift of ( ) f(x) to x f x ( ) f(x) x 23
Quantum algorithm (2) ( 2. Causes f to be queried in superposition (at + ) H f ( ) f() + ( ) f() x f (x) x f 2 (x) x f 3 (x) x f 4 (x) ±( + ) ±( ) 24
Quantum algorithm (3) ( 3. Distinguishes between ±( + ) and ±( ) H ±( + ) ± H ±( ) ± 25
Summary of Deutsch s algorithm Makes only one query, whereas two are needed classically produces superpositions of inputs to f : + extracts phase differences from ( ) f() + ( ) f() 2 3 H f H f() f() H constructs eigenvector so f-queries induce phases: x! ( ) f(x) x 26
How to contact Richard Cleve Office: DC 3524 (also at IQC) Email: cleve@iqc.ca Phone: 888-4567 x7762 27