1

We entangle two quarks; after measurement gives either |01> or |10> with probability of 50%.(regardless of their prior states ,they always give opposite states)

when I entangle 2 qubits using Cnot it gives |00> ,|01> ,|10> ,|11> all with 25% probability. why???

enter image description here

Sandipan Dey
  • 21,482
  • 2
  • 51
  • 63
Ayan Bhunia
  • 479
  • 3
  • 14

2 Answers2

0

The circuit you created is actually doing this: first, applying Hadamard gates to |00> will create the state 1/2(|00>+|01>+|10>+|11>). Then, applying the C-NOT will make |01> to |11> and |11> to |01> (normally |10> to |11> and |11> to |10> with textbook's convention but the Qiskit's convention makes it the other way), therefore your state actually is the same, that's why you get the 25% probability for each. I hope it is clear enough!

Lena
  • 238
  • 1
  • 8
  • that means it is not same as real entanglement happen in quantum world. we are just flip one`s spin w.r.t. other.!!!!???? – Ayan Bhunia Jun 30 '20 at 16:58
  • Actually it is the same, but may I suggest putting one X gate instead of the Hadamard gate on qubit 1? Then you would get the result you are trying to reach, |01> or |10> with probability of 50% – Lena Jul 01 '20 at 13:13
0

Let's consider the 2-qubit system where we are applying Hadamard operator to both the qubits and then a CNOT (with the first qubit as the control bit).

enter image description here

With qiskit we can simulate the above system as shown in the code below and see that the results are as per our expectation (the output system is uniform superposition of 4 states with equal probability).

from qiskit import QuantumCircuit, Aer, execute
from qiskit.visualization import plot_histogram

qc = QuantumCircuit(2)
qc.h(0)  # |0> -> |+>
qc.h(1)  # |0> -> |+>
qc.cx(0,1)
qc.draw()

enter image description here

backend = Aer.get_backend('statevector_simulator')
plot_histogram(execute(qc,backend).result().get_counts())

enter image description here

In order to get the desired states we need to apply a Hadamard gate (H) to the first qubit, a NOT (X) gate to the 2nd qubit and then apply CNOT to have desired entangled states (Bell State):

enter image description here

Simulating the above with qiskit:

qc = QuantumCircuit(2)
qc.h(0)  # |0> -> |+>
qc.x(1)  # |0> -> |1>
qc.cx(0,1)
qc.draw()

enter image description here

plot_histogram(execute(qc,backend).result().get_counts())

enter image description here

Sandipan Dey
  • 21,482
  • 2
  • 51
  • 63