Table of Contents
Fetching ...

An Online Approach for Entanglement Verification Using Classical Shadows

Marwa Marso, Sabrina Herbst, Jadwiga Wilkens, Vincenzo De Maio, Ivona Brandic, Richard Kueng

Abstract

Quantum measurements are slow, while classical processors are fast, yet existing hybrid protocols never exploit this asymmetry. In this work, we propose an alternative formulation of classical estimators as online algorithms that are updated incrementally upon obtaining a new sample. Classical shadows are the natural fit for this approach: designed around the principle of measuring first and asking questions later, each snapshot is a self-contained classical description that can be processed immediately and independently. As a first demonstration, we focus on mixed state entanglement verification via PT-moments, moments of the partially transposed density matrix that provide experimentally accessible sufficient conditions for entanglement. We construct two unbiased online estimators that together characterize the fundamental challenge between memory footprint and per-shot computational cost: one scales to large systems at low moment order, the other handles high moment orders at the expense of memory exponential in system size. The online estimator certifies entanglement reliably and, by exploiting all $\binom{T}{m}$ combinations of snapshots, requires fewer samples than state-of-the-art baselines, turning entanglement detection from a purely offline diagnostic into a protocol that runs concurrently with the experiment.

An Online Approach for Entanglement Verification Using Classical Shadows

Abstract

Quantum measurements are slow, while classical processors are fast, yet existing hybrid protocols never exploit this asymmetry. In this work, we propose an alternative formulation of classical estimators as online algorithms that are updated incrementally upon obtaining a new sample. Classical shadows are the natural fit for this approach: designed around the principle of measuring first and asking questions later, each snapshot is a self-contained classical description that can be processed immediately and independently. As a first demonstration, we focus on mixed state entanglement verification via PT-moments, moments of the partially transposed density matrix that provide experimentally accessible sufficient conditions for entanglement. We construct two unbiased online estimators that together characterize the fundamental challenge between memory footprint and per-shot computational cost: one scales to large systems at low moment order, the other handles high moment orders at the expense of memory exponential in system size. The online estimator certifies entanglement reliably and, by exploiting all combinations of snapshots, requires fewer samples than state-of-the-art baselines, turning entanglement detection from a purely offline diagnostic into a protocol that runs concurrently with the experiment.

Paper Structure

This paper contains 42 sections, 3 theorems, 77 equations, 10 figures, 3 tables.

Key Result

Lemma 1

For any product operator $\hat{\rho}=\bigotimes_{n=1}^N \hat{\rho}_n$ and any subset $B$,

Figures (10)

  • Figure 1: From Randomized Measurements to Online Entanglement Detection. (Left) Each shot produces a snapshot $\hat{\rho}_i$ by applying a random Clifford rotation and measuring in the computational basis. (Middle) In the offline setting, all $T$ snapshots are acquired before any processing begins. In the online setting, running PT-moment estimates $\hat{P}_t^{(m)}$ are updated incrementally as each new shot arrives. (Right) The $m{=}3$ PT-moment inequality gap for a $2$-qubit Werner state ($t = 5/6$), tracked by the online estimator over shots. The trace crosses zero, yielding $e_3 < 0$ and certifying NPT entanglement on-the-fly.
  • Figure 2: Randomized measurements and classical-shadow reconstruction. For each shot $t \in [T]$, we prepare a copy of the state $\rho$, apply the tensor product of random single-qubit Clifford gates $U_t = \bigotimes_{n=1}^{N} U_n$, measure in the computational basis and return the measurement bit string $b_t \in \{0,1\}^N$. We can then construct the single-shot classical shadow $\hat{\rho}_t$ from the pair $(U_t,b_t)$, which can in turn be used to estimate linear observables as well as higher-order functions, such as the PT-moments, by combining $m$-tuple snapshots into the unbiased estimator of $\mathrm{Tr}(\rho^{T_B})^m$. For the purity, a quadratic function, this formula simplifies to $\hat{P}_T^{(2)}= \frac{2}{T(T+1)} \sum_{t_1 \neq t_2} \mathrm{Tr} \left( \rho_{t_1} \rho_{t_2} \right)$.
  • Figure 3: Online PT-moment estimators.(a) Without shadow reconstruction: the full measurement record $\{(U_t, b_t)\}_{t=1}^{T}$ is kept in memory (green). Upon arrival of shot $T{+}1$, all $\binom{T}{m-1}$ subsets of past snapshots are combined with the new snapshot to compute $\binom{T}{m-1}$ trace products $\operatorname{Tr}(\hat{\rho}_{t_1}^{T_B} \cdots \hat{\rho}_{T+1}^{T_B})$ (purple), yielding the updated estimate $\hat{P}^{(m)}_{T+1}$ (red). Snapshot matrices need never be explicitly constructed. (b) With shadow reconstruction: $m$ accumulated matrices $A_1(T), \dots, A_m(T)$ are kept in memory (green). Upon arrival of shot $T{+}1$, each matrix is updated via $A_k(T{+}1) = A_k(T) + A_{k-1}(T)\,\hat{\rho}_{T+1}^{T_B}$ (purple), and the new snapshot is immediately discarded. The estimate $\hat{P}^{(m)}_{T+1}$ follows from a single trace (red).
  • Figure 4: Online entanglement detection across system sizes. Each trace shows the elementary symmetric polynomial $e_k$ of the estimated PT spectrum over shots, for $10$ independent runs. Traces that cross $e_k = 0$ (dashed line) certify entanglement. Dots mark the stopping point of each run. Left: Werner $2$q, $k{=}3$. Middle: Werner $4$q, $k{=}6$. Right: Werner $6$q, $k{=}10$.
  • Figure 5: Online vs. batched entanglement detection. Orange traces show the online $e_k$ estimate over shots ($10$ runs); teal dots show batched estimates at fixed shot budgets ($10$ runs each). Dashed line: true $e_k$. Left: Werner $2$q, $t{=}0.83$, $k{=}3$. Middle: Werner $4$q, $t{=}0.73$, $k{=}6$. Right: Werner $6$q, $t{=}0.9$, $k{=}5$. The online estimator detects entanglement ($e_k < 0$) with fewer shots across all instances.
  • ...and 5 more figures

Theorems & Definitions (6)

  • Lemma 1
  • proof
  • Theorem 1: Online update
  • proof
  • Lemma 2: Descartes' rule $\Rightarrow$ bound on negative eigenvalues
  • proof