2
$\begingroup$

I'm working through MIT's Quantum Information Science I, Part 1 on OpenCourseWare, and for the life of me I can't figure out the following problem:

Quantum circuit

Given the circuit above, where the meter sign denotes the measurement with $\{|0⟩,|1⟩\}$ basis:

  • Suppose $U$ is a unitary having eigenvalue $e^{i\theta_1}$ with eigenstate $|u_1\rangle$, and eigenvalue $e^{i\theta_2}$ with eigenstate $|u_2\rangle$. Also, suppose that $e^{i\theta_1} \ne e^{i\theta_2}$. Let $|\psi_i=a|u_1\rangle+b|u_2\rangle$ where $a,b$ are real numbers satisfying $a^2+b^2=1$. Find the probability of getting the measurement result 0. Express the probability in terms of $a$, $\cos(\theta_1)$, and $\cos(\theta_2)$.

So far, I think I've managed to work out that, after the second Hadamard gate, we have $a(1+e^{i\theta_1}+b(1+e^{i\theta_2})) \otimes |+\rangle$. However, I'm absolutely confused about where to go next.

Our starting state is $|0\rangle \otimes |\psi_i\rangle$.

Then, we perform a Hadamard operation on the first qubit, and we get $|+\rangle \otimes |\psi_i\rangle$.

Then, we perform the controlled-U operation, and we get $(|0\rangle \otimes (a|u_1\rangle + b|u_2\rangle) + |1\rangle \otimes (e^{i\theta_1}a|u_1\rangle + e^{i\theta_2}b|u_2\rangle))$.

Finally, we perform a Hadamard operation on the first qubit again, getting state $(|0\rangle \otimes (a(1+e^{i\theta_1})|u_1\rangle + b(1+e^{i\theta_2})|u_2\rangle)) + (|1\rangle \otimes (a(1-e^{i\theta_1})|u_1\rangle + b(1-e^{i\theta_2})|u_2\rangle))$.

However, when I try to calculate the probability of measuring |0>, the math explodes and I wind up with crazy terms like $a^2(2i\cos\theta_1+2i\sin\theta_1+2\cos^2\theta_1+2\cos\theta_1)\cos^2\theta_1)+b^2(2i\cos\theta_2+2i\sin\theta_2+2\cos^2\theta_2+2\cos\theta_2)\cos^2\theta_2)$. Am I going wrong conceptually here or mathematically?

$\endgroup$
8
  • $\begingroup$ Since we don't know how to express $a|u_1\rangle + b|u_2\rangle$ in the standard basis, I'm a little unsure how to properly track the state through each gate, but here's what I have so far: - Prior to the first gate: $|0> \otimes a|u_1\rangle + b|u_2\rangle$ $\endgroup$ Commented Nov 3 at 23:40
  • $\begingroup$ - Prior to the first gate: $|0> \otimes a|u_1\rangle + b|u_2\rangle$ $\endgroup$ Commented Nov 3 at 23:46
  • $\begingroup$ - After the first Hadamard gate: $|+> \otimes a|u_1\rangle + b|u_2\rangle$ $\endgroup$ Commented Nov 3 at 23:46
  • $\begingroup$ - After the controlled U: $(|0\rangle \otimes a|u_1\rangle + b|u_2\rangle) + (|1> \otimes e^{i\theta_1}a|u_1\rangle + e^{i\theta_2}b|u_2\rangle)$ $\endgroup$ Commented Nov 3 at 23:46
  • $\begingroup$ - After the second Hadamard gate: $(|0\rangle \otimes (1+e^{i\theta_1})a|u_1\rangle + (1+e^{i\theta_2})b|u_2\rangle) + |1\rangle \otimes (1-e^{i\theta_1})a|u_1\rangle + (1-e^{i\theta_2})b|u_2\rangle)$ $\endgroup$ Commented Nov 3 at 23:46

1 Answer 1

4
$\begingroup$

Your initial state is $$ |0\rangle\otimes|\psi_i\rangle=|0\rangle\otimes(a|u_1\rangle+b|u_2\rangle). $$ After the first Hadamard, this becomes $$ \frac{1}{\sqrt{2}}(|0\rangle+|1\rangle)\otimes(a|u_1\rangle+b|u_2\rangle). $$

Now, the key is what to do with controlled-$U$. If the top qubit is $|0\rangle$, do nothing: $$ |0\rangle\otimes(a|u_1\rangle+b|u_2\rangle)\rightarrow |0\rangle\otimes(a|u_1\rangle+b|u_2\rangle) $$ while if the first qubit is $|1\rangle$, apply $U$ to the second register: $$ |1\rangle\otimes(a|u_1\rangle+b|u_2\rangle)\rightarrow |1\rangle\otimes U(a|u_1\rangle+b|u_2\rangle)=|1\rangle\otimes(ae^{i\theta_1}|u_1\rangle+be^{i\theta_2}|u_2\rangle). $$ This means that, after the controlled-$U$, the full state is $$ \frac{1}{\sqrt{2}}\left( |0\rangle\otimes(a|u_1\rangle+b|u_2\rangle)+|1\rangle\otimes(ae^{i\theta_1}|u_1\rangle+be^{i\theta_2}|u_2\rangle) \right). $$ Now we do the final Hadamard: $$ \frac{1}{2}\left( (|0\rangle+|1\rangle)\otimes(a|u_1\rangle+b|u_2\rangle)+(|0\rangle-|1\rangle)\otimes(ae^{i\theta_1}|u_1\rangle+be^{i\theta_2}|u_2\rangle) \right). $$ Collect the terms of $|0\rangle/|1\rangle$ on the first qubit: $$ \frac12|0\rangle(a(1+e^{i\theta_1})|u_1\rangle+b(1+e^{i\theta_2})|u_2\rangle)+\frac12|1\rangle(a(1-e^{i\theta_1})|u_1\rangle+b(1-e^{i\theta_2})|u_2\rangle). $$ Finally, you want to know the probability that the first qubit is measured in state $|0\rangle$. This is just the square of the length of that term: $$ \|\frac12|0\rangle(a(1+e^{i\theta_1})|u_1\rangle+b(1+e^{i\theta_2})|u_2\rangle)\|^2=\frac14\|a(1+e^{i\theta_1})|u_1\rangle+b(1+e^{i\theta_2})|u_2\rangle\|^2. $$ You don't need to know what the two vectors $|u_i\rangle$ look like in the standard basis. All you need to know is that they have length 1, and are orthogonal to each other (because they are eigenvectors). Thus, the probability is $$ \frac14\left(|a(1+e^{i\theta_1})|^2+|b(1+e^{i\theta_2})|^2\right), $$ which is the same as $$ \frac14\left(|a(e^{-i\theta_1/2}+e^{i\theta_1/2})|^2+|b(e^{-i\theta_2/2}+e^{i\theta_2/2})|^2\right), $$ and thus $$ |a|^2\cos^2(\theta_1/2)+|b|^2\cos^2(\theta_2/2) $$

$\endgroup$
4
  • $\begingroup$ Thank you! I was trying to work it out in matrix form, which was where I ultimately went wrong. I think I understand all your steps here except for one: how did you go from $1+e^{i\theta_1}$ to $e^{-i\theta_1/2}+e^{i\theta_1/2}$? $\endgroup$ Commented Nov 9 at 16:40
  • $\begingroup$ I used a more roundabout method, but I arrived at the same solution: $\frac{1}{4}(|a(1+e^{i\theta_1}|^2+|b(1+e^{i\theta_2})|^2) = \frac{1}{4}(|a(1+e^{i\theta_1})|^2||u_1\rangle|^2+|b(1+e^{i\theta_2})|^2||u_2\rangle|^2)=\frac{1}{4}(|a(1+e^{i\theta_1})|^2|+|b(1+e^{i\theta_2})|^2|)$. $\endgroup$ Commented Nov 9 at 16:51
  • $\begingroup$ We can simplify $\cos\theta^2+\sin\theta^2+2\cos\theta+1$ to either $4\cos(\frac{\theta}{2})^2$ or $2(\cos\theta + 1)$, so our answer becomes either $a^2\cos^2\frac{\theta_1}{2}+b^2\cos^2\frac{\theta_2}{2} = a^2(\cos^2\frac{\theta_1}{2}-\cos^2\frac{\theta_2}{2})+\cos^2\frac{\theta_2}{2}$ OR $\frac{1}{2}(a^2(\cos\theta_1+1)+b^2(\cos\theta_2 + 1) = \dfrac{a^2(\cos\theta_1 - \cos\theta_2) + \cos\theta_2 + 1}{2}$ $\endgroup$ Commented Nov 9 at 16:55
  • $\begingroup$ $1+e^{i\theta}=e^{i\theta/2}(e^{-i\theta/2}+e^{i\theta/2})$. The global factor disappears in the norm. $\endgroup$
    – DaftWullie
    Commented Nov 11 at 7:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.