In Zhandry's compressed oracle paper, one can read the following:
Next, we note that the oracle $h$ being chosen at random is equivalent (from the adversary’s point of view) to $h$ being in uniform superposition $\sum_h|h\rangle$. Indeed, the superposition can be reduced to a random $h$ by measuring, and measuring the $h$ registers (which is outside of $A$’s view) is undetectable to $A$. To put another way, the superposition over $h$ is a purification of the adversary’s mixed state.
Though it appears to be intuitive, I can't manage to prove this formally using density matrices.
Let us first consider an oracle that samples at random a function $h:\{0\,;\,1\}^m\to\{0\,;\,1\}^n$ and uses a register with $n\,2^m$ qubits, which can be decomposed in $2^m$ $n$-qubit registers, where the $i$-th register (indexing from 0) represents the value of $h(i)$. We consider three registers, namely the two adversary's registers $X$ and $Y$ and the oracle's register $F$. We define the unitary $\mathcal{O}$ to act on the basis states as follow: $$\mathcal{O}\left(|x,y\rangle\otimes|h\rangle\right)=|x,y\oplus h_x\rangle\otimes|h\rangle$$ with $h_x$ being the value stored in $F$'s $x$-th sub-register.
The goal is to show that, from the adversary's point of view, initialising $F$ with a uniformly sampled function $h$ or with a uniform superposition $\sum_h|h\rangle$ is equivalent.
Carrying out the computations and tracing out the oracle's registers, in the first case ($h$ is sampled once and for all) the system density matrix associated to the adversary's registers is: $$\rho^A_1 = \sum_{i,j,k,l}\rho_{i,j,k,l}\,|i,j\oplus h_i\rangle\,\langle k,l\oplus h_k|$$ while in the second case ($F$ is initialised with $\sum_h|h\rangle$), we get: $$\rho^A_2 = \frac{1}{2^{2\,n}}\,\sum_{i,j,k,l}\sum_{h_i, h_k}\rho_{i,j,k,l}\,|i,j\oplus h_i\rangle\,\langle k, l\oplus h_k|$$ which is very similar to $\rho^A_1$.
If we compute the probability of measuring $|x,y\rangle$, we get for the first case: $$\rho_{x,y\oplus h_x,x,y\oplus h_x}$$ which is the probability given $h$. By summing over the $h$, we find the same probability as the one in the second case, that is: $$\frac{1}{2^n}\,\sum_{h_x}\rho_{x,y\oplus h_x,x,y\oplus h_x}\,.$$
My questions are:
- We are forced to use probability theory after having performed the measurement in the first case to find the same probability as in the second case. Since the density matrix contains all the statistical information about the system's state, shouldn't we be able to say these cases are indistinguishable just by looking at the density matrices? How can/should I bring the uncertainty over $h$ into the density matrix?
- That's closely related to 1., but since the density matrices are different, are we sure that the adversary can't tell the difference by simply computing the probability once $\mathcal{O}$ has been applied? Shouldn't we consider that the adversary may apply an arbitrary unitary $\mathbf{U}$ on their state to help them distinguish between the cases? I guess it would work, but ocne again, can't we do it directly with the density matrices?
- How can Zhandry's justification can be translated into the density matrix formalism? Why is the fact that the state is now pure a reason to tell that the adversary can't tell the difference between both cases?