  The intrinsic Helmholtz free-energy functional, the centerpiece of classical
density functional theory (cDFT), is at best only known approximately for 3D
systems. Here we introduce a method for learning a quasi-exact neural-network
approximation of this functional by exclusively training on a dataset of radial
distribution functions, circumventing the need to sample costly heterogeneous
density profiles in a wide variety of external potentials. For a supercritical
3D Lennard-Jones system, we demonstrate that the learned neural free-energy
functional accurately predicts planar inhomogeneous density profiles under
various complex external potentials obtained from simulations.
