I have a beginner question regarding CNOT-Gates on IBM Quantum.

Assuming the following simple circuit:

qreg q[2];
creg c[2];

h q[0];
cx q[0],q[1];
measure q[1] -> c[1];
measure q[0] -> c[0];

Ideally, we would expect a probability of 50% for |00> and |11> and 0% for |10> and |01>, respectively. Now, if I simulate the circuit I get something like ~52 vs 48% for the entangled states; and |10> and |01> is still 0%. However, if I run the circuit on e.g. ibmq_manila there is a probability of some percentage to also find |10> and |01>. In total P(|10>) + P(|01>) is approx. 5% in my experiment. Is this simply the CNOT error rate?

Is there a way to account for these errors? Do they depend on which Qubits I am using?

  • $\begingroup$ There is a relevant question here: quantumcomputing.stackexchange.com/questions/13092/… $\endgroup$
    – Farhad
    Apr 20 at 13:02
  • $\begingroup$ To your first question of why not 50-50: When you flip a fair coin 10 times, do you get 5 heads and 5 tails exactly? Now, what if you flip it for 100 times? and then 1 million times? $\endgroup$
    – KAJ226
    Apr 20 at 14:16
  • $\begingroup$ Thank you very much. I am aware that we only get ideally 50:50. I was more concered about the CNOT error. $\endgroup$
    – choc1709
    Apr 20 at 14:17

2 Answers 2


When simulating the circuit, the distribution you get is purely statistical (i.e. A different round would yield different distributions) but should be fairly close to 50%-50%.

When running on a real machine, the system is not perfectly isolated from the environment and is therefore subjected to noise.

Errors caused by noise can be digitized, ie. Can be regarded as only bit-flip ($X$) or phase-flip ($Z$) errors. The thing is, these errors can occur even without the presence of gates. For example, if you set a qubit to $|1❭$ and wait long enough - without applying any gate - you would expect it to eventually reach a mixed state which upon measurement will yield 50%-50% for 0 or 1, which is equivalent to losing any information that qubit had.

  • $\begingroup$ Thank you. Maybe I should rephrase my question: Is the error of such a simple program realy that high (5 %)? $\endgroup$
    – choc1709
    Apr 20 at 13:27
  • $\begingroup$ The exact error rate is hardware dependent, but yeah - I’ve also seen similar error rates for a simple Bell state circuit using IBM devices. Edit: I see that in the comment for the original question someone notes that the CNOTs are indeed a large source of error, as you’ve suggested. $\endgroup$ Apr 20 at 13:50

Is this simply the CNOT error rate?

No. The top reason for these erroneous results is readout errors which introduced by imperfect qubit measurements. For ibmq_manila, readout errors are three times as much as CNOT errors[1].

You can reduce the impact of this type of errors by using error mitigation techniques. Some of these techniques are implemented in Qiskit and can be easily used by wrapping the backend in a QuantumInstance[2] and setting the value of measurement_error_mitigation_cls as follows:

backend = provider.get_backend('ibmq_manila')
quantum_instance = QuantumInstance(backend, measurement_error_mitigation_cls = CompleteMeasFitter)

counts = quantum_instance.execute(circ).get_counts()

The result will be something like:

enter image description here

  • $\begingroup$ Thank you very much. That is very helpful. Do you know why that value of measurement_error_mitigation_cls is not set on default? Does it come with any disadvantages? Is it just computing overhead? My understanding is that the error mitigation is based on forming a matrix for error correction. If there would be no error, the matrix would be the identity matrix - otherwise, the entries would correspond to the error probabilities. $\endgroup$
    – choc1709
    Apr 27 at 10:44

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.