Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current...

57
Quantum Computing deep dive Johnny Hooyberghs Robin Vercammen

Transcript of Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current...

Page 1: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Quantum Computingdeep dive

Johnny HooyberghsRobin Vercammen

Page 2: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Why am I presenting this talk?

• As a human, I like to experiment and discover

• As a software engineer, I like to learn new technical stuff

• As a teacher, I like to teach and get people enthusiastic

Page 3: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

What will you do after this talk?

• Be able to explain why quantum computing matters?

• Study more about quantum computing?

• Understand the basics about quantum computing?

• Run quantum algorithms using IBM Q Experience and Microsoft Q#?

• Decipher quantum algorithms?

• Use quantum computing tomorrow?

• Use quantum computing in the next decade?

Page 4: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Agenda

• Why Quantum Computing?

• Classic vs. Quantum

• Quantum superposition & entanglement

• Bit vs. Qubit

• IBM Q Experience

• Microsoft Q#

• Quantum Algorithms

Page 5: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Why Quantum Computing?

• Moores law has its physical limits

• Current classical computing architectures already have issues withquantum effects because of their scale

• Why try to simulate a quantum world using classical computers

Page 6: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Why Quantum Computing?

Page 7: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Why Quantum Computing?

Page 8: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Classical vs. Quantum

• Security

• Public / private key encryption

• Makes current encryption obsolete

• QKD (Quantum Key Distribution)

Page 9: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Classical vs. Quantum

• Artificial Intelligence

• Analyze large quantities of data

• Fast feedback

• Emulate human mind

Page 10: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Classical vs. Quantum

• Drug development

• It takes a quantum system to emulatequantum mechanics

• Interactions between molecules

• Gene sequencing

Page 11: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of
Page 12: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Superposition and Entanglement

• Quantum Physics describes superposition and entanglement ofquantum particles

• Quantum Computing can use these phenomenon to its advantage

Page 13: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Superposition

Page 14: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Superposition

Page 15: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Entanglement

Page 16: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Bits vs. Qubits

0 1

Page 17: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Bits vs. Qubits

1

0

0

1

Page 18: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Bits vs. QubitsIdentity = 0 0

1 0

0 1

1

0=

1

0

1 11 0

0 1

0

1=

0

1

Negation = ¬ 0 10 1

1 0

1

0=

0

1

1 00 1

1 0

0

1=

1

0

Constant-0 = 0 0 01 1

0 0

1

0=

1

0

1 01 1

0 0

0

1=

1

0

Constant-1 = 1 0 10 0

1 1

1

0=

0

1

1 10 0

1 1

0

1=

0

1

Page 19: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Bits vs. Qubits

• Classical bit 0, Quantum bit |0⟩

• Classical bit 1, Quantum bit |1⟩

• Quantum bit in superposition

|0⟩ + |1⟩ where | | + | | = 1

• and are complex number a + b

• Value known after measurement

• Collapses to 0⟩ with probability or 1⟩ with probability

Page 20: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Bits vs. Qubits

• 2 Qubit system (4 values):

|00⟩ + |01⟩ + |10⟩ + |11⟩

• 3 Qubit system (8 values):

|000⟩ + |001⟩ + |010⟩ + |011⟩ + |100⟩ + |110⟩ + |101⟩ + |111⟩

• 4 Qubit system (16 values):…

Page 21: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Bits vs. Qubits

| ⟩ = |0⟩ + |1⟩

| ⟩ = cos |0⟩ + sin |1⟩

Page 22: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Bits vs. Qubits

Page 23: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

XBits vs. Qubits

0 1

1 0

Bit-Flip

Page 24: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Bits vs. Qubits

1

2

1

2

1

2

− 1

2

H Hadamard

Page 25: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Bits vs. Qubits

1 0 0 00 1 0 00 0 0 10 0 1 0

+

CNOT(2-qubit gate)

Page 26: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Bits vs. Qubits

Measurement

• Collapses a qubit to either| ⟩ or | ⟩

• A qubit in superposition hasa 50% chance to collapse to| ⟩ and a 50% chance tocollapse to | ⟩

• A measurement destroys anycomplex quantum state

Page 27: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Entanglement

|0⟩

|0⟩ H

+

|0⟩ =10

|0⟩ =10 →

1

2

1

21

2

− 1

2

10

=

1

21

2

=

1

21

2

⨂10

=

1

201

20

1 0 0 00 1 0 00 0 0 10 0 1 0

1

201

20

=

1

2001

2

= ?

Page 28: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Entanglement

• If the product state of two qubits cannot be factored, they are entangled

1

2001

2

= ⨂ →

=1

2= 0= 0

=1

2

• This set of two qubits has a 50% chance of collapsing to |00⟩ and a 50%chance of collapsing to |11⟩

Page 29: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

IBM Q Experience

• https://quantumexperience.ng.bluemix.net

Page 30: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Microsoft Q#

• https://www.microsoft.com/en-us/quantum/development-kit

Page 31: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Quantum Algorithms

• Deutch (1985)• Is there a problem that a Quantum Computer can solve faster than a Classical

Computer?• Deterministic!

• Deutsch–Jozsa (1992)• Based on Deutch (for 1 bit), but applicable for n-bits• Deterministic!

• Grover's algorithm (1996)• “Searching a database”• Probabilistic!

• Shor's algorithm (1994)• Prime factorization of large integers• Combination of classical and quantum algorithm• Probabilistic!

Page 32: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Can a Quantum Computer be quicker than a Classical Computer?

• A Black-Box containing a function on one bit

• How many operations do you need to figure out the function ifinput and output is know?

• On a Classical Computer?

• On a Quantum Computer?

| ⟩ | ⟩BB

Page 33: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• It is important to ask the right question!

• A Black-Box containing a function on one bit

• How many operations do you need to figure out if the function isCONSTANT or VARIABLE if input and output is know?

• On a Classical Computer?

• On a Quantum Computer?

| ⟩ | ⟩BB

Page 34: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• It is important to ask the right question!

• A Black-Box containing a function on one bit

• How many operations do you need to figure out if the function isCONSTANT or VARIABLE if input and output is know?

• On a Classical Computer?

• On a Quantum Computer?

|0⟩ | ⟩

BB| ⟩ | ⟩

Page 35: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• If BB is a constant function Quantum state will always measure to |11⟩

• If BB is a variable function Quantum state will always measure to |01⟩

|0⟩ |?⟩

|0⟩ |?⟩

X

X

H

H

H

H

BB

Page 36: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Constant-0

|0⟩ |0⟩

BB| ⟩ | ⟩

|0⟩ |0⟩

| ⟩ | ⟩

?

Page 37: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Constant-0

|0⟩ |0⟩

BB| ⟩ | ⟩

|0⟩ |0⟩

| ⟩ | ⟩

Page 38: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Constant-1

|0⟩ |1⟩

BB| ⟩ | ⟩

|0⟩ |1⟩

| ⟩ | ⟩

?

Page 39: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Constant-1

|0⟩ |1⟩

BB| ⟩ | ⟩

|0⟩ |1⟩

| ⟩ | ⟩

X

Page 40: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Identity

|0⟩ | ⟩

BB| ⟩ | ⟩

|0⟩ | ⟩

| ⟩ | ⟩

?

Page 41: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Identity

|0⟩ | ⟩

BB| ⟩ | ⟩

|0⟩ | ⟩

| ⟩ | ⟩

+

Page 42: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Negation

|0⟩ |¬ ⟩

BB| ⟩ | ⟩

|0⟩ |¬ ⟩

| ⟩ | ⟩

?

Page 43: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Negation

|0⟩ |¬ ⟩

BB| ⟩ | ⟩

|0⟩ |¬ ⟩

| ⟩ | ⟩

+ X

Page 44: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Constant-0 (circuit overview)

|0⟩ |1⟩

|0⟩ |1⟩

X

X

H

H

H

H

Page 45: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Constant-0 (calculated proof – part 1)

|0⟩ =10 →

0 11 0

10

=01 →

1

2

1

21

2

− 1

2

01

=

1

2− 1

2

|0⟩ =10 →

0 11 0

10

=01 →

1

2

1

21

2

− 1

2

01

=

1

2− 1

2

Page 46: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Constant-0 (calculated proof – part 2)

1

2− 1

2

1

2

1

21

2

− 1

2

1

2− 1

2

=01

= |1⟩

1

2− 1

2

1

2

1

21

2

− 1

2

1

2− 1

2

=01

= |1⟩

Page 47: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Constant-1 (circuit overview)

|0⟩ |1⟩

|0⟩ |1⟩

X

X

H

H

H

H

X

Page 48: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Constant-1 (calculated proof – part 1)

|0⟩ =10 →

0 11 0

10

=01 →

1

2

1

21

2

− 1

2

01

=

1

2− 1

2

|0⟩ =10 →

0 11 0

10

=01 →

1

2

1

21

2

− 1

2

01

=

1

2− 1

2

Page 49: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Constant-1 (calculated proof – part 2)

1

2− 1

2

→0 11 0

1

2− 1

2

=

− 1

21

2

1

2

1

21

2

− 1

2

− 1

21

2

=0

− 1= |1⟩

1

2− 1

2

→1 00 1

1

2− 1

2

=

1

2− 1

2

1

2

1

21

2

− 1

2

1

2− 1

2

=01

= |1⟩

Page 50: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Identity (circuit overview)

|0⟩ |1⟩

|0⟩ |0⟩

+X

X

H

H

H

H

Page 51: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Identity (calculated proof – part 1)

|0⟩ =10 →

0 11 0

10

=01 →

1

2

1

21

2

− 1

2

01

=

1

2− 1

2

|0⟩ =10 →

0 11 0

10

=01 →

1

2

1

21

2

− 1

2

01

=

1

2− 1

2

=

1

2− 1

2

1

2− 1

2

=

1

2

−1

2

−1

21

2

Page 52: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Identity (calculated proof – part 2)

1

2

−1

2

−1

21

2

1 0 0 00 1 0 00 0 0 10 0 1 0

1

2

−1

2

−1

21

2

=

1

2

−1

21

2

−1

2

=

1

21

2

1

2− 1

2

=

1

2− 1

2

1

2

1

21

2

− 1

2

1

2− 1

2

=01

= |1⟩

1

21

2

1

2

1

21

2

− 1

2

1

21

2

=10

= |0⟩

Page 53: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Negation (circuit overview)

|0⟩ |1⟩

|0⟩ |0⟩

+X

X

H

H

H

H

X

Page 54: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Negation (calculated proof – part 1)

|0⟩ =10 →

0 11 0

10

=01 →

1

2

1

21

2

− 1

2

01

=

1

2− 1

2

|0⟩ =10 →

0 11 0

10

=01 →

1

2

1

21

2

− 1

2

01

=

1

2− 1

2

=

1

2− 1

2

1

2− 1

2

=

1

2

−1

2

−1

21

2

Page 55: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

Deutsch's algorithm

• Negation (calculated proof – part 2)

1

2

−1

2

−1

21

2

1 0 0 00 1 0 00 0 0 10 0 1 0

1

2

−1

2

−1

21

2

=

1

2

−1

21

2

−1

2

=

1

21

2

1

2− 1

2

=

1

2− 1

2

→0 11 0

1

2− 1

2

=

− 1

21

2

1

21

2

→1 00 1

1

21

2

=

1

21

2

1

2

1

21

2

− 1

2

− 1

21

2

=0

− 1= |1⟩

1

2

1

21

2

− 1

2

1

21

2

=10

= |0⟩

Page 56: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

“About your cat, Mr. Schrödinger – I have goodnews and bad news.”

Page 57: Quantum Computing...Why Quantum Computing? • Moores law has its physical limits • Current classical computing architectures already have issues with quantum effects because of

−Johnny Hooyberghs

Robin Vercammen

[email protected]

@djohnnieke

[email protected]

@Robin_Vercammen

https://github.com/Djohnnie/QuantumComputingQSharpIntroduction2018

www.involved-it.be