Trotterization approximates quantum time evolution by sequentially applying Hamiltonian terms. Because noncommuting terms introduce ordering-dependent errors, selecting an optimal term ordering is a combinatorial problem over a factorial search space. Prior approaches rely on fixed heuristics or on selection among predefined structured orderings, both of which require simulating candidates before choosing among them. For 1D and 2D Heisenberg-style Hamiltonians, we instead learn the ordering directly with a physics-aware ranking transformer that assigns a scalar score to each Hamiltonian term and predicts an ordering by sorting these scores. Physical structure enters through commutator-biased attention and an anticommutation-weighted ranking loss, and the models are trained on simulated-annealing (SA) reference orderings. We train separate models for first- and second-order Trotterization, each jointly on chains up to 14 qubits and lattices up to 12 qubits, and evaluate them on unseen chains with 16-20 qubits and lattices with 16 and 20 qubits. Predicted orderings are evaluated by the median gap in simulation fidelity to the SA reference. At first order, the model reaches a pooled gap below 10^-4 on chains, 0.0144 and 0.0088 on triangular lattices, and 0.0948 and 0.0823 on rectangular lattices at 16 and 20 qubits; at second order, the gaps are 0.0114, 0.0364 and 0.0244, and 0.1348 and 0.1239. The prediction exceeds the SA reference on 34% of first-order and 8% of second-order chain instances and can match its fidelity even when the two sequences differ because commuting terms may be rearranged without changing the Trotter unitary. The learned models generalize to larger systems across all three geometries, performing best on chains and triangular lattices, and produce an ordering in one forward pass without candidate enumeration, simulated annealing, or fidelity evaluation.
Comments
8 pages, 4 figures. Accepted at 2026 IEEE 2nd International Conference on Quantum Artificial Intelligence (QAI)
Trotterization approximates quantum time evolution by sequentially applying Hamiltonian terms. Because noncommuting terms introduce ordering-dependent errors, selecting an optimal term ordering is a combinatorial problem over a factorial search space. Prior approaches rely on fixed heuristics or on selection among predefined structured orderings, both of which require simulating candidates before choosing among them. For 1D and 2D Heisenberg-style Hamiltonians, we instead learn the ordering directly with a physics-aware ranking transformer that assigns a scalar score to each Hamiltonian term and predicts an ordering by sorting these scores. Physical structure enters through commutator-biased attention and an anticommutation-weighted ranking loss, and the models are trained on simulated-annealing (SA) reference orderings. We train separate models for first- and second-order Trotterization, each jointly on chains up to 14 qubits and lattices up to 12 qubits, and evaluate them on unseen chains with 16-20 qubits and lattices with 16 and 20 qubits. Predicted orderings are evaluated by the median gap in simulation fidelity to the SA reference. At first order, the model reaches a pooled gap below 10^-4 on chains, 0.0144 and 0.0088 on triangular lattices, and 0.0948 and 0.0823 on rectangular lattices at 16 and 20 qubits; at second order, the gaps are 0.0114, 0.0364 and 0.0244, and 0.1348 and 0.1239. The prediction exceeds the SA reference on 34% of first-order and 8% of second-order chain instances and can match its fidelity even when the two sequences differ because commuting terms may be rearranged without changing the Trotter unitary. The learned models generalize to larger systems across all three geometries, performing best on chains and triangular lattices, and produce an ordering in one forward pass without candidate enumeration, simulated annealing, or fidelity evaluation.
Trotterization is a standard approach for simulating quantum time evolution on quantum computers, where the Hamiltonian is split into local terms and each term is applied in sequence. The order of these terms affects the fidelity of the simulation when they do not commute, so the choice of ordering directly impacts the accuracy of the simulation. We study this problem for one-dimensional XXZ Heisenberg Hamiltonians using a structured set of 24 candidate orderings derived from colorings of the Hamiltonian's commutation graph and their group permutations. Finding the best candidate for large systems becomes prohibitive because fidelity evaluation is computationally expensive. In this work, we train a transformer encoder on smaller systems to predict the best candidate ordering for larger systems directly from Hamiltonian and Trotter-configuration features, without computing candidate fidelities at inference time. The model is trained on in-range systems of 3 to 14 qubits with 15-qubit systems held out for validation. Experimental results show that the model reaches a mean test fidelity gap of 0.00115 relative to the best of the 24 candidates on out-of-range systems of 16 to 20 qubits. A training-size sweep further shows that generalization emerges once training includes systems up to L=8 qubits, with validation at L=9, and the gap continues to decrease as the training range grows. To our knowledge, this is the first application of a learned model to Trotter ordering, and it motivates future work on AI-guided Trotter ordering with generalization across Hamiltonian families and system types.
Trotter–Suzuki decompositions are frequently used in the quantum simulation of quantum chemistry. They transform the evolution operator into a form implementable on a quantum device, while incurring an error—the Trotter error. The Trotter error can be made arbitrarily small by increasing the Trotter number. However, this increases the length of the quantum circuits required, which may be impractical. It is therefore desirable to find methods of reducing the Trotter error through alternate means. The Trotter error is dependent on the order in which individual term unitaries are applied. Due to the factorial growth in the number of possible orderings with respect to the number of terms, finding an optimal strategy for ordering Trotter sequences is difficult. In this paper, we propose three ordering strategies, and assess their impact on the Trotter error incurred. Initially, we exhaustively examine the possible orderings for molecular hydrogen in a STO-3G basis. We demonstrate how the optimal ordering scheme depends on the compatibility graph of the Hamiltonian, and show how it varies with increasing bond length. We then use 44 molecular Hamiltonians to evaluate two strategies based on coloring their incompatibility graphs, while considering the properties of the obtained colorings. We find that the Trotter error for most systems involving heavy atoms, using a reference magnitude ordering, is less than 1 kcal/mol. Relative to this, the difference between ordering schemes can be substantial, being approximately on the order of millihartrees. The coloring-based ordering schemes are reasonably promising—particularly for systems involving heavy atoms—however further work is required to increase dependence on the magnitude of terms. Finally, we consider ordering strategies based on the norm of the Trotter error operator, including an iterative method for generating the new error operator terms added upon insertion of a term into an ordered Hamiltonian.
Trotterization is a technique that allows one to approximate a time evolution of a Hamiltonian by repeatedly evolving the individual terms of the Hamiltonian one-at-a-time for small time durations. Bounds on the error of this approximation exist; however, they are typically loose and moreover, it is known that the true error can be greatly influenced by the order in which the terms of the Hamiltonian are evolved. In this work, we consider various ordering strategies that exploit the commutation structure of the Hamiltonian, in addition to a few other baseline ordering strategies. These commutation-based strategies involve dividing the terms of the Hamiltonian into groups where all the terms within each group commute with one another. These groupings can be obtained by using graph coloring techniques on what we call the "commutation graph" of the Hamiltonian. We prove various results regarding the structure and properties of such commutation graphs for certain classes of Hamiltonians. We also empirically calculate the (true) Trotter error using these ordering strategies on various 1D and 2D Heisenberg-style systems.
Trotter–Suzuki decompositions are frequently used in the quantum simulation of quantum chemistry. They transform the evolution operator into a form implementable on a quantum device, while incurring an error—the Trotter error. The Trotter error can be made arbitrarily small by increasing the Trotter number. However, this increases the length of the quantum circuits required, which may be impractical. It is therefore desirable to find methods of reducing the Trotter error through alternate means. The Trotter error is dependent on the order in which individual term unitaries are applied. Due to the factorial growth in the number of possible orderings with respect to the number of terms, finding an optimal strategy for ordering Trotter sequences is difficult. In this paper, we propose three ordering strategies, and assess their impact on the Trotter error incurred. Initially, we exhaustively examine the possible orderings for molecular hydrogen in a STO-3G basis. We demonstrate how the optimal ordering scheme depends on the compatibility graph of the Hamiltonian, and show how it varies with increasing bond length. We then use 44 molecular Hamiltonians to evaluate two strategies based on coloring their incompatibility graphs, while considering the properties of the obtained colorings. We find that the Trotter error for most systems involving heavy atoms, using a reference magnitude ordering, is less than 1 kcal/mol. Relative to this, the difference between ordering schemes can be substantial, being approximately on the order of millihartrees. The coloring-based ordering schemes are reasonably promising—particularly for systems involving heavy atoms—however further work is required to increase dependence on the magnitude of terms. Finally, we consider ordering strategies based on the norm of the Trotter error operator, including an iterative method for generating the new error operator terms added upon insertion of a term into an ordered Hamiltonian.
Trotter Suzuki product formulas are the standard route to Hamiltonian evolution on noisy intermediate-scale quantum (\NISQ{}) hardware, but their accuracy depends on three coupled choices: term grouping, product-formula order, and time-step allocation. Grouping and order are discrete, which makes direct gradient optimization infeasible and forces existing compilers to rely on static heuristics.
We describe P-GONE, a method that combines a conditional diffusion model (D3PM + DDPM), a graph neural network (\GNN{}) encoder, and closed-loop REINFORCE fine-tuning to jointly learn grouping, order, and time-step optimization over a mixed discrete-continuous space. Under fidelity-matched conditions (F≥0.95), the method achieves circuit depth 86 versus 1673 for Qiskit fourth-order (ungrouped, Suzuki-4), about 19.4× compression, and 141 for Paulihedral (first-order Trotter), about 1.6× compression. At T=0.90 the method also beats the Qiskit group-commuting teacher (65 vs 103, 1.6× compression), though at T=0.95 the teacher still leads -- a stratified pattern that points toward fidelity-aware fine-tuning. Under a standard depolarizing noise model, the method achieves noisy fidelity roughly 2× the Qiskit fourth-order baseline (0.743 vs 0.380). Ablation shows a clear hierarchy: order learning > time allocation > grouping. Best-of-N sampling (N=32 is a practical sweet spot) and CFG guidance give flexible fidelity-depth trade-offs at inference. The method works well on structured Hamiltonians (TFIM, Heisenberg), but random Pauli Hamiltonians fail entirely at T≥0.95 -- a boundary that defines where the method applies.
Product formulas are a basic tool for simulating quantum many-body dynamics, but a fundamental degree of freedom in their application---the ordering of Hamiltonian terms---has remained largely unexplored. Here we systematically study such ordering effects, quantifying their impact on simulation accuracy and exploiting them to design more accurate product-formula simulations. We develop an efficiently computable, ordering-sensitive bound on the finite-step-size Trotter error for geometrically local Hamiltonians for arbitrarily high-order product formulas. For translation-invariant one-dimensional chains, our bounds are close to exact second-, fourth-, and sixth-order Trotter errors in small-system tests, while on large-scale systems they improve on previous higher-order analytical bounds by orders of magnitude. We further use the local structure of the error bounds and estimates to optimize ordering efficiently, reducing the long-chain problem to a minimum-mean-weight-cycle problem on a weighted de Bruijn graph. For random translation-invariant chains, sequential (staircase-like) orderings consistently outperform standard brickwall circuits; when circuit depth is restricted, the optimizer instead favors wave-like parallel-sequential orderings, which preserve much of the accuracy advantage over brickwall circuits. These results establish ordering as a useful degree of freedom for both understanding and improving product-formula simulation.