Drag to orbit · click a node to inspect
⚠ Couldn't load the 3D engineThree.js failed to load from the CDN. Check your connection and reload.

Quantum Circuit Simplifier: ZX-Calculus Spider Fusion

This simulation explores the fundamental principles of quantum computing through a hands-on tool used in real quantum compilers: the ZX-calculus. A randomly generated quantum circuit — Hadamard, CNOT and phase gates across several wires — is redrawn as a 3D graph of colored "spiders" connected by wires, laid out by a live spring simulation. Two provably correct rewrite rules, spider fusion and identity removal, can be applied on demand: click through them and watch the spider count, edge count and T-count (the count of expensive non-Clifford phase gates) drop as the diagram — and the circuit it represents — gets smaller without changing what it computes.