xnn.gnn.models.qet#

QET (Ko et al., arXiv:2511.07249), the charge-equilibrated TensorNet.

An implementation of

  • T. W. Ko, R. Liu, A. R. Mishra, Z. Yu, J. Qi, S. P. Ong, “A Linear-Scaling, Charge-Aware Foundation Potential for Atomistic Simulations”, arXiv:2511.07249,

written from the paper on TensorNet and consistent with the conventions of the authors’ code (MatGL, BSD-3-Clause) without copying it. Parameter names follow MatGL where xnn has the same layer, so that its published weights transplant.

The TensorNet trunk gives every atom invariant features h_i. Two networks read them: an electronegativity chi_i and a positive hardness eta_i (one value per element, or a softplus network of h_i). An external potential phi_i on an atom shifts its electronegativity. Minimizing sum_i (chi_i q_i + eta_i q_i^2 / 2) at a fixed total charge Q of the structure gives the charges in closed form (eq 2 of the paper):

q_i = (lambda - chi_i) / eta_i,   lambda = (Q + sum_j chi_j / eta_j) / sum_j 1 / eta_j

which costs one sum per structure, so the model stays linear in the number of atoms. The charges set a damped Coulomb potential at every atom (eq 3):

V_i = k_e sum_j q_j erf(r_ij / (sqrt(2) gamma_ij)) f_cut(r_ij) / r_ij,
gamma_ij = sqrt(sigma_i^2 + sigma_j^2)

over the neighbors within the cutoff, with Gaussian charge widths sigma (the covalent radii of the elements, or learned per element), the polynomial envelope of degree 3 as f_cut and k_e = 14.399645478425668 eV Angstrom / e^2. The atomic energy is a gated network of the layer-normed [h_i, q_i, V_i].

Conventions worth knowing:

  • the defaults are those of the authors’ code: 32 Gaussians on [0, cutoff + 1] with exponent 0.5, no self pairs, two interaction layers of 64 features, a cutoff of 5 Angstrom and one hardness per element; the paper’s foundation potentials use the smooth Bessel basis (radial_basis="smooth_bessel") and the environment-dependent hardness (hardness="environment");

  • the trunk takes no charge: the total charge of a structure enters through the charge equilibration alone;

  • the charge constraint couples every atom of a structure, so the model has no bounded receptive field (QET.receptive_field()).

Module Attributes

COULOMB_CONSTANT

Coulomb's constant e^2 / (4 pi epsilon_0) in eV Angstrom / e^2 (CODATA 2018).

COVALENT_RADII

Covalent radii (Angstrom) indexed by atomic number, from Cordero et al., Dalton Trans.

Classes

QET([n_features, n_interactions, n_rbf, ...])

QET interatomic potential: TensorNet with analytic charge equilibration.