Hi Jeffrey
There's an example how to build a simple water box for lammps of any
size in chapter 3 of the manual for "moltemplate" (moltemplate.org).
I know I mentioned it to you before. Anyway here's a quick summary:
You need to define a "lammps template" for each molecule that you
need. For SPC/E, it has been done for you. The SPC/E water molecule
definition is here:
http://www.moltemplate.org/examples/waterSPCE+Na+Cl/spce.lt
You can use this file to build a box of water (or a combination of
water and other molecules). In the example from the manual, we
created a new file (for example "system.lt") containing this text:
# ----- system.lt -------
import "spce.lt"
wat = new SPCE [10].move(0,0,3.45)
[10].move(0,3.45,0)
[10].move(3.45,0,0)
write_once("Data Boundary") {
0.0 34.5 xlo xhi
0.0 34.5 ylo yhi
0.0 34.5 zlo zhi
}
# ------------
That's it.
Then you can generate the DATA and input-script files that you need
to run LAMMPS using:
moltemplate.sh system.lt
These files contain a complete description of your system including
force-field parameters, topology information, and coordinates.
(This will generate a 10x10x10 cubic water box example. This (3.45
A)^3 initial spacing between water molecules seems to work reasonably
well, but it's a little too dense. You will have to run the system at
constant pressure for a short while to equilibrate the volume, and
randomize the molecular positions. The following LAMMPS input script
does this reasonably well:
http://www.moltemplate.org/examples/waterSPCE+Na+Cl/run.in.npt
This input script includes files which were created when you ran
moltemplate.sh above.)
Solute & water mixtures:
By editing your ".LT" file, you can also cut out (rectangular) holes
in the solvent to make space for solutes or other objects manually
using the "delete" command:
(For an example, see:
http://www.moltemplate.org/images/translocation/solvent.jpg
http://www.moltemplate.org/examples/translocation/solvent.lt)
(If you have many such solutes, you can create a new "object", which
is functionally similar to a molecule, however the atoms in it do not
have to be bonded together. Each object contains a solute molecule as
well as the water molecules surrounding it. Then you can stack them
together the same way you stacked individual water molecules together
above. To do this, just surround the text which defines this object
with {} brackets. Your "system.lt" file would look something like
this:
import "wat.lt"
import "solute.lt"
UnitCell {
wat = new SPCE [4].move(3.45,0,0)
[4].move(0,3.45,0)
[4].move(0,0,3.45)
delete wat[1-2][1-2][1-2] # 2x2x2 hole for solute
solute = new Solute.move(5.175,5.175,5.175)
}
cells = new UnitCell[3].move(13.8,0,0)
[3](0,13.8,0)
[3](0,0,13.8)