← Atlas

Basic circuits · Multipartite entanglement

W state (three-qubit)

The three-qubit W state, an equal superposition of every single-excitation basis string that survives the loss of one qubit better than GHZ.

Exact & formalUpdated

View frozen graph

A small worked example, computed in your browser. It is not a result from this record's papers.

The 3-qubit W state

3 qubits, preparing (|001⟩ + |010⟩ + |100⟩) / √3.

q0q1q2Step 1 of 1 · W state (3 qubits)W state (3 qubits)

Step 1 of 1 · W state (3 qubits)

Probability of each outcome after this step

  • 00133%
  • 01033%
  • 10033%
  1. A staircase of controlled-RY rotations (each built from RY and CX) and a CCX spreads a single excitation evenly across all three qubits, so that exactly one of them reads |1⟩ at a time, with equal probability for each.

    Probability leaves the outcome it was on and appears on 3 entirely different ones — not one outcome is populated both before and after. This is the step that entangles the qubits: from here on no single qubit has a state of its own, only the register as a whole does.

Readout Measuring gives 001, 010 or 100, each equally likely, and never 000, 011, 101, 110 or 111: exactly one qubit reads |1⟩.

Open in Studio
  • Steps5
  • Wires3
  • Qubits3
  • Depth2 controlled rotations + 2 CNOT
  • Entanglement classW (SLOCC-distinct from GHZ)
  • Papers1
Native
w_state.py
import numpy as np
from qiskit import QuantumCircuit
from qiskit.quantum_info import Statevector

def w_state(n: int) -> QuantumCircuit:
    qc = QuantumCircuit(n)
    qc.x(n - 1)
    for k in range(n - 1):
        remaining = n - k
        theta = 2 * np.arccos(np.sqrt(1 / remaining))
        qc.cry(theta, n - 1 - k, n - 2 - k)
    for k in range(n - 1, 0, -1):
        qc.cx(k, k - 1)
    return qc

qc = w_state(3)
sv = Statevector.from_instruction(qc)
# sv equals (|100> + |010> + |001>) / sqrt(3) exactly
print(sv.probabilities_dict())


FINAL_CIRCUIT = qc

References

Exact & formal
  • Direct mathematics
  • Verified by construction
  • Peer-reviewed paper
Method
The target amplitudes (1/√3 on each of |100⟩, |010⟩, |001⟩, zero elsewhere) are derived analytically from the recursive Möttönen-style rotation angles used in the preparation circuit, then compared against the circuit's exact statevector.
Result
Pass · the prepared state has support only on the three single-excitation basis strings, each with amplitude 1/√3 and zero relative phase.
Three qubits can be entangled in two inequivalent ways ↗
Kind
curated reference
Reviewed by
Leona Quantum curation pass
License
CC BY 4.0-compatible reference metadata
entanglementw-statemultipartitestate preparation

Atlas stars stay in the public catalog. Saving this entry to your workspace starts an unstarred private copy.