I don't understand it. But suppose you have a state of two qubits in superposition and it looks like $|10\rangle-|11\rangle$. Now you have in your circuits two gates one is a controlled-NOT from the first qubit to the second and the other gate following is the Hadamard gate on the first qubit.

If I applied first the CNOT I got, $|11\rangle-|10\rangle$, right? (I am not entirely sure why it's allowed to work like this but ok.)

Now I was trying two approaches yielding different results but I am actually not sure about what is the meaning of the first qubit.

  1. So one approach was to take the original state $|10\rangle-|11\rangle$ and apply to it $\operatorname{H}$ gate multiplied by CNOT gate.

  2. The second approach is to take the state after the CNOT $|11\rangle-|10\rangle$ and just as I did with the CNOT I would apply $\operatorname{H}$ gate only on the first qubit which is $|1\rangle-|1\rangle$, right? (Could be there is some coefficient there like $\frac{1}{\sqrt{2}}$ but I don't care about it now). But the thing I don't understand is how do I apply $\operatorname{H}$ gate on $|1\rangle-|1\rangle$? It isn't even clear to me what it means. Doesn't $|1\rangle-|1\rangle$ equal nothing? I mean, it isn't even a state, no?

Anyways it is strange, the first approach would yead a vector like $(-1,1,1,-1)$ I am not sure what it means. But it looks like I can never get such a state in the second approach, simply because I can't get more than two states combined because the Hadamard is acting only on the first qubit while the second qubit should remain unchanged. But mainly I am not sure what's $|1\rangle-|1\rangle$?

  • 1
    $\begingroup$ Hi. I strongly recommend learning linear algebra properly before delving into quantum computing. Otherwise, you'll end up wasting a lot of time and effort. Anyway, I hope someone will answer this question in detail. $\endgroup$ – Sanchayan Dutta Feb 20 at 21:18
  • $\begingroup$ Where do you see here lack of knowledge in linear algebra? $\endgroup$ – bilanush Feb 20 at 21:23
  • $\begingroup$ I answered that below. To be precise I meant tensors and tensor products. I think N&C devotes a whole chapter on linear algebra and properties of tensors and tensor products, which should be a good start. There are some other nice textbooks too, which we could discuss sometime if you drop by Quantum Computing Chat. :) $\endgroup$ – Sanchayan Dutta Feb 20 at 21:47
  • $\begingroup$ Thank you very much. I know I am not so fluent in linear algebra. My bigger problem is actually lack of knowledge regarding the concepts of QC which is on what linear algebra grounds does each of them stand. So I probably must read the chapter of N&C and see the connection between the two subjects. Thanks! $\endgroup$ – bilanush Feb 20 at 22:21

The second approach is to take the state after the CNOT $|11\rangle-|10\rangle$ and just as I did with the CNOT I would apply $\operatorname{H}$ gate only on the first qubit which is $|1\rangle-|1\rangle$, right?

The state of the first qubit is not $|1\rangle-|1\rangle$. It is simply $|1\rangle$.

The tensor product follows a distributive law. See this for a proof.

In your case, the composite state of two qubits (let's call them $A$ and $B$) is $|10\rangle-|11\rangle$. It may be more explicitly written as $$|1\rangle_A\otimes |0\rangle_B - |1\rangle_A \otimes|1\rangle_B$$ $$=|1\rangle_A\otimes (|0\rangle_B - |1\rangle_B).$$ This follows from the distributive law I linked. From here it should be clear that the state of the first qubit A is $|1\rangle_A$ and not $|1\rangle_A - |1\rangle_A$. And the state of the second qubit B is $|0\rangle_B-|1\rangle_B$. Can you take it from here?

  • $\begingroup$ Comments are not for extended discussion; this conversation has been moved to chat. $\endgroup$ – Sanchayan Dutta Feb 23 at 20:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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