I met a problem in simulating the movement of a group of atoms in LAMMPS.
As is shown in the input script “in.velocity” as attached, I created a bilayer plane of Au atoms and used the “velocity” command to set all the atoms a constant velocity in the z direction. However, the average velocities of these atoms in the z direction at different times were outputed in “velocity.txt” as attached and they are not constant at all. It seems that the “velocity” command is not valid in my simulation.
Setforce should be the last fix you apply to ensure that forces imposed by any other fix are removed. From the manual:
“Set each component of force on each atom in the group to the specified values fx,fy,fz. This erases all previously computed forces on the atom, though additional fixes could add new forces.”