LAMMPS WWW Site - LAMMPS Documentation - LAMMPS Mailing List Archives
Re: [lammps-users] fix rigid/npt with triclinic
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lammps-users] fix rigid/npt with triclinic


From: Axel Kohlmeyer <akohlmey@...24...>
Date: Mon, 28 Aug 2017 14:38:00 -0400



On Mon, Aug 28, 2017 at 2:28 PM, Wes Barnett <w.barnett@...6288.....> wrote:


On Mon, Aug 28, 2017 at 12:14 AM, Trung Nguyen <ndactrung@...24...> wrote:
Hi Wes,

it's possible to support triclinic boxes for fix rigid/npt and rigid/nph either by following the reference cited the fix rigid doc (Kamberaj et al), or by borrowing what is implemented in fix nh for updating the full box dimension tensor.

However, please note that fix rigid/npt and rigid/nph with triclinic boxes would be mostly useful for the cases where you only have rigid bodies in the system. For systems of polymer-grafted rigid bodies like yours, I think the workaround along the line Axel suggested would work to the similar effect:

# assuming you're having a triclinic box setup

group nanoparticles type 1
group tethers type 2
fix 1 nanoparticles rigid/nvt temp ...
fix 2 tethers npt temp 1.0 1.0 1.0 xy 1.0 1.0 10.0 ...  dilate all
fix_modify 2 press thermo_press

The reason that it would work is that the simulation triclinic box is to be barostatted by the fix npt, which uses the system pressure tensor as feedback.


Thanks Axel and Trung, this helps. I now see that this method is one of the options listed on the "fix rigid" page for using pressure coupling with a mixture of rigid and non-rigid molecules.

Is the thermo_press compute modification (the last line) always necessary in a system like this?

​it is a case of "better safe than sorry". you can have only one fix changing the cell shape and volume, and that has to be coupled to the complete system pressure. that is usually for group all, i.e. what the thermo press keyword outputs. that should be done correctly by the npt or nph fix, but there is no harm in making it explicit.

i would be careful with dilate all. it can mess up your rigid body geometries if you run multi-part trajectories. if your system is large enough and the pressure fluctuations small enough (and the damping constant long enough), then it may be better to not update particle positions with the box change. this a "lesser of two evils" kind of situation.

​axel.​

 
That's one step I did not see on the "fix rigid" page's section on how to use pressure coupling with a system containing both rigid and non-rigid bodies.

--
James "Wes" Barnett
Postdoctoral Research Scientist
Department of Chemical Engineering



--
Dr. Axel Kohlmeyer  akohlmey@...92......  http://goo.gl/1wk0
College of Science & Technology, Temple University, Philadelphia PA, USA
International Centre for Theoretical Physics, Trieste. Italy.