Cluster analysis on the MD trajectories extracted from LAMMPS

GROMACS version: 2020.1
GROMACS modification: Yes/No

Dear GROMACS community,


I have performed Reactive forcefield MD simulations using LAMMPS software. During production run, I have extracted trajectories at 10 fs. Next, I wanna perform cluster analysis using GROMACS. Can you please guide me how to perform cluster analysis on the trajectories extracted from the software other than GROMACS?

Khizar Hayat

Hi, for the clustering, I’d check the documentation of gmx cluster and start there.

The only slight complication is the trajectory conversion from whichever format you used for the LAMMPS trajectory dump. If you used XTC, you’re in luck, otherwise most other formats that LAMMPS supports GROMACS can’t read directly, and you should convert them first.


Hello Giacomo,

Thanks. I wanna perform cluster analysis using gmx clustsize, however, the issue is that my LAMMPS trajectories are not xtc file type. As you mentioned, yes I am trying to convert them first but couldn’t find suitable tool. Anyone please refer any tool to convert LAMMPS dump file to xtc file.

Looking forward.


Did you check the tools in this page first?
You should be already closely familiar with that list if you have used LAMMPS.

Look for a package that reads the format you have and writes in a GROMACS-compatible format. Nearly all of those packages have easy to browse documentation.


Also this:

Dear Giacomo,

Got it. Thank you so much.