Fix for comparing force magnitude in a two species system

​Hi,

​I am simulating a system with two species (Liquid Water- Platinum). It looks something like attached image. I want to write a fix as follows:

  1. It compares the magnitude of the Interaction forces, between Water and Platinum and between Water and Water molecules. and checks for Force(water-platinum) > Force(water-water) where-ever applicable.

For doing this, I believe I need to use the subroutine, pair_lj_cut. Could any of you please confirm if this would indeed be the right approach to solving this problem?

Thank you,

Peetak

Representational image.PNG

​Hi,

​I am simulating a system with two species (Liquid Water- Platinum). It
looks something like attached image. I want to write a fix as follows:

​a custom fix style doesn't seem like the right approach for this.​ a
compute style

1. It compares the magnitude of the Interaction forces, between Water and
Platinum and between Water and Water molecules. and checks for
Force(water-platinum) > Force(water-water) where-ever applicable.

​how is "magnitude of interaction​ forces" defined? how can you compare
water-platinum to water-water forces? why not simply look at the
interaction energy?

For doing this, I believe I need to use the subroutine, pair_lj_cut. Could
any of you please confirm if this would indeed be the right approach to
solving this problem?

there is no such subroutine in LAMMPS. the right approach would be writing
a compute style. you may want to look into compute group/group, compute
pe/tally or compute force/tally.

axel.

If you dump snapshots of your system, you can use the

rerun command twice, once with just a water/water potential

defined, once with just a water/platinum. In both rerun scripts

dump out the forces on each atom (into new dump files).

It sounds like the difference in forces on each atom

in the new pair of dump files is what you are asking for.

Steve

Thank you for your helpful replies everyone.

Dr. Plimpton, your reply helps but I intend to use that comparison between forces and write a fix for temperature scaling for the atoms which satisfy the condition of Interaction Potential (Water-Platinum)> Interaction Potential (Water-Water). If I dump the snapshots of the system, will I be able to implement my temperature scaling when the force loop runs each time using another fix?

Dr. Kohlmeyer, if I use a group command, I guess I will only get the group interaction potentials and not per atom interaction potential?

Thank you once again,

Sincerely,

Thank you for your helpful replies everyone.

Dr. Plimpton, your reply helps but I intend to use that comparison between
forces and write a fix for temperature scaling for the atoms which satisfy
the condition of Interaction Potential (Water-Platinum)> Interaction
Potential (Water-Water). If I dump the snapshots of the system, will I be
able to implement my temperature scaling when the force loop runs each time
using another fix?

​of course not. when you use re-run, the trajectory will not change. the
purpose of rerun is to analyze​ a previous run.

Dr. Kohlmeyer, if I use a group command, I guess I will only get the group
interaction potentials and not per atom interaction potential?

​don't guess. that is a very bad habit in science. ​your description of
what you want is quite confusing and you have not provided any additional
explanation or answered my questions.

axel.