ATB files for moltemplate

Dear lammps users,

I have used ATB (automatic topology builder) to download the .lt files and moltemplate to build diiodomethane with the GROMOS_54A7 force field (https://atb.uq.edu.au/molecule.py?molid=25459#panel-md), everything seems fine with the diiodomethane alone.
Now i would need to add a slab of Ge/Geo2/Si/SiO2 which uses tersoff. I tried from the moltemplate manual but did not fully understood how it is the best way to do that.
I would like to mix the diiodomethane with some slabs which I already have, it is that possible?
Otherwise, do i have to build the slab from a unit cell in .lt style and I also should manually change the force field GROMOS_57A7 to add hybrid in the pair style and also the style for each pair coeff??
In allied the force field file and he geometry of the diiodomethane in .lt format

Kind regards,
Lorenzo

GROMOS_54A7_ATB.lt (65.6 KB)

diiodo_geometry.lt (8.35 KB)

I have used ATB (automatic topology builder) to download the .lt files and moltemplate to build diiodomethane with the GROMOS_54A7 force field (https://atb.uq.edu.au/molecule.py?molid=25459#panel-md), everything seems fine with the diiodomethane alone.
Now i would need to add a slab of Ge/Geo2/Si/SiO2 which uses tersoff. I tried from the moltemplate manual but did not fully understood how it is the best way to do that.
I would like to mix the diiodomethane with some slabs which I already have, it is that possible?

Yes

Whether or not this is a good idea is not clear to me.
Correct me if I'm wrong, but I'm under the impression that force
fields like "tersoff" were intended for shorter timesteps and higher
temperatures. I think the parameter files for tersoff which are
distributed with LAMMPS also assume you are running your simulation
using different physical units (ie "metal" instead of "real"). If you
mix the two types of molecules, then you will be forced to use the
tiny timestep that tersoff requires (which is probably inefficient).
You will also have to convert the numbers in the parameter file used
by tersoff into "real" units (so that distances are measured in
Angstroms, and energies in kCal/mol... OR visa-versa).

   You will also have to define separate "pair_coeff" commands for
every combination of atom types i and j, where atom type i belongs to
diiodomethane, and atom type "j" belongs to your Ge/Geo2/Si/SiO2 slab.
(This is because many-body pair_styles do not support mixing. The
"system.lt" file example mentioned at the end of this email
demonstrates the syntax you would need to use for this task.)

     However, at the lower temperatures that I suspect you will be
running your simulation at, it seems likely that a solid slab of
Ge/Geo2/Si/SiO2 would not change its conformation or even vibrate
significantly. In that case, what's the point of simulating it? Why
not just hold the positions of these atoms rigid, either using "fix
rigid", or simply by omitting them from group of atoms which is acted
on by the fix which integrates the equations of motion. There are
several moltemplate examples which demonstrate different plausible
ways to immobilize slab-shaped objects immersed in solvent. Check out
the "run.in.nvt" and "run.in.npt" files which are part of the
following two examples:

http://moltemplate.org/visual_examples.html#translocation
http://moltemplate.org/visual_examples.html#nanotube+water

    This would be both easier and more efficient.

Regarding your original question:

Yes. It is not too hard to mix pairwise-additive pair_styles such
"lj/gromacs" (used by GROMOS) with a many-body pair_style such as
"tersoff". There is a moltemplate example which mixes "ordinary"
molecules (cyclododecane) with water-like particles which interact
using the "sw" many-body pair_style:

http://moltemplate.org/visual_examples.html#3bodyWater+hydrocarbons

     Additional details for this example are available at the git-hub page:

https://github.com/jewettaij/moltemplate/tree/master/examples/coarse_grained/3bodyWater%2Bhydrocarbons_MW%2BTraPPE/moltemplate_files

When mixing molecules that use different pair_styles, each molecule
(such as "cyclododecane" and "water" in that example) is defined in a
separate .LT file which contains a list of force-field styles
(pair_styles, bond_styles, angle_styles...) and parameters
(pair_coeffs, bond_coeffs,...). Each of these LT files either
contain the actual force-field information (such as the"
diiodomethane.lt" file from ATB I suspect) OR a reference to another
file which contains this information (such as "trappe98.lt" in the
case of "cyclododecane.lt"):

Either way, there will be a clash whenever different molecules (or
materials) require different force-field styles. When this happens,
you can override the pair_style settings in the write_once("In Init")
section of the "system.lt" file. That is the one of the main
functions of the "system.lt" file.

     There is one quirk which has to be mentioned. Both of the LT
files describing either molecule must both use "hybrid" pair styles
(either "pair_style hybrid tersoff", or "pair_style hybrid lj/gromacs
9.0 12.0", in your case), even though they only use one pair_style
each. (This is a quirk of the way LAMMPS does things and is beyond
my control.) However, in the "system.lt" file, you must define the
complete hybrid style for the entire system. ("pair_style hybrid
tersoff lj/gromacs 9.0 12.0", in your case). For reference, here's
the "system.lt" file from the cyclododecane+mw example:

https://github.com/jewettaij/moltemplate/blob/master/examples/coarse_grained/3bodyWater%2Bhydrocarbons_MW%2BTraPPE/moltemplate_files/system.lt
(scroll to the bottom of that file)
Excerpt:

write_once("In Init") {
  pair_style hybrid sw lj/charmm/coul/charmm 9.0 11.0 9.0 11.0
}

(The two pair_styles being used are "sw" and "lj/charmm/coul/charmm
9.0 11.0 9.0 11.0")

Otherwise, do i have to build the slab from a unit cell in .lt style and I also should manually change the force field GROMOS_57A7 to add hybrid in the pair style and also the style for each pair coeff??
In allied the force field file and he geometry of the diiodomethane in .lt format

You could also try that, holding each atom in the slab with a network
of bonds between nearest neighbors. However I have no idea what kind
of bonds you should use and no reason to believe doing it that way
would result in more realistic motion than just immobilizing the atoms
in the slab.

I hope this helps.

Cheers

Andrew

correction. the unit of time in metal units is picoseconds, not
femtoseconds. hence the small numbers. and tersoff potentials are
often used at higher temperatures, since they are a good choice for
materials like diamond or crystalline silicon or mixtures of those,
which are then more often studied at elevated temperatures, but this
doesn't have to be. nanomachining studies for example are performed at
room temperature (although local temperatures may be high due to
deformation). timesteps for these simulations are around 1fs.

axel.