mod curvature

module curvature

Spectral statistics of the curvature at a point, without forming a Hessian.

A work ledger charges gradient evaluations, so anything computed alongside a relaxation has to be cheap in those units. Building the Hessian of a 75-point cluster explicitly and diagonalising it costs of order twenty times the relaxation it would inform, which makes it useless as a screen however informative it is.

Lanczos needs only the action of the Hessian on a vector, and that action is a central difference of the gradient: two evaluations per matrix-vector product, so the lowest handful of eigenpairs costs a few tens of gradients against the roughly eighty a relaxation from a deep minimum takes.

What the spectrum is for. On a multi-funnel landscape the structures a search settles into and the structures worth leaving differ in stiffness before they differ in any order parameter: a relaxation started near the minimum a search plateaus at costs about 79 charged evaluations, while one started from a random configuration costs about 270, because a deep minimum is stiff and a perturbation falls straight back into it. That stiffness is the smallest eigenvalues of the curvature, and it is available before the relaxation that would otherwise discover it by returning.

Three quantities come out of the low end of the spectrum:

The smallest eigenvalue, which is the softest direction and near zero at a saddle or a flat shoulder.

The participation ratio of its eigenvector, which distinguishes a soft mode carried by a few atoms, a surface rearrangement, from one carried by the whole cluster, a collective distortion. Both can have the same eigenvalue.

The gap between the first and second, which says whether the softest direction is isolated or one of a degenerate family, and a degenerate soft family is what a symmetric structure has.

Rigid motions are projected out. A cluster in free space has three translational zero modes, and near a minimum three rotational ones, and leaving them in makes the smallest eigenvalues numerical noise about zero rather than a property of the structure.

Functions

fn curvature_features<G>(x: ArrayView1<f64>, mut grad: G, steps: usize, epsilon: f64) -> Option<CurvatureFeatures>
where
    G: FnMut(ArrayView1<f64>) -> Option<Array1<f64>>
fn project_rigid_with(v: &mut Array1<f64>, basis: &[Array1<f64>])

Removes the rigid motions in basis from v, in place.

fn rigid_basis(x: ArrayView1<f64>) -> Vec<Array1<f64>>

Orthonormal basis of the rigid motions of the structure at x.

Three translations and three infinitesimal rotations about the centre of mass, orthonormalised against each other by modified Gram-Schmidt.

The orthonormalisation is the part that matters. Projecting against the six generators one at a time only removes the rigid subspace when they happen to be mutually orthogonal, and the rotation generators of a general geometry are not. The residue survives as a near-zero eigenvalue of the projected operator, so the reported softest curvature is a leftover rotation rather than a property of the structure.

fn soft_subspace<G>(x: ArrayView1<f64>, mut grad: G, steps: usize, epsilon: f64, k: usize) -> Option<(Vec<f64>, Vec<Array1<f64>>, usize)>
where
    G: FnMut(ArrayView1<f64>) -> Option<Array1<f64>>

The k softest non-rigid eigenpairs at a point.

The same two-pass shifted Lanczos as curvature_features, returning the subspace rather than the softest vector alone. A single soft mode is a poor displacement – measured here, 6494 of 6550 single-mode trials failed the energy screen – because one parabola climbed at fixed amplitude is all rise. A draw over the soft subspace with per-mode thermal amplitudes is a different object: it is the local Gaussian N(0, T H^{-1}) truncated to the modes that carry displacement at temperature T, the correct preconditioned perturbation in the Hessian metric.

Structs and Unions

struct CurvatureFeatures

Low-end spectral summary of the curvature at a point.

lambda_min: f64

Smallest non-rigid eigenvalue.

lambda_second: f64

Second smallest, for the gap.

gap: f64

lambda_second - lambda_min; small when the softest mode is degenerate.

participation: f64

Participation ratio of the softest mode, in (0, 1].

One when every atom moves equally, of order 1/n when one atom carries the mode. Defined as 1 / (n * sum p_i^2) with p_i the fraction of the squared norm on atom i, so it does not depend on cluster size for a collective mode.

mode: Array1<f64>

The softest non-rigid direction, unit norm.

Returned rather than summarised because a direction is what an escape needs. Goedecker’s argument for molecular dynamics as the escape is that it follows the soft modes and so crosses low barriers, by the Bell-Evans-Polanyi correlation between barrier height and the energy change along the path. An isotropic displacement has no such preference: scaled up it crosses high barriers or none, measured on LJ38 as a controller pinned at its ceiling with a discovery rate of 67 in 1871.

evaluations: usize

Gradient evaluations spent.