Add mcz, mcp and crz to QuantumCircuit
#305
Draft
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The Qrisp documentation provides a list of operations that can be added to an object of the
QuantumCircuitclass.If the
mcz,mcporcrzgates are added to a quantum circuit, we getAttributeError: 'QuantumCircuit' object has no attribute 'mcz'/'mcp'/'crz'. This PR adds the missing gates as methods of theQuantumCircuitclass.In the above code block, replace
mczwithmcporcrz.Edit: Spoke with Raphael on this. The gates that can be applied to theQuantumCircuitclass are different from the gate functions on the linked page in the documentation. I don't know if it's worth adding these gates....To do: mcrx exists in
standard_operations.pybut not as a method of theQuantumCircuitclass.