[lammps-users] Constraining molecules with respect to z axis of simulation box?

Dear LAMMPS community,
I would like to know if there is any method to constrain molecules with respect to specific axis of simulation box. In my case, I would want to penalize flip-flopping of a group of lipids. So it would be great if I can constrain the angle which lipids make with the z axis of simulation box. Let me know if there is any fixes or methods to achieve this.

Thank you.

Dear LAMMPS community,
I would like to know if there is any method to constrain molecules with respect to specific axis of simulation box. In my case, I would want to penalize flip-flopping of a group of lipids. So it would be great if I can constrain the angle which lipids make with the z axis of simulation box. Let me know if there is any fixes or methods to achieve this.

I am not aware of an existing feature of LAMMPS that can do this. You are welcome to implement it and contribute it.

As for using existing features, the question is: how strongly do you want to manipulate the system. Rather than acting on the whole molecules (which has issues when running in parallel with many MPI ranks), you could just implement something that acts only on some selected atom in the head and the tail(s) of the lipids. You could define a group for each of those and then apply fix spring/self to restrict their movement in z-directions (that would be rather drastic). or you could then apply a harmonic wall selectively to each group of those atoms so they cannot move beyond a given threshold and are softly repelled, you you can define a region in the center area of the lipid layer and then apply fix oneway for each group to flip the atom’s velocity one they enter that zone (which can be rather subtle if the lipids are long and the region can be set up so that the selected head or tail atoms rarely reach it).

Axel.

Thank you Dr. Axel for the detailed reply with suggestions.