Spectral analysis of product formulas for quantum simulation

We consider the time-independent Hamiltonian simulation using the first order Lie–Trotter–Suzuki product formula under the assumption that the initial state is supported on a low-dimension subspace. By comparing the spectral decomposition of the original Hamiltonian and the effective Hamiltonian, we obtain better upper bounds for various conditions. Especially, we show that the Trotter step size needed to estimate an energy eigenvalue within precision ϵ using quantum phase estimation can be improved in scaling from ϵ to ϵ1/2 for a large class of systems. Our results also depend on the gap condition of the simulated Hamiltonian.


INTRODUCTION
The Lie-Trotter-Suzuki product formula 1-3 was originally used by Lloyd 4 to establish the first method for efficiently approximating the dynamics U(t) = e −iHt generated by a local Hamiltonian H with a universal quantum computer. After many refinements 5,6 this approach (often called "Trotterization") continues to be an appealing method for Hamiltonian simulation from both experimental and mathematical perspectives.
The method is based on dividing U(t) into L short-time evolutions U(t) = U(δt) L , t = Lδt, and replacing each U(δt) with an approximation U Tro (δt). The parameter L is the number of Trotter steps and δt > 0 is the Trotter step size. Given a decomposition of the Hamiltonian into a sum of layers H ¼ P Γ n¼1 H n , the first order product formula approximation is where δt and L are chosen to depend on the tolerable level of error, as we subsequently discuss. We term the digital error of this method as Trotter error, usually, it's quantified by the operator norm distance between the digital evolution operator and the ideal evolution operator. Most prior works calculate the Trotter error by first relating the global error to the local error (which is the digital error of a single Trotter step), then calculating the local error carefully. However, several reasons motivate us to seek for a different approach. For instance, in the two-layer case H = H A + H B , the first order formula has similar asymptotic error scaling with the second order one 7 . While it's hard to prove it from the local error perspective 8 , for its relation to the global error is non-trivial. Besides, it's hard to reveal the difference between fidelity error and norm distance error in specific simulations. Although for general situations they share the same asymptotic scaling, in quantum phase estimation (QPE) 9 it's not the case. Moreover, sometimes the condition about the energy levels of the initial state will influence the error estimation, but it's unnatural to take it into consideration in this framework.
All these issues can be improved with our framework, which is based on the spectral analysis of the effective Hamiltonian e H that generates the Trotterized time evolution, e H i logðU Tro ðδtÞÞ=δt; U Tro ðδtÞ L ¼ e Ài e Ht : Treating δt as a small parameter, perturbative methods can be used to compare the energy levels and eigenstates fE l ; ψ l j ig of the original Hamiltonian H to those f e E l ; e ψ l g of the effective Hamiltonian e H. For fixed δt the fidelity between corresponding eigenstates ffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffi 1 À j ψ l j e ψ l j 2 q is independent of the total simulation time, while the error in phase accumulates as j e E l À E l jt, which is the dominant part of the Trotter error. The detail analysis of the deviation in energy enables us to obtain better upper bounds.
To obtain an improvement for j e E l À E l j, we consider special cases in which the first order perturbation in energy vanishes. The main two cases are (1) the two-layer Lie-Trotter formula H = H A + H B , and (2) the case in which all the layers of the decomposition simultaneously have real matrix elements in some choice of basis. In the first case, the leading perturbation term has expression −iδt[H A , H B ]/2. Given any eigenstate ψ l j i of H, it's easy to verify that ψ l h j½H A ; H B ψ l j i ¼ ψ l h j½H; H B ψ l j i ¼ 0. Thus the perturbation in energy has order Oðδt 2 Þ instead. As a first conclusion, we reveal the similarity between the first and second order product formulas.
These methods also lead us to consider applications in which the initial state ψ j i is (or is close to) an eigenstate of H, enabling an improved upper bound on the Trotter step size in QPE. QPE relates Hamiltonian time-evolution U(t) = e −iHt to the measurement of energy eigenvalues [10][11][12] . In the ideal version of the algorithm, measuring the output of the phase estimation circuit collapses the system into an energy eigenstate of H. If we replace the time evolution with the product formula approximation U Tro (δt) L , then (in the ideal case) we will instead measure an energy eigenvalue of e H. In our framework, the Trotter error in phase estimation can be reduced from OðLδt 2 Þ to OðLδt 3 Þ. In terms of the target precision ϵ of the QPE, this means the Trotter step size can be enlarged from δt ¼ OðϵÞ to δt ¼ Oðϵ 1=2 Þ.

Set up and notations
Usually, the Trotter error is quantified by the norm distance between operators. Δ kΔk;Δ U Tro ðδtÞ L À UðtÞ: The notation ∥⋅∥ refers to the operator norm: To quantify Δ, usually, we relate it to the norm distance error of a single Trotter step δ ≡ ∥U Tro (δt) − U(δt)∥ as Δ ≤ Lδ, then calculate δ with Baker-Campbell-Hausdorff formula 13 or Magnus expansion 14 . For a given error tolerance ϵ, the restriction of Δ ≤ ϵ determines the gate complexity of the algorithm.
The Trotterized evolution operator U Tro (δt) can also be viewed as an exact evolution under an effective Hamiltonian e H i logðU Tro ðδtÞÞ=δt. Because the logarithmic of a unitary operator has more than one solutions, we settle down the effective Hamiltonian as e H ¼ e HðδtÞ, where e HðτÞ i logðU Tro ðτÞÞ=τ; τ 2 ½0; δt is the branch that is always continuous in τ, and e Hð0Þ ¼ H. Owing to the tiny size of δt, the energy levels and eigenstates of e Hf e E l ; e ψ l g are close to those of H. Denote the projector into the original eigenstate as P l ψ l j i ψ l h j, and e P l e ψ l e ψ l . The fidelity distance between the eigenbasis equals to the operator norm distance between the two projectors, ffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffi 1 À j e ψ l jψ l j 2 q ¼ k e P l À P l k: To ensure there exists a one-to-one correspondence between ψ l j i andψ l , we assume the spectrum is nondegenerate. Therefore there is some spectral gap lower bound e λ l > 0 around this eigenstate during τ ∈ [0, δt]: e λ l min τ2½0;δt ðmin m≠l j e E l ðτÞ À e E m ðτÞjÞ; where f e E l ðτÞg is the energy levels of e HðτÞ. In the next section, we will illustrate how the deviations in eigenbasis and energy levels are related to the Trotter error.

Framework
We first point out that Δ does not always reflect the true Trotter error. Separate the digital error into phase error θ and fidelity error f defined by θ Arg ψ h jU y ðtÞU Tro ðδtÞ L ψ j i ; where ψ j i is an initial state, then we prove for any L, δt that satisfy Δ 1= ffiffi ffi 2 p , the Euclidean distance error E kΔ ψ j ik 2 satisfies (see Without further assumptions about H and ψ j i, the two parameters are bounded by f ¼ OðΔ 2 Þ; jθj ¼ OðΔÞ as E Δ. It means the estimation of Δ is already an upper bound for ffiffi f p and |θ|. However, it's possible that ffiffi f p can have a different parameters scaling with Δ, for the error can be dominated by |θ| instead. Given one of the eigenstate ψ l j i of H as the initial state, we define its fidelity error and phase error as f l and θ l . f l is only a function of δt, while θ l grows linearly with the simulation time t. To see this, we first project ψ l j i to the associated effective state e ψ l , then let it evolve under U Tro (δt) L . Because e ψ l is an eigenstate of this operator, the effect of the evolution is merely a phase. After the evolution, we project the state back to the original eigenbasis. Thus, f l is only relevant to the distance between two eigenstates k e P l À P l k, and the phase error originates from the difference in energy levels. After a short initial period, the Trotter error only accumulates in the global phase. This is an extreme example of f ≪ Δ 2 .
More general, we can use this perspective to analyze the leakage rate of the Trotterized evolution operator as well. Suppose the initial state is supported on a subspace L, define its leakage rate as the percentage for it to transfer outside L after evolution U Tro (δt) L . Using the argument about e H we prove: (see Supplementary Note 2) Lemma 1. Consider a Hamiltonian evolution U(t) = e −iHt simulated by U Tro (δt) L , if the initial state ρ belongs to subspace L P L X l2L P l ; Tr ðρP L Þ ¼ 1; (9) and the norm distance between P L and corresponding effective projector e P L induced by e H satisfies kP L À e P L k < 1, then the leakage rate can be bounded by 1 À TrðU Tro ðδtÞ L ρU y Tro ðδtÞ L P L Þ 4k e P L À P L k 2 : When the subspace L contains only one eigenstate ψ l j i, the leakage rate is equivalent to fidelity error f l .
Similar analysis can be applied to a general initial state ψ j i. We first transform ψ j i ¼ P l c l ψ l j i into the effective initial state e ψ ¼ P l c l e ψ l (denote the transformation between two eigenbasis as S); then let the state evolve under U Tro (δt) L ; after the evolution, we can transform the state back to the original basis. The generated state is Although it's hard to compare U Tro ðδtÞ L ψ j i with UðtÞ ψ j i directly, it's easy to compare P l c l e Ài e E l t ψ l j i with P l c l e ÀiE l t ψ l j i, and S † U Tro (δt) L S with U Tro (δt) L . Analytically, it means we can separate Trotter error into two parts: the first part originates from the difference in the two eigenbasis, which is only relevant to δt; the other part accumulates during the evolution, which depends on j e E l À E l j and grows linearly with the simulation time t. Formally speaking: (see Supplementary Note 3) H is the effective Hamiltonian associated with U Tro (δt). After spectral decomposition we have H = ∑ l E l P l and e H ¼ P l e E l e P l . Given initial state ψ j i supported on subspace L : P L ψ j i ¼ ψ j i, the Trotter error has upper bound k e P l À P l k: A quick remark is, even when t = 0, the upper bound in Eq. 12 is still non-zero. This is because near the beginning time, the digital evolution operator is almost identity, thus SU Tro (δt) L S † ≈ U Tro (δt) L . In this region, the error related to S also increases with t. However, it only happens when the simulation time t is meaninglessly small, thus we don't emphasize it in Lemma 2.
The remaining part is to derive proper upper bounds for j e E l À E l j and k e P l À P l k, which depends on the specific choice of product formulas. Here we consider the first order formula as an example. Using the Baker-Campbell-Hausdorff formula, e H can be estimated by The first few terms of the standard (Rayleigh-Schrodinger) perturbation theory can be used to estimate k e P l À P l k and C. Yi and E. Crosson j e E l À E l j, but to avoid convergence issues and derive rigorous results, we use other methods 15,16 that are widely used in proofs of adiabatic theorems. By Weyl's inequality, the perturbation in the eigenvalues satisfies j e E l À E l j k e H À Hk: The perturbation of the eigenstate is bounded by k e P l À P l k ¼ k e P l ðδtÞ À e P l ð0Þk δt max The term k e H 0 ðτÞk quantifies the size of the perturbation. k e H 0 ðτÞkδt shares the same order with k e H À Hk. For a general normalized Hamiltonian H ¼ P N j¼1 h j ; kh j k 1 supported on N site, in Lemma 5 we show that k e H 0 ðτÞk ¼ Oð poly ðNÞÞ. We use it as a proper upper bound in the next paragraphs.
Combinig the estimations of k e P l À P l k and j e E l À E l j with Lemma 2, we already obtain upper bound for kΔP L k. When t is large and dim ðLÞ is small, the Trotter error is dominated by j e E l À E l jt, which is approximately Oðk e H À HktÞ. This estimation can also be derived from the inequality ke Ài e Ht À e ÀiHt k k e H À Hkt. Thus, till now our approach hasn't resulted in any significant improvement yet, except for the observation that f l has an upper bound that does not depend on t in the large time region. However, the improvement on the upper bound of j e E l À E l j can be used to obtain better results. In the next section, we will show how this improvement is achieved.
Improved j e E l À E l j from Special Perturbation The bound in Eq. 14 is a common estimation. However, in this section, we show that this upper bound can be improved by a factor of δt under assumptions that are satisfied for many Hamiltonians of interest, and this improves the scaling of the operator norm Δ and the Trotter step size needed for QPE.
In perturbation theory, we know that for e H ¼ H þ V, the leading perturbation in the lth energy level has expression E ð1Þ l ¼ ψ l h jV ψ l j i. If the perturbation term V is off-diagonal in the eigenbasis of H, then 8l; E ð1Þ l ¼ 0, the leading perturbation in energy has order OðkVk 2 Þ instead. Therefore, consider a general decomposition H ¼ P Γ n¼1 H n , whenever the leading order correction (see Eq. 13), is off-diagonal in the eigenbasis of H, we can reduce the Trotter error in energy from OðδtÞ to Oðδt 2 Þ. Thus: (see Supplementary Note 5) H is a normalized local Hamiltonian on N sites with spectrum fE l ; ψ l j ig, e H is its corresponding effective Hamiltonian induced from first order product formula. The energy and eigenstates of e H are f e E l ; e ψ l g. e λ l is the lower bound of spectral gap defined in Eq. 5. Suppose δt ¼ Oð1= poly ðNÞÞ and the first perturbation of e H is off-diagonal in the eigenbasis of H then the Trotter error in energy satisfies j e E l À E l j ¼ O poly ðNÞδt 2 max 1; 1 e λ l : Here we list several conditions where Eq. 17 is satisfied (or it maintains true for one specific energy level).  Fig. 1 for a simple illustration.
• Real Hamiltonians 17 . Assume all of the local terms of H have real matrix elements in some basis. The components of an eigenstate ψ l j i of any real symmetric matrices can all be taken to be real. Consider an arbitrary commutator in V, ψ l h jH k H m ψ l j i is conjugate to ψ l h jH m H k ψ l j i, and both are real numbers. So they are equal and appear with opposite signs in the commutator. Therefore, 8k; l; m; ψ l h j½H k ; H m ψ l j i ¼ 0.
• Frustration-free Hamiltonians 18 . This type of Hamiltonian satisfies H = ∑ j Π j , where Π j is a local term that shares the same ground state with H. (See Theorem 1 in 19 for an example) With this property, when the initial state is the ground state, there will be no Trotter error no matter how big δt is. In Lemma 3, the upper bound on the Trotter error is inversely proportional to the spectral gap λ. However, it's possible for frustration-free Hamiltonian to be gapless 19 . This example shows that our methods can still overestimate the Trotter error for gapless Hamiltonians.
Finally, we provide an example H = H 1 + H 2 + H 3 in which V is not off-diagonal to show the result in Lemma 3 is not fully general.
Let H be a diagonal matrix Λ in the eigenbasis of itself. In this basis, choose Thus, The first term is off-diagonal, the second term is not. Thus V is not off-diagonal.
Comparison between the first and the second order product formulas Our first conclusion is the similarity between the first and second order product formulas. The second order product formula has expression In Eq.
(121) of 5 , it has been proved that: kU ð2Þ Tro ðδtÞ L À UðtÞk Oð poly ðNÞLδt 3 Þ, which is much better than the first order formula. However, in the two-layer case H = H A + H B , it's easy to discover their similarity: the corresponding effective Hamiltonians have exactly the same energy levels, and their eigenbasis is related by a small unitary e ÀiHAδt . There has been several works 7,8 addressing that the first order product formula can share similar error asymptotic scaling with the second order one. The following corollary can also be regarded as a supportive result: Theorem 1. Given a normalized local Hamiltonian H on N sites, define e λ min l e λ l with e λ l introduced in Eq. 5. Suppose the first order product formula U Tro (δt) L of H satisfies the condition mentioned in Lemma 3 and δt ¼ Oð1= poly ðNÞÞ, and the initial state is supported on a low-dimension subspace, then the corresponding operator norm error has upper bound This theorem is a direct conclusion of Lemma 2 and Lemma 3. Besides the common two-layer case, our result also includes the real Hamiltonian situation, which generalizes previous results.

Application in quantum phase estimation
The QPE algorithm constructs a quantum circuit to detect the phase 2πθ of a unitary operator: U ψ j i ¼ e i2πθ ψ j i. For an exact QPE algorithm, the measurement outcome is the integer a closest to 2 q θ, where q is the size of the first register. Since it's unlikely for 2 q θ to be an integer, the QPE algorithm has precision ξ ¼ Oð2 Àq Þ. The probability of measuring the value closest to the true θ is at least 4/π 212 .
The influence of the Trotter error comes from two aspects. Again let's regard the Trotterized evolution operator as an exact evolution operator under the effective Hamiltonian e H. This effective Hamiltonian has an eigenstate e ψ , which is very close to the initial eigenstate ψ j i : ψ As a result, the final phase detected should be e θ associated with e ψ , and the success rate should be decreased by a factor of (1 − p). However, since usually p is much smaller comparing to 1, this change in success rate is almost negligible.
More importantly, the Trotter error in phase δθ ¼ j e θ À θj should satisfy δθ < 2πξ, otherwise, the phase error caused by Trotterization will be detected. This relation gives us a constraint on the Trotter error j e E À Ejt 2πξ: In QPE, θ should be set to be close to 1 to avoid wasting the accuracy provided by the first register, thus t ¼ Oð1=jEjÞ.
However, we can only guess about E before the algorithm. Here we use t 0 to denote an appropriate choice of time scale in U. Thus, where L is the circuit depth of a single U in QPE. Follow from Lemma 3, we prove: Theorem 2. Consider a quantum circuit performing QPE, the size of the first register is q thus the precision is ξ ¼ Oð2 Àq Þ. The unitary operator U ¼ e ÀiHt0 is simulated by U Tro ðt 0 =LÞ L . The initial state is the lth eigenstate with spectral gap lower bound e λ l defined in Eq. 5. Suppose the effective Hamiltonian of the digital evolution operator satisfies the condition in Lemma 3, and δt ¼ Oð1= poly ðNÞÞ, to guarantee that the Trotter error in phase j e E l À E l jt 0 is smaller than 2πξ, we require As a comparison, in general case with j e E l À E l j ¼ Oð poly ðNÞδtÞ, the final circuit depth is Oð poly ðNÞt 2 0 =ξ 2 Þ. The theorem is stated for an initial state that is an exact eigenstate, but by linearity, it can be applied to an arbitrary superposition, with a corresponding reduction in the probability of measuring the energy eigenvalue of interest (in the cases where the desired eigenvalue is measured, it will have the precision guarantee of ϵ despite the use of the enlarged Trotter step size above).

DISCUSSION
Our main contribution is the observation that the refined estimation of Trotter error can be established from the spectral analysis of the effective Hamiltonian e H. When the initial state is an eigenstate, we find that during evolution, most error accumulates in the phase. Further, if the leading perturbation term of e H vanishes in the eigenbasis of H, the Trotter error in energy is reduced from OðδtÞ to Oðδt 2 Þ, which results in improvement of the upper bound of first order product formula, coincides with the previous results 7, 8 . As an application, this improvement significantly reduces the circuit complexity of QPE. Similar results also apply to other phase estimation methods such as robust phase estimation 20 (See Supplementary Note 7), as long as the Trotterized unitary operator is used.
One question is the dependence on the gap condition. Our framework requires the spectral gap to be open for e HðτÞ; τ 2 ½0; δt. This condition doesn't show up in previous analysis about product formulas. For instance, for 2-local Hamiltonian with zero spectral gap, it's direct to simulate its evolution with product formula, while in our method the upper bound of Trotter error diverges. One possible explanation is the inverse dependence on λ can be fake. Consider a Hamiltonian, all of its low energy levels are degenerate, while the perturbation occurs only on the high energy levels. If we still use the formula k e P À Pk k e H À Hk=λ to analyze a low energy state, we will see the deviation is infinite large, while there's no perturbation in low energy levels. The effective Hamiltonian associated with Motzkin path model in 19 might be an example to reveal this point.
The effective Hamiltonian perspective has also led to a new analysis of the error in digital adiabatic simulation based on Trotterization 21 . Additional open questions include whether focusing on special cases of observables allows for additional improvement in Trotter error 22,23 , and whether the effective Hamiltonian perspective may be applicable to the randomized version of product formulas 24,25 or other Hamiltonian simulation algorithms [26][27][28] . Finally, the effective Hamiltonian in our framework is also termed as Floquet Hamiltonian in other fields of study [29][30][31] , where our methods can be useful as well.

Rigorous perturbation methods
The improved dependence on the gap, from λ −1 in Eq. 15 to λ −1/2 in Eq. 30, can be carried through to improve the spectral gap dependence of our results here, when the eigenstate in question is the ground state. In the main text we use the general result kH 0 ðsÞk=λ as a general upper bound for kP 0 ðsÞk. Similar results can be derived using Sylvester equation as well. See Lemma 3.1 in ref. 33 .