foundations of quantum programming - tsinghua .foundations of quantum programming mingsheng ying

Download Foundations of Quantum Programming - Tsinghua .Foundations of Quantum Programming Mingsheng Ying

Post on 01-May-2019

214 views

Category:

Documents

0 download

Embed Size (px)

TRANSCRIPT

Foundations of Quantum Programming

Mingsheng Ying

University of Technology Sydney, AustraliaInstitute of Software, Chinese Academy of Sciences

Tsinghua University, China

Outline

Introduction

Syntax of Quantum Programs

Operational Semantics

Denotational Semantics

(Floyd-)Hoare Logic for Quantum Programs

Research Problems

Outline

Introduction

Syntax of Quantum Programs

Operational Semantics

Denotational Semantics

(Floyd-)Hoare Logic for Quantum Programs

Research Problems

How to program quantum computers?

I Quantum algorithms:

Deutsch-Josza, Grover, Shor, HHL, ...

Quantum algorithm zoo (http://math.nist.gov/quantum/zoo/)

I Quantum computers:

IBM Q (20 qubits Nov 2017; 50 qubits 2018)

Google (49 qubits 2018)

Intel (17 qubits Oct 2017)

How to program quantum computers?

I Quantum algorithms:

Deutsch-Josza, Grover, Shor, HHL, ...

Quantum algorithm zoo (http://math.nist.gov/quantum/zoo/)I Quantum computers:

IBM Q (20 qubits Nov 2017; 50 qubits 2018)

Google (49 qubits 2018)

Intel (17 qubits Oct 2017)

Quantum programming languages

I Q# @Microsoft

I Open Fermion @GoogleI Quil @RiggetiI Quipper @DalhousieI Scaffold @PrincetonI Project Q @ETHI QWire @UPennI Q|SI> @UTS

Quantum programming languages

I Q# @MicrosoftI Open Fermion @Google

I Quil @RiggetiI Quipper @DalhousieI Scaffold @PrincetonI Project Q @ETHI QWire @UPennI Q|SI> @UTS

Quantum programming languages

I Q# @MicrosoftI Open Fermion @GoogleI Quil @Riggeti

I Quipper @DalhousieI Scaffold @PrincetonI Project Q @ETHI QWire @UPennI Q|SI> @UTS

Quantum programming languages

I Q# @MicrosoftI Open Fermion @GoogleI Quil @RiggetiI Quipper @Dalhousie

I Scaffold @PrincetonI Project Q @ETHI QWire @UPennI Q|SI> @UTS

Quantum programming languages

I Q# @MicrosoftI Open Fermion @GoogleI Quil @RiggetiI Quipper @DalhousieI Scaffold @Princeton

I Project Q @ETHI QWire @UPennI Q|SI> @UTS

Quantum programming languages

I Q# @MicrosoftI Open Fermion @GoogleI Quil @RiggetiI Quipper @DalhousieI Scaffold @PrincetonI Project Q @ETH

I QWire @UPennI Q|SI> @UTS

Quantum programming languages

I Q# @MicrosoftI Open Fermion @GoogleI Quil @RiggetiI Quipper @DalhousieI Scaffold @PrincetonI Project Q @ETHI QWire @UPenn

I Q|SI> @UTS

Quantum programming languages

I Q# @MicrosoftI Open Fermion @GoogleI Quil @RiggetiI Quipper @DalhousieI Scaffold @PrincetonI Project Q @ETHI QWire @UPennI Q|SI> @UTS

This lectureI Principles underlying all of the quantum programming

languages

I Not the languages themselves.

I Reference:M. S. Ying, Foundations of Quantum Programming, MorganKaufmann 2016, Chapters 3 and 4.

This lectureI Principles underlying all of the quantum programming

languagesI Not the languages themselves.

I Reference:M. S. Ying, Foundations of Quantum Programming, MorganKaufmann 2016, Chapters 3 and 4.

This lectureI Principles underlying all of the quantum programming

languagesI Not the languages themselves.

I Reference:M. S. Ying, Foundations of Quantum Programming, MorganKaufmann 2016, Chapters 3 and 4.

Programming languages and tools

Programming languages are notations used for specifying, organisingand reasoning about computations.

[R. Sethi, Programming languages: Concepts and Constructs]

I Semantics

I Turing-complete?I ComiplersI Program analysis: Termination, ...I How to verify correctness of your programs?I ......

Programming languages and tools

Programming languages are notations used for specifying, organisingand reasoning about computations.

[R. Sethi, Programming languages: Concepts and Constructs]

I SemanticsI Turing-complete?

I ComiplersI Program analysis: Termination, ...I How to verify correctness of your programs?I ......

Programming languages and tools

Programming languages are notations used for specifying, organisingand reasoning about computations.

[R. Sethi, Programming languages: Concepts and Constructs]

I SemanticsI Turing-complete?I Comiplers

I Program analysis: Termination, ...I How to verify correctness of your programs?I ......

Programming languages and tools

Programming languages are notations used for specifying, organisingand reasoning about computations.

[R. Sethi, Programming languages: Concepts and Constructs]

I SemanticsI Turing-complete?I ComiplersI Program analysis: Termination, ...

I How to verify correctness of your programs?I ......

Programming languages and tools

Programming languages are notations used for specifying, organisingand reasoning about computations.

[R. Sethi, Programming languages: Concepts and Constructs]

I SemanticsI Turing-complete?I ComiplersI Program analysis: Termination, ...I How to verify correctness of your programs?

I ......

Programming languages and tools

Programming languages are notations used for specifying, organisingand reasoning about computations.

[R. Sethi, Programming languages: Concepts and Constructs]

I SemanticsI Turing-complete?I ComiplersI Program analysis: Termination, ...I How to verify correctness of your programs?I ......

Quantum circuit vs Quantum programs

Example: Quantum walk on a circle with an absorbing boundary.I Hd = span{|L, |R} the direction space, |L and |R indicate

directions left and right, respectively.

I Hp = span{|0, |1, ..., |n 1} the position space withorthonormal basis states, the vector |i denotes position i for each0 i n 1.

I The state space of the walk H = Hp Hd.I The initial state |0p|Ld.

Quantum circuit vs Quantum programs

Example: Quantum walk on a circle with an absorbing boundary.I Hd = span{|L, |R} the direction space, |L and |R indicate

directions left and right, respectively.I Hp = span{|0, |1, ..., |n 1} the position space with

orthonormal basis states, the vector |i denotes position i for each0 i n 1.

I The state space of the walk H = Hp Hd.I The initial state |0p|Ld.

Quantum circuit vs Quantum programs

Example: Quantum walk on a circle with an absorbing boundary.I Hd = span{|L, |R} the direction space, |L and |R indicate

directions left and right, respectively.I Hp = span{|0, |1, ..., |n 1} the position space with

orthonormal basis states, the vector |i denotes position i for each0 i n 1.

I The state space of the walk H = Hp Hd.

I The initial state |0p|Ld.

Quantum circuit vs Quantum programs

Example: Quantum walk on a circle with an absorbing boundary.I Hd = span{|L, |R} the direction space, |L and |R indicate

directions left and right, respectively.I Hp = span{|0, |1, ..., |n 1} the position space with

orthonormal basis states, the vector |i denotes position i for each0 i n 1.

I The state space of the walk H = Hp Hd.I The initial state |0p|Ld.

Quantum circuit vs Quantum programsI Each step of the walk:

1. Measure the system to see whether the current position is 1(absorbing boundary). If yes, terminates; otherwise, continues:

M = {Myes = |11| Id, Mno = IMyes};

2. A coin-tossingoperator C = 12

(1 11 1

)is applied on the

direction space;3. A shift operator

S =n1i=0|i 1i| |LL|+

n1i=0|i 1i| |RR|

is performed on the state space H.

I Question: How to specify it in the circuit language?

Quantum circuit vs Quantum programsI Each step of the walk:

1. Measure the system to see whether the current position is 1(absorbing boundary). If yes, terminates; otherwise, continues:

M = {Myes = |11| Id, Mno = IMyes};

2. A coin-tossingoperator C = 12

(1 11 1

)is applied on the

direction space;3. A shift operator

S =n1i=0|i 1i| |LL|+

n1i=0|i 1i| |RR|

is performed on the state space H.

I Question: How to specify it in the circuit language?

Quantum circuit vs Quantum programsI Each step of the walk:

1. Measure the system to see whether the current position is 1(absorbing boundary). If yes, terminates; otherwise, continues:

M = {Myes = |11| Id, Mno = IMyes};

2. A coin-tossingoperator C = 12

(1 11 1

)is applied on the

direction space;

3. A shift operator

S =n1i=0|i 1i| |LL|+

n1i=0|i 1i| |RR|

is performed on the state space H.

I Question: How to specify it in the circuit language?

Quantum circuit vs Quantum programsI Each step of the walk:

1. Measure the system to see whether the current position is 1(absorbing boundary). If yes, terminates; otherwise, continues:

M = {Myes = |11| Id, Mno = IMyes};

2. A coin-tossingoperator C = 12

(1 11 1

)is applied on the

direction space;3. A shift operator

S =n1i=0|i 1i| |LL|+

n1i=0|i 1i| |RR|

is performed on the state space H.

I Question: How to specify it in the circuit language?

Quantum circuit vs Quantum programsI Each step of the walk:

1. Measure the system to see whether the current position is 1(absorbing boundary). If yes, terminates; otherwise, continues:

M = {Myes = |11| Id, Mno = IMyes};

2. A coin-tossingoperator C = 12

(1 11 1

)is applied on the

direction space;3. A shift operator

S =n1i=0

Recommended

View more >