量子干扰是量子计算的灵魂。每当您有垃圾量子位时,它们都将防止干扰。这实际上是非常简单但非常重要的一点。比方说,我们有一个函数其中单位映射到一个位。说f是一个非常简单的函数,例如f (x )= x。假设我们有一个电路C f,它输入x和输出f (x )f:{0,1}→{0,1}fF(x )= xCFXF(x )。现在,当然,这是一个可逆电路,可以使用a变换实现。现在,我们可以输入1| X⟩→交通 | X⟩和输出也将是11个2√| 0⟩+ 12√| 1⟩。现在让我们应用Hadamard变换门并测量得到的结果。如果将Hadamard变换应用于此状态11个2√| 0⟩+ 12√| 1⟩1个2√| 0⟩+ 12√| 1⟩, you get the | 0⟩ state, and you see 0 with probability 1个. In this case there was no junk created in the intermediate steps, while converting the classical circuit to a quantum circuit.
But, let's say we created some junk in an intermediate step when using a circuit like this one:
.
For this circuit, if we start off in the state | X⟩ | 0⟩=(12√| 0⟩+ 12√| 1⟩)| 0⟩, after the first step we get 12√|00⟩+12√|11⟩. If we apply the Hadamard transform to the first qubit, we end up with:
12|00⟩+12|01⟩+12|10⟩+12|11⟩
If we make a measurement on the first qubit we get 0 with probability 12, unlike in the previous case where we could see 0 with probability 1! The only difference between the two cases was the creation of a junk bit in an intermediate step, which was not gotten rid of, thus leading to a difference in the final result of the computation (since the junk qubit got entangled with the other qubit). We will see a different interference pattern than in the previous case when the Hadamard transform is applied. This is exactly why we don't like to keep junk around when we are doing quantum computation: it prevents interference.
Source: Professor Umesh Vazirani's lecture on EdX.