Skip to content

Clarify CNOT control, target, and basis ordering - #5625

Merged
abbycross merged 1 commit into
mainfrom
fix-cnot
Sep 14, 2026
Merged

abbycross merged 1 commit into
mainfrom
fix-cnot

Conversation

@henryzou50

Copy link
Copy Markdown
Collaborator

Clarifies the CNOT explanation in “Get started with Qiskit in the classroom” to distinguish control/target argument order from Qiskit’s ket ordering.

  • Explicitly identifies the control, target, and ordered matrix basis.
  • Replaces the ambiguous input/output equation with the actual CNOT transformation.
  • Links to the bit-ordering guide.

The existing matrix is correct and remains unchanged, along with code and notebook outputs.

Validation: Verified the matrix and all four basis-state mappings with Qiskit. Markdown, spelling, and internal-link checks passed.

Fixes #5622.

Distinguish gate argument order from Qiskit's ket ordering and replace
the ambiguous equation with the explicit CNOT transformation.
Preserve the correct matrix, code, and notebook outputs.

Fixes #5622
@review-notebook-app

Copy link
Copy Markdown

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@qiskit-bot

Copy link
Copy Markdown
Contributor

One or more of the following people are relevant to this code:

@abbycross abbycross left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@kaelynj

Copy link
Copy Markdown
Collaborator

cc christopherporter1

@christopherporter1 christopherporter1 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perfect. Thanks, Henry!

@abbycross
abbycross added this pull request to the merge queue Sep 14, 2026
Merged via the queue into main with commit 723a39c Sep 14, 2026
5 of 6 checks passed
@abbycross
abbycross deleted the fix-cnot branch September 14, 2026 17:56

This branch was successfully deployed

1 active deployment
pr_preview — 94432642 Deployed Sep 9, 2026 by github-actions[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

problem on CNOT Gate

5 participants