Currently, deep learning paradigms challenge and inspire all branches of scientific research. Computational chemistry and molecular modeling are no exception to this trend, although data generation in these fields is notoriously costly1. The reason for the difficulties lies at the very heart of quantum mechanics: the atomic world is governed by the Schrödinger equation, a complicated eigenvalue problem formulated in an abstract many-body Hilbert space. Writing in Nature Computational Science, He Zhang and colleagues have harnessed the predictive power of graph neural networks to help orbital-free density functional theory (OFDFT), a highly promising alternative to the above, overcome its long-standing hurdle of insufficient accuracy and become applicable to molecular systems; hence the name M-OFDFT2.

Despite the fact that any serious attempt to solve a molecular Schrödinger equation exactly, even for a moderately-sized system, has to be postponed until the advent of quantum computers3, numerical approximations delivering accurate answers to many questions asked by physicists and chemists are just a matter of conventional computing power and time. In most cases, a separation of the problem into a nuclear and an electronic part can be justified by a simple argument of timescales, and within the so-called Born–Oppenheimer approach, we may assume that rearrangements of the much lighter electrons happen instantaneously whenever nuclear positions change. With this, the solution of the nuclear part becomes trivial, but the electronic part remains highly challenging. One of the most successful treatments of the latter, and the starting point for the work of Zhang and colleagues, takes an entirely different route.

Instead of working with the high-dimensional electronic wavefunction, it declares the electron density, a scalar function of three Cartesian coordinates, as the central target. This radical simplification is justified by the Hohenberg–Kohn theorems, which state that, in the ground state, there is one and only one electron density arrangement possible for a set of N electrons and a given molecular structure4. Therefore, it should be possible to find a functional \(E(\rho )\) that maps any electron density \(\rho\) onto an electronic energy \(E\), and consequently, through minimization of the latter, to determine the corresponding ground state electron density. Although the functional is not known exactly, this computational approach, known as density functional theory (DFT), has become the most widely used electronic structure method in chemistry.

The major drawback of the theory (and the reason why, until today, the real success of DFT remains exclusively limited to a sub-variety named conventional Kohn–Sham DFT5) is that it seems impossible to arrive at an acceptable mapping between a given electron density and its kinetic energy. To overcome this fundamental hurdle, DFT’s linear scaling with the number of electrons (its largest advantage over wavefunction-based treatments) had to be sacrificed very early on: stepping back into the wavefunction domain allowed for building a more suitable approximation from N single-electron wavefunctions or so-called Kohn–Sham orbitals, with the consequence of increasing the computational effort to O(N3), an unfortunate scaling related to orthogonalization and diagonalization steps involved in the procedure. While still showing a much better scaling than wavefunction-based methods of similar quality and, in fact, representing the only possibility for electronic structure theory on very large systems, a linear scaling with system-size would open access to structures of biological interest such as enzymes or even subcellular components.

Obviously, researchers were aware of this substantial flaw throughout the entire era of DFT development, and first attempts to establish a pure DFT formulation, based exclusively on the electron density, predate even the works of Hohenberg and Kohn6. Fig. 1 gives a simplified overview of various suggestions and techniques referred to as ‘orbital-free’ DFT approaches to underline the opposition to conventional implementations involving orbitals. The most recent additions to this collection are methods based on machine learning. Among them, the work of Zhang and colleagues clearly stands out for several reasons.

Fig. 1: Overview of approaches in orbital-free density functional theory.
figure 1

Conventional, meaning orbital-based DFT, is opposed by ‘pure’ methods involving only the electron density. A crucial problem of the latter group is the mapping between electron density and kinetic energy, referred to as the ‘kinetic energy density functional’ or KEDF. Zhang et al. employ a neural network for the latter, while falling back on physics-informed expressions for other contributions to the energy.

First, the authors arrive at chemical accuracy (~1 kcal mol–1) for molecular systems, which (despite very promising results obtained for selected systems prior to this publication) constitutes a significant advancement. Second, it is an eclectic approach which employs the Graphormer deep learning model7, specifically the GD3 encoder module, for only one specific task, namely to compensate for the lack of the unknown kinetic energy density functional, while at the same time falling back on the well-established PBE functional (named after its three inventors) for energy contributions stemming from exchange and correlation8. Third, a whole series of improvements extract as much information as possible out of each data point obtained via conventional, costly DFT in a supervised learning algorithm: the electron density is expanded in a set of atomic basis functions, internally re-oriented so that geometric invariance with respect to molecular rotations and translations is obtained. Gradient information on the density, known to be essential for optimization towards the molecular ground state, is included in the neural network model. Furthermore, each conventional DFT data point, created — by necessity — in an iterative procedure repeated until self-consistency, holds numerous mappings between electron density, energy and gradient, which are all utilized. The authors refer to this as ‘multi-coefficient and gradient-labelled data’, retrieved through projection onto their atomic density basis set.

Having presented successful tests on common molecular benchmark sets, the authors conclude with an outlook beyond current size limitations of electronic structure theory. An impressive scaling of their method is demonstrated on two systems the size of a protein. Clearly, the observed real-world time improvements by a factor of N over conventional Kohn–Sham DFT for N-electron systems mark a substantial advance in computational chemistry. It remains to be seen how well the method generalizes to systems of arbitrary charge and spin multiplicity, and how applicable it is to more sophisticated functionals that provide better approximations to the exact solution.