Home▸Geology & Earth Science▸Two-Qubit Bloch Sphere & Circuit Simulator (2D)

Two-Qubit Bloch Sphere & Circuit Simulator (2D)

A real two-qubit statevector engine on plain canvas: apply H/X/Z/CNOT gates, measure either qubit, and watch the reduced Bloch vector, basis-state probabilities and entanglement collapse live as you tune coherence and gate error rate.

Geology & Earth Science2DModerate60 FPS📱 Mobile-adapted⇄ 3D version
2d-interactive-quantum-computer-simulation ↗ Open standalone

The 3D original places labelled hardware props around a rotating scene but never computes a qubit state. This 2D companion replaces the decoration with a genuine two-qubit statevector: gate buttons apply real unitary matrices (Hadamard, Pauli-X, Pauli-Z, CNOT), a partial trace over qubit B derives qubit A's reduced Bloch vector each frame, and the coherence slider drives a stochastic dephasing model so superposition visibly decays toward a mixed state as coherence drops.

⚙ Under the hood

Real 2-qubit |ψ⟩ statevector (4 complex amplitudes): H/X/Z/CNOT gates, measurement with amplitude projection, a partial-trace Bloch vector for qubit A, and a coherence-scaled stochastic phase-kick model of T2 dephasing.

qubitbloch spheresuperpositionentanglementquantum gatedecoherence

2D · HTML5 Canvas 2D · 60 FPS target · runs fully client-side, no install

What did you find?

Add reproduction steps (optional)