[lammps-users] deleteing molecules using region/group

Hi Tim

I've included the files. There are two source files in the src/ directory
(fix_cavity.*) and an example input in the cavity/ directory. To add to
your lammps distribution, add the fix_cavity files to the src/ directory,
edit src/Makefile.list and add the .cpp and .h filenames to the
appropriate lines, and finally edit src/style_user.h so that lammps can
use the fix. Change the following lines:

#ifdef FixInclude

#ifdef FixClass


#ifdef FixInclude
#include "fix_cavity.h"

#ifdef FixClass
FixStyle(cavity, FixCavity)

The format for the fix is as follows:

fix [name] [group] cavity [spring constant] sphere [x] [y] [z] [final radius]

so in the example:

fix hole all cavity 5.0 sphere 0.0 0.0 0.0 10.0

grows a spherical cavity centered at the origin, with a force proportional
to 5 kcal/mol/Ang^2, ending with a final radius of 10 Ang. The cavity will
be grown uniformly through the next run.


fix_cavity.tar (200 KB)

Naveen's idea is a good one. However, you will be increasing
the density of water elsewhere in your box, so you would likely
need to run NPT to accommodate the cavity. The new fix
he provided is essentially the existing "fix indent" with a time varying
radius. So I think I would implement it as an option for a 2nd R with
fix indent ...