Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Controlled Not Gate

  1. May 6, 2008 #1
    I'm not sure where to post this, so here it is:

    [tex]\left[\begin{array}{cccc}
    1&0&0&0\\
    0&1&0&0\\
    0&0&0&1\\
    0&0&1&0\\
    \end{array}\right][/tex]

    How is this a controlled NOT gate? If I multiply this with [tex]\left[\begin{array}{c}1\\0\\1\\0\end{array}\right][/tex], the second bit is flipped regardless.
     
  2. jcsd
  3. May 6, 2008 #2

    Hurkyl

    User Avatar
    Staff Emeritus
    Science Advisor
    Gold Member

    That looks fine to me. Maybe it would be more clear with Kronecker products in the ket notation? Let |0> and |1> denote the standard basis on C². Then....

    [tex]
    \left[\begin{array}{c}1\\0\\1\\0\end{array}\right]
    = |0\rangle \otimes |0\rangle + |1\rangle \otimes |0\rangle
    [/tex]

    while

    [tex]
    \left[\begin{array}{c}1\\0\\0\\1\end{array}\right]
    = |0\rangle \otimes |0\rangle + |1\rangle \otimes |1\rangle
    [/tex]
     
  4. May 6, 2008 #3
    Which coordinates in that column vector represents the control, and which the target bit?
     
  5. May 7, 2008 #4

    Hurkyl

    User Avatar
    Staff Emeritus
    Science Advisor
    Gold Member

    You're thinking classically. Your state vector cannot be partitioned into "control" and "target" parts -- instead, the vector represents the joint amplitudes of the two qubits. In your chosen basis, the components of the state vector correspond to each of the four ways to choose a basis vector for each qubit. If you had three qubits, your state vector would have eight components.

    Algebraically, the joint state space is the tensor product of the individual state spaces. You, however, were thinking of the direct sum (equivalently, direct product) of the individual state spaces.
     
  6. May 7, 2008 #5
    So suppose my control bit is 0, and target is 1, then the vector representing the joint amplitudes of them (on which the matrix acts) is [tex]\left[\begin{array}{c}1\\0\end{array}\right] \otimes \left[\begin{array}{c}0\\1\end{array}\right] = \left[\begin{array}{c}0\\1\\0\\0\end{array}\right][/tex]
     
    Last edited: May 7, 2008
  7. May 7, 2008 #6

    Hurkyl

    User Avatar
    Staff Emeritus
    Science Advisor
    Gold Member

    That looks right.
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Have something to add?



Similar Discussions: Controlled Not Gate
Loading...