WorksPhysics and Astronomy
Where the Error Lives: Spectral Representations of Learned Kohn-Sham Hamiltonians
Abstract
Kohn-Sham density functional theory (DFT) is the standard method for computing the electronic structure of molecules and materials, but its self-consistent-field (SCF) iterations make it expensive for large systems and high-throughput screening. Machine-learned Hamiltonian models offer a shortcut: an equivariant network predicts the Kohn-Sham Hamiltonian matrix in one forward pass, and diagonalizing the prediction yields orbital energies, the HOMO-LUMO gap, molecular orbitals and the electron density. These models are trained to match the reference matrix entry by entry, yet a small entry-wise error does not guarantee accurate eigenvalues or eigenvectors. Two physics-informed alternatives go partway: a recently proposed wavefunction-alignment loss adds a spectral penalty without diagonalizing the prediction, and matching the electron density of the diagonalized prediction supervises it directly. Neither is complete: by representing the prediction error in the eigenbasis of the reference Hamiltonian, we show that each sees only part of the error, and that shifting the predicted orbital energies leaves the electron density exactly unchanged. The same analysis identifies a complete training signal: the cumulative local density of states (cumulative LDOS), the number of electrons at each point in space with energy below a given threshold. The cumulative LDOS is a single physical observable that contains the electron density as a special case, responds to every component of the error, determines the Hamiltonian uniquely, and yields gradients that do not vanish for large orbitalenergy errors. Fine-tuning three Hamiltonian networks on QH9 in this way, which we call FermiScope, reduces the HOMO-LUMO gap error without increasing the element-wise error. The gains carry over to out-of-distribution and molecular-dynamics splits, where the wavefunction-alignment loss helps less.
Introduction
Kohn–Sham density functional theory (DFT) [6, 11], recognized by the 1998 Nobel Prize in Chemistry [10], is the most widely used method for computing the electronic structure of molecules and materials. It summarizes the electrons of a molecule in a single matrix, the Kohn–Sham Hamiltonian, whose generalized eigendecomposition gives the orbital energies, the energies of the highest occupied and lowest unoccupied molecular orbitals (HOMO and LUMO) and their gap, the molecular orbitals, and the electron density. These quantities determine chemical reactivity, optical and electronic behaviour and, through the total energy, molecular stability. Obtaining the Hamiltonian, however, requires self-consistent-field (SCF) iterations (Szabo & Ostlund, [22]). Each iteration builds the Hamiltonian from the current occupied orbitals ( in the number of basis functions for hybrid functionals) and diagonalizes it to obtain new ones (). A typical calculation repeats this times, until the Hamiltonian and the orbitals it is built from agree ( for the QH9 molecules studied here; Appendix § 11). This loop limits DFT on large systems and in high-throughput screening.
Machine-learned Hamiltonian models remove this bottleneck. An equivariant neural network predicts the Hamiltonian directly from the atomic numbers and positions (Schütt et al. [18]; Unke et al. [24]; Li et al. (2022); Yu et al. [27]; Li et al. [14]; Luo et al. [15]), replacing all iterations by one forward pass. The predicted Hamiltonian is used in two ways: it can be diagonalized once to obtain orbital energies, orbitals and the density, or it can initialize a conventional DFT calculation to save SCF iterations (Yu et al. [26]; Li et al. [14]). We focus on the first setting, where no SCF iteration is left to correct the prediction and the quality of the loss function directly determines the quality of the result. On the QH9 benchmark (Yu et al. [26]), the entry-wise error of the predicted Hamiltonian has more than halved since the benchmark was introduced (Table 1), but this has not always translated into better eigenvalues.
Table 1: Results on the QH9-stable-id test set (13,084 molecules) after 30k fine-tuning steps. Energies in Ha, in %. For each backbone, the gray rows are the two baselines, the pretrained model and fine-tuning with WALoss (Li et al., [14]). The violet row, density only, is the ablation at weight that keeps only the slice of our loss, which is density matching (Proposition B.4). The blue row is our cumulative LDOS loss, which adds the energy resolution. All fine-tuning runs share every other setting, and the peak-shaped variant is in Appendix § 17.§ 4. Bold marks the best downstream metric per backbone.
| backbone | role | method | diag | non-diag | HOMO | LUMO | gap | |||
| QHNet | baseline | pretrained | 77.56 | 129.25 | 73.68 | 1041 | 9445 | 9632 | 1206 | 96.28 |
| QHNet | baseline | + WALoss | 78.04 | 119.03 | 74.95 | 847 | 5458 | 5835 | 570 | 96.79 |
| QHNet | ablation | + density only () | 76.82 | 118.70 | 73.65 | 719 | 1575 | 2081 | 356 | 97.87 |
| QHNet | ours | + cumulative LDOS (ours) | 74.81 | 109.54 | 72.19 | 678 | 1482 | 2027 | 341 | 97.91 |
| SPHNet | baseline | pretrained | 36.60 | 44.79 | 35.38 | 345 | 1309 | 1554 | 380 | 99.06 |
| SPHNet | baseline | + WALoss | 37.28 | 46.03 | 35.98 | 341 | 957 | 1259 | 288 | 99.17 |
| SPHNet | ablation | + density only () | 37.63 | 47.14 | 36.23 | 363 | 684 | 970 | 143 | 99.08 |
| SPHNet | ours | + cumulative LDOS (ours) | 36.64 | 44.83 | 35.42 | 292 | 572 | 789 | 137 | 99.25 |
| WANet | baseline | pretrained | 40.07 | 51.28 | 38.42 | 335 | 1454 | 1684 | 288 | 98.98 |
| WANet | baseline | + WALoss | 40.99 | 53.26 | 39.19 | 328 | 1025 | 1306 | 157 | 99.13 |
| WANet | ablation | + density only () | 40.21 | 51.63 | 38.53 | 324 | 823 | 1101 | 140 | 99.22 |
| WANet | ours | + cumulative LDOS (ours) | 40.19 | 51.59 | 38.52 | 287 | 573 | 791 | 137 | 99.22 |
Table 1.
The entry-wise error does not translate directly into accurate eigenvalues and eigenvectors. For example, continuing to train QHNNet with its own element-wise loss lowers its matrix error but raises its HOMO–LUMO gap error, consistently on all four QH9 splits and by 53% on the standard split (Appendix § 17.§ 2). Li et al. [14] observed the same decoupling from the other side: on QH9, their alignment loss increased the matrix error while improving the orbital energies, and on larger molecules, matrices with tiny relative errors produced unusable total energies. The reason is that these models are trained with an element-wise loss, the mean absolute or squared error over matrix entries, which treats every entry alike, whereas eigenvalues and eigenvectors respond very unevenly to an error. Classical matrix perturbation theory makes this precise (Kato, [9]; Davis & Kahan, 1970; Stewart & Sun, 1990): to first order, an eigenvalue moves only with the corresponding diagonal entry of the error expressed in the eigenbasis, and the eigenvectors rotate by the off-diagonal entries divided by eigenvalue differences. On QH9, an error that couples the HOMO and the LUMO, about 0.25 Ha apart, therefore changes the LUMO about 75 times more than an equally large error that couples it to a core orbital some 19 Ha lower.
To make this precise, we represent the prediction error in the eigenbasis of the reference Hamiltonian, where it separates into three interpretable blocks, which we call sectors (Figure 1d): diagonal entries, which shift orbital energies; entries corresponding to an occupied and an unoccupied orbital, which mix the two and change the electron density; and entries corresponding to two occupied or two unoccupied orbitals, which only rotate orbitals within those spaces. This view explains why existing physics-informed losses help only partly. The wavefunction-alignment loss (WALoss) of Li et al. [14] evaluates the predicted Hamiltonian in the reference orbital basis. In its full form it weights every entry of the error uniformly, like the element-wise loss, and therefore does not concentrate on the errors that matter; in the diagonal-only form proposed by Li et al. [14], it penalizes only the orbital energies, and only to first order. A natural alternative is to diagonalize the prediction and match its electron density, which is exact and automatically focuses on the frontier orbitals, those closest to the HOMO–LUMO gap. We prove, however, that energy shifts and rotations within the occupied or the unoccupied space leave the density exactly unchanged, so a loss that depends only on the density does not respond to them at all; we say that it is blind to them. These errors span about 69% of the degrees of freedom of the error on QH9 and include every orbital-energy error.

Figure 1. Overview. (a–c) A Hamiltonian network maps a molecule, QH9 #23470 (CHN), to its Kohn–Sham Hamiltonian , whose eigendecomposition gives the orbital energies and HOMO–LUMO gap, the electron density and the molecular orbitals. All visualizations in panels (a–c) use reference DFT data for this molecule. (d) In the reference orbital basis, the prediction error splits into three sectors: orbital-energy shifts (A, yellow-orange diagonal), occupied–virtual mixing (B, blue off-diagonal block) and rotations within the occupied or the virtual space (C, purple off-diagonal blocks). The tags in panel (c) mark the sectors each downstream property depends on. (e) The sectors each training signal sees. WALoss is from Li et al. [14]; density matching, Equation (4), is the slice of our loss. (f) At a point , the cumulative LDOS is a staircase with one step per orbital. An energy error shifts a step (A), and a shape error changes step heights (B, C). The shape error shown changes the LUMO step but not the slice at , which is the density, so it is of type C and invisible to density matching; Figure 2 shows all three types.

Figure 2. How each kind of error shows up in the cumulative LDOS: the first-order change of at one point as a function of energy (schematic levels with the median QH9 gap, Ha; sign and scale arbitrary). An orbital-energy error (A, left) adds a bump at its level. An occupied–virtual coupling (B, middle) adds a plateau between the two levels, which crosses the Fermi level . A coupling of two occupied orbitals (C, right) adds a plateau that ends below . Density matching reads only the slice (dashed line), where only the B plateau is nonzero; the cumulative LDOS loss reads the whole energy window and sees all three (Theorem 3.5(ii)).
The same representation tells us what a complete training signal must do: see every sector, weight each by its effect on the properties of interest, and use the exact eigenpairs of the prediction. We find such a signal in a physical observable, the local density of states (LDOS), which resolves the electron density by energy and is what a scanning tunnelling microscope measures [23]. Its cumulative form, , the number of electrons at point with energy below , represents the Hamiltonian in the language of the density without discarding the orbital energies (Figure 1f). We prove four properties. The density is its slice at the Fermi level, the energy midway between the HOMO and the LUMO. It responds to every sector. It determines the Hamiltonian uniquely. And unlike a peak-shaped LDOS, it keeps pulling on an orbital energy toward its target however far inside the energy window it starts. We turn into a training loss, the cumulative LDOS loss : the mean squared difference between computed from the predicted and from the reference Hamiltonian, over sampled points and energies . A network is fine-tuned on , where is its usual element-wise loss and a weight, with no change to its architecture. We call this method FermiScope, as it scans across a window of energies around the Fermi level.
Across three architectures and four QH9 splits, this loss improves every eigen-derived metric in all twelve settings and is the best method in each (Table 1 and Table 6). On the standard split, it lowers the HOMO–LUMO gap error by 49–79%, 2.0–2.6 times more than WALoss, while the element-wise error rises by at most 0.3% and QHNet even falls by 3.5%. Under distribution shift, it still lowers the gap error by 36–77%, whereas WALoss makes it worse in three of the nine shifted settings, all on QHNet.
| backbone | split | method | diag | non-diag | HOMO | LUMO | gap | |||
| QHNet | stable-ood | pretrained | 73.53 | 122.32 | 70.78 | 561 | 4632 | 4522 | 740 | 95.54 |
| + WALoss | 72.70 | 115.00 | 70.30 | 475 | 5511 | 5671 | 393 | 95.04 | ||
| + cumulative LDOS (ours) | 71.10 | 110.81 | 68.87 | 442 | 1420 | 1506 | 290 | 96.17 | ||
| dynamic-geo | pretrained | 98.4 | 161.4 | 93.6 | 960 | 5561 | 6090 | 840 | 96.66 | |
| + WALoss | 100.0 | 162.2 | 95.3 | 976 | 6950 | 7441 | 597 | 96.06 | ||
| + cumulative LDOS (ours) | 95.6 | 148.5 | 91.6 | 771 | 1517 | 2132 | 400 | 97.85 | ||
| dynamic-mol | pretrained | 173.5 | 420.1 | 153.7 | 7662 | 68568 | 62262 | 9696 | 79.74 | |
| + WALoss | 174.5 | 419.4 | 154.8 | 8101 | 74057 | 67285 | 9280 | 79.10 | ||
| + cumulative LDOS (ours) | 172.3 | 415.9 | 152.8 | 2494 | 15105 | 14356 | 4842 | 90.57 | ||
| SPHNet | stable-ood | pretrained | 30.38 | 38.62 | 29.44 | 171 | 911 | 1004 | 110 | 98.62 |
| + WALoss | 30.95 | 39.60 | 29.95 | 187 | 605 | 720 | 107 | 98.67 | ||
| + cumulative LDOS (ours) | 30.47 | 38.87 | 29.51 | 156 | 504 | 590 | 105 | 98.70 | ||
| dynamic-geo | pretrained | 37.77 | 41.27 | 37.23 | 225 | 758 | 928 | 104 | 99.39 | |
| + WALoss | 38.55 | 42.73 | 37.90 | 241 | 642 | 854 | 104 | 99.49 | ||
| + cumulative LDOS (ours) | 37.74 | 41.21 | 37.20 | 203 | 431 | 592 | 98 | 99.53 | ||
| dynamic-mol | pretrained | 102.32 | 221.59 | 83.38 | 1461 | 13758 | 13433 | 2862 | 93.54 | |
| + WALoss | 102.09 | 221.60 | 83.12 | 1344 | 10632 | 10466 | 2346 | 94.11 | ||
| + cumulative LDOS (ours) | 102.28 | 221.43 | 83.36 | 1306 | 8528 | 8362 | 2068 | 94.56 | ||
| WANet | stable-ood | pretrained | 37.05 | 78.99 | 32.28 | 380 | 1259 | 1055 | 160 | 98.55 |
| + WALoss | 34.42 | 49.26 | 32.72 | 176 | 524 | 577 | 113 | 98.57 | ||
| + cumulative LDOS (ours) | 34.09 | 48.39 | 32.46 | 162 | 486 | 549 | 110 | 98.59 | ||
| dynamic-geo | pretrained | 41.04 | 46.63 | 40.19 | 269 | 953 | 1126 | 106 | 99.32 | |
| + WALoss | 41.93 | 48.54 | 40.93 | 252 | 675 | 898 | 103 | 99.45 | ||
| + cumulative LDOS (ours) | 41.06 | 46.64 | 40.20 | 217 | 440 | 609 | 97 | 99.51 | ||
| dynamic-mol | pretrained | 127.51 | 290.69 | 101.52 | 3238 | 26236 | 24126 | 4112 | 89.17 | |
| + WALoss | 127.15 | 290.41 | 101.15 | 3070 | 23111 | 21184 | 3571 | 89.88 | ||
| + cumulative LDOS (ours) | 127.46 | 290.44 | 101.51 | 2020 | 13756 | 12936 | 2186 | 92.47 |
Table 6. Results on the shifted QH9 splits (test sets; energies in Ha, in %). Same protocol as Table 1. Bold marks the best downstream metric per block.
Our contributions are as follows.
• Problem. We show that the mismatch between how Hamiltonian networks are trained, entry by entry, and how they are used, through eigenpairs, is a question of where the error lies. In the reference orbital basis, the error separates into sectors that each property and each training signal read selectively, and the electron density, the most natural physical target, is blind to every orbital-energy error (§ 3.1).
• Solution. We identify the cumulative LDOS as a representation of the Hamiltonian that contains the density, sees every sector and determines the Hamiltonian uniquely, and we turn it into a training loss that any Hamiltonian network can use unchanged (§ 3.2 and § 3.3).
• Results and implications. The loss improves every eigen-derived metric in all twelve backbone–split settings without raising the element-wise error by more than 0.3% (§ 4). How a predicted Hamiltonian is represented during training, and not only the architecture that produces it, decides whether it is useful.
Background
Notation. We follow standard quantum-chemistry notation [22]; Appendix § 11 explains the terms we use and illustrates the SCF procedure. Bold upright symbols denote matrices and vectors. A star marks quantities of the reference DFT calculation and a hat quantities computed from a network’s prediction; unadorned symbols (, , , , ) denote the same maps applied to a generic Hamiltonian. A hat thus means predicted, as in statistics.
Kohn–Sham Hamiltonians. Consider a molecule of atoms with atomic numbers , which identify the element of each atom, and positions . Its electrons are described in a basis of real-valued, atom-centred basis functions , also called atomic orbitals; for the def2-SVP basis used here, they are Gaussian-type functions. The basis functions are linearly independent but not orthogonal. Their inner products form the overlap matrix , with entries ; it depends only on the geometry and is positive definite, written . In Kohn–Sham DFT [6, 11], the electronic structure is represented by a second symmetric matrix, the Kohn–Sham Hamiltonian , with entries , where is the Kohn–Sham operator built from the occupied orbitals through their density matrix Equation (2) and is the converged, self-consistent one. The molecular orbitals of the reference are linear combinations of the basis functions, (we omit their star), whose coefficients and energies solve the generalized eigenvalue problem
The second condition states that, unlike the basis functions, the molecular orbitals are orthonormal, . Column of holds the coefficients of orbital , and is its energy. A closed-shell molecule with electrons occupies the lowest orbitals (the set ); the remaining orbitals are unoccupied, or virtual (the set ). The HOMO and LUMO energies are and , and the electron density is
where and holds the occupied columns of . The density matrix is twice the projector onto the occupied subspace, the span of the lowest orbitals.
Two maps connect the Hamiltonian and the density matrix. Diagonalizing a Hamiltonian and filling its lowest orbitals gives a density matrix, , and from it the density by Equation (2). Conversely, evaluating the Kohn–Sham operator in the basis builds an Hamiltonian from a density matrix, ; for a hybrid functional such as B3LYP, the exact-exchange term needs all of , not only the density. DFT alternates the two maps in the self-consistent-field (SCF) iteration,
from an initial guess until stops changing. The reference is the fixed point of this loop, with . The two maps are not mirror images. The build gives one Hamiltonian for each density matrix, but many Hamiltonians share the same density matrix, because records only which subspace is occupied, not the orbital energies or how the subspace is split into individual orbitals. The build costs for hybrid functionals, and the iterations dominate the cost of the calculation (Figure 4 in Appendix § 11).

Figure 4. (a) The self-consistent-field loop of Kohn–Sham DFT: the Kohn–Sham matrix is built from the current density matrix and diagonalized, and the occupied orbitals give the next density matrix, until the two agree. (b) A Hamiltonian network predicts the converged matrix in one forward pass; one diagonalization gives the orbital energies, orbitals and density, and the prediction can also initialize SCF. Iteration counts are medians over 50 QH9-stable-ood test molecules (PySCF, B3LYP/def2-SVP).
Learning Hamiltonians. A Hamiltonian network predicts and is built to transform correctly under rotations of the molecule; is computed exactly from the geometry. Existing models are trained with the element-wise loss , the mean absolute or squared error over matrix entries [27, 14, 15]. At inference, replaces in Equation (1), and every downstream quantity follows from its eigenpairs . Following QH9 [26], models are evaluated by the element-wise error of together with the errors of the orbital energies and the similarity of the orbital coefficients (§ 4.1).
Physics-informed losses. The wavefunction-alignment loss (WALoss) of Li et al. [14] adds a spectral signal without diagonalizing the prediction. It precomputes the reference orbitals and evaluates the prediction in their basis: since diagonalizes , the matrix should equal . The full form penalizes every entry of the deviation alike, , where is the mean absolute or squared error over the entries (Appendix § 17.§ 3); we use this form for all backbones. Li et al. [14] also propose a diagonal-only form that keeps only the diagonal, , with large weights on the occupied orbitals and the LUMO; it appears as reweighted WALoss in Figure 1e. A second option is to diagonalize , form the predicted density by Equation (2), and penalize its deviation from at a set of sample points,
where is a geometry-only factor that down-weights the region near the nuclei, where the density is orders of magnitude larger (Ushenin et al. (2025)). We call Equation (4) density matching; § 3.2 shows that it is a special case of our loss.
Spectral Representations of Hamiltonian Errors
We first represent the prediction error in the basis of reference orbitals and determine which part of it each eigen-property depends on (§ 3.1). This identifies what a complete training signal must see and leads to the cumulative LDOS (§ 3.2), whose guarantees we establish in § 3.3.
Where the prediction error lives
Write the prediction as and express the error in the basis of reference orbitals,
Entry measures how strongly the error couples reference orbitals and . We partition the symmetric matrix into three sectors (Figure 1d): (A) the diagonal entries ; (B) the occupied–virtual block ; and (C) the off-diagonal parts of the occupied–occupied and virtual–virtual blocks, and . This partition is exact: it sorts the entries of by position alone, according to whether an entry lies on the diagonal and whether the orbitals it couples are occupied or virtual. The full WALoss averages the entries of without weights (Lemma B.1), so it treats all sectors alike.
Classical matrix perturbation theory (Kato, [9]; Stewart & Sun, [20]) then shows what each sector does to the downstream properties.
Proposition 3.1 (What each property depends on). Let the reference orbital energies be non-degenerate, and expand the eigenvalues and eigenvectors of as functions of around the reference, . To first order:
(a) Sector A: orbital energies depend only on the diagonal: ;
(b) Sectors B and C: orbital shapes depend on the off-diagonal entries, weighted by inverse energy spacings: ;
(c) Sector B only: the density depends only on the occupied–virtual block, with the largest weights on orbital pairs near the HOMO–LUMO gap:
Appendix § 12 gives the proof and the second-order corrections. Item (c) holds because the occupied–occupied contributions cancel in pairs: rotating occupied orbitals among themselves leaves their total density unchanged. This cancellation is exact, not only first-order. Items (a) and (b) need non-degenerate orbital energies, but (c) needs only a nonzero HOMO–LUMO gap, because the density matrix is the spectral projector onto the occupied subspace, which depends analytically on the Hamiltonian while the gap is open (Kato, [9]). This matters on QH9, where 12% of the molecules have two orbital energies closer than 0.1 mHa. Remark B.3 in Appendix § 12 relates the sectors to the reported metrics.
Proposition 3.2 (The density is blind to sectors A and C). If and no eigenvalue of crosses the HOMO–LUMO gap, then exactly. Any loss that depends on only through its density therefore vanishes on a subspace of dimension out of .
The reason is the map of § 2, which keeps only the occupied subspace. If , the prediction does not mix occupied with virtual reference orbitals, and if no level crosses the gap, its occupied subspace is that of the reference. Shifting energies (A) or rotating orbitals within the occupied or the virtual space (C) leaves this subspace, and with it and , in place.
On a uniform sample of 4,000 QH9-stable molecules, with median and , this blind subspace holds a median of 69.0% of the degrees of freedom of , that is, of its independent entries, and 66–71% between the 5th and 95th percentiles (Table 5). It contains every orbital-energy error, including the HOMO–LUMO gap error. The fraction counts directions, not error size: on physically realized Hamiltonian changes, the blind sectors carry 16–30% of more at larger displacements (Appendix § 14.§ 4). On a real molecule, shifting the HOMO or LUMO energy by 2 mHa changes the density loss by less than , whereas rotating the HOMO and LUMO into each other changes it by (Figure 12a in Appendix § 18).
| quantity | median | range | min–max |
| atoms per molecule | 18 | – | 5–29 |
| heavy atoms (C, N, O, F) | 9 | – | 1–9 |
| basis functions | 171 | 141–196 | 34–226 |
| occupied orbitals | 33 | 29–35 | 5–37 |
| occupied fraction | 0.193 | 0.178–0.219 | 0.147–0.256 |
| HOMO–LUMO gap (Ha) | 0.248 | 0.173–0.305 | 0.079–0.463 |
| HOMO–LUMO gap (eV) | 6.74 | 4.72–8.31 | 2.15–12.60 |
| lowest eigenvalue (Ha) | −19.14 | – | −24.76–−10.17 |
| highest eigenvalue (Ha) | 3.69 | – | 2.91–4.14 |
| density-blind fraction of | 0.690 | 0.661–0.709 | – |
Table 5. QH9-stable composition and reference spectra, measured on a uniform 4,000-molecule sample. Ranges are 5–95% intervals unless a min–max is stated. The last row is the exact fraction of the parameters of a symmetric residual that lie in the two sectors the density loss cannot resolve.

Figure 12. (a) Response of each loss to controlled perturbations of the reference Hamiltonian of one QH9 molecule (#12345): shifting the LUMO or HOMO energy by 2 mHa with all orbitals fixed, or rotating the HOMO and LUMO into each other with all energies fixed. Density matching does not respond to energy shifts at all (values at the level of floating-point round-off); both LDOS losses respond to both kinds of error. (b) Mismatch between a displaced and a reference orbital as a function of the energy error , for a Gaussian peak and for a cumulative step (closed forms of Theorem 3.5(iv)): the peak mismatch saturates, the step mismatch keeps growing. (c) The corresponding gradient with respect to , normalized by its maximum: the peak gradient vanishes beyond a few , whereas the step gradient approaches a constant.
Remark 3.3 (Why density matching still improves the gap). Proposition 3.2 is a statement about directions, not about what a trained network does. A network produces all sectors from the same atomic-orbital blocks, so correcting the frontier couplings of sector B, which the density weights by , also changes the frontier orbital energies. In practice it improves them, and density matching alone lowers the gap error substantially (§ 4.4). The density loss is, however, exactly flat along any change of the predicted orbital energies that leaves the predicted orbitals fixed and moves no level across the gap, so it cannot correct the energy error that remains. That error lies in sector A, which is where energy resolution adds most (§ 4.4).
From the density back to the Hamiltonian. SCF fixes the Hamiltonian from the density matrix, , but only because the reference is self-consistent: it is built from its own density matrix. A predicted is not, and the step from to its density matrix loses information. Every Hamiltonian that differs from only in sectors A and C, and moves no level across the gap, has the same and hence the same . Matching the density, or even the density matrix, therefore cannot single out . This is enough when the prediction only initializes SCF, whose first build turns the right into (Appendix § 16), but not when the prediction is diagonalized once and used directly, the setting we focus on.
What existing losses see. Figure 1e applies these results to the losses of § 2, and Table 3 in Appendix § 12 lists how each loss weights the sectors. The element-wise loss and the full WALoss penalize every sector, but uniformly: a small coupling between two frontier orbitals, which shifts the gap at second order with weight (Appendix § 12), costs as much as an equally large coupling between two deep core orbitals, which barely affects the properties of interest. The diagonal-only WALoss responds only to the diagonal and only to first order. Because off-diagonal entries also shift the orbital energies at second order, it can be lowered while the true orbital energies stay wrong, and increasing its weight indeed makes the gap worse (§ 4.4). Density matching uses the exact eigenpairs and focuses on the frontier, but is blind to the sectors of Proposition 3.2.
Table 3. Which sectors of the error each loss responds to (first order), how it weights them, and whether it uses the eigenpairs of the prediction. The element-wise loss is uniform up to the overlap metric (Lemma B.1).
Desiderata. A loss that reliably improves eigen-properties should therefore (i) respond to every sector, so that no error goes unpenalized; (ii) weight the sectors by their effect on the quantities of interest, so that model capacity is spent where it matters; and (iii) use the exact eigenpairs of rather than a first-order proxy. No existing loss meets all three requirements. We now construct one that does.
From the density to the cumulative LDOS
The density is blind to orbital energies because it sums the occupied orbitals and discards their energies, as Equation (2) shows. Keeping the energy of each orbital gives the local density of states (LDOS), , where is an energy coordinate and is the Dirac delta, placing a peak at each orbital energy . The LDOS describes how the electrons at point are distributed in energy and is measured directly by scanning tunnelling microscopy [23]. We use its cumulative form, with each peak smoothed by a Gaussian of width , so that each step becomes an error-function step:
where is the standard normal cumulative distribution function and is a smoothing width. is the number of electrons per spin at with energy below . As a function of , it is a smoothed staircase with one step per orbital: the step sits at the orbital energy , and its height is the orbital density at that point Figure 9b in the appendix. An error in an orbital energy moves a step (A). An error in an orbital shape changes step heights, whether it mixes occupied with virtual orbitals (B) or orbitals within the occupied or the virtual space (C); Figure 1f shows an example of A and one of C.

Figure 9. Spectral reference quantities for molecule #23470. (a) Generalized eigenvalues with the loss window shaded; the energy axis is broken so that the nine core levels are visible. (b) Cumulative LDOS of Equation (7) at five of the 256 sample points, spanning three orders of magnitude in local density. (c) Proposition B.4 tested pointwise: against at all 256 sample points. (d) The two energy profiles at one sample point, with the constant contribution of the levels below the window removed and each curve normalized by its own maximum. Ticks mark the orbital energies.
The staircase is what a scanning tunnelling microscope traces as its bias voltage is swept. With the tip held above a point , the tunnelling current at bias counts the states between the Fermi level and , so it is proportional to [23, 19].2 Each time the bias crosses an orbital energy, the current changes by one step, whose height is that orbital’s density at the tip. The density is one value of , its level at the Fermi energy. The cumulative LDOS loss also compares how changes across the energy window, which is what the bias sweep traces, at many points , much as one would compare two samples by sweeping the bias at many tip positions.
Where the density matrix, and with it the density, keeps only the occupied subspace, keeps the energy and the spatial density of every orbital, occupied and virtual: the positions and heights of its steps. These are enough to rebuild the Hamiltonian, , so the map discards nothing (Theorem 3.5(iii)). At an energy inside the HOMO–LUMO gap, every occupied step is complete and no virtual step has begun, so that slice of is the density, up to exponentially small tails (Theorem 3.5(i)). is a single function of the predicted eigenpairs, not a sum of terms for the three sectors: the sectors are only the lens through which Section 3.3 shows that it responds to every part of the error.
Definition 3.4 (Cumulative LDOS loss). Let be a set of sample points, an energy grid on the window around the reference Fermi level , and divide the factor in (4). The cumulative LDOS loss is
where is computed from the exact eigenpairs of and gradients are propagated through the eigensolver.
FermiScope trains with , where is the element-wise loss of Section 2 and the weight balances the scales of the two terms, selected on the validation split (Table 15); on QHNet, the results change little over a tenfold range of (§ 4.4). Two variants serve as ablations: replacing the step by a Gaussian peak gives a peak-shaped LDOS loss , and a single grid point at recovers density matching (Theorem 3.5(ii)).
| QHNet | SPHNet / WANet | |
| optimizer | AdamW, | native |
| learning rate | ||
| warm-up steps | 1,000 | native |
| fine-tuning steps | 30,000 | 30,000 |
| batch size | 32 | 64 |
| gradient clipping | norm 5.0 | norm 5.0 |
| molecules per auxiliary step | 8 | 8 |
| energy grid | , Ha | , Ha |
| cumulative LDOS weight | 30 (stable-id), 100 (other splits) | 450 |
| WALoss weight | 0.1 | 0.05 |
Table 15. Fine-tuning settings. Every method of a given backbone shares all settings except the auxiliary loss and its weight; unlisted settings follow each backbone’s released training recipe (“native”). The cumulative LDOS weight is selected on the validation split; Table 9 reports its test-set sensitivity on QHNet.
Theoretical properties
Theorem 3.5 (Properties of the cumulative LDOS). Let the reference orbital energies be non-degenerate, as in Proposition 3.1, let be the reference HOMO–LUMO gap, and let be any open energy interval for equal to the loss window. Then:
(i) Density matching is a special case. If no orbital energy lies within of , then up to per orbital, so is the slice of .
(ii) No blind sector. The first-order response of on to is injective: every energy error (sector A) and every off-diagonal entry (sectors B and C) changes .
(iii) Identifiability. on if and only if .
(iv) Non-saturating gradient. If one orbital energy is displaced by with its shape fixed, the gradient of the cumulative mismatch with respect to is proportional to , the Gauss error function3, which saturates at as $\lvert\delta\rvert * grows. In contrast, the gradient of the peak-shaped mismatch is proportional to* , which vanishes for large displacements. Concretely, at the cumulative gradient has reached of its asymptotic value while the peak gradient has fallen to , a factor of 13 apart, and the ratio grows without bound as $\lvert\delta\rvert * increases.*
Appendix B proves each part (Propositions B.4 and B.6, Theorem B.5) for any linearly independent basis of Gaussian-type orbitals, and Appendix H checks every part numerically on QH9 molecules.
Figure 2 shows why (ii) holds and why the density fails it. To first order, an energy error adds a bump to at its level, and a coupling adds a plateau between and , shaped in space like . Steps and bumps at different energies are linearly independent functions of , and different orbitals are linearly independent functions of , so no combination of errors can cancel. The density reads only the slice . Bumps never reach it, and a plateau crosses it only if one of its two orbitals is occupied and the other virtual: this is Proposition 3.2 seen through .
Implications. By (i), which holds at every energy inside the gap and hence at the two grid energies next to , the cumulative loss keeps everything that density matching sees, including its automatic focus on the frontier orbitals (Proposition 3.1c); the other energies add the orbital-energy information that the density lacks. By (ii) and (iii), all three sectors are visible, and on the loss window determines the Hamiltonian, so it cannot be matched by trading one kind of error for another, as the diagonal-only WALoss can. Pairs of orbitals that both lie far outside the window, such as two core orbitals or two high virtual orbitals, enter only through the Gaussian tails of their energy profiles; they barely affect ground-state properties and remain supervised by the element-wise term. The loss therefore concentrates on the valence and low virtual orbitals, the part of the spectrum that governs chemistry. Together, these properties meet the three desiderata of Sec. 3.1, and (iv) makes training robust: unlike a peak-shaped loss, the cumulative loss keeps pulling an orbital energy toward its target once the error exceeds a few , because it compares the local spectra through their cumulative distributions, as a transport distance does, rather than through the overlap of peaks (Proposition B.6 in Appendix § 12).
Finally, because most degrees of freedom of lie in sectors that barely affect the target properties, a model can lower by moving error out of the sensitive sectors rather than by enlarging it, so the element-wise error need rise only slightly (Proposition B.7 in Appendix § 12).
Experiments
Setup
Datasets. QH9 (Yu et al., [26]) provides B3LYP/def2-SVP Hamiltonians for QM9 molecules (Ramakrishnan et al., [17]) with up to nine heavy atoms. We use its four official splits: stable-id is a random split, stable-ood tests on larger molecules, dynamic-geo on unseen geometries of training molecules and dynamic-mol on unseen molecules. Appendix § 13 gives sizes and statistics.
Backbones. We fine-tune three pretrained Hamiltonian networks that span the development of the field: QHNet (Yu et al., [27]), the original QH9 baseline, and WANet (Li et al., [14]) and SPHNet (Luo et al., [15]), which make equivariant message passing cheaper through SO(2) convolutions and adaptive sparsity.
Baselines and protocol. We compare with WALoss (Li et al., [14]), the state-of-the-art physics-informed loss for Hamiltonian prediction, in its full form. For each backbone, every method fine-tunes the same pretrained checkpoint for 30k steps with the same optimizer, learning-rate schedule, batch size and data. Only the auxiliary loss and its weight differ, and all methods are evaluated with the same code. Appendix § 20 lists all hyper-parameters.
Training objective and cost. We apply when fine-tuning a pretrained model. At each step it is evaluated on eight molecules of the batch, at 256 sample points per molecule drawn once from the PySCF quadrature grid (Sun et al., [21]), whose atomic-orbital values are cached, and on energies on Ha with Ha, covering the valence occupied orbitals, the LUMO and the low virtual orbitals. The eigenpairs of are computed in double precision, with gradients through the eigensolver (Appendix § 16). On QHNet the loss adds about 5% to the cost of pretraining, and it costs nothing at inference (Appendix § 17.§ 6).
Metrics. Following QH9, we report the MAE of over all entries (), over same-atom blocks (diag) and over the remaining blocks (non-diag). We also report the MAE of the HOMO and LUMO energies, of the gap and of all occupied orbital energies (), and the cosine similarity of the occupied orbital coefficients. Energies are in Ha and in % (Appendix § 15).
Main results
Table 1 reports results on the QH9-stable-id test set. On QHNet, SPHNet and WANet, the cumulative LDOS loss gives the best orbital energies and orbital coefficients. It reduces the HOMO–LUMO gap error by 79% on QHNet, 49% on SPHNet and 53% on WANet, and the LUMO error by 56–84%; its gap error is 1.6–2.9 times lower than that of WALoss. These gains come without a cost in element-wise accuracy: the Hamiltonian MAE stays within 0.3% of the pretrained value on SPHNet and WANet, and on QHNet it falls by 3.5%, making our loss the best in every downstream column. WALoss improves the gap by 19–39% but raises the Hamiltonian MAE on all three backbones (by 0.6–2.3%), consistent with the trade-off that Li et al. [14] reported on QH9.
This pattern follows from the analysis of § 3.1. WALoss weights all entries of equally, so much of its effect goes to the large sectors that barely influence the spectrum, and its spectral gains come at the expense of element-wise accuracy. The cumulative LDOS loss concentrates on the sectors that control the frontier spectrum, and the model can satisfy it by moving error out of these sectors at little cost in total error (Proposition B.7 in Appendix § 12).
Generalization across splits
Figure 3 applies the same protocol to the three shifted splits; Table 6 in Appendix § 17.§ 1 lists all metrics. The gains persist under distribution shift. Across all four splits, the cumulative LDOS loss lowers the gap error of every model, by 36–77% on the shifted splits, and never raises the element-wise error by more than 0.3%, whereas WALoss moves both errors in either direction and increases the gap error on all three shifted splits of QHNet. On dynamic-mol, where the pretrained QHNet is least accurate, our loss lowers its gap error by 77% and raises its orbital similarity from 79.7% to 90.6%. Predicted Hamiltonians are also used to initialize DFT; starting SCF from them saves about a third of the iterations relative to the standard minao guess (Appendix § 17.§ 5).

Figure 3. Reduction of the HOMO–LUMO gap error relative to each pretrained model on the three shifted QH9 splits (higher is better; negative values mean that the error grew). The cumulative LDOS loss (ours, trained as ) lowers the gap error on every backbone and split, and it also improves every other downstream metric; Table 6 in Appendix § 17.§ 1 lists all metrics.
Ablation studies
Energy resolution. The ablation rows of Table 1 isolate the first design choice of the loss, the energy resolution; the second, step versus peak, is in Appendix § 17.§ 4. Density matching alone already lowers the gap error by 35–78%, which confirms the value of its automatic focus on the frontier (Proposition 3.1c). Adding energy resolution helps most where the density is blind to the remaining error: on WANet the gap error falls from 1101 to 791 Ha, and on SPHNet from 970 to 789 Ha. On QHNet, where density matching already captures most of the gap improvement, energy resolution removes its element-wise cost ( from 76.82 to 74.81 Ha) and further lowers the LUMO and occupied-orbital errors.
Weight sensitivity. On QHNet, the gap error of the cumulative loss stays between 1811 and 2231 Ha as varies tenfold, whereas the diagonal-only form of WALoss, which sees orbital energies only to first order, degrades as its weight grows (Appendix § 17.§ 3).
Related Work
Hamiltonian prediction. SchNOrb [18] and PhiSNet [24] predict molecular Hamiltonians and wavefunctions, and DeepH (Li et al., 2022) targets materials. QHNet [27] introduced an efficient equivariant architecture, and QH9 [26] established the benchmark used here. WANet [14] and SPHNet [15] improve accuracy and scalability through convolutions and adaptive sparsity. All of them are trained with element-wise losses; our loss applies to each of them without modification.
Physics-informed and spectral objectives. Gu et al. (2022) regress eigenvalues directly, which requires differentiating through an eigensolver at every step, supervises the energies but not the orbitals, and was found hard to optimize on large systems [14]. WALoss [14] avoids the eigensolver by evaluating in the reference orbital basis. Lemma B.1 shows that its full form is the element-wise error measured in an orthonormal basis, and its perturbation theorem bounds eigenvalue errors by that error. Our analysis refines this bound into a map of which entries matter for which property, and explains the trade-off between matrix error and properties that Li et al. (2025) observed on QH9. Self-consistency training [28] rebuilds a Hamiltonian from the predicted density through the exchange–correlation functional and matches it to the prediction on unlabeled molecules; it enforces the SCF fixed point rather than the spectrum and is complementary to our loss.
Electron density and LDOS in machine learning. DeepDFT [7], ChargE3Net [12] and LAGNet [25] predict the electron density as an output; LAGNet introduced the sampling grid and core suppression that we use. Ellis et al. (2021) predict the LDOS itself as the target of a finite-temperature DFT surrogate for materials. We use the LDOS as a training signal for a predicted Hamiltonian and show why its cumulative form is the one to optimize.
Conclusion
The element-wise error of a predicted Kohn–Sham Hamiltonian is a poor guide to its eigen-properties, because each property depends on a specific part of the error. Representing the error in the reference orbital basis makes this dependence explicit and shows what existing physics-informed losses miss. The cumulative LDOS represents the Hamiltonian in the language of the density without losing the orbital energies: it sees every part of the error, weights it by its effect on the spectrum, and determines the Hamiltonian uniquely. As the drop-in training signal of FermiScope, it reduces the HOMO–LUMO gap error by 49–79% on three architectures, maintains these gains under distribution shift, and leaves the element-wise accuracy intact. Appendix § 19 discusses limitations and future work.
AI Use Statement
In this work, we used generative AI tools to implement methods: AI coding assistants helped write parts of the software implementation, including experiment orchestration scripts and figure-generation code. We have not used generative AI tools to generate synthetic data sets, help develop theoretical models or conceptual frameworks, formulate mathematical claims, provide critical ingredients for proving mathematical claims, propose or refine hypotheses, design or provide feedback on research methodology or experiments, assist with translation, clean and reformat the dataset, support qualitative and thematic data analysis, or interpret results. All mathematical proofs were written by the authors; generative AI tools were subsequently used to polish the exposition, and numerical scripts were used to verify the correctness of every closed-form expression (see Appendix § 18). Additionally, we used generative AI tools to identify and summarize relevant literature during the related-work survey and to edit the paper to improve readability after the authors had written the full draft. We have reviewed all AI-assisted work. AI-generated code was tested for correctness and verified against quantum-chemical reference calculations by the authors. Literature identified by AI was verified through manual inspection of the original sources. All experiments were designed and executed by the authors, and all reported numbers were checked against the DFT reference data. We take responsibility for the final content of this work, including text, claims, and artifacts produced with the aid of generative AI.
Reproducibility Statement
All code for computing the proposed losses, the cached quadrature grids, and the evaluation scripts are provided in the supplementary material. Appendix J lists the fine-tuning settings and the evaluation protocol, and the README of the supplementary code gives the training commands with these settings. Complete proofs of the theoretical results appear in Appendix B, and Appendix H reports numerical checks of every analytical statement against reference data. The three backbone architectures we build on, QHNet, SPHNet and WANet, are publicly available together with the QH9 dataset and its published splits.
Ethics Statement
This work develops auxiliary training objectives for neural-network models of molecular Kohn–Sham Hamiltonians. The research uses only publicly available quantum-chemical datasets (QH9) and involves no human subjects, private data, or dual-use applications. We are not aware of any direct negative societal impact; by improving the physical accuracy of predicted Hamiltonians without requiring additional data or architectural changes, the method may help reduce the computational cost of molecular simulations.
Acknowledgments
This work was partially supported by NSF 2303037, NSF 2312501, NSF 2531008, SRC JUMP 2.0 Center, CDSC Industry Partners, Amazon Research Awards, Snapchat, and Google Gifts.
Kohn–Sham DFT in Brief
This section collects the quantum-chemistry background assumed in the main text: a glossary of terms (Table 2), and the self-consistent-field procedure and its cost (Figure 4).
| term | meaning |
| atomic number | Number of protons of a nucleus; it identifies the element (H 1, C 6, N 7, O 8, F 9). |
| basis set, basis function, atomic orbital | A fixed set of functions centred on the atoms, in which the molecular orbitals are expanded; each function is called an atomic orbital. |
| def2-SVP | A standard Gaussian basis set of split-valence quality with polarization functions; it gives 5 functions per H atom and 14 per C, N, O or F atom. |
| molecular orbital | A one-electron wavefunction of the molecule, a linear combination of basis functions; is the probability density of an electron in that orbital. |
| Kohn–Sham DFT | Density functional theory in which the interacting electrons are replaced by non-interacting electrons in an effective potential that depends on the electron density. |
| exchange–correlation functional, B3LYP | The approximate part of the effective potential that accounts for many-electron effects; B3LYP is a widely used hybrid functional, which mixes in exact exchange. |
| level of theory | The functional and basis set of a calculation, here B3LYP/def2-SVP. |
| Kohn–Sham matrix H | The matrix of the Kohn–Sham operator in the basis, also called the Hamiltonian or Fock matrix. |
| overlap matrix S | The inner products of the basis functions; it differs from the identity because the basis functions are not orthogonal. |
| generalized eigenvalue problem | ; its eigenvalues are the orbital energies and its eigenvectors the orbital coefficients. |
| self-consistent field (SCF) | The iteration that makes the Hamiltonian and the density consistent with each other (Figure 4). |
| initial guess (minao, core) | The starting point of SCF: minao superposes atomic densities in a minimal basis; the core guess ignores the interaction between electrons. |
| DIIS | The standard extrapolation scheme that accelerates SCF convergence [16]. |
| closed shell | Every occupied orbital holds two electrons of opposite spin, so . |
| occupied, virtual orbitals | The lowest orbitals hold the electrons; the others, called virtual or unoccupied, are empty. |
| HOMO, LUMO, gap | The highest occupied and lowest unoccupied molecular orbitals, and the difference of their energies, a common indicator of reactivity and optical excitation. |
| frontier orbitals | The orbitals closest in energy to the HOMO–LUMO gap. |
| core orbitals | The deep 1s orbitals of the heavy atoms, far below the valence orbitals. |
| Fermi level | Here, the energy midway between the HOMO and the LUMO; the orbitals below it are occupied. |
| electron density | The expected number of electrons per unit volume at . |
| density matrix P | , the matrix that gives the density through . |
| local density of states (LDOS) | The density at resolved by orbital energy; it is measured by scanning tunnelling microscopy. |
| units | Hartree (Ha), the atomic unit of energy: 1 Ha = 27.211 eV, 1 Ha = Ha, 1 kcal/mol = 1.594 mHa. |
Table 2. Quantum-chemistry terms used in this paper.
Glossary. Table 2 defines the quantum-chemistry terms used in the paper.
The SCF procedure and its cost. The Kohn–Sham operator depends on the occupied orbitals through their density matrix, and the density matrix is computed from the eigenvectors of its matrix. DFT resolves this circularity by iteration (Figure 4a). Starting from an initial guess of the density matrix, each iteration builds the Kohn–Sham matrix from the current density matrix, solves the generalized eigenvalue problem, Equation (1), occupies the lowest orbitals and forms a new density matrix by Equation (2), until the input and output density matrices agree. Building the matrix requires the Coulomb and, for hybrid functionals such as B3LYP, the exact-exchange contributions, formally in the number of basis functions, together with a numerical quadrature of the exchange–correlation potential; the diagonalization costs . A calculation with iterations costs times one iteration. On 50 QH9-stable-ood test molecules, PySCF with its default settings (B3LYP/def2-SVP, DIIS ([16]) converges in a median of iterations (range 8–10) from its default minao guess and in 17 from the core-Hamiltonian guess, taking a median of about 9 s per molecule on a CPU node. A Hamiltonian network replaces the whole loop (Figure 4b): one forward pass predicts the entries of , and one diagonalization gives every downstream quantity. On the same molecules, the QHNet forward pass on a GPU and the eigensolve take a median of 0.1 s together. Used instead as an initial guess, the prediction saves about a third of the SCF iterations (Appendix § 17.§ 5). The loss proposed in this paper changes only training; inference is that of the backbone.
Proofs and Additional Theory
Throughout, denotes the density matrix, so that with ; hats denote the same quantities computed from . We write for the reference HOMO–LUMO gap and for the functions representable in the basis, which contains every predicted and reference orbital. Gaussian-type basis functions are real-analytic on and linearly independent, so every nonzero is a nonzero real-analytic function. Two consequences are used below: a nonzero does not vanish identically on any nonempty open set, and if satisfy on , then or (if , vanishes on the dense open set where , hence everywhere).
The error in the orbital basis
Whitening a matrix means expressing it in an orthonormal basis of the span of the atomic orbitals, (Löwdin orthogonalization). The error of Equation (5) is the whitened error rotated into the reference eigenbasis, which gives the following identities.
Lemma B.1 (Whitening). . Moreover , so the full WALoss of Li et al. [14], an average of the absolute or squared entries of this matrix, weights every entry of alike (its mean-squared form is ), and the diagonal-only form equals .
Proof. Write with orthogonal (from ). Then , and the Frobenius norm is orthogonally invariant. The bound follows from submultiplicativity and . The identity is Equation (5), because by Equation (1), and the diagonal of is .
The inequality is the core of the perturbation theorem of Li et al. [14]. On QH9 it is loose: Appendix § 14.§ 4 measures a median amplification of 3.0 against a median bound of 1878, so the location of the error, rather than its size, is what determines its effect. Table 3 applies Propositions 3.1 and 3.2 to the losses of § 2; Figure 1e shows the same comparison.
Perturbation theory for each property
Besides Proposition 3.1, the main text uses two second-order facts.
Proposition B.2 (Second-order corrections). Under the assumptions of Proposition 3.1:
(d) ;
(e) the Kohn–Sham total energy is stationary in at the ground state, so its error is second order in and has no first-order dependence on any sector.
Item (d) is the channel through which off-diagonal errors reach the orbital energies: a coupling between two orbitals close in energy shifts both with weight , which is largest across the HOMO–LUMO gap. It is also why a loss that sees only the diagonal, and only to first order, such as the diagonal-only WALoss, can be lowered while the true orbital energies stay wrong. Item (e) explains why total-energy errors are a late indicator of the problem [14]: the energy is the least sensitive probe of the occupied subspace and the density the most sensitive one.
Remark B.3 (What the sectors mean for the metrics). To first order, the gap error is , two entries of sector A out of ; the orbital coefficients, and with them the similarity , depend on sectors B and C; and the density depends on sector B alone. The weights in (b) and (c) are inverse orbital-energy differences. On QH9, the HOMO and LUMO are about 0.25 Ha apart and the deepest core orbital lies about 19 Ha below the LUMO (Table 5), so an error coupling the two frontier orbitals changes the LUMO about 75 times more than an equally large error coupling it to the deepest core orbital (median over QH9; 5–95% range 51–109). Item (c) is the first-order form of the Davis–Kahan theorem [3]: the occupied subspace, and with it the density, is rotated only by sector B, with a strength set by the gap (Appendix § 12).
Proof of Propositions 3.1 and B.2. (a), (b) and (d) are Rayleigh–Schrödinger perturbation theory for the pencil after whitening [9, 20]. For (c), ; inserting (b) and pairing the terms and with gives by symmetry of , which leaves
and (6). Part (c) does not need the non-degeneracy assumption. is the spectral projector of the pencil onto its lowest eigenvalues, which is analytic in while [9]; expanding its resolvent integral to first order gives entries between occupied and virtual orbitals and zero elsewhere, whether or not levels within or within coincide. The pairwise cancellation above is the same computation for non-degenerate levels. Beyond first order, the sin theorem of Davis & Kahan (1970) gives the same picture. In the reference orbital basis, the predicted orbitals are the eigenvectors of , and the occupied reference subspace leaves a residual whose only nonzero block is ; if , the canonical angles between the occupied subspaces of the reference and the prediction, which measure how far the occupied subspace, and with it and , has moved, therefore satisfy [20]. (e) is the variational principle for the Kohn–Sham energy with respect to occupied–virtual rotations.
Proof of Proposition 3.2. If then is block diagonal in , so is an -invariant subspace of ; if no eigenvalue crosses the gap it is the occupied subspace of , and because depends only on the subspace. The dimension count is that of symmetric matrices on and on .
Remark (directions versus norm). Proposition 3.2 counts directions, not norm: at the QH9 median, 69% of the parameters of lie in the two blind sectors (Table 5), and this is the room that density matching leaves unpenalized. How much of an actual residual sits in that room is a separate, empirical question. For the physically realized Hamiltonian ensemble discussed in Appendix D.4, the blind sectors carry 15.6% of at a displacement of 0.02 Å and 30.3% at 0.30 Å, almost all of the growth in the virtual–virtual block that contains the LUMO energy error. The blind share is therefore smaller in norm than in dimension, but it contains every orbital-energy error and grows under distribution shift.
Properties of the cumulative LDOS loss
Theorem 3.5 collects the following results.
Proposition B.4 (Fermi-level identity; Theorem 3.5(i)). Let be the orbitals of or of , and let the energy lie between their HOMO and LUMO energies at a distance of at least from both. Then, at every point , : each orbital deviates by at most a fraction of its density. At and for the reference, , and the fraction is for and .
Proof. By (2), . Every bracket and every in this expression is at most , and the two sums have opposite signs, so the total is bounded by the larger of them.
The identity holds at every energy inside the gap, not only at . This matters for the training grid: with points on , is not a grid point but lies midway between the points . With , both are density slices up to per orbital at the median QH9 gap and at its 5th percentile, so the loss contains density matching through these two slices (Table 14). Orbitals far below the window contribute a constant step equal to their density, so nothing that density matching sees is lost; the other grid points add how that density is distributed in energy.
Theorem B.5 (No blind sector and identifiability; Theorem 3.5(ii, iii)). Let the reference orbital energies be non-degenerate, and let be an open energy interval, for example the loss window. Write for the standard normal density, and . Then
(i) the first-order response is injective on symmetric : energy errors enter through the step positions with weight , and every off-diagonal , including the occupied–occupied and virtual–virtual entries invisible to , enters through the step heights with the -profile , a smoothed indicator of the interval between and ;
(ii) on if and only if , and then and for every .
By contrast, vanishes on the blind set of Proposition 3.2, and the diagonal-only WALoss vanishes whenever for every with .
Proof. We use one fact about the energy profiles. (F) For distinct , the functions and are linearly independent on . All of them extend to entire functions of , so a combination that vanishes on vanishes on . Differentiating it and multiplying by gives , and exponential polynomials with distinct exponents vanish only if every polynomial coefficient does, so for all .
(i) By Proposition 3.1(a,b), the first-order change of (7) is
Collecting the terms and gives , the step-height profile of the statement. If on , then (F), applied at each , gives and on for every . Since , the product property of gives and ; linear independence of the then gives for all . Hence .
(ii) For a Hamiltonian with eigenpairs , group (7) by distinct eigenvalues,
If on , (F) applied to the union of the two spectra gives on for every . For an eigenvalue of , is a sum of squares of nonzero functions in , so it is not identically zero and is an eigenvalue of ; the converse holds likewise. has distinct eigenvalues and has eigenvalues counted with multiplicity, so every eigenvalue of is simple and . Then , that is, on , so and . Finally, Equation (1) gives for either Hamiltonian, and the signs cancel, so ; the converse is immediate. The statements about and the diagonal-only WALoss are Proposition 3.2 and Lemma B.1.
The theorem concerns the representation over all of space; the loss is its sample estimate at 256 points and energies per molecule (§ 4.1). It needs nothing of the basis beyond linear independence and the analyticity of Gaussian-type functions. We state it on all of space rather than on a finite point set because the natural finite-sample condition, linear independence of the products on the points, fails in def2-SVP: on an atom with two shells of radial parts , , identically. Because may be any interval, the theorem applies to the loss window, but orbital pairs far outside the window enter only through the Gaussian tails of their profiles, which is the energy-window weighting of Table 3. Table 14 checks both statements on QH9 molecules. On the level-0 quadrature grid, the first-order response is injective over the full energy range, and on the loss window it resolves every direction that involves an orbital inside the window, although some only weakly. The theorem does not carry over to the 256 points sampled per molecule: there, some directions on the loss window remain unresolved, mostly couplings between occupied orbitals and virtual orbitals above the window, whose energy profiles are nearly constant over the window, and less than 1% of their weight lies on pairs of orbitals inside the window. The element-wise term supervises these directions, and a denser sample resolves them.
| statement | what is checked | result | reference |
| generalized eigenbasis | – | ||
| cache consistency | recomputed vs. released | App. C | |
| cache consistency | vs. | App. C | |
| Prop. B.4 | vs. , all 256 points | rel. (float32 cache) | Figure 9c |
| Prop. B.6 | closed forms , vs. quadrature | rel. | Figure 12b |
| energy-only perturbation | induced | 2.000 mHa (exact) | Figure 12a |
| energy-only perturbation | eigenvector overlap deviation | Figure 12a | |
| shape-only perturbation | Ha | Figure 12a | |
| Prop. 3.2 | response to a 2 mHa energy shift | – (machine zero) | Figure 12a |
| Prop. 3.1(c) | response to a 0.05 rad rotation | Figure 12a | |
| Gaussian saturation | at , , rel. to its peak | , | Figure 12c |
| Prop. 3.1(a,b), first-order | exact minus first-order change, perturbation scale , , | rel. error () | Thm. B.5(i) |
| Prop. 3.1(c), degenerate levels | same for , two occupied and two virtual levels degenerate | rel. error () | App. B |
| Prop. B.4 at the grid energies Ha | on the grid; ratio to the bound | ; | App. B |
| Thm. B.5(i), full energy range | smallest relative singular value of the first-order response | , no null direction | App. B |
| Thm. B.5(i), loss window () | directions with an orbital inside the window / with both outside | all resolved, /below round-off | App. B |
| Thm. B.5(ii), recovery | max orbital-energy error after minimizing (or ), three random starts | 0.03 mHa (: 10 mHa) | App. B |
| Davis–Kahan bound | over the bound, 600 random with | App. B | |
| restoring force on the grid | , Ha, levels Ha inside | Prop. B.6 | |
| gradient of | Daleckii–Krein form vs. central differences | rel. | App. B |
| two shells on one atom | (identically zero) | App. B |
Table 14. Numerical checks. Molecule #12345 and #23470 are the two QH9-stable geometries used in the appendix figures; the lower block also uses molecule #18. “Machine zero” means the response is at or below the double-precision noise floor of the quantity being differenced.
Proposition B.6 (Non-saturating restoring force; Theorem 3.5(iv)). Displace one orbital energy by with its shape fixed. Per sample point and up to the factor , the mismatch integrated over is, for a unit-height Gaussian peak, , which saturates at with ; and, for the cumulative step, , with . As , becomes the Cramér–von Mises distance between the local spectral measures of and .
Proof. For any square-integrable , with the autocorrelation. For the unit-height Gaussian , and , giving . For the step, differentiate under the integral: , the last step being the Gaussian convolution identity evaluated in closed form; integrating from gives the stated . Both closed forms agree with numerical quadrature to machine precision (Table 14). As , , the distance between two unit point masses, and for general spectra is the Cramér–von Mises statistic between the two local spectral measures.
A peak stops pulling once it no longer overlaps its target; a step does not, as long as the displaced level stays inside the energy window (Figure 12b,Figure 12c). At Ha and an energy error of 0.1 Ha, the peak gradient has fallen to 1% of its maximum, while the cumulative gradient is at 99.96% of its limit. On a window , the part of the integral for that the window omits is bounded by over , so
The restoring force is therefore that of the proposition, up to an exponentially small error, while the displaced level is a few inside the window, and it vanishes, like the peak’s, once the level has left the window. The step is also wide in , so the coarse training grid does not alias it: on the grid, whose spacing is , the gradient stays within of for Ha and every level at least Ha inside the window (Table 14).
Error reallocation
Proposition B.7 (Error reallocation). Let be the set of errors a model can reach and a sector weighting with large entries on and . If minimizes over and minimizes , then and , both strictly unless the two objectives share a minimizer.
Proof. is feasible for the first problem, so ; is feasible for the second, so ; combining the two gives both inequalities, and equality in either forces a common minimizer.
Every eigen-derived metric is a function of the -weighted sectors, while the complementary sectors hold most of the degrees of freedom. A spectral loss can therefore lower every eigen-derived metric at the price of at most a small increase in the element-wise error. The two losses also push on differently. With , the Daleckii–Krein formula for the derivative of a spectral function [2] gives with
where for and . The divided difference is bounded by and is exponentially small unless a grid energy lies between and or within a few of them. The gradient of is thus concentrated on close and frontier pairs of predicted orbitals inside the window, whereas the gradient of the mean-absolute element-wise loss, , weights every entry of alike. Read in reverse, the proposition also explains why continuing to minimize the element-wise loss alone on a converged model can move error into the sensitive sectors (Appendix G.2).
The QH9 Datasets and Splits
Provenance and quantum-chemical settings
Every experiment in this paper uses QH9 (Yu et al., [26]), which supplies converged Kohn–Sham Hamiltonians for QM9 (Ramakrishnan et al., [17]) molecules. The reference calculations are B3LYP with the def2-SVP basis, carried out in PySCF (Sun et al., [21]); each record stores the converged Fock matrix in the atomic-orbital basis together with the overlap matrix , the nuclear charges and the geometry. Because is the converged operator, the label is a fixed point of the self-consistency map and not a single SCF iterate, so a model that reproduces it reproduces the entire converged electronic structure of that geometry.
Two families are released. QH9-stable holds one equilibrium geometry for each of 130,831 molecules. QH9-dynamic holds ab initio molecular-dynamics trajectories; we use the 100k release, which is 999 molecules sampled at 100 geometries each, 99,900 records in total. The dynamic family is the harder of the two: consecutive frames of a trajectory visit distorted, off-equilibrium geometries whose Hamiltonians are not close to any equilibrium structure in the stable set.
The basis is small enough to state completely. In def2-SVP a hydrogen carries five atomic orbitals (, ) and each of C, N, O and F carries fourteen (, , ), so the matrix dimension is determined by the composition alone: . The two molecules used for the figures below check this exactly: molecule #12345 is with , and molecule #23470 is with .
Splits
The four splits used in this paper are given in Table 4. They probe different kinds of generalization, which matters for the interpretation of Table 6: stable-id is an interpolation test, stable-ood extrapolates in molecule size, dynamic-geo extrapolates to unseen geometries of molecules the model has seen, and dynamic-mol extrapolates to unseen molecules altogether. The size split is a substantial shift. Measured on a uniform 4,000-molecule sample of QH9-stable, the training side has a median of 17 atoms and , while the test side has a median of 23 atoms and , and the median gap moves from 6.43 to 8.10 eV: the test molecules are systematically larger, and have wider HOMO–LUMO gaps, than the training molecules.
| split | selection rule | train | val | test | tests |
| stable-id | random 80/10/10 | 104,664 | 13,083 | 13,084 | interpolation |
| stable-ood | / 21–22 / atoms | 104,001 | 17,495 | 9,335 | molecule size |
| dynamic-geo | geometries within a molecule | 79,920 | 9,990 | 9,990 | unseen geometry |
| dynamic-mol | disjoint molecules | 79,900 | 9,900 | 10,100 | unseen molecule |
Table 4. The four QH9 splits. Sizes are the exact record counts read from the released split masks. The size split thresholds are on the total atom count, hydrogens included; the random split uses a fixed permutation with seed 43.
Composition, spectra, and the size of the blind subspace
Table 5 and Figure 5 summarize the sample. Two entries matter for the rest of the paper. First, the occupied fraction is small: the median molecule has occupied orbitals out of basis functions, so . Second, the dimension count of Proposition 3.2 is therefore severe. A symmetric residual has free parameters, of which lie in the occupied–occupied and virtual–virtual blocks that the density cannot resolve. At the QH9 median that is a fraction of 0.690, and the 5–95% range across the sample is [0.661, 0.709]: roughly seven of every ten directions in which a predicted Hamiltonian can be wrong are directions in which density matching is exactly blind, and this holds for every molecule in the sample.

Figure 5. QH9-stable statistics from a uniform 4,000-molecule sample. (a) Basis size. (b) Number of occupied orbitals. (c) Reference HOMO–LUMO gap. (d) Exact partition of the parameters of a symmetric residual into the three sectors of Proposition 3.1, at fixed , as a function of the occupied fraction . Only the occupied–virtual slice changes the density; at the QH9 median occupied fraction it accounts for 31% of the parameters, and the remaining 69% is invisible to .
The spectra are also wide. The median molecule has its lowest eigenvalue at −19.1 Ha and its highest at +3.7 Ha, while the quantities we care about live in a window of order 1 Ha around the Fermi level. Nine deep core levels of molecule #23470 sit below the loss window and thirty-two levels lie inside it; the cumulative form is defined so that the levels below the window contribute a constant step and drop out of any difference (Appendix § 20).
A gallery
Figure 6 shows the reference density of twelve molecules drawn at even spacing through the QH9-stable index range, on a common length scale. The sample is chemically diverse: saturated and conjugated skeletons, three- to six-membered rings, one to three heteroatoms, planar and strongly non-planar geometries, from 100 to 191 and reference gaps from 0.14 to 0.30 Ha. A single auxiliary loss with a single weight has to be useful across all of it.

Figure 6. Reference electron density for twelve QH9-stable molecules, on the best-fit plane through the nuclei, logarithmic colour scale, all panels on the same length scale and the same colour scale. Bonds are drawn from covalent-radius criteria; nuclei more than 0.7 off the plane are drawn open, so a panel with many open markers is a non-planar molecule seen in projection. Molecular formulae are in Hill notation.
The cached auxiliary quantities
The auxiliary losses need real-space and spectral quantities that the released dataset does not contain, so we precompute them once per geometry and cache them. Each cache record holds the level-0 atom-centred radial–Lebedev quadrature grid of PySCF (14,112 points for molecule #23470) with its weights, the reference density on that grid, the geometry-only core-suppression factor div, the fixed random subset of 256 sample points, and the atomic-orbital values at those points. Caching the orbital values is what makes the loss cheap: evaluating during training costs one eigendecomposition and two small matrix products, with no basis-function evaluation in the training loop.
Two checks confirm the cache is consistent with the released labels. Rebuilding the def2-SVP molecule from the stored geometry and recomputing the overlap integrals reproduces the released to , and integrating the cached density against the cached weights gives 59.978 electrons for a molecule with , the expected accuracy of a level-0 grid.
Visualizing the Reference Data
This section shows what the objects in Sections 2 and 3 actually look like. Everything plotted here is reference DFT data: no learned model enters any panel. The purpose is to make the structural claims of the sector analysis concrete, and to make the scale of the quantities the losses compare explicit.
The Hamiltonian and overlap matrices
Figure 7 shows the two matrices for molecule #12345. Three features shape the metrics reported throughout the paper. The dynamic range is large: Ha, carried by the core diagonal, against a median magnitude three orders of magnitude smaller. The matrices are strongly local: the median is Ha for basis functions on the same atom, Ha for atoms 4–6 apart, and Ha beyond 9 . And the same-atom blocks dominate, which is why the diagonal-block MAE is roughly twice the off-diagonal-block MAE in every table in this paper; the split into “diag” and “non-diag” columns is a split by magnitude as much as by position.

Figure 7. Anatomy of a reference Kohn–Sham Hamiltonian, molecule #12345 (CHO, , ). (a) and (b) on a logarithmic colour scale; thin white rules mark heavy-atom block boundaries. Entries below are shown at the floor of the scale. (c) Magnitude of the Hamiltonian elements against the distance between the atoms carrying the two basis functions, with same-atom pairs placed at zero and jittered. The orange curve is the binned median and the orange marker the same-atom median. The decay over six orders of magnitude is what local message-passing architectures exploit.
This is also why element-wise accuracy is a weak proxy for spectral accuracy. An error budget dominated by a few large core entries can be reduced substantially while leaving the frontier of the spectrum untouched, and the element-wise-only control of Appendix G.2 does exactly that.
Density, frontier orbitals, and core suppression
Figure 8 shows the real-space side for molecule #23470, a planar molecule chosen so that the frontier orbitals can be drawn without projection artefacts. Both frontier orbitals are of symmetry: their amplitude in the nuclear plane is , numerically zero, so they are sampled above it. The HOMO is the bonding combination delocalized over the ring and both substituents; the LUMO adds a nodal plane across the ring. These are the objects that the occupied–virtual sector controls, and the reason the sector matters physically: an error in mixes the two pictures and moves both the gap and the frontier shapes.

Figure 8. Real-space reference quantities for molecule #23470, 2,5-diethynyl-1H-pyrrole (CHN, , ), which is exactly planar. (a) Electron density in the nuclear plane, logarithmic scale, with the molecular skeleton overlaid and the nitrogen drawn open. (b,c) HOMO and LUMO amplitudes sampled above the nuclear plane and normalized by their own maxima; both vanish identically in the plane itself. (d) Upper envelope (99.5th percentile per radial bin) of and of the core-suppressed target against distance to the nearest nucleus; the two coincide beyond , where . (e) The 256 sampled points reproduce the radial distribution of the full 14,112-point quadrature grid. (f) Relative error of the atomic-superposition density against distance to the nearest nucleus.
Panel d explains the core-suppression factor. The reference density spans eighteen orders of magnitude, from in the tails to at the nuclei, and an unweighted squared residual would be a cusp-fitting objective. Dividing by the geometry-only factor of Ushenin et al. (2025), which reaches 148 at the nuclei and decays to exactly one beyond about , compresses the peak by a factor of 139 and leaves the valence region untouched. Panel f records how far an uninformed start is from the converged density: the atomic-superposition guess has a whole-grid NMAE of 13%, with the error concentrated in the bonding region around – where the atomic picture has nothing to say. Closing that gap is what buys the SCF savings in Table 12.
| method | SCF iterations | SCF time | total time |
| pretrained | 0.6732 | 0.8115 | 0.8619 |
| element-wise loss only (control) | 0.6735 | 0.8139 | 0.8655 |
| density only () | 0.6710 | 0.8171 | 0.8682 |
| cumulative LDOS () | 0.6713 | 0.8028 | 0.8505 |
Table 12. SCF acceleration on 50 QH9-stable-id test molecules: ratio of SCF iterations and of wall time relative to the minao initial guess (lower is better; total time includes model inference).
The spectral picture and the Fermi-level identity
Figure 9 shows the spectral side. Panel a places the energy window in context: nine core levels sit far below it, the valence occupied levels and the low virtuals lie inside, and the window width of 1.8 Ha is an order of magnitude larger than the gap it straddles. Panel b shows the cumulative LDOS at five sample points. Each curve is a staircase whose risers are the orbital weights at that point, and the curves differ by orders of magnitude between points, which is why the loss is informative: a single molecule supplies 256 independent spectral fingerprints rather than one.
Panel c is a pointwise test of Proposition B.4 on real data. Evaluating and independently at all 256 sample points agrees to a maximum relative deviation of , which is the precision of the single-precision cached orbital values rather than of the identity. The cumulative loss therefore contains density matching as its slice, and the ablation between and in the main text compares one slice with the full profile.
Panel d shows why the extra slices help. At a fixed sample point the Gaussian-peak profile is a set of isolated bumps separated by intervals where it is numerically zero; a frontier orbital whose energy is wrong by more than a few falls into one of those intervals and receives no gradient, which is the saturation of Proposition B.6 and the mechanism behind the deep-orbital drift in Table 11. The staircase has no such intervals: it is monotone in and its plateaus still record how many states lie below, so the mismatch integrated over the window grows with the displacement instead of saturating.
| loss | LUMO+2 | LUMO+1 | LUMO | HOMO | HOMO−5 | HOMO−19 | HOMO−21 | HOMO−23 |
| pretrained | 3455 | 3838 | 9593 | 1005 | 403 | 635 | 1029 | 1049 |
| peak LDOS | 2287 | 1698 | 7685 | 1053 | 593 | 5955 | 11364 | 20979 |
| cumulative LDOS | 1032 | 994 | 1567 | 690 | 235 | 195 | 251 | 367 |
Table 11. Per-orbital energy error on QHNet (1,000 test molecules, Ha) for the peak-shaped and the cumulative loss at the same weight (), window and . The peak-shaped loss corrects the virtual orbitals inside the window but lets the deep occupied orbitals drift; the cumulative loss improves every orbital.
Where a real residual lives
The sector analysis of § 3.1 is a statement about an arbitrary residual. It is worth asking where a physically realized residual actually sits, and the dynamic trajectories answer this without involving a model: taking two frames of the same molecule, is a genuine change of the converged Kohn–Sham operator caused by a geometric displacement, and is its whitened form in the eigenbasis of the reference frame. It is the kind of error a model makes when it fails to track a change of geometry, which is what the dynamic splits test. Figure 10 reports the decomposition over 640 frame pairs drawn from 214 trajectories.

Figure 10. Sector content of a physically realized Hamiltonian change, and two numerical properties of the estimator. (a) for one pair of QH9-dynamic frames of the same molecule separated by 0.30 Å RMSD, in the eigenbasis of the reference frame; red rules mark the occupied/virtual boundary at , and values are clipped to the colour range at both ends. (b) Median share of per sector against displacement, over 640 frame pairs from 214 trajectories. The virtual–virtual share, which contains the LUMO energy error and is invisible to , doubles from 15% to 30% as the displacement grows. (c) Relative standard error of the per-molecule loss estimate when of the 256 cached sample points are used, over 400 draws; solid lines are a random 75 Ha element-wise residual, dashed lines a 10 mHa LUMO shift, and the grey guide is the rate. (d) Observed amplification against the bound of Lemma B.1, same frame pairs.
Three findings matter for the argument of this paper. First, the occupied–virtual sector dominates the magnitude: it carries a median of 70–84% of while occupying only 31% of the parameters. Density matching is therefore well aimed, which is why alone already achieves a large share of the gap improvement in Table 1.
Second, the blind part is not negligible and it grows with the shift. At a displacement of 0.02 Å the two density-blind sectors hold 15.6% of ; at 0.30 Å they hold 30.3%, and essentially all of the growth is in the virtual–virtual block. That block is exactly where the frontier eigenvalue errors live: by Proposition 3.1(a) the LUMO energy error is , a virtual–virtual entry, which Proposition 3.2 shows the density cannot resolve at any weight. The virtual–virtual share therefore grows exactly where a density-only signal becomes less informative, under geometric shift, which is the setting of the dynamic splits in Table 6.
Third, the whitening bound of Lemma B.1 is loose by a wide margin on real data. The observed amplification has a median of 3.0 with a 5–95% range of [2.3, 5.2], while the bound has a median of 1878: the certificate overstates the true amplification by a median factor of 580. Such a loose bound cannot certify that a small element-wise error implies a small spectral error; the looseness reflects the conditioning of def2-SVP overlap matrices, whose condition number has a median of across QH9-stable. This is the quantitative version of the paper’s starting observation: element-wise accuracy and spectral accuracy are only weakly coupled, so the spectrum has to be supervised directly.
Metric Definitions
All reported errors are test-set means over molecules, and all energies are converted to . Let and be the predicted and reference Hamiltonians of a molecule with basis functions and occupied orbitals, and let , and , solve the generalized eigenproblems and with the reference overlap in both cases.
Element-wise errors. is the mean absolute error over all matrix entries, . The diag column restricts the average to entries whose two basis functions sit on the same atom, and non-diag to the remaining entries; the two subsets partition the matrix, and by the locality shown in Figure 7c the diagonal subset carries the larger entries. All three are invariant to any permutation of the basis, so they are comparable across code bases that order the atomic orbitals differently.
Orbital energies. HOMO, LUMO and gap are the absolute errors of , and their difference against the reference values. is the mean absolute error over all occupied orbitals, , which is dominated by the deep levels and is therefore the column in which the deep-orbital drift of the peak-shaped loss (Table 11) is visible. The per-orbital table (Table 11) reports the same quantity resolved by orbital index relative to the frontier.
Orbital shapes. is the mean cosine similarity between predicted and reference occupied orbitals, , reported as a percentage; the overlap metric is the natural inner product for the generalized problem, and the absolute value removes the sign ambiguity of an eigenvector. Values are high in absolute terms for every model, so the informative comparison is between methods within a backbone rather than against zero.
Downstream cost. The SCF columns of Table 12 are ratios against a minao initialization on the same molecules and the same convergence threshold: iteration count, SCF wall time, and total wall time including the forward pass of the model. Ratios below one are savings.
Comparisons across backbones. Each backbone is evaluated with its own code base. All comparisons in this paper are made within a backbone, between methods that share a checkpoint, a data split, an evaluation code and a step budget.
The Losses as Implemented
This section states the auxiliary terms in the form the training code evaluates them.
Whitening and eigensolve. For each selected molecule the code assembles the full predicted Hamiltonian from the model’s diagonal and off-diagonal blocks, permutes it from the backbone’s basis ordering into the PySCF ordering, and casts to float64 on the CPU. With the Cholesky factorization it forms , calls a symmetric eigensolver, and back-transforms with , so that holds to roundoff. Gradients flow through the Cholesky factorization and the eigensolver. The reference spectrum is obtained by the identical code path applied to the reference blocks, which guarantees that prediction and target are compared under the same conventions and the same precision.
Sample average and core suppression. Writing for the cached set of sample points and for the geometry-only suppression factor, the density term is
and the two energy-resolved terms replace the single residual by a mismatch averaged over the energy grid as well,
with , the standard normal distribution function, for and , the unit-height Gaussian, for . The same appears in all three terms, so the core region is suppressed identically and no term is a cusp-fitting objective. The orbital sum runs over all orbitals, not only those inside the window.
Window anchoring. The grid is with and Ha, where is the reference Fermi level. Anchoring the window to the reference rather than to the prediction is what keeps the objective from drifting: a model cannot reduce the loss by moving its own Fermi level out of the window, and the identity of Proposition B.4 at holds against a fixed target.
Batching and cost. Eight molecules per optimizer step contribute to the auxiliary term, drawn uniformly at random from the batch; the element-wise term uses the whole batch. This subsampling is the only randomness that the auxiliary term adds, and Figure 10c bounds the resulting per-molecule estimator noise. The auxiliary term has no clipping or rescaling of its own; the gradient-norm clipping of Table 15 applies to the gradient of the total loss.
SCF acceleration protocol. For Table 12 the predicted Hamiltonian of each test molecule is used to build an initial guess: we solve the generalized eigenproblem for with the reference overlap, form the density matrix from the resulting occupied orbitals, and hand it to PySCF as the starting density for an otherwise unmodified B3LYP/def2-SVP calculation with the default DIIS [16] and the default convergence threshold. The baseline is the same calculation started from minao. Reported ratios are over the same 50 molecules, and the total-time column includes the model forward pass and the eigensolve, so a ratio below one is a net saving after paying for inference.
Additional Results
All metrics on the shifted splits
Table 6 lists every metric for the shifted splits summarized in Figure 3.
Element-wise-only control
Setting. Every fine-tuning run in this paper starts from the same pretrained checkpoint and trains for 30k steps with the same optimizer, learning-rate schedule, batch size and data (Table 15); the runs differ only in the auxiliary loss. The element-wise-only run is the control that removes the auxiliary loss altogether: it continues training the pretrained model with its own element-wise loss (the mean entry-wise error between and , exactly the objective used in pretraining) for the same 30k steps, so it simply keeps minimizing the Hamiltonian MAE and nothing else. It isolates the effect of the additional training itself, so that any difference between the WALoss or cumulative-LDOS runs and this control is due to the auxiliary signal and not to the extra steps. Table 7 and Table 8 repeat the rows of Table 1 and Table 6 with this control added, for all three backbones on stable-id and for QHNet on all four splits.
| backbone | method | diag | non-diag | HOMO ↓ | LUMO ↓ | gap ↓ | ↓ | ↑ | |
| QHNet | pretrained | 77.56 | 129.25 | 73.68 | 1041 | 9445 | 9632 | 1206 | 96.28 |
| QHNet | + element-wise loss only (control) | 74.44 | 108.11 | 71.90 | 1280 | 14946 | 14769 | 868 | 95.57 |
| QHNet | + WALoss | 78.04 | 119.03 | 74.95 | 847 | 5458 | 5835 | 570 | 96.79 |
| QHNet | + cumulative LDOS (ours) | 74.81 | 109.54 | 72.19 | 678 | 1482 | 2027 | 341 | 97.91 |
| SPHNet | pretrained | 36.60 | 44.79 | 35.38 | 345 | 1309 | 1554 | 380 | 99.06 |
| SPHNet | + element-wise loss only (control) | 36.55 | 44.67 | 35.35 | 349 | 1311 | 1555 | 381 | 99.05 |
| SPHNet | + WALoss | 37.28 | 46.03 | 35.98 | 341 | 957 | 1259 | 288 | 99.17 |
| SPHNet | + cumulative LDOS (ours) | 36.64 | 44.83 | 35.42 | 292 | 572 | 789 | 137 | 99.25 |
| WANet | pretrained | 40.07 | 51.28 | 38.42 | 335 | 1454 | 1684 | 288 | 98.98 |
| WANet | + element-wise loss only (control) | 40.08 | 51.25 | 38.43 | 335 | 1603 | 1827 | 292 | 98.95 |
| WANet | + WALoss | 40.99 | 53.26 | 39.19 | 328 | 1025 | 1306 | 157 | 99.13 |
| WANet | + cumulative LDOS (ours) | 40.19 | 51.59 | 38.52 | 287 | 573 | 791 | 137 | 99.22 |
Table 7. QH9-stable-id, all three backbones (Table 1 with the element-wise-only control added; test set, Ha, in %). Bold marks the best downstream metric per backbone.
| split | method | diag | non-diag | HOMO ↓ | LUMO ↓ | gap ↓ | ↓ | ↑ | |
| stable-id | pretrained | 77.56 | 129.25 | 73.68 | 1041 | 9445 | 9632 | 1206 | 96.28 |
| stable-id | + element-wise loss only (control) | 74.44 | 108.11 | 71.90 | 1280 | 14946 | 14769 | 868 | 95.57 |
| stable-id | + WALoss | 78.04 | 119.03 | 74.95 | 847 | 5458 | 5835 | 570 | 96.79 |
| stable-id | + cumulative LDOS (ours) | 74.81 | 109.54 | 72.19 | 678 | 1482 | 2027 | 341 | 97.91 |
| stable-ood | pretrained | 73.53 | 122.32 | 70.78 | 561 | 4632 | 4522 | 740 | 95.54 |
| stable-ood | + element-wise loss only (control) | 70.86 | 109.25 | 68.70 | 783 | 15801 | 15638 | 582 | 94.35 |
| stable-ood | + WALoss | 72.70 | 115.00 | 70.30 | 475 | 5511 | 5671 | 393 | 95.04 |
| stable-ood | + cumulative LDOS (ours) | 71.10 | 110.81 | 68.87 | 442 | 1420 | 1506 | 290 | 96.17 |
| dynamic-geo | pretrained | 98.4 | 161.4 | 93.6 | 960 | 5561 | 6090 | 840 | 96.66 |
| dynamic-geo | + element-wise loss only (control) | 95.1 | 146.4 | 91.3 | 1503 | 20655 | 20468 | 770 | 94.51 |
| dynamic-geo | + WALoss | 100.0 | 162.2 | 95.3 | 976 | 6950 | 7441 | 597 | 96.06 |
| dynamic-geo | + cumulative LDOS (ours) | 95.6 | 148.5 | 91.6 | 771 | 1517 | 2132 | 400 | 97.85 |
| dynamic-mol | pretrained | 173.5 | 420.1 | 153.7 | 7662 | 68568 | 62262 | 9696 | 79.74 |
| dynamic-mol | + element-wise loss only (control) | 172.1 | 415.8 | 152.5 | 9145 | 82180 | 74214 | 11343 | 76.80 |
| dynamic-mol | + WALoss | 174.5 | 419.4 | 154.8 | 8101 | 74057 | 67285 | 9280 | 79.10 |
| dynamic-mol | + cumulative LDOS (ours) | 172.3 | 415.9 | 152.8 | 2494 | 15105 | 14356 | 4842 | 90.57 |
Table 8. QHNet on all four QH9 splits (the QHNet rows of Tables 1 and 6 with the element-wise-only control added; test sets, Ha, in %). Bold marks the best downstream metric per split.
Finding. Continued element-wise training does what it is asked to do and no more. The element-wise error goes down or stays put, while the eigen-derived quantities do not improve and, on QHNet, deteriorate sharply. On QHNet the Hamiltonian MAE falls on every split (by 4.0%, 3.6%, 3.4% and 0.8% on stable-id, stable-ood, dynamic-geo and dynamic-mol), while the gap error rises by 53%, 246%, 236% and 19%, falls on every split, and on dynamic-mol the occupied-orbital error rises as well. On SPHNet every metric changes by less than 1.5% (the gap error by 0.1%); on WANet the Hamiltonian MAE is unchanged while the LUMO and gap errors rise by 10% and 8%. A matrix that is more accurate entry by entry therefore does not by itself give a better spectrum. The same decoupling has been reported independently: Li et al. [14] found that on larger molecules matrices with tiny relative errors gave unusable total energies, and Kaniselvan et al. [8] measured only a weak correlation between matrix-element errors and eigenvalue errors across the test splits of DFT. This is Proposition B.7 read in reverse: the element-wise loss does not distinguish the sectors of the error, so without a spectral signal the optimizer is free to move error into the sectors that the properties are sensitive to.
Two directions of generalization. Table 7 holds the dataset fixed (stable-id) and varies the model: the control behaves the same way on three architectures of very different accuracy, so the effect is a property of the training signal rather than of one network. Table 8 holds the model fixed (QHNet) and varies the data: the same pattern appears on the random, size-extrapolation and molecular-dynamics splits, so it is not tied to one distribution either. In both tables the cumulative LDOS loss, which shares every setting with the control except the auxiliary term, improves every eigen-derived metric while keeping the Hamiltonian MAE at most 0.3% above the pretrained value.
Weight sensitivity on QHNet
WALoss as used in this paper. Throughout the paper, WALoss means the full form of Li et al. [14]: the prediction is expressed in the basis of reference orbitals and every entry of is penalized. On SPHNet and WANet, the loss is the mean absolute plus the mean squared entry of this matrix, with weight 0.05. On QHNet, it is the mean absolute entry, evaluated on eight molecules per batch like our own loss, and we report two weights: , at which the WALoss term is about as large as the element-wise term, and , at which it dominates; both are in Table 9 and give similar gap errors (6072 and 5835 Ha).
| method | diag | non-diag | HOMO | LUMO | gap | |||
| pretrained | 77.56 | 129.25 | 73.68 | 1041 | 9445 | 9632 | 1206 | 96.28 |
| element-wise loss only (control) | 74.44 | 108.11 | 71.90 | 1280 | 14946 | 14769 | 868 | 95.57 |
| WALoss | 76.01 | 112.51 | 73.26 | 823 | 5728 | 6072 | 593 | 96.81 |
| WALoss | 78.04 | 119.03 | 74.95 | 847 | 5458 | 5835 | 570 | 96.79 |
| density only | 77.72 | 126.93 | 74.02 | 780 | 1923 | 2376 | 571 | 97.44 |
| density only | 79.01 | 138.44 | 74.55 | 802 | 2500 | 2896 | 373 | 97.43 |
| density only | 76.82 | 118.70 | 73.65 | 719 | 1575 | 2081 | 356 | 97.87 |
| cumulative LDOS | 74.88 | 109.66 | 72.26 | 675 | 1693 | 2231 | 348 | 97.80 |
| cumulative LDOS | 74.81 | 109.54 | 72.19 | 678 | 1482 | 2027 | 341 | 97.91 |
| cumulative LDOS | 74.85 | 109.90 | 72.21 | 655 | 1300 | 1811 | 336 | 97.98 |
Table 9. QHNet on QH9-stable-id: all metrics against the auxiliary weight (test set, Ha). WALoss is the full form used throughout the paper; the weight of the cumulative loss, , is selected on the validation split.
Figure 11 plots the density-only and cumulative rows of Table 9 and the diagonal-only rows of Table 10 against , with the pretrained model, the control and WALoss () as horizontal references. Across all tested weights, the density-only and cumulative losses give 2–3 times lower gap error than WALoss, so the ranking does not depend on the choice of . The cumulative loss responds only mildly to its weight (gap error 2231, 2027 and 1811 Ha at , 30 and 100) and its element-wise error stays essentially constant: at the selected weight, , its element-wise error is within 0.6% of the lowest value among all runs, that of the control, while its gap error is 7.3 times lower.
| method | diag | non-diag | HOMO | LUMO | gap | |||
| pretrained | 77.56 | 129.25 | 73.68 | 1041 | 9445 | 9632 | 1206 | 96.28 |
| diagonal-only WALoss | 74.48 | 108.29 | 71.93 | 1130 | 12504 | 12373 | 797 | 95.88 |
| diagonal-only WALoss | 75.20 | 110.03 | 72.58 | 1090 | 14208 | 13701 | 977 | 95.59 |
| diagonal-only WALoss | 77.84 | 117.44 | 74.86 | 1862 | 28282 | 26813 | 1573 | 93.66 |
Table 10. QHNet on QH9-stable-id with the diagonal-only form of WALoss at three weights (test set, Ha).

Figure 11. Weight sensitivity on QHNet (entries of Table 9 and Table 10). (a) Gap error and (b) occupied-orbital energy error against the auxiliary weight , with the pretrained checkpoint, the element-wise-only control and WALoss () as horizontal references. The diagonal-only WALoss gets worse as its weight grows; the density-only and cumulative losses improve or stay flat, and the cumulative loss is the lowest at every weight.
The diagonal-only form. Li et al. [14] also propose a second form of WALoss that keeps only the diagonal of the projected matrix, , with large weights on the occupied orbitals and the LUMO. Each term is the first-order estimate of one orbital energy (Proposition 3.1a), so this form sees sector A only, and only to first order. We implemented it on QHNet ( on the occupied orbitals and the LUMO, elsewhere) to test the prediction of § 3.1 that such an objective can be lowered by rotating orbitals instead of correcting their energies. Table 10 confirms it: as the weight grows, the gap and occupied-orbital errors get monotonically worse, from 12,373 to 26,813 Ha and from 797 to 1573 Ha, while falls.
Peak-shaped LDOS variants
The peak-shaped loss of Sec. 3.2 replaces the cumulative step by a unit-height Gaussian; everything else (window, , sample points) is shared with the cumulative loss. On SPHNet and WANet at it reaches gap errors of 805 and 813 Ha (HOMO 281 and 270, LUMO 588 and 613, 235 and 140, 99.22 and 99.19%), close to the cumulative loss at (789 and 791 Ha), so on these two backbones the two forms perform similarly. On QHNet, whose initial orbital-energy errors are the largest, the peak-shaped loss is unreliable: two runs with identical settings end at gap errors of 6917 and 1994 Ha, and in the first run the occupied-orbital error doubles relative to the pretrained model. The three cumulative runs of Table 9, by contrast, vary smoothly with (gap error 2231, 2027 and 1811 Ha). Per-orbital errors (Table 11) show why: the deep occupied orbitals, whose errors are largest, drift away from their targets (for HOMO−23, the 23rd orbital below the HOMO, the error grows from 1,049 to 20,979 Ha), whereas the cumulative loss, with the same window, and weight, shows no drift and gives the best and of all variants at the same element-wise error.
The mechanism is Theorem 3.5(iv): once an orbital’s energy error exceeds a few , the predicted and reference peaks no longer overlap, the mismatch saturates and its gradient vanishes (Figure 12b,Figure 12c), so the orbital is no longer pulled back; the step of the cumulative form keeps a constant restoring force at any distance. This is the failure mode of overlap-based divergences between distributions with disjoint supports, whose gradients vanish while a transport (Wasserstein) distance keeps a usable one [1]; the cumulative form compares the local spectra through their distribution functions, as a transport distance does, and tends to their Cramér–von Mises distance as (Proposition B.6). The deep occupied orbitals, whose initial errors on QHNet are the largest, are the first to be released.
SCF acceleration
A predicted Hamiltonian can also initialize a conventional DFT calculation (the protocol is in Appendix § 16). On 50 stable-id test molecules, every model in Table 12 saves about a third of the iterations and 13–15% of the total time relative to the minao guess, and the models differ little (0.671–0.674 in iterations, 0.80–0.82 in SCF time). The loss improves the eigen-properties without changing what the model offers as an SCF starting point.
Training cost
With the cached orbital values, evaluating costs one eigendecomposition and two small matrix products per molecule; QH9 matrices are at most . On QHNet the auxiliary term adds 0.72 s to each training step and no GPU memory, because the eigendecompositions run on the CPU (Table 13); over the 30k fine-tuning steps this amounts to about 6 hours, roughly 5% of the cost of pretraining QHNet for 300k steps. The loss is used only in training, so inference costs exactly what it costs for the backbone.
| auxiliary loss | seconds/step | overhead | peak GPU memory (GB) |
| none (element-wise only) | 1.47 | – | 31.2 |
| density only | 1.92 | +0.45 s (+30%) | 31.2 |
| peak LDOS | 2.28 | +0.81 s (+55%) | 31.2 |
| cumulative LDOS | 2.19 | +0.72 s (+49%) | 31.2 |
Table 13. Training cost of the auxiliary losses on QHNet (QH9-stable-id), measured on one NVIDIA L40S with the same code, data order and batch size (32). Seconds per step are averaged over steps 50–300 without validation; memory is the peak reserved CUDA memory. The eigendecompositions run on the CPU in double precision.
Numerical Verification
Every analytical statement in Sections 2 and 3 was checked numerically on reference data. Table 14 collects the checks and their outcomes. The Fermi-level identity holds to the single precision in which the orbital values are cached: the residual scales with the float32 unit round-off. The two perturbations used in Figure 12a are exact by construction: the energy-only shift moves the intended orbital energy by 2.000 mHa with an eigenvector overlap deviation at the level of double-precision round-off, and the shape rotation leaves every eigenvalue fixed to Ha, so the sector test cleanly separates energy errors from shape errors.
The lower block of Table 14 checks Theorem B.5 and the statements around it on the reference Hamiltonians of three QH9-stable molecules, #18 (), #12345 () and #23470 (), with orbital values evaluated on the level-0 quadrature grid. For injectivity, we form the first-order response of to every entry of a symmetric , one column per entry, normalize the columns, and report the smallest singular value relative to the largest. For recovery, we start from random symmetric errors with mHa on molecule #18 and minimize the mismatch in over the full energy range, or in , over . Minimizing the mismatch in recovers every orbital energy to 0.03 mHa and shrinks the error among orbitals inside the window about 30-fold; the residual, 20–30% of the initial , lies mostly in couplings between core and virtual orbitals, the directions to which is least sensitive. Minimizing the density mismatch instead leaves the orbital energies wrong by 10 mHa. The supplementary code contains the scripts for these checks (tests/check.py and tests/verify_theory.py).
Limitations and Future Work
The analysis is exact within its assumptions: first-order perturbation theory in the basis of reference orbitals, with non-degenerate reference energies for the statements about orbital energies and shapes and an open HOMO–LUMO gap for the statement about the density. Under these assumptions the sector picture is a change of basis rather than an approximation. What the analysis does not do is predict how a given network moves along the sectors during training, so the sector picture is best read as a diagnostic rather than a guarantee.
The loss has been tested where Hamiltonian prediction is currently benchmarked: on QH9 (B3LYP/def2-SVP), with three architectures that span the development of the field, on all four official splits, and against the strongest published physics-informed loss. Its ingredients, the predicted Hamiltonian, the overlap matrix and orbital values at a few hundred points, exist for any basis set, functional or system, so the same construction should carry over to larger molecules, other levels of theory and periodic systems, where the LDOS is resolved per -point and is the quantity that scanning tunnelling microscopy measures; these are the settings in which we plan to test it next. Two design choices should be noted: the energy window covers the valence and low virtual orbitals, the right choice for ground-state properties, and would be widened for excited-state targets; and the smoothing width was fixed rather than tuned.
The cost is one eigendecomposition per sampled molecule and training step, the same operation that reads any property from a predicted Hamiltonian; on QH9 it adds 0.72 s per step on QHNet (Appendix § 17.§ 6), and inference is untouched. At the scale of thousands of basis functions the dense solver would give way to the iterative and fragment-based solvers that DFT codes already use.
Two directions follow from the analysis itself. The cumulative LDOS can be used from the start of training rather than as a fine-tuning signal, where its non-vanishing gradients should matter most while the spectrum is still far from the reference. And the sector representation can serve as a diagnostic in its own right: computed on a validation set, it tells which part of the residual a model still carries and therefore which training signal will help, turning the choice of loss from trial and error into a measurement.
Implementation Details and Protocol
Sample points and core suppression. Each molecule’s sample set is a fixed random subset of 256 points of the atom-centred radial–Lebedev quadrature grid of PySCF at level 0, cached once. The core-suppression factor is the element-wise fit of Ushenin et al. (2025), which depends only on the geometry.
Eigensolve. For each of the eight molecules per step we form with , call a symmetric float64 eigensolver on the CPU, and back-transform; gradients flow through the eigensolver.
Energy grids and weights. points on Ha with Ha for all backbones. The loss weights are listed in Table 15. The sum in Equation (7) runs over all orbitals, so orbitals below the window contribute a constant step and holds at every energy inside the gap, up to the bound of Proposition B.4.
Evaluation. Element-wise MAE is basis-permutation invariant. Eigen-derived metrics are computed from the generalized eigenproblem of with the DFT overlap . All comparisons are made within a backbone using the backbone’s own evaluator and matched settings. For SPHNet and WANet, whose evaluator runs on the GPU, TF32 matrix multiplication is disabled and the generalized eigenproblem is solved in float64, matching the CPU float64 evaluation of QHNet.
Optimization. Table 15 lists the settings. Every fine-tuning run of a given backbone starts from the same released checkpoint and differs only in the auxiliary term and its weight; the optimizer, learning rate, schedule, batch size, gradient clipping, step budget and data split are held fixed across runs.
Verification scripts. A sensitivity script perturbs the reference Hamiltonian of one molecule by an eigenvalue-only shift (which moves by and no eigenvector) and by a rotation in the HOMO/LUMO plane, and evaluates each loss (Figure 12a). A second script checks the identity of Prop. B.4, the closed forms of Prop. B.6 against numerical quadrature, and the sector sensitivities of both LDOS forms. Appendix § 18 reports the outcome of every check.
References
- [1]Martin Arjovsky, Soumith Chintala, and Léon Bottou. Wasserstein generative adversarial networks. In International Conference on Machine Learning (ICML), 2017.
- [2]Rajendra Bhatia. Matrix Analysis, volume 169 of Graduate Texts in Mathematics. Springer, New York, 1997.
- [3]Chandler Davis and W. M. Kahan. The rotation of eigenvectors by a perturbation. III. SIAM Journal on Numerical Analysis, 7(1):1–46, 1970.DOI
- [6]Pierre Hohenberg and Walter Kohn. Inhomogeneous electron gas. Physical Review, 136(3B):B864–B871, 1964.
- [7]Peter Bjørn Jørgensen and Arghya Bhowmik. Equivariant graph neural networks for fast electron density estimation of molecules, liquids, and solids. npj Computational Materials, 8:183, 2022.
- [8]Manasa Kaniselvan, Benjamin Kurt Miller, Meng Gao, Juno Nam, and Daniel S. Levine. Learning from the electronic structure of molecules across the periodic table. In International Conference on Learning Representations (ICLR), 2026.arxiv.org/abs/2510.00224
- [9]Tosio Kato. Perturbation Theory for Linear Operators. Classics in Mathematics. Springer, Berlin, 1995.
- [10]Walter Kohn. Nobel lecture: Electronic structure of matter—wave functions and density functionals. Reviews of Modern Physics, 71(5):1253–1266, 1999.DOI
- [11]Walter Kohn and Lu Jeu Sham. Self-consistent equations including exchange and correlation effects. Physical Review, 140(4A):A1133–A1138, 1965.DOI
- [12]Teddy Koker, Keegan Quigley, Eric Taw, Kevin Tibbetts, and Lin Li. Higher-order equivariant neural networks for charge density prediction in materials. npj Computational Materials, 10:161, 2024.arxiv.org/abs/2312.05388
- [14]Yunyang Li, Zaishuo Xia, Lin Huang, Xinran Wei, Samuel Harshe, Han Yang, Erpai Luo, Zun Wang, Jia Zhang, Chang Liu, Bin Shao, and Mark Gerstein. Enhancing the scalability and applicability of Kohn-Sham Hamiltonians for molecular systems. In International Conference on Learning Representations (ICLR), 2025.arxiv.org/abs/2502.19227
- [15]Erpai Luo, Xinran Wei, Lin Huang, Yunyang Li, Han Yang, Zaishuo Xia, Zun Wang, Chang Liu, Bin Shao, and Jia Zhang. Efficient and scalable density functional theory Hamiltonian prediction through adaptive sparsity. In International Conference on Machine Learning (ICML), 2025.arxiv.org/abs/2502.01171
- [16]Péter Pulay. Convergence acceleration of iterative sequences. The case of SCF iteration. Chemical Physics Letters, 73(2):393–398, 1980.DOI
- [17]Raghunathan Ramakrishnan, Pavlo O. Dṙal, Matthias Rupp, and O. Anatole von Lilienfeld. Quantum chemistry structures and properties of 134 kilo molecules. Scientific Data, 1:140022, 2014.
- [18]Kristof T. Schütt, Michael Gastegger, Alexandre Tkatchenko, Klaus-Robert Müller, and Reinhard J. Maurer. Unifying machine learning and quantum chemistry with a deep neural network for molecular wavefunctions. Nature Communications, 10:5024, 2019.
- [19]Annabella Selloni, Paolo Carnevali, Erio Tosatti, and C. D. Chen. Voltage-dependent scanning-tunneling microscopy of a crystal surface: Graphite. Physical Review B, 31(4):2602–2605, 1985.
- [20]Gilbert W. Stewart and Ji-guang Sun. Matrix Perturbation Theory. Academic Press, 1990.
- [21]Qiming Sun, Timothy C. Berkelbach, Nick S. Blunt, George H. Booth, Sheng Guo, Zhendong Li, Junzi Liu, James D. McClain, Elvira R. Sayfutyarova, Sandeep Sharma, Sebastian Wouters, and Garnet Kin-Lic Chan. PySCF: the Python-based simulations of chemistry framework. WIRES Computational Molecular Science, 8(1):e1340, 2018.arxiv.org/abs/1701.08223
- [22]Attila Szabo and Neil S. Ostlund. Modern Quantum Chemistry: Introduction to Advanced Electronic Structure Theory. Dover, Mineola, NY, 1996.
- [23]Jerry Tersoff and Donald R. Hamann. Theory of the scanning tunneling microscope. Physical Review B, 31(2):805–813, 1985.
- [24]Oliver T. Unke, Mihail Bogojeski, Michael Gastegger, Mario Geiger, Tess Smidt, and Klaus-Robert Müller. SE(3)-equivariant prediction of molecular wavefunctions and electronic densities. In Advances in Neural Information Processing Systems (NeurIPS), 2021.arxiv.org/abs/2106.02347
- [25]Konstantin Ushein, Kuzma Khrabrov, Artem Tsypin, Anton Ber, Egor Rumiantsev, and Artur Kadurin. LAGNet: better electron density prediction for LCAO-based data and drug-like substances. Journal of Cheminformatics, 17:65, 2025.
- [26]Haiyang Yu, Meng Liu, Youzhi Luo, Alex Strasser, Xiaofeng Qian, Xiaoning Qian, and Shuiwang Ji. QH9: A quantum Hamiltonian prediction benchmark for QM9 molecules. In Advances in Neural Information Processing Systems (NeurIPS), Datasets and Benchmarks Track, 2023a.arxiv.org/abs/2306.09549
- [27]Haiyang Yu, Zhao Xu, Xiaofeng Qian, Xiaoning Qian, and Shuiwang Ji. Efficient and equivariant graph networks for predicting quantum Hamiltonian. In International Conference on Machine Learning (ICML), 2023b.arxiv.org/abs/2306.04922
- [28]He Zhang, Chang Liu, Zun Wang, Xinran Wei, Siyuan Liu, Nanning Zheng, Bin Shao, and Tie-Yan Liu. Self-consistency training for density-functional-theory Hamiltonian prediction. In International Conference on Machine Learning (ICML), 2024.arxiv.org/abs/2403.09560