quantumlib / Qualtran

Qᴜᴀʟᴛʀᴀɴ is a Python library for expressing and analyzing Fault Tolerant Quantum algorithms.
https://qualtran.readthedocs.io/en/latest/
Apache License 2.0
173 stars 40 forks source link

Bug in `CNOT.get_ctrl_system` #1065

Closed mpharrigan closed 3 months ago

mpharrigan commented 3 months ago

There is a transposition error on the two control bits resulting in very wrong circuits if you decompose a Controlled(...) that contain cnots.

The fix is simple. I'm investigating why I didn't catch this immediately