1
$\begingroup$

enter image description here I made a simple circuit that we can see. In my view, $|00000\rangle$ should appear in one result, but I didn't see it. why? enter image description here

$\endgroup$
1
$\begingroup$

The problem is that IBM Q environment does not show all results in case there is more than 16 results (there is maximally 20 columns in the histogram). To get all results, you have to click on Download in the top right corner of a page with results. Two files with extension *.json are downloaded. Then open file ending with _results.json in notepad and look for string results. There will be something like this:

"results":[{"data":{"counts":"{"0x0":27,"0x1":33,"0x10":36,"0x11":41,"0x12":21,"0x13":32,

Instead of binary numbers, the results are expressed in hexadecimal format.

The result for state $|00000\rangle$ you were looking for is

"0x0":27

This means the number of occurences of $|00000\rangle$ is 27 (I used 1,024 shots).

$\endgroup$
5
  • 1
    $\begingroup$ Martin, can you explain what a shot really is? $\endgroup$ Apr 7 '20 at 18:07
  • $\begingroup$ @EmilProdan: a shot is one run of an algorithm. So number of shots tells you how many times the algorithm was repeated to get statistics (a histogram) on measured quantum states. $\endgroup$ Apr 7 '20 at 21:10
  • 1
    $\begingroup$ Does anybody know where the term "shot" came from? $\endgroup$ Apr 8 '20 at 0:45
  • $\begingroup$ Thank you!Good answer. $\endgroup$
    – BELL
    Apr 8 '20 at 7:57
  • $\begingroup$ @BELL: If the answer is satisfactory for you, could you please accept it? $\endgroup$ Apr 8 '20 at 8:07

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.