ZKSF logo, a neon quantum brainZKSF
← All articles

How Many Qubits Can a Tensor Network Actually Simulate?

· 12 min read · ZKSF team

Vendors of tensor-network simulators routinely advertise thousands of qubits. The claim is true and it is also less informative than it appears, because it conflates two operations with very different costs and very different failure modes. This article reports what happens when the claim is measured, on our own matrix product state engine, with every figure produced by the production code path rather than a benchmark harness written to flatter it.

The short version: the engine reaches 2,000 qubits while returning measured bitstring counts with a certified error bound, and 5,000 qubits when the requested output is an expectation value. In between sits a wall that is not where anyone would expect, and understanding why it is there says something about what a qubit-count claim actually means.

Method

Four circuit families, chosen because they are the workloads matrix product states exist to handle, and because their entanglement structure is understood in advance:

  • GHZ: a Hadamard followed by a CNOT chain. Exactly representable at bond dimension 2, and its output distribution has only two outcomes.
  • Transverse-field Ising dynamics, Trotterized to depth 4. The canonical matrix product state workload, and the one closest to real condensed-matter research.
  • QAOA on an open chain, one layer. All two-qubit gates are nearest-neighbour.
  • QAOA on a ring, one layer. Identical except for a single gate closing the chain, which is long-range under a matrix product state and therefore expensive.

Every run used bond dimension 64, cutoff 1e-10, 256 shots, and certified mode, which re-runs the circuit at twice the bond dimension to measure convergence. The reported times therefore include roughly double the work of an uncertified run. Certification is not free and the figures below do not pretend otherwise.

Results

Circuit                       Qubits    Time      chi   Error bound   Converged
GHZ                            2,000    873 s       2   2.1e-08       yes
QAOA ring, p=1                 1,000    312 s       4   3.2e-07       yes
TFIM, Trotter p=4              1,000    203 s       4   2.5e-05       no
QAOA line, p=1                 1,000    202 s       2   1.1e-07       yes

Expectation value <Z_0>, no bitstring sampling:
QAOA line                      1,000    0.7 s       2   norm^2 = 1.000000
QAOA line                      3,000    2.1 s       2   norm^2 = 1.000000
QAOA line                      5,000    3.6 s       2   norm^2 = 1.000000

Two observations before the interesting one.

The bond dimension never approached its ceiling. Every circuit compressed to chi between 2 and 4 against a cap of 64. Nothing was being truncated hard, which is why the error bounds are small. On GHZ the discarded weight is 2.2e-16, which is machine epsilon: the representation is not approximating the state at all, and the reported bound of 2.1e-08 is the floating-point floor rather than a modelling error. QAOA on a line reports 5.6e-15, the same story.

Sampling dominates the cost by more than two orders of magnitude. Constructing the 1,000-qubit state takes 0.7 seconds. The full certified run at the same size takes 202. Over 99 percent of the elapsed time is drawing 256 bitstrings and performing the convergence re-run, not evolving the quantum state. Anyone reasoning about the cost of large tensor-network simulation from the physics alone will be wrong by a factor of 300.

A bound means little until it is read against shot noise. The Ising row above carries a bound of 2.5e-05, the largest in the table, and it is the only run not marked converged. That sounds like the weak result until the comparison is made: at 1,024 shots, statistical noise on each outcome probability is approximately 1/sqrt(1024), or 3.1e-02, which is three orders of magnitude larger. The truncation error is undetectable in the counts the run actually returns. This is the general point rather than a fact about one row. An approximation error far below the sampling error of the same experiment cannot affect any conclusion drawn from it, and a bound quoted without that comparison invites the reader to worry about the wrong term.

The wall, and where it is not

Transverse-field Ising and QAOA both failed at 2,000 qubits. Not slowly: they raised an error from inside the sampler, reporting that the probabilities contained NaN.

The obvious explanations are both wrong, and it is worth recording that they were tested rather than assumed.

It is not the certification path. Certified mode disables renormalization so that the final state carries its exact accumulated discarded weight, which is what makes the bound measured rather than estimated. That makes it the prime suspect for a numerical failure. Running the identical circuit with certification switched off fails at exactly the same sizes, so the certification machinery is not implicated.

It is not a missing canonical form. A matrix product state that is not in canonical form accumulates conditional probabilities as products of non-unit tensors, which is a standard route to underflow on a long chain. Canonicalizing before sampling, with and without an additional normalization, changes nothing.

It is not entanglement, bond dimension, or truncation error. QAOA on a line runs at a discarded weight of 5.6e-15, essentially nothing, and fails anyway.

What it actually is

The probability of any one specific n-bit measurement outcome is approximately 2^-n. Double-precision floating point holds normal numbers down to 2^-1022 and denormal numbers to 2^-1074, below which the value is exactly zero. A sampler that walks the chain accumulating conditional probabilities therefore reaches a point, somewhere past a thousand sites, where the running product underflows to zero and the subsequent normalization divides zero by zero.

Bracketing the failure confirms it. At eight shots, QAOA on a line samples correctly at 1,100 and 1,150 qubits and fails at 1,175 and 1,200.

The decisive evidence is GHZ. It samples without difficulty at 2,000 qubits, well past where the others fail. GHZ has only two possible outcomes, each at probability one half, so the sampler's conditionals are never small and nothing underflows. The limit is therefore a property of the breadth of the output distribution, not of the qubit count. A state concentrated on a few outcomes can be sampled at any size the memory allows. A state spread near-uniformly over 2^n outcomes cannot be sampled past roughly 1,150 qubits in double precision, by anyone, on any hardware, using any tensor-network library.

Why this matters for reading a specification sheet

The state itself is unaffected by all of this. At 5,000 qubits the norm is 1.000000 and an expectation value returns in 3.6 seconds. The simulation is healthy far past the point where bitstrings become unrepresentable. What fails is not the physics but the request for a specific kind of output.

This means bitstring sampling and expectation values are different measurements with different ceilings, and a qubit count quoted without saying which one is being performed does not describe a capability. When a tensor-network product advertises thousands of qubits, it is almost certainly reporting observables, correlation functions or energies. It is not returning shot histograms over thousands of qubits, because that quantity does not fit in a double.

The practical consequence for anyone choosing a simulator is a question worth asking directly: at the qubit count you care about, what does the tool actually return? If the answer is expectation values, the comparison is a fair one and the qubit count is meaningful. If you need sampled counts, the ceiling is far lower than the headline and it is set by arithmetic rather than by the vendor.

Reproducing this

Every figure above came from the production engine through its ordinary interface, at bond dimension 64 and cutoff 1e-10, on ordinary CPU hardware with no GPU involved. The circuit definitions are four short functions and the whole sweep is a single script. The methodology behind the bound itself, including where it can be loose and the 334 runs used to test it, is described in Error bars for quantum computing. The underlying representation is explained in Tensor networks explained, and the question of which engine suits which circuit is covered in CPU, GPU or QPU.

Run your own 100-qubit circuit, with an error bar.

Share this articleLink copied