I wanted to share some results from an experiment which I find thought were deeply surprising.
The basic idea is to prepare a superposition in a main register then conditionally apply lots of random gates to a "messy" register, undo them, and then measure the main register. The idea is to see whether noise can amplify certain outcomes.
Results
The circuit diagram for the simplest case of this is:
circuit-56544 is created using qiskit's random_circuit and turning it into a controlled gate. Note that the middle auxilliary qubit is especially important when there are multiple qubits in the top register to reduce number of controlled-ops.
My prediction was that either nothing would happen or that applying messy gates would "accidentally measure" the messy register because of noise, and collapse the top qubit into the 1 state. The qasm_simulator predicts that nothing will happen (which makes sense since the circuit is just the $H_0$ + identity):
However, when we run on a real device (ibmq_bogota), thus introducing noise, interesting things start to happen:
This is the opposite of what I expected to happen, so I was quite shocked. However, as we increase the depth of the random circuits and the size of the messy register, this effect (and my surprise) are greatly amplified, until we're basically measuring only zeros:
(Of course, I would love to see what happens for more qubits but I only have access to small hardware and obviously we can't trust simulators anymore.)
For now, I'm just hoping someone can explain what is actually going on here. To be clear, we can eliminate the possibility that the messy circuit is somehow inadvertedly doing Grovers-like amplification because the simulator predicts random uniform output for all of these circuits. Therefore, it is physical noise which is driving these effects. One possible metaphor is that qubits dislike interacting with the environment and so "prefer" to take the path of least resistance through the circuit. I am keen to hear what an Everettian (or indeed any interpretation) would say about this.
Search
To add some motivation for understanding what's going on here, I just wanted to point out you can easily use this technique to create a search algorithm. So the circuit to find '101' is
For which we get:
To understand how well this algorithm scales in terms of search space, mess depth or mess width, we of course need to understand the basic effect here.
Questions
Sorry this post has been a bit of a mess (if you pardon the pun). I'll end with some questions:
- Is this due to a quantum effect not considered in the simulator or a physical effect not considered in QM? If former, which one?
- Which interpretation of QM is this most consistent with?
- How well does this scale?
- Are some random circuits messier than others?
- Is it the noiser the device, the better? Or does some other trade-off kick in at some point?
Please feel free to ask any of your own!
p.s. if anyone who has access to larger devices wants to investigate how this scales, I'm happy to share my code.
EDIT: as pointed out by LinLin, this can all be explained by the fact that decoherence means states tend towards |0...0>. As such, the following two circuits produce basically the same output, even though the latter has no entanglement between the main register and the mess.
There's nothing surprising here, I just got a little overexcited.