Format of supercells_rattled.extxyz

Dear all,
I’d like to calculate the second order force constants (FC2) from an MD simulation. In the example of the tutorial
https://hiphive.materialsmodeling.org/tutorial.zip
I understood that I have to provide a trajectory file like supercells_rattled.extxyz in which:

  1. The lattice parameters are in Angstrom as well as the atomic positions
  2. the forces are in eV/Ang
  3. the last column of each trajectory step is an energy

My question is: what is that energy? How is it calculated? It looks like that it is an energy referred to the atom but it is not clear to me how it could be obtained, especially if the trajectory is from an ab initio MD simulation or it’s a sequence of geometries obtained in any other way. Moreover, is this last energy column necessary to compute the FC2? How is it used by the optimizer? I understood that the optimizer solves an equation of the kind F=Ma by means of linear regression as described here

and references therein. In such formulations, no energy value is needed, as only the forces and displacements are enough. For the same reason, I don’t think it is necessary to report the total energy of the configuration in the second line of each trajectory step, but I might miss something and might be wrong.

Thanks a lot in advance for your help.

All the best

Antonio

You dont need to specifically provide a .extxyz file, as long as you can read the trajectory with forces from your python-script then you should be able to run hiphive.

The .extxyz file is written by ASE, ase.io.write function, as you can see in 1_prepare_reference_data.py.

Yes you are correct the energy is not included in the standard optimization with hiphive (it can be included if you want to).

OK, thanks a lot for the quick reply!

Antonio