i-pi / i-pi

i-PI: a universal force engine
https://ipi-code.org/
237 stars 117 forks source link

Different trajectories from lammps and I-PI #230

Closed changxiaoju closed 2 years ago

changxiaoju commented 2 years ago

I do PIMD using i-pi with lammps. I have 8 beads and 8 xyz position files and a centriod file, and all of them are very different from trajectory dumped by lammps. Is it normal? Which trajectory should i believe? Meanwhile, the thermo information dumped by lammps and i-pi are the same. the i-pi input file: <trajectory filename='pos' stride='1000' format='xyz' cell_units='angstrom'>positions{angstrom} </trajectory> positions{angstrom} </trajectory> i have tried pbc='True' and pbc='False' lammps input file: variable NSTEPS equal 4000002 dump trj all atom 10000 out.lammpstrj

very different trajectories: (left dumped by lammps, right is the xyz file from i-pi (wraped at PBC)) Is there anything wrong with the communication of coordinate between lammps and i-pi? And it seems xyz file from i-pi also very strange because the box keeps getting larger and larger and larger... c99f3a6a979769630397673522cecf1

ceriottm commented 2 years ago

I suspect a mess-up with units. i-PI expects, unless otherwise specified, everything to be in atomic units. if you are using an xyz that is in angstrom in the initialization without specifying it's so, it will load it assuming it's in bohr and all hell will break loose.

changxiaoju commented 2 years ago

Thankyou for reply. But I have specified cell parameters in the initial xyz file like: 9000 \# CELL(abcABC): 28.5 28.5 28.5 90.0 90.0 90.0 cell{angstrom} positions{angstrom} and in the input xml file ` conf.xyz

[28.5,28.5,28.5] ` Is that still not enough? but I see example like `/i-pi/examples/lammps/graphene` no more settings on units
ceriottm commented 2 years ago

Is the simulation stable (low drift, temperature and potential fluctuating around fixed mean value....)? In all events it's probably easier to debug this if you upload a zip with all the files needed to run (xml, input xyz, lammps input and data files).

changxiaoju commented 2 years ago

Thank you ceriottm, the simulation is stable, the temperature, the pressure... I upload a zip of mine. the error happens in the beginning, so you can kill if there is a second frame output of both lammps and i-pi to save your CPU time. Thanks again files.zip

changxiaoju commented 2 years ago

Is the simulation stable (low drift, temperature and potential fluctuating around fixed mean value....)? In all events it's probably easier to debug this if you upload a zip with all the files needed to run (xml, input xyz, lammps input and data files).

I am so sorry , the potential file is 68MB too large to upload here, I put it in my repositories. could you please go there and download it?

ceriottm commented 2 years ago

So you solved this? Might be useful to explain what was the problem so others can benefit.

changxiaoju commented 2 years ago

yes, it is because the index of atoms in the data file for lammps are not a sequence, but out of order.