4.3 Gromacs
The simulation program Gromacs bases on algorithms for flexible models, mainly applied for bio-systems. Since the MMBZS database mainly contains rigid molecular models, the proposed force fields are only partially applicable for Gromacs. Rigid models are constructed by using workarounds such as bond and angles constrains. The introduction of these constraints is only possible for models with less than four interaction sites. The database therefore only provides Gromacs input files for such molecular structures. Furthermore, it should be noted that Gromacs distinguishes between two types of interaction sites:
-
The interaction site
can be Lennard-Jones and/or Coulomb point charge interactions and have a mass. -
The virtual site
can be Coulomb point charges and have no mass.
Neither point dipoles nor point quadrupoles can be modeled in Gromacs explicitly. Therefore, point dipoles and point quadrupoles are modeled by using point charges that reproduce such dipoles and quadrupoles. This procedure is described in section 3. The point charges are introduced using virtual sites.
The structure and content of the Gromacs input files provided by the MMBZS database are described in the following. The input file for a single molecular model is separated into four individual files for the sake of simplicity and to avoid a large and cluttered input file. Each of the four individual files has a separate task:
-
forcefield.itp
Defines the type of interactions between similar and differently parameterized interaction sites. -
atomtypes.atp
Lists all sites used in the force field model and additionally gives the mass of these interaction sites. -
*.itp
Defines the topology of the models and thus indicates the relative position of the sites to each other. -
*.pdb
Contains the coordianes of all sites for a single molecule in pdb format, which can be used to visualize
the model, for instance in VMD, and to generate a simulation box using the "genbox " tool in gromacs.
In the following, the structure of the individual files is described
in more detail, with special attention on the implementation of
rigid models in Gromacs. In general, Gromacs input files are divided
into sections. The name of each section is define using brakets.
Then, each line within a section defines a set of parameters of the
model. Since several parameters are defined per line, the name or
purpose of a parameter is given in a comment line below the name of
the section for the sake of clarity. A comment is indicated by a
semicolon "
forcefield.itp File
The
-
"
nbfunc "
Defines the type of interaction used to model the dispersive and repulsive interactions. Two interaction types are available: Lennard-Jones ("1" ) and Buckingham ("2" ). For all models of the database this parameter is set to: "1 ". -
"
comb-rule "
Defines the calculation of the interaction parameters for the interaction between two unlike sites, i.e. the combination rule. To use the convention already introduced in section 3, this parameter is set to: "2 ", which means that the Lorentz-Berthelot mixing rules are applied. -
"
gen-pairs "
Specifies whether certain interactions between two unlike interaction sites are to be specified manually, thus modifying the existing convention for certain interaction pairs. This results in the values "yes " and "no " for this parameter. Since a convention for interactions between two unlike interaction sites has already been made, this parameter is set to: "no " for the files provided here.
These general settings are identical for each model of the database
and therefore the input file "
[ defaults ] ; nbfunc comb-rule gen-pairs 1 2 no
atomtypes.atp File
The input file
A1 #Mass_of_interaction_site_A1 A2 #Mass_of_interaction_site_A2 . . . . . . An #Mass_of_interaction_site_An VS1 #Mass_of_virtual_site_VS1 VS2 #Mass_of_virtual_site_VS2 . . . . . . VSm #Mass_of_virtual_site_VSm
*.itp File
- Lennard-Jones interaction parameter
- charge
- mass
- Type of the site
After the individual sites are fully specified, the molecular model
is defined under the section "
In this section, the individual sites are specified by setting the following parameters for each site:
-
name
The name assigned to the interaction site in the input file \texttt{atomtypes.atp}, this name serves as reference which site is defined in this line. -
bond_type
This tag define the bonds that the site can form, but since only rigid models are provided here, this tag is not used. -
ptype
This parameter indicates whether the interaction site is an interaction site of type (A ) or a virtual site (D ) -- see above. -
mass, charge , LJ-parameter (sigma, epsilon )
These parameters define the molecular interactions of the site.
For each site, the parameters listed above are defined in the order shown in the Figure below, with the parameters separated by at least one space. Note that each site is defined in a separate line.
name bond_type mass charge ptype sigma epsilon
After the individual interaction sites have been specified, a
molecule is defined in this section that consists of the sites
defined above. First, the molecule is named , followed by an
integer.
The integer defines the number of bonds or constraints below which
non-bonded interactions within a molecule are excluded. For instance,
a three indicates that all non-bonded interactions between sites
separated by three or less bonds are neglected.
Since the database only consists of rigid molecular models, this
integer is set to a large number so that no internal interactions
are considered. In the case of n interaction sites, the number is
set to
[ moleculetype ] moleculename n-1
The individual atoms of the molecule are specified in the section
"
-
nr
Internal molecule reference number for each atoms -
type
This parameter is used to describe the interaction properties of the atom. This is achieved by setting this parameter to the name of the interaction site already defined in the "atomtypes " section. -
resnr, residue, cgnr
These parameters can be used to define further substructures like functional groups. The input files provided by the MMBZS database does not use this feature, whereby these parameters have the same value for each atom (resnr = 1, residue = MOD, cgnr = 1 ). -
atom
This parameter generally describes which physical part of a substance is modeled by this site. -
charge, mass
These parameters adjust the corresponding interaction properties of the atom. In the case of the input files provided by the MMBZS database no further adjustments are needed, thus these parameters are identical to those of the corresponding interaction sites.
[ atoms ] nr type resnr residue atom gnr charge mass
After the atoms of the molecule have been defined, the topology of the molecule is now defined in the following sections. First, the relative arrangement of the atoms described by an interaction site is defined. In the second step the relative position of the virtual sites is described based on the interaction sites. The definition of the position of the interaction sites is analogous to the Z-Matrix representation, where distances and angles between the sites are given.
In the section "
[ constraints ] #site_1_nr. #site_2_nr. 1 #distance
If, however, the number of interaction sites is greater than two,
additional bond angles must be defined, which must also be kept
constant over the entire simulation. To keep the bond angle
constant, the option "
Defining an angle is similar to the definition of sites and is done
in two steps. First, the type of the angle has to be specified. This
is done after the section "
The definition of the angle is done by five parameters. The first
three parameters indicate the sites between which the angle is
located. The names of the interaction sites are used for
referencing. This procedure is analogous to the Z-Matrix. The next
parameter defines the function that describes the bond angle
potential, at this point the option "
[ angletypes ] ;i j k func th0 cth A1 A2 A3 1 57.4074 1000.000
After the positions of the interaction sites have been defined, the
positions of the atoms corresponding to virtual sites are specified
in the section "
Since the models of the database are rigid models, intramolecular interactions must be switched off in Gromacs. This section describes how to exclude intramolecular interactions between atoms by using the internal reference numbers of the atoms. Since all molecular interactions are to be excluded, all interactions with the other atoms must be excluded for each atom. Thus the following scheme results, if the number of sites is $n$:
[ exclusions ] 1 2 3 ... n 2 1 3 ... n . . . . . . . . . . . . . . . n-1 1 ... n-2 n n 1 2 ... n-1
*.pdb File
The
MODEL: #model_name CRYST1 #heigth #width #depth 90.00 90.00 90.00 ATOM 1 A1 MOD 1 #x #y #z ATOM 2 A2 MOD 1 #x #y #z . . . . . . . . . . . . . . . . . . . . . . . . ATOM n An MOD 1 #x #y #z ATOM n+1 VS1 MOD 1 #x #y #z . . . . . . . . . . . . . . . . . . . . . . . . ATOM n+m VSm MOD 1 #x #y #z
In the first line, "
This is shown schematically in the figure below, where the lengths of the information and the spaces are indicated by square brackets:
MODEL: #model_name [10] | [3] | [6] | [3] |[6]| [3] |[4]| CRYST1 |#heigth| |#width| |#depth| | 90.00 90.00 90.00 [6] | [5] | [4] |[1]| [3] |[1]|[1]| [9] | [8] | [8] | [8] | ATOM | 1 | A1 | | MOD | | 1 | | #x | #y | #z | . . . . . . . .
Example
The 'C2H4 I'-model published by Vrabec et al. in [Vrabec, 2001] is taken as an full example for the Gromacs input files provided by the MMBZS database. Note that the point quardupole of the original model was converted into point charges, since the Gromacs simulation program cannot handle point quardupoles explicitly. The input files of this model for the simulation program Gromacs has than the following form:
[ defaults ] ; nbfunc comb-rule gen-pairs 1 2 no
A1 14.027 A2 14.027 VS1 0 VS2 0 VS3 0
; rigid model: use the option "all-angles" *.mdp file [ atomtypes ] ; name bond_type mass charge ptype sigma epsilon A1 A1 14.0270 0.00000 A 0.37610 0.63980 A2 A2 14.0270 0.00000 A 0.37610 0.63980 VS1 VS1 0.00000 12.7515 D 0.00000 0.00000 VS2 VS2 0.00000 -25.5030 D 0.00000 0.00000 VS3 VS3 0.00000 12.7515 D 0.00000 0.00000 [ moleculetype ] C2H4_I 1 [ atoms ] ;nr type resnr residue atom cgnr charge mass 1 A1 1 MOD A1 1 0.00000 14.0270 2 A2 1 MOD A2 1 0.00000 14.0270 3 VS1 1 MOD VS1 1 12.7515 0.00000 4 VS2 1 MOD VS2 1 -25.5030 0.00000 5 VS3 1 MOD VS3 1 12.7515 0.00000 [ constraints ] ; fixed bond length ; d (nm) 1 2 1 0.12700 [ exclusions ] 1 2 3 4 5 5 1 2 3 4 4 5 1 2 3 3 4 5 1 2 2 3 4 5 1 [ virtual_sites2 ] ; Vsite from to funct a 3 1 2 1 0.64811736904293 4 1 2 1 0.5 5 1 2 1 0.35188263095707
MODEL: C2H4_I CRYST1 1.0 1.0 1.2 90.00 90.00 90.00 ATOM 1 A1 MOD 1 0.000 0.000 -0.634 ATOM 2 A2 MOD 1 0.000 0.000 0.634 ATOM 3 VS1 MOD 1 0.000 0.000 0.188 ATOM 4 VS2 MOD 1 0.000 0.000 0.000 ATOM 5 VS3 MOD 1 0.000 0.000 -0.188