Source-linked AI summary

The hiphive package for the extraction of high-order force constants by machine learning

Fredrik Eriksson, Erik Fransson, Paul Erhart

arXiv:1811.09267v3cond-mat.mtrl-sciphysics.comp-ph

TL;DR

High-order force constants are important for modeling material thermodynamics, but their extraction becomes difficult as system size and expansion order increase. hiPhive addresses this with symmetry-constrained, regularized regression and demonstrates accurate results using substantially fewer configurations than conventional calculations.

  • Problem

    High-order force constants are needed to describe anharmonic thermodynamic behavior, while the number of expansion degrees of freedom scales exponentially with system size and order.

  • Method

    hiPhive uses crystal symmetries, sum rules, and regularized machine-learning regression to construct and extract force-constant models of arbitrary order.

  • Results

    20 to 25 configurations produced converged thermal conductivity results, compared with 441 configurations for equivalent phono3py calculations at a 5.9 Å cutoff.

  • Takeaways & Limitations

    The package supports efficient high-order force-constant extraction and integration with electronic-structure, phonon, and machine-learning workflows for ideal and defective materials.

Abstract

from arXiv · show

The efficient extraction of force constants (FCs) is crucial for the analysis of many thermodynamic materials properties. Approaches based on the systematic enumeration of finite differences scale poorly with system size and can rarely extend beyond third order when input data is obtained from first-principles calculations. Methods based on parameter fitting in the spirit of interatomic potentials, on the other hand, can extract FC parameters from semi-random configurations of high information density and advanced regularized regression methods can recover physical solutions from a limited amount of data. Here, we present the hiPhive Python package, that enables the construction of force constant models up to arbitrary order. hiPhive exploits crystal symmetries to reduce the number of free parameters and then employs advanced machine learning algorithms to extract the force constants. Depending on the problem at hand both over and underdetermined systems are handled efficiently. The FCs can be subsequently analyzed directly and or be used to carry out e.g., molecular dynamics simulations. The utility of this approach is demonstrated via several examples including ideal and defective monolayers of MoS$_2$ as well as bulk nickel.

I. INTRODUCTION

Force constants are needed to model vibrational properties beyond the harmonic approximation, but systematic finite-difference extraction becomes impractical for large systems and high orders. hiPhive addresses this by combining symmetry-aware force-constant models with machine-learning regression and related analysis workflows.

  • Anharmonic effects must be included to capture the correct behavior of systems such as metastable materials and temperature-dependent phonon modes.
  • Higher-order force constants become increasingly difficult to enumerate because their degrees of freedom grow exponentially with interaction range.
  • hiPhive uses crystal symmetry, sum rules, and regularized regression to extract high-order force constants from comparatively limited first-principles data.
  • Its models can be post-processed with phonopy and phono3py or used for molecular-dynamics simulations through ASE.
  • Force expansions are linear in the force constants, enabling their extraction through parameter-fitting methods.

B. Clusters

Clusters provide a compact representation of force-constant interactions, while permutation and crystal symmetries relate equivalent clusters and reduce the number of independent parameters.

  • Clusters group force-constant interactions by the sites involved, including one-body, two-body, and many-body clusters.A cluster’s size can be defined by the largest distance between any two sites.
  • Force constants obey permutation symmetry because differentiating the total energy must remain invariant under simultaneous permutation of atomic and Cartesian indices.
  • Space-group operations relate force constants for clusters mapped onto one another by rotations, translations, or improper rotations.
  • Clusters connected by lattice symmetries form orbits, allowing hiPhive to reduce the number of free force-constant parameters.

D. Constraints

Translational and rotational invariance impose force-constant constraints, but increasing cutoff and order can still produce rapidly growing parameter spaces and underdetermined fitting problems.

  • Translational invariance yields acoustic sum rules that constrain force constants through conservation of linear momentum.
  • Rotational invariance produces sum rules linking force constants of order n and n + 1 through conservation of angular momentum.The formulation uses infinitesimal-rotation generators and atomic position vectors.
  • The Born-Huang and Huang constraints are simplified second-order rotational sum rules used in the implementation.
  • The number of clusters, orbits, and unknown parameters increases rapidly with cutoff radius, potentially exceeding the available reference forces.
  • The selected constraints do not guarantee full rotational invariance, although they enforce the correct near-Γ dispersion relation important for two-dimensional materials.

III. METHODOLOGY

hiPhive constructs a symmetry- and sum-rule-constrained cluster space, converts displaced-supercell forces into a sensing matrix, and fits the remaining parameters using suitable optimization methods.

  • The workflow begins by identifying structure symmetries, enumerating cutoff-limited periodic sites, and constructing compatible clusters.
  • The resulting cluster space records allowed clusters, orbit organization, orbit force constants, symmetry-compatible free parameters, and invariance constraints.
  • The cluster space contains the information required to construct template force constants for any supercell with the same structure and chosen cutoff inputs.
  • Clusters are grouped into symmetry orbits, whose representative force constants are reduced into components obeying internal symmetry relations.
  • The workflow constructs equations for translational and rotational sum rules and determines the parameter space satisfying those constraints.
  • A sensing matrix built from displaced supercells relates the free force-constant parameters to the resulting atomic forces.

A. Clusters and orbits

hiPhive organizes symmetry-related clusters into orbits and uses invariant eigentensor bases to reduce the independent force-constant components.

  • Clusters and orbits: Unique clusters are categorized into orbits, each represented by a prototype cluster related through symmetry operations and permutations.
  • Clusters and orbits: A symmetry mapping a cluster onto a permutation of itself can reduce the number of free force-constant components.
  • Invariant bases: Representative-cluster symmetries are transformed into an eigenvalue problem whose back-transformed eigenvectors form an invariant basis.
  • Invariant bases: Symmetry-compliant force constants are constructed as linear combinations of the invariant basis functions.
  • Invariant bases: The parameters associated with basis functions remain optimization variables because symmetry alone cannot determine them.

C. Translational sum rules

hiPhive enforces translational and rotational sum rules by constraining or correcting force-constant parameters within symmetry-compatible parameter spaces.

  • Translational constraints: Translational sum rules are enforced by re-parametrizing parameters using linear combinations spanning the constraint nullspace.
  • Translational constraints: The translational constraint equations define relationships among parameters that satisfy the sum rules.
  • Parameter fitting: The sensing matrix relates predicted forces to constrained force-constant parameters for a given displacement vector.
  • Rotational constraints: Rotational constraints are applied by projecting a previously determined parametrization onto the correct subspace while preserving lattice symmetries and translational invariance.
  • Rotational constraints: Rotational corrections can be found by minimizing the correction norm while satisfying constraint residual and correction tolerances, for example through ridge regression.

F. Reference structures

Reference structures are selected according to the intended force-constant application, with small rattled displacements for lower-order models and distance-preserving large-displacement methods for higher orders.

  • Use cases: Training structures support lattice-dynamics force constants, interatomic-potential models for molecular dynamics, or lower-order fits to molecular-dynamics trajectories.
  • Lower-order models: For second- and third-order force constants, Gaussian rattled structures with displacement amplitudes of ∼0.01 to 0.05 ˚A commonly yield accurate force constants.
  • Lower-order models: Rattle structures can mix higher-order force contributions into fitted lower-order constants, so fitting respective higher-order terms can improve accuracy.
  • Higher-order models: For fourth-, sixth-, and higher-order models, large displacements are needed, while rattle standard deviations above ∼0.1 ˚A can create short distances and huge repulsive forces.
  • Higher-order models: Monte Carlo sampling generates large random displacements while preserving interatomic distances, avoiding the short-distance problem of large-amplitude rattling.
  • Physically informed structures: Normal modes populated with average energy k_BT/2 provide physically sensible displacement patterns at specified temperatures.

IV. WORKFLOW

The hiPhive workflow builds a force-constant potential from a symmetry-defined cluster space, reference-force data, and selected training and validation structures.

  • Model construction: A force-constant potential is created by constructing a cluster space from a prototype structure and order-specific interaction cutoffs.
  • Model construction: The cluster space specifies supercell clusters and eigentensors and defines free parameters that are fitted to forces from displaced structures.
  • Training data: Reference structures should span the configuration space of interest while using as few structures as computationally practical.
  • Training and validation: hiPhive compiles training and validation configurations into a structure container and constructs a sensing matrix for each added structure.

C. Training and validation

hiPhive trains force-constant models by solving regularized linear systems that may be over- or underdetermined, then converts the fitted parameters into force-constant potentials for vibrational analysis and simulations. In ideal monolayer MoS2, the resulting phonon dispersions agree with phonopy when invariance conditions are imposed, with convergence reached using a 6 × 6 × 1 supercell and a cutoff just over 9 Å.

  • Training and validation: Regularized regression handles both overdetermined and underdetermined force-constant systems, where sparse or noisy solutions make regularization useful.hiPhive supports LASSO, ARDR, singular-value decomposition, elastic net, Bayesian-ridge regression, and recursive feature elimination.
  • Training and validation: The fitted parameters are transformed into a force-constant potential that can enforce rotational sum rules and calculate force constants in compatible supercells.The resulting force constants can be analyzed with phonopy and phono3py or used in molecular-dynamics simulations through ASE.
  • Validation on ideal MoS2: Phonon dispersions from hiPhive with all invariance conditions imposed are virtually indistinguishable from phonopy results for ideal monolayer MoS2.The lowermost transverse acoustic branch exhibits the expected quadratic dispersion near the Brillouin-zone center.
  • Validation on ideal MoS2: Disabling rotational sum rules creates a small imaginary pocket near the Brillouin-zone center and removes the quadratic dispersion.This error can affect properties for which acoustic modes contribute substantially, such as thermal conductivity.
  • Convergence: Convergence is achieved at a cutoff just over 9 Å, equivalent to a 6 × 6 × 1 supercell containing 108 atoms.The model used second-order cutoffs up to 15 Å and included third-order terms up to 3.0 Å; the largest model had 319 parameters.

B. Thermal conductivity of monolayer-MoS2

The MoS2 thermal-conductivity test evaluates whether machine-learned second- and third-order force constants converge accurately from limited reference data. hiPhive reaches agreement with phono3py using about 20–25 configurations, while sulfur-vacancy models converge in force and frequency errors with substantially fewer calculations than phonopy enumeration.

  • Test rationale: Thermal conductivity is a stringent test because it requires accurate second- and third-order force constants.Sulfur vacancies likewise require defect-supercell second-order force constants, while low symmetry and large cells make enumeration costly.
  • Ideal monolayer: About 20–25 configurations are sufficient for converged thermal conductivity, with values in very good agreement with phono3py across the entire temperature range.The validation RMSE levels off at about 1.5 meV/Å from roughly 15 structures onward, while thermal conductivity converges slightly more slowly.
  • Sulfur vacancy: Sulfur-vacancy force-component RMSE reaches about 3 meV/Å with roughly 25–30 structures, whereas phonopy requires 215 individual DFT calculations.The same convergence behavior extends to frequency MAE, frequency RMSE, and the overall phonon dispersion.
  • Sulfur vacancy: The sulfur-vacancy regression remains sparse, with the fraction of nonzero parameters below 70%.This sparsity is consistent with force constants decaying rapidly with interaction distance and order.

D. Molecular dynamics simulations of nickel

hiPhive enables anharmonic force-constant models to support molecular-dynamics simulations, demonstrated with a fourth-order model for bulk nickel. The simulations compare harmonic and fourth-order descriptions of atomic mean-square displacement across temperature.

  • Molecular-dynamics workflow: Anharmonic force-constant models can be used in molecular-dynamics simulations through hiPhive's ASE calculator interface.The calculator requires a set of force constants as input and supports dynamic properties including dynamical structure factors, velocity autocorrelation functions, and free energies.
  • Model construction: A fourth-order nickel model used 20 unique orbits and 119 free parameters from interactions extending to the fourth nearest neighbor for pair terms.The model used cutoff radii of 5.0, 4.0, and 4.0 Å for second-, third-, and fourth-order terms, respectively, corresponding to 171 clusters in the unit cell.
  • Training data: Five randomly displaced 256-atom structures supplied 3,840 force components for training, with reference forces generated by an effective medium theory model.Displacements averaged about 0.13 Å and were constrained to avoid interatomic distances shorter than 2.3 Å.
  • Training procedure: The nickel model parameters were fitted using standard least squares because the training system was heavily overdetermined.The fitting choice is reported in connection with the training data summarized in Table I.
  • Scope: The nickel example illustrates hiPhive's broader use for extracting higher-order force constants and performing dynamic simulations within a workflow that interfaces with electronic-structure codes through ASE.The paper presents nickel among examples covering phonon analysis and dynamic simulations.
Loading 1811.09267v3…