Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add u as alias for u3 gate. Required for compatibility with OpenQASM 2. #218

Merged
merged 1 commit into from
May 6, 2024

Conversation

dlyongemallo
Copy link
Contributor

@dlyongemallo dlyongemallo commented May 4, 2024

The u gate is in the header for OpenQASM2.

In particular, it is produced by qiskit.qasm2.dumps() for circuits generated by qiskit.circuit.random.random_circuit.

@dlyongemallo dlyongemallo marked this pull request as draft May 4, 2024 19:43
@dlyongemallo dlyongemallo changed the title Add 'u' as alias for 'u3' gate. Required for compatibility with Qiskit 1.0+. Add 'u' as alias for 'u3' gate. Required for compatibility with OpenQASM 2. May 4, 2024
…ASM 2.

The `u` gate is in the header for OpenQASM2: https://github.com/Qiskit/qiskit/blob/main/qiskit/qasm/libs/qelib1.inc

In particular, it is produced by `qiskit.qasm2.dumps()` for circuits generated by `qiskit.circuit.random.random_circuit`.
@dlyongemallo dlyongemallo changed the title Add 'u' as alias for 'u3' gate. Required for compatibility with OpenQASM 2. Add u as alias for u3 gate. Required for compatibility with OpenQASM 2. May 4, 2024
@dlyongemallo dlyongemallo marked this pull request as ready for review May 4, 2024 20:53
@jvdwetering jvdwetering merged commit cc22a72 into zxcalc:master May 6, 2024
3 checks passed
@dlyongemallo dlyongemallo deleted the add_u_gate branch May 6, 2024 17:00
dlyongemallo added a commit to dlyongemallo/pyzx that referenced this pull request May 9, 2024
dlyongemallo added a commit to dlyongemallo/pyzx that referenced this pull request May 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants