|q⟩
Bad Qubits
Play
Quest
Questions
Learn
Playground
☕
← Question Bank
Multiple choice
A circuit prepares
R
Y
(
θ
)
∣
0
⟩
RY(\theta)|0\rangle
R
Y
(
θ
)
∣0
⟩
, so the cost
E
(
θ
)
=
⟨
Z
⟩
=
cos
(
θ
)
E(\theta) = \langle Z\rangle = \cos(\theta)
E
(
θ
)
=
⟨
Z
⟩
=
cos
(
θ
)
. Using the parameter-shift rule, the gradient is
0.5
(
E
(
θ
+
π
/
2
)
−
E
(
θ
−
π
/
2
)
)
0.5(E(\theta + \pi/2) - E(\theta - \pi/2))
0.5
(
E
(
θ
+
π
/2
)
−
E
(
θ
−
π
/2
))
. At
θ
=
0.8
\theta = 0.8
θ
=
0.8
, what is
d
E
/
d
θ
dE/d\theta
d
E
/
d
θ
?
-0.6967
-0.3587
-0.7174
0.7174
Check answer