8
$\begingroup$

I'm looking for fast code, or a fast algorithm, for checking if a given state vector $A$ can be transformed into another state vector $B$ using only the Pauli operations $X$, $Y$, $Z$.

The naive strategy is to simply iterate through all $4^n$ ways to apply a Pauli operation (or no operation) to each of the $n$ qubits, actually simulate applying the operations ($2^n$ cost for each qubit for each case) to one of the states, and check if the resulting state vector is equivalent to the other state. Surely it's possible to do this in better than worst case $n 8^n$ time?

[Update] I am specifically interested in worst case performance. Heuristics are interesting and useful answers, but won't become the accepted answer.

$\endgroup$
2
$\begingroup$

The way that I thought to start was to look at the reduced density matrices of the individual qubits. If they cannot be interconverted using Pauli matrices, then the whole thing can't.

The only problem is that this idea breaks down as soon any of the reduced density matrices are maximally mixed. At that point, you could ask "are the two states equivalent under local unitaries?". If you derive the unitaries as a result of that question, then it's easy to test if they're Pauli or not. This was studied here. I think there are still cases where the scaling is problematic, but I don't remember the bit with maximally mixed reduced density matrices well enough.

$\endgroup$
  • 2
    $\begingroup$ That's a good heuristic for states such as $|CCZ\rangle$, but common states such as graph states without any singleton nodes will not benefit from it. The idea does generalize to e.g. looking at the reduced density matrix of pairs or triplets of qubits. $\endgroup$ – Craig Gidney Feb 11 at 11:54
  • 1
    $\begingroup$ I agree. Of course, for graph states there have been a lot of studies about local Clifford equivalence, but then you have to start talking about how the states are specified. The trickiness of distinguishing between local Clifford and local Unitary equivalence is suggestive of how nasty the problem could be in general. $\endgroup$ – DaftWullie Feb 11 at 12:10
2
$\begingroup$

Pick an element $a_i$ of A and find its position in B, disregarding changes in phase. The shift in position uniquely identifies the series of $X$ or $Y$ applications needed for the transformation.

The relative phase of $(a_0, b_0)$ tells you, in steps of $-i$ rotations, how many $Y$ gates you need for the transformation. The relative phase of $(a_1,b_1)$ to $(a_0,b_0)$ tells you have many $Y$ or $Z$ gates act on the first qubit; and so on for the relative phase of $(a_{2^{k-1}},b_{2^{k-1}})$ to $(a_0,b_0)$ for $Y$ or $Z$ gates acting on qubit $k$.

If $a_i$ does not appear in B then the transformation is not possible.

I believe the above can be done in $O(n)$-sh.

$\endgroup$
  • 1
    $\begingroup$ What happens if the elements $a_i$ aren't unique? $\endgroup$ – DaftWullie Feb 11 at 15:40
  • $\begingroup$ You take cases. In any case as the degeneracy of the elements increases the problem becomes more trivial. The (magnitudes of the) elements of A and B have to be balanced. $\endgroup$ – Eelvex Feb 11 at 15:43
  • 3
    $\begingroup$ But what about states like graph states where all elements have the same magnitude? The point I'm trying to make is that taking cases would lead to the same exponential blow up. Admittedly, your suggestion is very good for eliminating or solving a lot of simple cases. $\endgroup$ – DaftWullie Feb 11 at 15:53
  • $\begingroup$ I'm not saying that I have covered all corner cases but If all elements have the same magnitude, you need zero $X$ gates and you proceed with the relative phase check. $\endgroup$ – Eelvex Feb 11 at 15:58
  • $\begingroup$ This is another good heuristic for certain states. But I'm specifically looking for an algorithm with good worst-case performance. $\endgroup$ – Craig Gidney Feb 11 at 19:12

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.