[lammps-users] force per atom

Hello,

I have 2 surfaces interacting. I want the top surface to move at a
constant velocity. Is there a command to keep the velocity constant
throughout the simulation? Also I would like to calculate the forces on
each atom of the bottom surface from all of the atoms on the top
surface. (i.e., what are the forces on atom 1 of molecule A as it
interacts with all the atoms on molecule B?). Is there currently a way
to calculate this?

Thanks

Pam

Pam,

Take a look at the "velocity" and "fix setforce" commands.

http://lammps.sandia.gov/doc/velocity.html
http://lammps.sandia.gov/doc/fix_setforce.html

Set the velocity to the constant value that you want and then use fix setforce to zero out forces on those atoms and ensure that the velocities don't change.

For the force-force calculation that you want, see the "compute group/group" command:

http://lammps.sandia.gov/doc/compute_group_group.html

Paul

Thanks Paul.

I have tried the compute group/group command. It seems that it
calculates the TOTAL force of interactions between two groups. I just
want the value of each individual atom in one group. If atoms 1, 2, and
3 are in group ONE and a, b, and c are in group TWO, then I need the
force on atom 1 from a, b, and c.

Pam

Pam,

You're welcome. Please note that you can define a group as a single atom. So you should be able to compute what you want using the compute group/group command. Of course there's the limit on the total number of groups that you can define (which is 32). Alternatively, there's always the option of writing your own compute or fix to do the job, or writing a script to do the computation as a post-process on a LAMMPS dump file.

Paul