Quantum Computing
Quantum Computing
COMPUTING
Exercise 1.8. Consider the following gate that inverts the inputs before passing them into an AND gate,
sometimes called a negative-AND gate:
ÖÖ =
1
(a) Write the truth table for this circuit. (b) What logic gate is this equivalent to?
a
35=
I 8 .
= 0
1 .
I 1 = 0
- -
b)
Nor
gate
:
[ -z
z =
X Y NOR
00 1
010
100
110
Exercise 1.10. In some homes, special switches are used so that two switches control a single light. Often, these
switches are located at opposite ends of a stairway or a hallway, and either switch can be used to turn the light
on or off. A traditional switch enables or disables the flow of electricity through a single wire. In contrast, these
special switches, called three pole switches, choose between two different wires. The following electrical circuit
gives an example:
Each switch has three poles, labeled C, 0, and 1. Switch A is current flipped up, which connects C and 0. Switch
B is currently flipped down, which connects C and 1. In this configuration, there is a complete path for the
electricity to flow. It comes out of the positive end of the battery, through Switch A along A = 0, then down to B
= 1, then through Switch B, then down through the light bulb, left through the bottom wire, and up to the
negative end of the battery. So, the light bulb is on when A = 0 and B = 1.
(a) Say A = 0 and B = 0. Sketch the circuit and draw arrows indicating the path through which the
electricity is flowing. Is the light bulb off or on?
(b) Say A = 1 and B = 0. Sketch the circuit and draw arrows indicating the path through which the
electricity is flowing. Is the light bulb off or on?
(c) Say A = 1 and B = 1. Sketch the circuit and draw arrows indicating the path through which the
electricity is flowing. Is the light bulb off or on?
(d) What logic gate does the circuit correspond to?
al off .
b) off.
doff .
d) XOR gate .
Exercise 1.13. What is the truth table for the following circuit diagram?
Note the solid dot simply means that the wires are connected there. Then, C is both inputs of the NAND gate, so
the gate takes the NAND of C with itself.
A BC (A + B)C
1 (I = =
O S =
I =
1
+
1 = 0 =
O -- 15 =
1 =
=
1 (1 + c
=
O (2 + 1) =
-
&
1 (1 +
1) = =
Exercise 1.18. Draw a circuit diagram using only NAND gates that implements the following truth table:
·... - output
S
Exercise 1.21. Consider the anti-Toffoli gate, which flips the third bit if the first two bits
are both 0:
a) -
BC A B ABC
1 0 + 0 =
1
ÖÖ
+
1 =
e
O
1
--
1 li + 1 = 1
b) OR
C R
d) A
II
Toffi
↑
A ⑤
C i 5B + C
Exercise 1.25. An error-detecting scheme is to send a parity bit. For example, say I want to transmit to you the
character “Q” in ASCII, which is encoded by seven bits 1010001. The parity of this bit string is odd, since there
is an odd number of 1’s in the string. (Alternatively, taking the XOR of all the bits yields 1.) I append this parity
of 1 to the transmission, so I send you the eight bits 10100011.
Say the bits you actually receive are 11100011.
(a) Calculate the parity of the first seven bits you received.
(b) Does the parity you calculated in part (a) match the parity bit (the last bit)?
(c) Did an error occur in the transmission? Why or why not?
(d) Can this scheme reliably detect if more than one error occurred? Why or why not?
b) o ,
because the last number is 1 (the light bit) instead of 0 .
2) Yes ,
because the eight bit (in the parity) is
wrong because is 1 instead of 0
.
d) Yes ,
There is one error in the parity .
bit
to not be in P .
Exercises 2 – The Qubit
Exercise 2.3. Consider the complex number z = −3 − i.
a) Find R(z).
b) Find I(z).
c) Plot z as a point in the complex plane.
d) Write z in polar form reiθ . Hint: The angle should be between π and 3π /2 (i.e., 180º
and 270º ).
e) Find z∗.
f) Find |z|.
2
g) Find |z|
a) R(z) =
-
3 f)(z) =
( 3) +
1 -
17 =
Mo
b) [(z) = -
1 g) (zk =
R(z) + [(z)" = 10
piltan" (113) m) m)
No e13 1809 yo
46
Noeilo'32
:
+ +
d) orvoei (18 4 +
Noe
: 198
.
, ,
10 =
= =
Exercise 2.7. The following two states are opposite points on the Bloch sphere:
So, we can measure relative to them. Now consider a qubit in the state
al Para escribir los ceseficientes de la) y /b) en la combinación lineal de los y /1) usando sus
prod internos .
-(( i)(a) 3
+/b)
+
-
b) plas
= 10 -
112) 1931 .
=
2
P(b) /E10 -(2) 1632
2
= -
.
=
Exercise 2.9. A qubit is in the state
a) Where on the Bloch sphere is this state? Give your answer in relación sacada de
(θ,φ) coordinates. coordenadas esféricas
b) Sketch the point on the Bloch sphere. ↓ Hilbert
en
en el espacio de .
0 = 200s (1c)
al Para las coordenadas (0 0) C
B
=
encontrar , Utilizaremos las siguientes relaciones
b =
arg(p)
j ,
amplitudes
2 (1 i)
- prob del
=
de
-
2 qubit para
10 Y (1)
1) : yarg() =
ag
0 :
2cos"(E) =
0 = 1
2
SOLUCIÓ (*, )
b) Z
X ·
y (10 + i (1)
Exercise 2.11. Consider a map U that transforms the Z-basis states as follows:
(4) = C (0) +
B(1)
B
/0
Portanto VIY
+ (2)
+ 5 +
3iB11
=
(0) -
(B +
v ip)(0)
+
+
( =3ip)(1)
6) Una puerta cuántica es válida si es unitaria, es decir , si preserva la norma la info de la amplitud
y
.
a) cal en términos de (014/11 , expresamos (al como combinación lineal de (01 y (11
( al
= 01 +
E(1)
b) las como vector fila :
(a) =
()
c) (b1 en términos de Col y (11 , expresamos (b1 como combinación lineal de COI y (1)
+
(bl :E
d)(bl =
(alb) i
3
. +
Ex
= 0
-
x =
i5 -
3
1bk (xi
/5(2 1
= =
+
: 0
X
= sorción x e rs
: =
=
1 b) = normalizado
c) Para que las y /b) sean ortonormales :
E <alb) = 1
+
x = 8 -
i5
-
Y
al lo encontrar las matrices de cambio de base : H
= ()
20 Ahora Calculamos HIY
= (1) = (1)
30 solución 14
=E-
:
soluci
20 se calcula U14) y con eso obtenemos la
30 solución :
-
1 -
3i
14) (i) i
+
= -
25
1 (3 +
i)(1 i)
a)
-
U =
25 -
(1 +
i)(3 i) -
(3 i]a-Chris
+
VIPS-1 (3 i)d -
+ (1 i)ß -
i
1B](3 ()
(+ i
-[3
+
i - i ( i)
-
vu =
+ +
,
-
+ 2 -
=
(3 -
i)d + (1 i)ß
-
Sí es unitario
producto tensorial
a
0
+ 00) +Es
b) 14 =
[10i]
de un solo
qubit
143 =
(a)G(b) =
(ay(0) + a
= (1))(be(0) + b2 (1))
El estado 14) podría escribirasi
(103 E113)@(10 E11))
:
se
+ -
b)
t 10) 1 +3
+ (2) ( +
= 1010 + 1x)
+ 12)()(10) -
12))
No se
puede separar esta , por lo tanto
expresión
ES ENTRELAZADO
Este operador puede ser construido por otras puertas más básicas como seve.
10000000
O 1 000000
0 O 1 0 0 0 0 0
0 0010 0 0 0
0 0 0 0 100 0
0 0 0 0 0 10 o
0 0 0 0 0 0 O 1
00000010