Machine-learned, finite temperature Fermi-operator expansions suitable for GPUs and AI-hardware Preprint: LA-UR
Stanislaw Kowalski, Christian F. A. Negre, Anders M. N. Niklasson, Kipton Barros, Joshua Finkelstein · 2026
Read Machine-learned, finite temperature Fermi-operator expansions suitable for GPUs and AI-hardware Preprint: LA-UR by Stanislaw Kowalski, Christian F. A. Negre, Anders M. N. Niklasson, Kipton Barros, Joshua Finkelstein (2026) in the Tower of Babel, a free online library of public-domain works preserved in clean, searchable text. No sign-up. The full text is served as a plain-text file at a predictable URL, where text is present: https://antarctic-labs.com/tower-of-babel/arxiv-2605-08523.txt.
Introduction
Stanislaw Kowalski and four coauthors speed up a core quantum chemistry calculation by teaching it with machine learning. Their target is the density matrix at real temperatures, usually found through costly matrix splitting. A recursive expansion method maps neatly onto deep network structure, and learned coefficients replace formulas that do not exist in closed form for warm systems.
A rescaling trick means one trained model serves many temperatures and chemical settings without retraining. The method leans only on fast matrix multiplication, suiting modern graphics hardware well. On small and medium matrices it runs about ten times faster than standard splitting methods. Electronic structure work gains a faster path for warm, fractional electron systems.
Catalog record
| CREATOR | Stanislaw Kowalski, Christian F. A. Negre, Anders M. N. Niklasson, Kipton Barros, Joshua Finkelstein |
|---|---|
| YEAR | 2026 |
| COLLECTION | PAPERS |
| FORMAT | TXT |
| FILE SIZE | 61 KB |
| LICENSE | http://creativecommons.org/publicdomain/zero/1.0/ |
| RIGHTS | CC0 |
| SOURCE | arXiv |
Source: https://arxiv.org/abs/2605.08523
Browse the full library · About the Tower of Babel
Full text
The opening of the work, from the library's hosted text:
Machine-learned, finite temperature Fermi-operator expansions suitable for GPUs and AI-hardware Preprint: LA-UR Stanislaw Kowalski, Christian F. A. Negre, Anders M. N. Niklasson, Kipton Barros, Joshua Finkelstein Abstract We present several finite-temperature recursive Fermi–operator expansion schemes based on the second-order spectral projection (SP2) method. Our approach builds on a previous observation that the electronic structure problem, as formulated through a recursive SP2 expansion, can be mapped onto the architecture of a deep neural network. Using this perspective, we generalize SP2 to finite electronic temperatures and construct machine learning models to determine optimized expansion coefficients. These coefficients are trained for a specified chemical potential and electronic temperature and are not available in closed analytical form. However, by employing an appropriate affine rescaling strategy to the Hamiltonian matrix, we eliminate the need to retrain the model during a simulation if the temperature and chemical potential change. Our approach avoids explicit diagonalization and relies solely on highly optimized matrix–matrix multiplication kernels. Compared to state-of-the-art diagonalization, we achieve an order-of-magnitude speedup in the single-particle finite-temperature density matrix calculation for small and moderately sized matrices on modern GPUs and dense matrix multiply units. I Introduction Quantum mechanics and electronic structure theory provide a complete theoretical framework for describing phenomena relevant to materials science, chemistry, and biology. In practical applications, however, the computational complexity prohibits the exact many-body solution to the Schrödinger equation. As a result, a variety of approximate electronic structure methods have been developed, balancing various levels of theory with computational cost. Among these, the most widely used methods are based on the Kohn-Sham density functional theory (KS-DFT), 15 ; 21 ; 41 ; 6 within the Born–Oppenheimer approximation. 25 In these approaches, the computational cost is governed by an algebraic eigenvalue problem. Solving the eigenvalue problem through diagonalization exhibits a computational cost that scales cubically with system size, 13 which for systems beyond a few thousand atoms typically becomes prohibitively expensive. Consequently, alternative techniques, such as numerically thresholded sparse matrix algebra 12 ; 34 ; 3 or various divide-and-conquer-like approaches, 52 ; 51 ; 20 ; 35 have been developed. Some of the most efficient methods are based on recursive Fermi-operator expansion schemes, in which the effective single-particle density matrix is computed directly, rather than constructed from the individual eigenvectors and eigenvalues. 40 ; 29 ; 16 ; 31 ; 32 ; 18 ; 44 ; 46 ; 43 ; 48 Unfortunately, the most efficient recursive Fermi-operator expansion schemes are restricted to zero electronic temperature, which results in an idempotent density matrix. These recursive schemes therefore cannot model systems with fractional orbital occupations, which are often needed to capture, for example, degenerate eigenstates at the chemical potential for chemical reactions or systems at elevated electronic temperatures. The purpose of this work is to demonstrate how a zero-temperature recursive expansion scheme can be generalized to enable the computation of the Fermi-operator for systems with fractional occupation numbers, using extremely accurate polynomial approximations to the true Fermi distribution function. An earlier attempt to construct a reasonably accurate pseudo-recursive Fermi–operator expansion was based on a modification of the second-order spectral projection (SP2) method. 31 In this approach, the SP2 recursion is deliberately truncated after a finite number of iterations to introduce an effective thermal smearing, 27 with higher electronic temperatures corresponding to earlier truncation. However, this truncated expansion remains inherently approximate and fails to reproduce key features of the exact Fermi function, particularly in the vicinity of the chemical potential where accuracy is often most critical. Notably, the exact Fermi distribution is only recovered in the limit of zero electronic temperature, indicating that an alternative formulation is required for finite-temperature applications. Several alternative approaches for computing the finite-temperature density matrix without explicit diagonalization have been proposed, including Chebyshev expansions 11 and Padé approximants, 32 though each presents its own limitations. At low temperatures, Chebyshev expansions typically require very high polynomial orders to suppress Gibbs oscillations. While the introduction of smoothing kernels 49 can mitigate these oscillations, the resulting approximation still deviates from the exact Fermi function near the chemical potential. For small but finite temperatures, accurately resolving all states may require hundreds or even thousands of Chebyshev terms, with each term requiring a corresponding matrix multiplication. Although reduced-scaling techniques—where the number of matrix multiplications grows instead with the square root of the polynomial order—have been developed, 8 ; 42 ; 24 they may still fall short of practical efficiency and can exhibit ill-conditioning effects at large enough polynomial order. Recursive Padé expansions avoid Gibbs oscillations and typically require only a small number of recursion steps, largely independent of temperature. Each recursion, however, requires the solution of a linear system, usually carried out with a few (1–4) conjugate gradient iterations, 32 and while the number of recursions remains modest, the need to repeatedly perform linear solves is computationally burdensome. Both Chebyshev- and Padé-based Fermi–operator expansions therefore incur a significant cost through the potentially large number of matrix multiplications or repeated linear solves. In practice, this overhead can outweigh their benefit, making them less efficient than direct diagonalization—particularly on modern GPU architectures, where highly optimized vendor-supplied routines achieve exceptional performance. Previous work has demonstrated highly-performant implementations of SP2 using GPUs 4 ; 45 and, more recently, AI-oriented hardware such as NVIDIA Tensor Cores, 9 ; 10 enabling evaluation of the zero-temperature density matrix in significantly less time than the optimized Nvidia cuSOLVER diagonalization routines across a wide range of matrix sizes. Beyond these performance gains, this previous work highlighted that the recursive algebraic structure of SP2 maps naturally onto the architecture of a deep neural network, suggesting that its recursive second-order form could be systematically exploited with machine learning. This viewpoint provides new flexibility in constructing recursive expansions: rather than relying exclusively on analytically determined spectral projection (SP2) functions, we introduce polynomial functions with machine learned coefficients (or, weights) at each iteration to capture the exact Fermi function at arbitrary temperature. This idea, introduced in Ref. 9 , forms the central focus of the present work and enables the reproduction of virtually exact Fermi functions at low computational cost for finite-temperature systems and cases with vanishing electronic HOMO–LUMO gaps. We begin by presenting some general theoretical background for density functional theory and the SP2 method in Section II . In Section III we discuss our generalizations of SP2 to finite temperatures based on several different types of neural network architectures, details on how we train those models and how we can use them to efficiently compute the electronic entropy. In Section IV , we demonstrate and provide a workflow for how these schemes can be implemented and applied to construct the finite-temperature density matrix. Lastly, in Section V we discuss our numerical results and computational performance using Nvidia Tensor Cores as well as how we can estimate model layer count. II Background II.1 The quantum mechanical eigenvalue equation in KS-DFT In Kohn-Sham density functional theory the effective single-particle electronic states (or molecular orbitals), \psi_{i}({\bf r})=\sum_{j}v^{(i)}_{j}\phi_{j}({\bf r}), (1) for a local basis-set \{\phi_{j}\} , are obtained from the eigenvectors, v^{(i)}=\{v^{(i)}_{j}\} , of the Kohn-Sham Hamiltonian matrix, H_{ij}=\langle\phi_{i}|{\widehat{H}}|\phi_{j}\rangle=\int\phi_{i}^{\dagger}({\bf r}){\widehat{H}}\phi_{j}({\bf r})d{\bf r}, (2) i.e. from the matrix eigenvalue equation, Hv^{(i)}=\varepsilon_{i}v^{(i)}\;. (3) For simplicity, we assume the local basis-set representation, \{\phi_{j}\} , is