Circuits
Quantum circuits are the standard way of representing quantum algorithms. They consist of qubits (horizontal lines) and quantum gates (boxes or symbols) that act on them. Below is an example circuit with key gates:
Interactive Circuit Builder
X Gate
Z Gate
Drag X and Z gates onto the circuit line, then run the animation.
Drag gates from above onto the circuit line to build your quantum circuit!
Two-Qubit Circuit Example
Figure: Two-qubit circuit with X and Z gates on different qubits.
Two-qubit system ready - Choose initial state: |00⟩ or |10⟩
Circuit: |0⟩ → X → H
X gate flips |0⟩ to |1⟩, then Hadamard creates superposition.
Ready to run - Circuit gives random results due to Hadamard superposition