This is the one-way (measurement-based) quantum computer. A 2D lattice of qubits is first prepared as a cluster state: every qubit starts in |+⟩ = (|0⟩+|1⟩)/√2, then a CZ (controlled-Z) gate is applied along every edge of the grid:
|+⟩ per qubit → CZ on every lattice edge → |cluster⟩
CZ|00⟩=|00⟩, CZ|01⟩=|01⟩, CZ|10⟩=|10⟩, CZ|11⟩=−|11⟩
No further gates are ever applied. Instead the whole computation happens by measuring each qubit, column by column, in a basis rotated by an angle θ in the X–Y plane of the Bloch sphere:
|±θ⟩ = (|0⟩ ± e^(iθ)|1⟩)/√2
P(outcome 0) = |⟨+θ|+⟩|² = (1+cos θ)/2 = cos²(θ/2)
Measuring a qubit in this basis teleports the logical state one step to the right and applies an effective single-qubit rotation Rz(θ) to it — exactly the identity Raussendorf and Briegel used to show that measurement alone is computationally universal. Each random outcome bit m must be fed forward: it flips the effective angle used for the next column by π (a byproduct/Pauli-frame correction), which is why the angle used per row here depends on the previous column's result. Toggling the correction off in this simulator lets you see the (wrong) statistics you would get if the byproduct were never tracked — a concrete illustration of why feed-forward is not optional in a real one-way computer.
Verified numerically before building this page: for a qubit in |+⟩, |⟨+θ|+⟩|² = ¼|1+e^{-iθ}|² = (1+cos θ)/2 = cos²(θ/2) — the probability formula used below and in the source 3D simulator is the exact textbook result, not an approximation.
- Grid width / height — how many columns and rows of entangled qubits make up the resource state.
- θ slider — the measurement basis for the next column; different θ implements a different logical rotation as information teleports through.
- Correction toggle — whether the previous column's outcome bit feeds forward as a π byproduct correction to the next column's effective angle.
- Measure Next Column — consumes the leftmost unmeasured column: each qubit collapses to 0 or 1, and its lattice edges (its entanglement with neighbours) are destroyed in the process.
- Entanglement entropy at cut — for a graph/cluster state, the entanglement across a straight cut equals the number of edges crossing it; here that is exactly the row count until the lattice is fully consumed.
Real-world relevance: this is the architecture behind leading photonic quantum computing efforts (PsiQuantum, Xanadu), where generating large cluster states is easy but two-qubit gates are hard — so all the "computing" is pushed into cheap single-photon measurements instead.
Drag inside the lattice panel to pan, and scroll/pinch to zoom — useful once the grid grows past a handful of columns.