Applying a force to each atom, that is dependent upon it's coordintates

In LAMMPS, I have a system with around 1000 atoms. I want to apply a force to each atom, which is a function of the atom’s location ( in terms of x, y and z). How can this objective be achieved?

I couldn’t find a fix in lammps that does this. Is there a LAMMPS feature that allows us to cycle through each atom and apply a force (functionally dependent upon it’s position) to it?

How to go about this problem?

Regards
Brahm Prakash Mishra
Mechanical Engineering
National Institute of Technology
Trichy

BPM > In LAMMPS, I have a system with around 1000 atoms. I want to
apply a force BPM > to each atom, which is a function of the atom's
location ( in terms of x, y BPM > and z). How can this objective be
achieved? BPM >
BPM > I couldn't find a fix in lammps that does this. Is there a LAMMPS
feature BPM > that allows us to cycle through each atom and apply a
force (functionally BPM > dependent upon it's position) to it?
BPM >
BPM > How to go about this problem?

this has been discussed on this list several times. please always check
the mailing list archives.

the way to do this is to use fix addforce with an atom style variable.

axel.

BPM >
BPM >
BPM > Regards
BPM > Brahm Prakash Mishra
BPM > Mechanical Engineering
BPM > National Institute of Technology
BPM > Trichy