0
$\begingroup$

I am a bit stuck in decomposing these gates in single qubit gates, in the Cirq documentation it is written, for example that XX is for example the tensor product of Rx gates. But when I calculate these, I get terms with sin*cos where they write a 0. Is there any trick/explanation for this?

$\endgroup$
1
$\begingroup$

XXPow isn't a tensor product of Rx gates. It raises the matrix resulting from such a tensor product to a power, but the result is not expressible as a tensor product anymore.

If you want to decompose into CNOT gates, the key thing you need to know is that you can change the observable being exponentiated by conjugating it with Clifford operations. For example, if you conjugate XX with CNOTs, the result is a single X on the control. Meaning you can decompose $(X \otimes X)^t$ into this:

enter image description here

You can decompose the other ones similarly. Cirq can perform this decomposition for you, although it outputs CZ gates instead of CNOTs, via cirq.two_qubit_matrix_to_operations.

$\endgroup$
1
  • $\begingroup$ Thank you! This is what I was looking for! $\endgroup$ – Schrödinger314 Apr 9 at 23:10

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.