Equivalence Checking Quantum Programs Ebrahim Ardeshir June 28, 2012 FOCS,DIMAP

advertisement
Equivalence Checking Quantum Programs
Ebrahim Ardeshir
FOCS,DIMAP
June 28, 2012
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
1 / 15
Introduction
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
2 / 15
Introduction
Quantum Computation:Happy marriage of Quantum Mechanics and
Computer Science.
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
2 / 15
Introduction
Quantum Computation:Happy marriage of Quantum Mechanics and
Computer Science.
Different paradigm of computation and information processing:
Superposition of states.
This paradigm of computation can solve some NP problems (not NP
hard!), like Integer Factorization in polynomial time. (efficiently)
This paradigm of information processing can carry information
unconditionally secure. Example: Quantum Key Distribution (QKD).
Many technological advances has been achieved: Example:
Teleportation over 143 km in the free space. So we may see satellite
QKD soon.
Long way to go !
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
2 / 15
Some Definitions
Quantum State:
|Ψi = α |0i + β |1i
|α|2 + |β|2 = 1, α, β ∈ C
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
3 / 15
Some Definitions
Quantum State:
|Ψi = α |0i + β |1i
|α|2 + |β|2 = 1, α, β ∈ C
Density Operator (for probabilistic knowledge: {(pi , |φi )i}):
X
ρ :=
pi |φi i hφi |
i
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
3 / 15
Quantum Circuits
We represent operations on quantum states by quantum circuits. The
wires show qubits and boxes show quantum gates (We also have
controlled gates which they are applied on two qubits and is shown by
circles).For example the following circuit implements quantum
Teleportation:
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
4 / 15
Quantum Circuits
We represent operations on quantum states by quantum circuits. The
wires show qubits and boxes show quantum gates (We also have
controlled gates which they are applied on two qubits and is shown by
circles).For example the following circuit implements quantum
Teleportation:
|ψi
|0i
|0i
Ebrahim Ardeshir (FOCS,DIMAP)
H
•
•
H
NM
NM
X
Equivalence Checking Quantum Programs
•
Z
|ψi
June 28, 2012
4 / 15
Stabiliser Formalism
Stabiliser formalism: A small fraction of quantum states, which there
are efficient algorithms for representing quantum effects on
them.(primarily discovered in Quantum Error Correction theory)
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
5 / 15
Stabiliser Formalism
Stabiliser formalism: A small fraction of quantum states, which there
are efficient algorithms for representing quantum effects on
them.(primarily discovered in Quantum Error Correction theory)
1
|φi = √ (|00i + |11i)
2
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
5 / 15
Stabiliser Formalism
Stabiliser formalism: A small fraction of quantum states, which there
are efficient algorithms for representing quantum effects on
them.(primarily discovered in Quantum Error Correction theory)
1
|φi = √ (|00i + |11i)
2
X ⊗ X |φi = |φi
Z ⊗ Z |φi = |φi
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
5 / 15
Stabiliser Formalism
Stabiliser formalism: A small fraction of quantum states, which there
are efficient algorithms for representing quantum effects on
them.(primarily discovered in Quantum Error Correction theory)
1
|φi = √ (|00i + |11i)
2
X ⊗ X |φi = |φi
Z ⊗ Z |φi = |φi
Pauli Operators : {X , Z , Y , I }
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
5 / 15
The Problem
Problem
Designing quantum algorithms, cryptography and communication
protocols in the quantum circuit model is very hard and non-intuitive so
we need to develope high level methods, similar to computer science to
analyze quantum systems.
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
6 / 15
The Problem
Problem
For a quantum protocol P, How one can automatically verify its
correctness for all inputs?
input |φi
Ebrahim Ardeshir (FOCS,DIMAP)
P
Equivalence Checking Quantum Programs
output |ψi
June 28, 2012
7 / 15
Equivalence Checking
We propose Semantic Equivalence Checking :Implementation vs.
Specification
Previous work by Nick Papanikolaou here at Warwick(Best
Presentation Award WPCCS’06):Quantum Model Checking (property
based Model-Checking)
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
8 / 15
Quantum Programs:Syntax
Based on the influential paper Towards a quantum programming
language [P.Selinger 2004], we specify protocols in QPL:
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
9 / 15
Quantum Programs:Syntax
Based on the influential paper Towards a quantum programming
language [P.Selinger 2004], we specify protocols in QPL:
The syntax of QPL is as following:
P,Q ::= newbit b|newqbit q:=0 | discard x
skip|P;Q|q*= S|
if b then P else Q end| measure q then P else Q end |
while b do P | proc X:{P} in Q | call X
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
9 / 15
Quantum Programs:Semantics
The denotational semantic of each program is a Superoperator (i.e
linear transformation of input density operator to the output operator)
[PQPL ] : Dinput → Doutput
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
10 / 15
Semantic Equivalence Checking
To show a quantum protocol behave correctly, we formalise the
protocol in QPL in different levels of abstraction.One for lower level of
implementation and one for higher level of specification. Then we
automatically prove their denotational semantic is equivalent. To do
this we use the following result.
We have found (and implemented) a basis for the space of density
operators which can be characterised in the stabiliser formalism.
ImplementationQPL ' SpecificationQPL
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
11 / 15
Semantic Equivalence Checking
To show a quantum protocol behave correctly, we formalise the
protocol in QPL in different levels of abstraction.One for lower level of
implementation and one for higher level of specification. Then we
automatically prove their denotational semantic is equivalent. To do
this we use the following result.
We have found (and implemented) a basis for the space of density
operators which can be characterised in the stabiliser formalism.
ImplementationQPL ' SpecificationQPL
[ImplementationQPL ]v = [SpecificationQPL ]v
for all v in the above basis.
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
11 / 15
Our results and QMC
In addition to the above basis we also have found an efficient
algorithm for testing equality of two stabiliser states.
The key new idea: For each vector in the above basis interpret QPL in
the stabiliser formalism and then use our equality test. Thus we can
prove that for all input states, the protocol satisfies the specification.
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
12 / 15
Our results and QMC
In addition to the above basis we also have found an efficient
algorithm for testing equality of two stabiliser states.
The key new idea: For each vector in the above basis interpret QPL in
the stabiliser formalism and then use our equality test. Thus we can
prove that for all input states, the protocol satisfies the specification.
Quantum Model Checker (QMC): Property Checking,Quantum Tree
1
2
Logic, Evidence for correctness, Complexity:2( 2 +o(1)n ) initial states.
Quantum Equivalence Checker(QEC):Equivalence Checking,Quantum
Programming Language, Proof of correctness, Complexity:22n initial
states.
Conclusion:
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
12 / 15
Our results and QMC
In addition to the above basis we also have found an efficient
algorithm for testing equality of two stabiliser states.
The key new idea: For each vector in the above basis interpret QPL in
the stabiliser formalism and then use our equality test. Thus we can
prove that for all input states, the protocol satisfies the specification.
Quantum Model Checker (QMC): Property Checking,Quantum Tree
1
2
Logic, Evidence for correctness, Complexity:2( 2 +o(1)n ) initial states.
Quantum Equivalence Checker(QEC):Equivalence Checking,Quantum
Programming Language, Proof of correctness, Complexity:22n initial
states.
Conclusion:With super exponential improvement in the time needed
for Model Checking of quantum protocols, we get stronger results.
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
12 / 15
The Tool: Quantum Equivalence Checker
QPL complier using SableCC.
QPL Interpreter using algorithms developed for stabiliser formalism.
Density operators basis generator.
Stabiliser states equality checkers.(Linear independence,Inner product)
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
13 / 15
The Tool: Quantum Equivalence Checker
QPL complier using SableCC.
QPL Interpreter using algorithms developed for stabiliser formalism.
Density operators basis generator.
Stabiliser states equality checkers.(Linear independence,Inner product)
Scheduler for dealing with quantum probabilistic branching.(In
progress)
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
13 / 15
Future Works
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
14 / 15
Future Works
Adding Concurrency to the QPL and implement it.
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
14 / 15
Future Works
Adding Concurrency to the QPL and implement it.
Investigating how Bisimulation can be defined and Implemented.
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
14 / 15
Future Works
Adding Concurrency to the QPL and implement it.
Investigating how Bisimulation can be defined and Implemented.
Developing tools for Communicating Quantum Processes.
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
14 / 15
Future Works
Adding Concurrency to the QPL and implement it.
Investigating how Bisimulation can be defined and Implemented.
Developing tools for Communicating Quantum Processes.
Improving the Model Checking performance by using more advanced
data strictures.(Quantum Binary Decision Diagrams)
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
14 / 15
Thank You!
Ebrahim Ardeshir (FOCS,DIMAP)
Equivalence Checking Quantum Programs
June 28, 2012
15 / 15
Download