Title: Simulation and Design of Stabilizer Quantum Circuits
1Simulation and Design of Stabilizer Quantum
Circuits
ZIIX
0 0 1 11 1 0 0
?
XXZZ
1 0 0 00 0 0 1
- Scott Aaronson and Boriska Toth
- CS252 Project
- December 10, 2003
2Quantum Computing New Challenges for Architecture
- If you speculate on a measurement, rollback will
not happen - Cache coherence protocols violate no-cloning
theorem
- How do you design and debug circuits that you
cant even simulate efficiently?
3Our Approach Start With A Subset of Quantum
Computations
- Stabilizers (Gottesman 1996) Beautiful formalism
that captures much (but not all) of quantum
weirdness - Quantum linear error-correcting codes
- Teleportation
- Dense quantum coding
- GHZ (Greenberger-Horne-Zeilinger) paradox
- What We Did Invented new algorithms for
simulating and designing quantum circuits
described by the stabilizer formalism.
Implemented and tested an efficient simulator
with possible practical value.
4Quantum Gates We Allow
1. Controlled-NOT (CNOT) Replaces a,b by a,b?a
00??00?, 01??01?, 10??11?, 11??10?
1 1 1 -1
2. Hadamard Applies /?2 to single
qubit
0??(0?1?)/?21?? (0?-1?)/?2
H
1 0 0 i
3. Phase Applies to single qubit
0??0?, 1??i1?
P
4. Measurement of a single qubit
5Pauli Matrices Collect Em All
1 0 0 1
1 0 0 -1
0 1 1 0
0 -i i 0
I
Z
X
Y
X2Y2Z2I XYiZ YZiX ZXiY XZ-iY ZY-iX YX
-iZ Unitary matrix U stabilizes a quantum state
?? if U?? ??. Stabilizers of ?? form an
abelian group Theorem ?? can be produced from
the all-0 state by just CNOT, Hadamard, and phase
gates, iff ?? is stabilized by 2n tensor
products of Pauli matrices or their opposites
(where n number of qubits)In that case, ?? is
uniquely determined by these stabilizers
6Goal Using a classical computer, simulate an
n-qubit CNOT/Hadamard/Phase computer. Gottesman
Knills solution Keep track of n generators of
the stabilizer groupEach generator uses 2n1
bits 2 for each Pauli matrix and 1 for the sign.
So n(2n1) bits total Example But as we
discovered when we tried to implement,
measurement takes O(n3) steps by Gaussian
elimination
CNOT(1?2)
01?11?
01?10?
XX-ZZ
XI-IZ
Updating stabilizers takes only O(n) steps
7Our Faster, Easier-to-Implement Solution
Scoreboarding
- Idea Instead of n(2n1) bits, store 2n(4n1)
bits - n stabilizers, 2n1 bits each
- n destabilizers
- A 2n?2n scoreboard, that stores how to write
XIIII,,IIIIX, ZIIII,,IIIIZ as products of the
stabilizers and destabilizers
Together generate full Pauli group
XI IX ZI IZ
XIIX
1 0 0 00 1 0 0
Initial State00?
Destabilizers
ZIIZ
0 0 1 00 0 0 1
Stabilizers
Scoreboard
8Our Faster, Easier-to-Implement Solution
Scoreboarding
- Idea Instead of n(2n1) bits, store 2n(4n1)
bits - n stabilizers, 2n1 bits each
- n destabilizers
- A 2n?2n scoreboard, that stores how to write
XIIII,,IIIIX, ZIIII,,IIIIZ as products of the
stabilizers and destabilizers
Together generate full Pauli group
XI IX ZI IZ
ZIIX
0 0 1 00 1 0 0
Hadamard the 1st qubit00?10?
Destabilizers
Swap
XIIZ
1 0 0 00 0 0 1
Stabilizers
Scoreboard
9Our Faster, Easier-to-Implement Solution
Scoreboarding
- Idea Instead of n(2n1) bits, store 2n(4n1)
bits - n stabilizers, 2n1 bits each
- n destabilizers
- A 2n?2n scoreboard, that stores how to write
XIIII,,IIIIX, ZIIII,,IIIIZ as products of the
stabilizers and destabilizers
Together generate full Pauli group
XI IX ZI IZ
ZIIX
0 0 1 11 1 0 0
CNOT into the 2nd qubit00?11?
Destabilizers
?
XXZZ
1 0 0 00 0 0 1
Stabilizers
Scoreboard
10Advantages
- Because we force each instruction to tell the
scoreboard what it did, measuring a state (and
updating it after the measurement) can be done in
only O(n2) steps.No Gaussian elimination needed! - Recently measured observables are automatically
cachedmeasuring them again takes only O(n)
steps.
11CHP An interpreter for quantum assembly
language programs that implements our scoreboard
algorithm
12Performance of CHP
650MHz Pentium III, 256MB RAM Compiler
optimizations made it 50 slower!
20000 gates
15000 gates
10000 gates
5000 gates
- Randomly-generated circuits with equal mix of
CNOT, Hadamard, phase, and measurement gates - Updating the state after measurements with
random outcomes dominates the running time.
Amdahls Law suggests this is what we should
optimizeand we have ideas!
13Other Stuff We Did
- Proved that any stabilizer quantum circuit can
be simulated using only CNOT gatesIn theory
jargon Simulating stabilizer circuits is
?L-complete - Proved that any stabilizer circuit has an
equivalent circuit with at most O(n2/log n)
gates, saturating the Shannon lower boundBuilds
on work by an architecture group at U.
MichiganK. Patel, I. Markov, and J. Hayes
(quant-ph/0302002)who showed this for CNOT
circuits
14Future Directions
- Measurements (at least some) in O(n) steps?
- Apply CHP to quantum error-correction, studying
conjectures about entanglement in many-qubit
systems - Efficient minimization of stabilizer circuits?
- Superlinear lower bounds on stabilizer circuit
size? - Other quantum computations with efficient
classical simulations bounded entanglement
(Vidal 2003), matchgates (Valiant 2001)