QiskitGlobalSummerSchool Day3 QFTQPE AbeAsfaw

Download as pdf or txt
Download as pdf or txt
You are on page 1of 13

ShorbAlgorithmiandQPEd

Lecture3

Roadway G Qubits Quantum states


b ft H Y
H
Elif x
lo
147 alo tbh
Lol 47 a
j 4147 b j
Bob measo Halt Rob me as 1 Hbk

all't Hbk I 2 implications

l Operations quantum stales need to preserve


on norm to 1
t
Norm preserving matrices unitary U U
Utu au EI
det u I I
unitary
2 For a single qubit can think of gates as rotations on the
surface of the Bloch sphere
3 Eigenvalues and eigenvectors of unitary matrices are special
Ca U la Has
Salut Laila
Sulu I Latitude Cal XIX.la 1 12 calx 1 12
1 12 1 XE e for some 0
eigenvalues of U are of the form e
b U Ix tsetse tatty then
if
U
ly Ay ly saly calutuly XyLady
txt Xy Lady l titty 0
agrees of diff edguals multiplybyXx exly
are orthonormal and use 1 121 Lady Xx Xy O
Also covered Deutsch Josza algorithm
constant 1balanced function in one shot
Grover's algorithm

unstructured search in N items with 0 rn

Today Preliminaries for Shor's algorithm


famous algorithm

Problem
given a function that is periodic find its period period
for la k kf
strict definition f fly sety iff
se
y
np
21T
easy example

hard example 5

µwh g

classically 0 exp 43
c n 13µg a
P has n bits
quantum Shor's algorithm 0 n'Clog n loglog n
little faster than 0hr3
Reason why this works 1 quantum Fouriertransform
2 modular exponentiation
Implication difficulty of factoring on a classical computer is basis
for security more tomorrow
f m

Today Quantum Fourier Transform


Quantum Phase Estimatoon
shores algorithm is really QPE in disguise

QFT is effectively a change of basis from the computational


basis to a Fourier basis
1 qubit states in computational basis are 10 and 117
eg
States in Fourier basis are H7 and I 7

lot ID

ta
lo 107

105 IT

117 117

multiple qubits go to Qishit demo


notice that bases on thetwo poles of the
going from
we are

Block sphere to a basis on the equatorial plane


Building the quantum circuit that applies QFT
1 Show QFT rigorously
2 show circuit to implement QFT expression

l m qubits 2 basis states Define N 2 Then

IT QFT be
p t
Fourierbasis computational basis
N I
zitisey
analogous to inverse discrete
Z ENT y Fourier transform
y o

eg 1 qubit case N 2

To
ta My ta IZ Y
lo HD

it in El n
lo C D 117

107 117

A note on notation formultiple qubits eg n 3

eatin8 231y y
IIe 11 of
gy o eg ly I't
4 22 l t 2 lo t 20 o
4
23 2417
12403 12
0323
N I Y Cycyrys Yun
Tse 210ft 2n y
tip foe
12 Yu
1
y

oe.TT
imi hiyn

shy
e4 IYu
Yuya ynk

fro e
i i
in
eating
go g
TIE
k 4 term to my
62 term to t Iti F ly
notice i D foe Nz Az An

ye 0 MHz kn l
2
OOH Uz Rn 2
Hq
Final
form't lost e EH lo e h

lost eat Eun y


Fatah se to
Example
n 3 qubits N 23 8

be 157
QFT la lost e EH lo e Em
eatiEhs
do
Notice 2mi E 2Ti
E tf
21T 21
z
since e2TiZ
1 forany integer Z
Tilt
e2Ti I 2
2
eati eti I
in eminently

Ez eatin'Enly
0
9 n k
Let's write y Yk2 y Yi Yn
zn y 2 yw
u
then y Yh 2k and we have
gn
n

ta 1µg
eat Emily ya yn
Yeo
n 21T t 12h

If II ly.y
e yn

remember
o j
to
127 1 to I Tn lost b
if
lo EI In

Notice that we went from


Isen to
be se I see
1st lo te 2H lo te 22HD lo te T1
TheQuantamCiraitthatimplementsQFTI
Notice that we went from
Ise I see Ise Ian to
1st lo te 2H lo te 24iD lo te T1
42k
each qubit went from Izzy to Io IT
aIions lyy.TW2Tifz Zzt tEJ
G lot contains terms like 2 e 11111 11117

Is e E E e

e too to Hints
phase is qubit dependent
e2TiH2t l lo oo needto add up more components with
1more 1

Two ingredients needed


107 117 he
D H1 seu E
4 k
lo 117 rz
Oort
toy e'time 117 r2
2lTiIk
E 2

G UROTulsej e lap
WROTE to 2k
211424
f
applies phase e
THI DURAI ITURot URoTn
i

tii

step 0 Ise uz seu


n
step 1 lo e 117 bez an

to e'Time seipp I
steps
i
step 3 lo t e e me Mµy
n
im
c
step n lost e e ly

1
exp
Ii
Fat KINI
t
My
recall se 2 se 2 2kt t I nu
t
age Zen
term above is 21T
exp if
after step ni lost e 711 being sen

reverted
order fromderivedform but ok otherwise
Part II Quantum Phase Estimation

Here we will use QFT to do a


very
useful thing

Problem Recall that a unitary matrix has eigenvalues of the


form ei0 and that it has eigenvectors thatform an
orthonormal basis

U ly ei04147
Can we extract 04 given the ability to prepare 147

Solution Yes Use QPE


Why do we care Hamiltonian evolution operator is unitary
implications for q simulation

QPE trick i controlled U


I g f l

107 i Dt t.TT
F
c
c q l

I
THX Duet 1
c
o I
2 3

step o to 147
step 1 107147 117147
t
step 2 lo 147 t 117 e04147
04 Go ID 143
step 3 f 107 1 117 47 t e

I to Hei 04 t H l e
4
147

measure qubit O

prob µte Y measure


almost 12 each but
I 1 with small shift
prob ez 12 measure

if 04 0 prob o cos z4
prob I sin Et
To measure precisely using this bit of
information need to do
lots of measurements
155
04 10 Pablo Prob D 09999,7 615
eg
04 100 n 0.9924 O 007596

not a good idea to to with


such low precision
try measure

Beller solution use multiple qubits to measure the phase

TF
i

he I ITEEFI 7u
2
step 0 1050 147
0
step I lo t 1177 147
GET
Before proceeding note 212 147 UE U 147

wite 04147
42
e 147
I E
step z lo tei I co Eat Ip
2g
D t e y
Us app
n
127 lo I In lost b
iz
lo e In

the form is the same but 04 at


02 so do inverse QFT

he
iF

T
TTT
ITEEFI Fug Tue
24
Measurement should yield
10

You might also like