QNotation is a web application designed to help users convert between circuit, Dirac, and matrix notation in the context of quantum computing.
QNotation is available at https://qnotation.vercel.app/, so no setup is required! This section walks you through running your quantum circuits in the app.
QNotation takes in Qiskit quantum circuit objects, which are inputted through the code editor on the right side of the app. Here are some points to keep in mind while creating your quantum circuits for QNotation:
- quantum gates must be appended to the
qc
variable below theInsert code below
comment. - quantum circuits with 1 to 5 qubits can be run in the app. To change the number of qubits used in your circuit, modify the qubit argument on the following line:
qc = QuantumCircuit(3)
- measurement and classical operations are currently not supported
- Neighbouring qubits must be used for multi-qubit gates.
- ✅
qc.cx(0, 1)
- ❌
qc.cx(0, 2)
- ✅
- Control qubit(s) must have a lower qubit index than their respective target(s)
- ✅
qc.cx(0, 1)
- ❌
qc.cx(1, 0)
- ✅
- most Qiskit gates are supported by the app. A list of supported gates can be found below
Example input can be found in the EXAMPLES dropdown.
QNotation contains interactive visualizations for circuit, Dirac, and matrix. Clicking on different sections of a notation will reveal its equivalent sections in the other notations (in orange). The quantum state after the selected sections is shown on the right of the Dirac and matrix visualization subsections.
A couple of toggles have been included on the bottom right of the app:
- Little endian (LE) toggle: allows for toggling between little endian and big endian ordering
- Tensor (⊗) toggle: allows matrix notation visualization to be broken down into tensor products (for quantum circuits with 3 qubits or less)
- Samantha Norrie, Anthony Estey, Hausi Müller, Ulrike Stege, QNotation: A Visual Browser-Based Notation Translator for Learning Quantum Computing, technical paper published in the proceedings of QSEEC 2024 (QCE 2024)
- Samantha Norrie, Anthony Estey, QNotation: An Interactive Visual Tool to Lower Learning Barriers in Quantum Computing, extended abstract and poster published in QCE 2023 –Jupyter notebook version
QNotation is currently in beta. Although it has been tested, it may still contain bugs or unexpected behaviour.
- CCX: Controlled-controlled-x (Toffoli) gate
- CCZ: Controlled-controlled-z gate
- CH: Controlled-hadamard gate
- CP: Controlled-phase gate
- CRX: Controlled-rx gate
- CRZ: Controlled-rx gate
- CSDG: Controlled-s^dagger gate
- CS: Controlled-s gate
- CU: Controlled-u gate
- CX: Controlled-x gate
- CZ: Controlled-z gate
- H: Hadamard gate
- ID: Identity gate
- RCCX: Margolous gate
- R: Rot gate
- RX: Rot-x gate
- RY: Rot-y gate
- RZ: Rot-z gate
- X: Pauli-x gate
- Y: Pauli-y gate
- Z: Pauli-Z gate