Monday, 26 November 2012

PM6 in GAMESS, Part 3, a new file is introduced

Good news and bad news. After working with a fortran 77 file called mndod.F and mopac 7.1 (First mopac Fortran 95 version) for a while, it seemed like a lot of subroutines was missing in this old file. So recently we wrote James Stewart (Mr. Mopac) asking for potential missing files (with the missing subroutines).  James, luckily enough, instead of finding more files for us, found a updated version of the mndod.F file with the missing subroutines.

This was great, but it also meant I had to start over with respect to mapping and compiling of this file.

The mndod.f, for historical purpose, is the d-integrals from the old mndo-d method (created by Walter Theil), and then converted to work with MOPAC from version 7+, for AM1-D and on.
To follow the naming convention of GAMESS file structure, this holy file will now be known as mpcintd.src (because, yeah, d-integrals).

So I started over with mapping (see figure above), fixing compile errors, updating and deleting common blocks. This would not be possible without the source from Mopac 7.1 (available on, because the new mndod.f file lacked a lot of comments and documentation, referencing to unknown common-blocks and subroutines.

This was a lot of work, but still faster than rewriting mopac 7.1, because this version of mopac uses interfaces and modules, and so a lot of subroutine headers would need to be written before I could compile it, yet alone test it. No Thanks.

After working a weeks time on implementing the new code/subroutines, the result is now I get the correct nuclear repulsion term, but I do not get the correct electronic energy. This results in correct 'NUCLEAR ENERGY' (gamess output), but incorrect electronic energy, and therefore incorrect Heat of Formation.

Update list from last blogpost;

Step 1: Get mndod.f90 compiled with gamess
Step 2: Integration: Make IF(PM6) and mndod code instead of gamess with pm6 parameters and more
Step 3: Integration: Make IF(PM6) and run fock-d 1 and 2 in mpcg()
Step 4: Find out why it does not work and solve the problem
Step 5: Celebration

Clearly on step 4, trying to make it work.

Stay tuned for the dramatic conclusion of implementation of PM6 in GAMESS!


  1. Excellent story, I'm on tenterhooks waiting to see how your implementation of PM7 turns out! ;-)

  2. Hi,
    I've tested the PM6 implementation in GAMESS and it works quite fine, except... That in the version I have, the d-orbitals seem to be missing and therefore molecules such as thiophene are not well described.
    Is there a bugfix available? Or did you abandon the project?
    Thanks a lot!