Qualtran
Qualtran copied to clipboard
Add support for `MultiControlledU` via `C-U` and `MultiAnd`
- [x] Generalize
MultiControlledPaulito accept any BloqUwith a single-bit control. - [x] Replace
MultiControlledXwithMultiControlledU(XGate()) - [ ] Return this as the default in
Bloq.controlled()? - [x] Document: When the user needs $\text{MC-U}^\dagger \cdot V \cdot \text{MC-U}$, they can use
MultiAndto compute the controls, and only uncompute at the end (instead of twice when usingMultiControlledU)
Related: #914
The fallback for Bloq.controlled() returns qualtran.Controlled(subbloq) meta-wrapper. For (3), I'm proposing that we switch the decomposition for Controlled (which right now just does a multi-controlled version of each subbloq) to use an And ladder to produce one control bit, and then do a singly-controlled version of each subbloq
this was completed in #1451 and #1456
wooooooo