I'm making a quantum circuit with qubits and quantum gates. While I'm doing it, I have some problem with it. My calculation process is below. enter image description here

As you can see, start qubit is $|0 \rangle$ and after 'X' gate, the result will be $|1 \rangle$. And I checked if the result of quantum circuit and density matrix form of $|1 \rangle$ are different. As you can see, they are different.

Here are my questions.

  1. Why it occurs?
  2. If they are different, is my calculation wrong?

1 Answer 1


When you evolve a pure state under the action of a gate $U$, it evolves from $$ |\psi\rangle\rightarrow U|\psi\rangle. $$ However, a density matrix such as $\rho=|\psi\rangle\langle\psi|$ evolves differently. You must calculate $$ \rho\rightarrow U\rho U^\dagger. $$ So, in this case, you must calculate $$ \left(\begin{array}{cc} 0 & 1 \\ 1 & 0 \end{array}\right)\left(\begin{array}{cc} 1 & 0 \\ 0 & 0 \end{array}\right)\left(\begin{array}{cc} 0 & 1 \\ 1 & 0 \end{array}\right)=\left(\begin{array}{cc} 0 & 0 \\ 0 & 1 \end{array}\right). $$

  • $\begingroup$ Thank you for reply. Why we have to multiply conjugate transpose matrix? I wonder the reason. Could you tell me about it? $\endgroup$
    – 김동민
    Commented Oct 30, 2020 at 8:45
  • 1
    $\begingroup$ Simply because the bra of $U|\psi\rangle$ is $(U|\psi\rangle)^\dagger = \langle \psi |U^\dagger$. Therefore the evolution $|\psi\rangle\mapsto U|\psi\rangle$ is in the density matrix picture $|\psi\rangle\langle \psi |\mapsto U|\psi\rangle\langle \psi |U^\dagger$ $\endgroup$ Commented Oct 30, 2020 at 9:21
  • $\begingroup$ Could you be more in detail? I can't understand now. $\endgroup$
    – 김동민
    Commented Oct 30, 2020 at 9:46
  • $\begingroup$ You know that to convert a state $|\psi\rangle$ into a density matrix, you rewrite it as $\rho=|\psi\rangle\langle\psi|$. How do you rewrite the state $U|\psi\rangle$ as a density matrix? $\endgroup$
    – DaftWullie
    Commented Oct 30, 2020 at 10:42
  • $\begingroup$ Okay! I got this. Thank you $\endgroup$
    – 김동민
    Commented Oct 30, 2020 at 11:09

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.