Appendix: Generating a Force Field

Note

The scripts for this step in the tutorial can be found in mgo_surface/mgo_fit.

This tutorial will show you how to manually generate a force field for use in MM calculations. This is only relevant if you do not have a suitable forcefield to work with in your QM/MM calculations.

We will use GULP to generate our forcefield. We need the following information about our system:

  • Cell parameters

  • MgO structure in fractional or Cartesian (must be specified)

  • Species (core/shell and charge)

  • Starting guess for force field

All of this information is then structured in an input file with file extension .gin, e.g. input.gin. A full example file is shown below:

fit conp prop simul opti
cell
4.212000 4.212000 4.212000 90.000000 90.000000 90.000000
fractional
Mg   core  0.00000000   0.00000000   0.00000000
Mg   core  0.00000000   0.50000000   0.50000000
Mg   core  0.50000000   0.00000000   0.50000000
Mg   core  0.50000000   0.50000000   0.00000000
O    core  0.50000000   0.50000000   0.50000000
O    core  0.50000000   0.00000000   0.00000000
O    core  0.00000000   0.50000000   0.00000000
O    core  0.00000000   0.00000000   0.50000000
O    shel  0.50000000   0.50000000   0.50000000
O    shel  0.50000000   0.00000000   0.00000000
O    shel  0.00000000   0.50000000   0.00000000
O    shel  0.00000000   0.00000000   0.50000000
species
Mg    core    2.000000
O     core    0.869000
O     shel   -2.869000
buck
O    shel Mg   core    1295.553402 0.300000    0.00000  0.000 12.000 1 1 1
buck
O    shel O    shel   22764.000000 0.149000   27.88000  0.000 12.000 1 1 1

The first line of this input file dictates the type of calculation being run and should be kept the same in most cases:

  • fit means that the forcefield will be fitted, rather than the system altered

  • conp ensures fitting is down under constant pressure conditions

  • prop allows evaluation of system properties once completed

  • simul provides simultaneous fitting and coordinate optimisation

  • opti is necessary to also perform the unit cell optimisation

After this line, most of the file is specific to your system. Line three are the cell parameters in the order A (length of cell side A), B (length of cell side B), C (length of cell side C), \(\alpha\) (angle between X and Y), \(\beta\) (angle between X and Y) and \(\gamma\) (angle between X and Y).

To specify fractional and Cartesian structures, the next line in the script should read fractional or Cartesian respectively. Following the format Atom, core/shell, X, Y, Z, input your structural data immediately below.