# How does the CNOT gate operate when the control qubit is a superposition?

If a control qubit is in superposition, how it will affect target qubit if it is collapsed or in superposition? Is it true that CNOT works only if the control bit collapsed to 1? Also, is it possible to collapse or Hadamard control qubit “on the go” in a real life quantum computer and have a functional CNOT gate?

• If control bit is |1/2, 1/2| , output will be always unchanged? Dec 9 '18 at 18:04
• I tried answering your question in the way I understood it. But I am not sure what you mean about collapse. For me, we use the word collapse when we measured qubits. I think you meant when it is only in $|0\rangle$ or $|1\rangle$ state. Dec 9 '18 at 18:10
• Can you reformulate you question? What is it exactly you are asking? Dec 9 '18 at 18:20

By an example with a control qubit in superposition and the target in $$|0\rangle$$ state:
$$\frac{|0\rangle + |1\rangle}{\sqrt{2}} |0\rangle = \frac{|0\rangle|0\rangle + |1\rangle |0\rangle}{\sqrt{2}}$$
Applying a CNOT will have the following result: $$\frac{ CNOT(|0\rangle|0\rangle + |1\rangle |0\rangle)}{\sqrt{2}} = \frac{ CNOT(|0\rangle|0\rangle) + CNOT(|1\rangle |0\rangle)}{\sqrt{2}} = \frac{ |0\rangle|0\rangle + |1\rangle |1\rangle}{\sqrt{2}}$$
That is the CNOT acts linearly with a control qubit in superposition, but will change the target only on the part involving a $$|1\rangle$$ in the control qubit.