Quantifying the sensitivity to errors in analog quantum simulation

Quantum simulators are widely seen as one of the most promising near-term applications of quantum technologies. However, it remains unclear to what extent a noisy device can output reliable results in the presence of unavoidable imperfections. Here we propose a framework to characterize the performance of quantum simulators by linking robustness of quantum expectation values to the spectral properties of the output observable, which in turn can be associated with its macroscopic or microscopic character. We show that, under general assumptions and on average over all states, imperfect devices are able to reproduce the dynamics of macroscopic observables accurately, while the relative error in the expectation value of microscopic observables is much larger on average. We experimentally demonstrate the universality of these features in a state-of-the-art quantum simulator and show that the predicted behavior is generic for a highly accurate device, without assuming any knowledge about the nature of the imperfections.

In recent years, powerful quantum information processing devices that outperform their classical counterparts have become a real prospect. One of the most recognized potential applications of these technologies, as envisioned by Feynman [1], is to efficiently simulate properties of highly correlated quantum systems which are of interest in condensed matter [2,3], quantum chemistry [4,5] and high-energy physics [6,7]. Important advances in isolating and manipulating quantum systems while maintaining their coherence properties have led to highly complex quantum devices composed of several tens of qubits [8][9][10][11][12]. However, these systems, now routinely referred to as noisy intermediate scale quantum (NISQ) devices [13], do not meet the highly demanding requirements of fault tolerant, error-corrected quantum computers [14]. NISQ processors are intrinsically imperfect analog machines, subject to a continuum of errors in control, background fields and decoherence. Even as the quality of these devices continues to improve, it is unknown how such imperfections will in general affect the output of these analog quantum simulators (AQSs), and under which circumstances or for which tasks they yield a reliable output.
In this context, the issue of how imperfections affect the reliability of quantum processors has been studied in many different settings [15][16][17]. Particularly, it has recently been observed that extracting information about certain expectation values in noisy devices is a less demanding task than characterizing the full quantum state. This has been studied in the context of dynamical quantum simulators [18][19][20], qubit readout and tomography [21,22] and also in terms of algorithm complexity [23]. In this work we establish a general framework to characterize the robustness of AQSs by linking the average sensitivity of expectation values of generic observables to their spectral properties, and in turn to their macro-scopic or microscopic nature. We theoretically show this relation rigorously for both static and dynamical models of imperfect quantum simulators. Crucially, we demonstrate the predictive power of our framework in a realworld quantum simulator, and show that the imperfections that naturally affect the device lead to errors whose behavior are in excellent agreement with our theoretical findings.

EFFECT OF IMPERFECTIONS IN THE OUTPUT OF AQS
Consider a simulator whose objective is to prepare a d-dimensional quantum system in a state of interest |ψ . We define the output of the device as the expectation value of some observable A = ψ| A |ψ . Due to imperfect operation of the simulator, however, the system is prepared in a different state |ψ sim . Our goal is to characterize how the output of the simulator is affected by these imperfections, as a function of the choice of output observable A. For this, we define the simulation error and consider the perturbed state to be |ψ sim = N (γ) (|ψ + γ |ψ ⊥ ), where ψ|ψ ⊥ = 0 and N (γ) 2 = (1 + γ 2 ) −1 . In order to assess how the magnitude of the simulation error depends on the output observable, we consider its average value over all states |ψ in Hilbert space. Performing the average over the Haar measure [24,25], which we denote as (. . .), we obtain (see Methods for details and extension to mixed states) In order to compare the average error for different observables, it is convenient to shift the spectrum of A such arXiv:2007.01901v2 [quant-ph] 7 Jul 2020 that its minimum eigenvalue is zero (excluding the trivial case A = I), which in turn makes A > 0. This leaves the error in Eq. (1) invariant. Furthermore, in order to characterize the magnitude of the error relative to a typical mean value for different choices of A (similar in spirit to a signal-to-noise measure) we will consider the average relative error, δ rel (A) 2 where we introduced the notation ρ A ≡ A/Tr (A) which is a positive, unit trace, Hermitian operator. Eq. (3) is our first main result. It says that that the degree of robustness of expectation values to imperfections in the quantum state is dictated, on average, by η(A) ≡ Tr ρ 2 A , which we refer to as the purity of the observable A in analogy to the usual (state) purity.
As depicted in Fig. 1 (a), high purity observables are characterized by having a small, nonextensive set of dominant eigenvalues. As a consequence, their expectation values are greatly affected even by small deviations in the corresponding populations. The extreme case corresponds to projectors onto pure states, i.e., A = |φ φ|, which have purity equal to 1, and whose expectation value corresponds to a single state population. On the other hand, small purity observables correspond to highrank operators, which have an extensive set of eigenvalues close to the mean that contribute to its expectation value, leading naturally to robustness to small deviations in eigenstate populations which tend to average out. The extreme case η(A) = 1 d is only achieved by A = I, for which the error vanishes trivially. However, many observables of interest show purities which decrease with system size in a similar way. An example of this is given by the collective magnetization in a system of N spin-1 2 particles, α denotes Pauli operator acting on the i-th particle with α = x, y, z. The purity of the collective magnetization evaluates to This shows how a meaningful observable like the magnetization is characterized by an intrinsic robustness to imperfections (on average), which is similar to that of the identity operator for moderately large N . The definition of observable purity naturally relates to the notion of typical configurations in statistical mechanics, where observables are taken to be quantities which roughly take the same value in all phase space (compatible with constraints), apart from a small fraction of configurations deemed atypical [26]. As a consequence, the value of macroscopic observables is fairly independent of the specific microstate of the system [25,27,28]. A and its connection to the eigenspectrum of the observable. Largest purity (equal to 1) is attained for projectors onto pure states, while lowest purity (equal to d −1 ) corresponds to the identity operator. Intermediate cases correspond to various observables of interest (see main text for details). (b) Purity for even powers of the collective magnetization operator S 2k x with x (direction is chosen arbitrarily).
In our case, Eq. (3) precisely quantifies robustness to deviations in the microstate of the system. This allows us to associate low purity to macroscopic observables. Conversely, high purity observables are associated with quantities that vary sharply, as for example the probability of the system to be in an specific state in an exponentially large space. Finally, we note that sets of observables with different purities can be constructed in a variety of ways. One example (see Supplementary Material for further analysis) comes from considering powers of a collective spin operator, say S x , whose expectation values can be associated to moments of a probability distribution. In particular, even powers like S 2k x have spectra strongly dominated by degenerate eigenvalues corresponding to the stretched states where all spins are parallel to each other. This is the signature of high purity, as observed in Fig. 1 (b).

DYNAMICS OF ERRORS IN ANALOG QUANTUM SIMULATORS
A standard protocol for quantum simulation involves engineering a Hamiltonian H, under which an initial state |ψ 0 evolves, leading ideally to |ψ(t) = e −iHt |ψ 0 . Here we analyze this scenario, depicted in Fig. 2 (a) and often referred to as dynamical quantum simulation [8,11,29]. Assuming that |ψ 0 can be prepared with high accuracy, then errors will arise in the simulator because of an imperfect implementation of H. The nature of such imperfections can be of various kinds, and they depend on the particular physical platform [30]. In order to formulate a general model for the impact of errors in AQSs, we will consider that the ideal Hamiltonian dynamics is slightly perturbed in a random way in each run of the simulation, thus leading to an imperfect evolution dictated by a total Hamiltonian H + λV , where λ is a small dimensionless parameter, and V is a Hermitian operator characterizing the perturbation. Generalizing Eq.
(1), the error in the output of the dynamical simulator is given by where |ψ sim (t) = e −i(H+λV )t |ψ 0 (note that we set = 1) and [. . .] V denotes the average over the random perturbation V . Assuming the ideal Hamiltonian H has a nondegenerate spectrum with eigenstates {|u n } and eigenvalues {E n }, and considering V nn = u n | V |u n to be uncorrelated random variables, the leading order contribution to the error is given by (see Methods) where ρ ψ,D = n |b n | 2 |u n u n | is called the diagonal ensemble corresponding to the initial state |ψ 0 = n b n |u n in the eigenbasis of the ideal Hamiltonian H [26]. The function f (t) depends on the particular model for the perturbation, and in general obeys f (0) = 1 and f (τ ) → 0 for τ = λt 1 (see Methods). The expression obtained in Eq. (6) shows that, after a transient time set by the perturbation strength, the simulator error reaches a stationary behavior which depends on the choice of output observable A. Results similar to Eq. (6) have been obtained even in the nonperturbative regime in the context of thermalization [31,32], giving evidence of the broad validity of the predicted behavior for δ(A, t).
A particular application of Eq. (6) is to evaluate it for A = ρ(t) = |ψ(t) ψ(t)|, i.e. the projector onto the unperturbed state of the system. In this case the simulator error in Eq. (5) equals the infidelity I(t) or one minus the Loschmidt echo [33,34], which measures how well the device simulates the ideal quantum state |ψ(t) . From Eq. (6), we get which describes a monotonic increase of the infidelity up to a value 1 − S 0 , where S 0 = Tr ρ 2 ψ,D is the inverse participation ratio (IPR) of the state |ψ 0 in the basis of H, as shown originally in [33]. The evolution of the fidelity is in contrast with the alternative scenario where the output observable is any time-dependent operator A (e.g. the magnetization S x ).
For this case, the stationary behavior of the error in Eq. (6) is an oscillating function whose long-time average is zero in under general assumptions (see Methods).
To further analyze this generic case, we focus on the cumulative error E(A, t) defined as which, recalling the definition of δ(A, t), can be regarded as the root-mean-square error for the expectation value of A over time. As we did in the previous section, to gauge the dependence of the error on the output observable we perform the average of Eq. (8) over Haar-random initial states and consider the time-dependent average relative error, and denote its asymptotic value for t → ∞ as E ∞ rel (A). This quantity generalizes the average relative error δ rel (A) of Eq. (3) to the dynamical quantum simulation scheme. As shown in Methods, this quantity can be computed analytically and reads Here ρ X = X/Tr (X) for both operators A and A D = n A nn |u n u n |, where A nn = u n | A |u n (recall that A > 0 by construction). Eq. (10) compliments Eq. (3) as the main result of this work, and it demonstrates that the observable purity η(A) = Tr ρ 2 A determines the average sensitivity to imperfections in dynamical quantum simulations. Note that the second term inside the square root in Eq. (10) depends on the Hamiltonian through its eigenbasis {|u n } and can be thought of as measure of the IPR for observables. We expect this term to be of order 1/d for uncorrelated choices of A and H (see Methods).

QUANTUM SIMULATION RESULTS
In the previous section we presented a theoretical framework which relates the magnitude of errors in expectation values with the spectral properties of the corresponding observables. In the following we show that this framework can predict the behavior of such errors in a real-world device, even when no detailed information about the underlying physical imperfections is used in the model.
On our experimental platform, previously introduced in Ref. [20], information is encoded in the 16-dimensional hyperfine ground manifold of individual cesium atoms, which is formally isomorphic to that of N = 4 qubits. Within this space, this simulator is universal and thus | computed for these cases. It can be seen that the error computed from the theoretical model (blue) agrees qualitatively with the experimental observations. In particular, the accrual of errors is monotonic for the complete quantum state (since the fidelity continuously decays) but is fluctuating for generic observables. Simulated time has units of 1/Λ. Data in panel (c) is also shown in Ref. [20].
can be programmed to access the dynamics of any Hamiltonian of interest, in a similar spirit to other quantum processors [12,35]. The device is controlled through optimization of time-dependent radio frequency and microwave magnetic fields, and experiments are performed in parallel on ∼ 10 7 atoms, giving excellent measurement statistics for probability distributions in any arbitrary basis. Further details are given in the Methods section. Due to its high accuracy and relatively small size, this device represents an ideal platform to explore the effect of small imperfections in the simulated dynamics.
Even though our findings are largely independent of the details of the model Hamiltonian that is being simulated, here we focus on a particular many-body quantum system, the Lipkin-Meshkov-Glick (LMG) model [36] (see Supplementary Material for other cases). The LMG Hamiltonian describes the dynamics of a system of N spin-1 2 particles with Ising-like interactions in a completely connected graph, and reads This model has been extensively analyzed in the literature and is a paradigmatic example of a quantum sys-tem presenting both ground state and excited state phase transitions in the thermodynamic limit [37,38]. Recalling the collective spin operators S α = 1 2 i σ (i) α introduced previously, the LMG Hamiltonian can be written in more compact form as H LM G = −B S z − (Λ/N )S 2 x . Due to conservation of the total spin S 2 , we can focus on the evolution within the subspace of maximum spin number S = N/2, which is composed of states that are completely symmetric under particle exchange and has dimension N + 1. In our experimental simulations, we use N = 15 to make use of the maximum Hilbert space size available with our platform.
In Fig. 2 we show the evolution of the fidelity and expectation values obtained from quantum simulations (in red) of the LMG dynamics for B = 1.5Λ (paramagnetic) and B = 0.4Λ (ferromagnetic), starting from a spin coherent state |ψ 0 = |↓ x ⊗N . In Fig. 2 (b) and (e) we plot the experimental infidelity, which reaches roughly ∼ 30 − 40% at time Λt = 30, indicating significant deviation from the ideal quantum evolution. Nonetheless, expectation values are tracked with high accuracy, as can be seen from subplots (c) and (f) and the corresponding time-dependent errors in (d) and (g), which are seen to fluctuate over time (additional cases are presented in the Supplementary Material). This is the behavior pre- dicted by our theoretical framework. For comparison, we show results obtained from numerical simulations of this model (in blue). The only free parameter is the perturbation strength λ which is chosen to fit the infidelity curve (see Methods). Once λ is fixed, the model reproduces the main features of the expectation value error curves as can be seen from Fig. 2(d) and (g). Notice that this is achieved without any information about the actual physical imperfections affecting the experiment, which are expected to have fundamentally different character than the random perturbations considered in the theoretical model.
In order to explore the impact of imperfections on different observables A as a function of their purity, η(A), we study the long-time average cumulative error associated with the experimental expectation value curves. Here, evolution times were taken to be about ten times larger than those shown in Fig. 2, in order to be closer to the asymptotic regime and enable comparison with our theoretical findings, c.f. Eq. (10). To remove the dependence on the initial state of the system, we have obtained results for several different initial states, which we divide in two groups. First, a set n s = 10 random states sampled uniformly over the Haar measure, enabling direct comparison with the analytical result of Eq. (10). Conceptually, however, it could be argued that these states are not physically relevant for AQS [39]. We thus consider also a set of n s = 10 states which are prepared as (uniformly distributed) random rotations from the fiducial state |↑ x ⊗N , leading to a set of random spin coherent states.
In Fig. 3 we show the cumulative relative error, defined in Eq. (9), averaged over Haar-random states in (a)-(b), and over spin coherent states in (c)-(d). Errors calculated from the experimental quantum simulations are shown in tones of red in (a) and (c), while those obtained from numerical simulations based on our theoretical model are shown in tones of blue in (b) and (d). In all cases, we display results for three output observables: x and A 3 = |m x m x | (here m x = 1/2; other cases shown in Supplementary Material). These observables are chosen to have increasing purity, as discussed in the beginning of this paper. For both sets of initial states, the errors generated in the experiment follow essentially the same behavior as the theoretical prediction.
For short times, when the cumulative errors are small, the experimental values deviate considerably from the numerical curves. Most of this difference can be attributed to state preparation and measurement (SPAM) errors, as we show in the Supplementary Material. Nevertheless, for longer times the relative errors in the ex-pectation values become consistently higher as the purity of the corresponding observable increases. This validates the role of the purity as a measure of sensitivity of expectation values to imperfections in the state. For Haar-random initial states, the dashed lines indicate the analytical result of Eq. (10), which is able to faithfully reproduce the asymptotic values of the cumulative relative error for all cases. In the Supplementary Material we present further experimental and numerical data that illustrates this behavior.
To further demonstrate the role the observable purity plays in the buildup of errors, in Fig. 4 we present the long-time cumulative error computed for several choices (∼ 10) of output observable A = S 2k x . As seen in Fig. 1  (b), the purity of these observables increases monotonically with k. In Fig. 4 we plot the long-time relative error as a function of the observable purity for (a) Haarrandom initial states and (b) random spin coherent initial states. In both cases, it is evident that the errors are a monotonic function of the purity, which determines how well expectation values can be tracked in the presence of imperfections. Matching between experiment and theory is also observed, especially for the Haar-random initial states. In Fig. 4 (c) we plot the same data as in (a) but as a function of a modified purity Tr ρ 2 A − Tr ρ 2 A D , where we have computed the purity of the Hamiltoniandependent observable A D from Eq. (10). The resulting data can then be directly compared with the analytical prediction of Eq. (10), showing very good agreement.

DISCUSSION
In this work we have presented a framework to characterize the effect of errors in the output of quantum simulators. Critically, we have introduced the observable purity η(A) as the key metric that can be used to characterize the average sensitivity of expectation values A to random imperfections. By performing extensive experimental explorations in a small-scale universal quantum simulator, we were able to demonstrate the validity of this framework in a real-world device, without using any knowledge about the nature of the imperfections affecting its operation.
While we have tested our predictions on a specific quantum information processing platform, we expect our framework to be broadly applicable, as the concept of typicality [25,28] describes intrinsic robustness of expectation values for a wide range of perturbations. In scenarios with specific kinds of imperfections, e.g. local decoherence on a simulator with a local tensor product structure, errors will also depend on additional properties of the output observable. For some instances, given specifically chosen initial states of the simulator, we expect to see deviations from the universal average behavior set by η(A). Nonetheless, we expect that the observable  purity is the central tool to establish the baseline sensitivity of AQS outputs. More generally, we also anticipate that this framework will have applications in topics like tomography and sampling [21,22,40] and relaxation in many-body systems [32].

METHODS
State-averaged simulator error. In the case that the simulated state |ψsim is pure, the simulator error of Eq.(1) can be written as We now write the states above as |ψ = U |a l and |ψ ⊥ = U |am , where l = m and {|ai } with i = 1, . . . , d is a reference basis set (for instance, the basis of eigenstates of A). Here, U is a random matrix taken from the uniform distribution over the manifold of d × d unitary matrices, i.e. the Haar measure corresponding to the group U(d) [41]. We can then consider quantities like which can be computed analytically (for k = 1, 2) decomposing the integrand into sums of polynomials in the elements of U . Using known expressions for these integrals for up to quartic order [24], which we show in the Supplementary Material, we can compute Inserting these results in Eq. (12) we obtain δ(A) = 0 and the expression for δ(A) 2 in Eq. (2). Furthermore, these allow us to easily generalize our findings to mixed states, i.e. |ψsim → ρsim. For one simple noise model which has been discussed recently in the context of nearterm quantum information processing devices [12], we obtain δ(A) = A − Tr (ρsimA) which evaluates to δ(A) = γ A − A . Using Eqs. (14)- (17), it is straightforward to derive the average relative error for this model which depends on the purity in the same way as Eq. (3).
Perturbation model for dynamical quantum simulators. The time-dependent simulator error Eq. (5) can be written in terms of the quantum state averaged over the perturbation, where we have denoted U (t) = e −i(H+λV )t and ρ0 = |ψ0 ψ0|.
Using time-independent perturbation theory to expand the eigenvalues and eigenvectors of H = H + λV in powers of λ, we obtain where UV (t) is a unitary matrix given by Notice that the zeroth order contribution depends on the perturbation through its diagonal elements V kk . This is because λ cannot be neglected in the argument of the exponential since the time t could in principle be of order λ −1 [33]. Thus, the leading order contribution to the perturbed state is From Eqs. (22) and (23) it can be seen that the effect of the perturbation is condensed on the quantity where l = m, we have defined τ ≡ λt and introduced pV (x) which is the probability density function associated with the perturbation matrix elements V kk . A crucial assumption here is that the diagonal matrix elements V kk can be considered statistically independent. The integral inside the absolute value in Eq. (24) is the characteristic function g(τ ) of the probability distribution, which has the properties g(0) = 1 and |g(τ )| ≤ 1 [42]. Furthermore, for all probability distributions of interest, f (τ ) will be a function that goes to 0 as τ → ∞. As an example, if V is taken to be a random matrix from the Gaussian orthogonal ensemble (GOE), then we have that g(τ ) = e −τ 2 /2 [43].
After defining f (τ ), we obtain for the perturbed state the following expression from which the result on Eq. (6) immediately follows. For a general time-independent observable A, the average error given in (6) can be thought of as just due to deviations from the infinite-time average of A , since where b k = u k |ψ and so lim t→∞ 1 t  where Anm = un| A |um . We can then compute the Haar average over the initial state |ψ0 using the techniques mentioned before. In particular, it can be shown that |bn| 2 |bm| 2 = 1 d(d+1) for n = m, which leads to which in turn leads to Eq. (10) in a straightforward way.
In this result, we see the appearance of the Hamiltoniandependent observable purity: Given the resemblance to the IPR S0 = Tr ρ 2 ψ D , we could regard Eq. (30) as a measure of the spread of A in the basis of the Hamiltonian. The maximum value of Tr ρ 2 A D is clearly Tr ρ 2 A , which happens only if A and H commute and are thus diagonal in the same basis. In this regime, the error Eq. (10) vanishes and we need to increase our expansion to the next order in perturbation theory. On the other hand, the cases of interest are when A and H are "highly non commuting", such that A evolves non-trivially under the action of the Hamiltonian. Then, we can then expect Ann ∼ 1 d Tr (A) and thus Tr ρ 2 Simulation on a quantum processor. Generally, one can separate AQS into two distinct approaches which we refer to as "emulation" and "simulation". An "emulator" is a specialpurpose device that, by design, shares the symmetries of its Hamiltonian and structure of its Hilbert space with the model system of interest. This stands in contrast to a "simulator", which we define here as a fully programmable device, capable in principle of performing any generic AQS task, without necessarily sharing all of the symmetries of the model system other than its ability to act in a Hilbert space of equal or smaller size. The simulator paradigm is thus a general framework independent of the particulars of the underlying quantum hardware. The essential resource provided by a quantum simulator is universal control, in the sense that the hardware can be programmed to implement any desired unitary transformation on the input. For example, if one is interested in simulating the dynamics driven by a Hamiltonian of interest, the simulator can be programmed to apply a series of unitary time steps and thus perform a coarse-grained simulation of the evolving quantum state. Universal control also provides freedom in terms of state preparation and measurement (SPAM). In particular, it is straightforward to prepare arbitrarily chosen input states, and to map measurement in any desired basis onto a fiducial "computational basis". Ultimately, these key elements are likely to be present in some form on any broadly useful quantum simulator, such as a gate-based simulator. For the work presented here, we use a small, highly accurate quantum (SHAQ) simulator whose state-of-the-art fidelity is critical for the quantitative examination of errors and their impact, but similar studies can in principle be done using a wide range of simulators as well as emulators.
Our SHAQ simulator is based on the spin degrees of freedom of an individual 133 Cs atom in the electronic ground state. The atom is driven by a combination of static and time varying magnetic fields, rendering it fully controllable in a 16-dimensional Hilbert space. While different in structure and programming, the resulting simulator is formally equivalent to four qubits controlled by a universal quantum circuit.
Quantum Optimal Control. The Hilbert space of our simulator is spanned by a set of logical basis states |F, m , labeled by hyperfine spin quantum numbers F = 3, 4 and −F ≤ m ≤ F . Unitary control is achieved with a combination of a static magnetic bias field along z, a pair of phase modulated radio-frequency (rf) magnetic fields along x and y, and a single phase-modulated microwave (µw) magnetic field. The rf fields are tuned to the Larmor precession frequency in the bias field, and the microwave field is tuned to the transition between the |3, 3 and |4, 4 states. Phase-modulation waveforms that implement a desired transformation U ∈ SU(16) are found using either conventional optimal control, or a variant optimized for AQS that searches for co-optimal control fields and system-simulator maps using a new approach called EigenValue-Only (EVO) control [20]. The two protocols generate (non-unique) control waveforms consisting of 150 and 20 discrete phase steps, respectively, corresponding to waveform durations of 600µs and 80µs, with typical fidelities F = 0.985 and F = 0.995 as estimated by randomized benchmarking. EVO control is used exclusively for the unitary time steps that make up an AQS, while conventional control is used to generate unitary maps for state preparation and measurement.
Experimental Implementation. Our experiment begins with a sample of ∼ 10 7 laser cooled Cs atoms released from a magneto-optical trap/optical molasses into free fall. Optical pumping and state selective purification is used to prepare > 99% of these atoms in the logical basis state |ψ0 = |3, 3 . An AQS sequence begins with a map to the desired input state, |ψ0 → |χ0 = F,m CF,m |F, m . This is followed by k identical time steps U of duration δt to simulate time evolution from t = 0 to t = kδt. Finally, to measure a desired observable A = a a|φa φa| we apply a unitary map U = a |(F, m)a φa|, and determine the population of the states |(F, m)a with a Stern-Gerlach measurement. The latter is implemented by imposing a magnetic field gradient on the falling atoms and measuring the state dependent arrival times at a resonant probe beam located below the preparation volume. Fitting the time dependent fluorescence from atoms falling through the probe gives an accurate measure of the populations in the logical basis states |F, m , and these in turn provide good estimates of the probabilities pa = Tr (ρΠa) for the POVM outcomes Πa = |φa φa|, and the expectation value A = a apa. Measurement statistics contribute negligibly due to the large number of simulations running in parallel on millions of atoms; instead the accuracy is dominated by errors in the readout map, probe power fluctuations, and electronic noise. Measuring the projector |χ k χ k |, where |χ k is the state predicted in the absence of errors, gives an estimate of the fidelity of the AQS. Averaged over a sample of random states, the SPAM error on this estimate is approximately 1%. For a detailed evaluation of SPAM errors, see the accompanying Supplemental Material. For additional information about the operation and performance of our SHAQ simulator, see [20].
In this case, the growth in infidelity of the model depends directly on the perturbation strength λ, as τ = λt and S0 is fixed by the choice of initial state. This gives us a way to fix λ based on the decay of the state-level fidelity in the experiment, which shares the same form to leading order [44]. We use the ability to perform arbitrary unitary transformations to map the state |ψ(t) to a logical basis state. The resulting measurement is of the observable A = |ψ(t) ψ(t)|, from which we can calculate the infidelity. We then fit the data to minimize the residual between the data and Eq. (31) to find the λ that most closely matches the growth in experimental infidelity. Typical fit values are around λ ≈ 0.01, suggesting the amount of perturbation from the ideal is small.