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

Fix accumulated phase for rotations by 2 Pi #173

Merged
merged 2 commits into from
May 21, 2024
Merged

Conversation

swernli
Copy link
Collaborator

@swernli swernli commented May 20, 2024

This fix was missing from #163, which only addressed the special case for rotations by Pi and missing the corresponding special case for rotations by 2 Pi. This makes sure the phase of -1 is present for Rx/Ry by 2 Pi, and adds tests to confirm them.

This fix was missing from #163, which only addressed the special case for rotations by Pi and missing the corresponding special case for rotations by 2 Pi. This makes sure the phase of -1 is present for Rx/Ry by 2 Pi, and adds tests to confirm them.
@swernli swernli enabled auto-merge (squash) May 21, 2024 19:59
@swernli swernli merged commit 54f2ffc into main May 21, 2024
17 checks passed
@swernli swernli deleted the swernli/fix-phase-2pi branch May 21, 2024 20:07
swernli added a commit to microsoft/qsharp that referenced this pull request May 21, 2024
This updates the revision of the sparse simulator used to pull in the fix from qir-alliance/qir-runner#173. The change also includes the results from `cargo update` to get dependent packages up the latest minor/rev version compatible with the repo.
github-merge-queue bot pushed a commit to microsoft/qsharp that referenced this pull request May 24, 2024
This updates the revision of the sparse simulator used to pull in the
fix from qir-alliance/qir-runner#173. The change
also includes the results from `cargo update` to get dependent packages
up the latest minor/rev version compatible with the repo.
swernli added a commit that referenced this pull request Jun 14, 2024
This follows up on the fix from #173, which inadvertantly introduced a global phase on Rx/Ry rotations by 0.0 (and odd increments of Pi). This avoids the problem by checking the other part of the matrix to determine if the phase is required rather than applying it unconditionally.
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.

None yet

2 participants