Clarification on dynamical_matrix output units for regular and eskm with units metal

Hi,

I’m using the dynamical_matrix command in LAMMPS to compute vibrational frequencies for a Vineyard attempt frequency calculation, and I’m a bit confused about the output units. My simulation uses units metal. From the documentation,

my understanding is that the style “regular” outputs the mass-weighted dynamical matrix in the native simulation units and the style “eskm” applies an extra unit conversion. What I’m not clear about is that, for units metal, what exactly are the units of the dynamical matrix elements for styles “regular” and “eskm”?

From the docs, it looks like with “eskm” the matrix elements should be in units of fs^{-2}. So after diagonalizing and taking the square root of the eigenvalues, I assumed I would get frequencies in fs^{-1}, and then I tried converting to THz by dividing by 2\pi and multiplying by 1000. But that gives frequencies that seem too large. In fact, using the raw sqrt(eigenvalue) from “eskm” gives values very similar to what I get from “regular” after applying my manual post-processing. So I’m wondering for units metal, how exactly should the outputs from regular and eskm be interpreted, and what (if any) additional conversion is actually needed to get frequencies in THz?

Thanks!

Hi @JMian,

You can find the constants used for conversion between the two styles in the code here (line 509 and on).

In the case of the metal units the code is:

    conv_energy = 9648.5; // eV -> 10 J/mol
    conv_mass = 1; // g/mol -> g/mol
    conv_distance = 1; // angstrom -> angstrom
    ...
    conversion = conv_energy/conv_distance/conv_mass;
    ...
    dynmat[alpha][(j-1)*3+beta] *= conversion;

with conversion set to 1 outside the eskm case. For these calculation you might also see an effect from the displacement amplitude you use with the command but there can be many sources for the discrepancy you mention and without more information on your system and how you collect and post-process your data, it is hard to make anything other than wild guesses.

Thank you!