qiskit icon indicating copy to clipboard operation
qiskit copied to clipboard

Incorrect stated effect of CNOT gate when viewed as a XOR gate in the docs

Open tnemoz opened this issue 4 months ago • 3 comments

Environment

Not relevant.

What is happening?

The current documentation for the CXGate states that its effect is: $$|a,b\rangle\to|a,a\oplus b\rangle$$ However, this is the effect using the textbook bit ordering. But for instance, the CXGate sends $|0,1\rangle$ to $|1,1\rangle$. Indeed, the actual effect of the CXGate is: $$|a,b\rangle\to|a\oplus b,b\rangle$$.

How can we reproduce the issue?

Not relevant.

What should happen?

The documentation should correct the effect from $|a,a\oplus b\rangle$ to $|a\oplus b,b\rangle$.

Any suggestions?

No response

tnemoz avatar Oct 21 '24 08:10 tnemoz