Project

General

Profile

Bug #179

Bonded potentials in 3.3.2 vs. 3.3.1

Added by Amadeu empty about 12 years ago. Updated almost 12 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Erik Lindahl
Category:
mdrun
Target version:
Affected version - extra info:
Affected version:
Difficulty:
uncategorized
Close

Description

Created an attachment (id=259)
tpr file, created with grompp 3.3.1

I have come across a potential bug in the latest Gromacs version (3.3.2) for the
simulation of a CNT. I noticed that the bonded energies calculated with 3.3.2 are quite different compared to those from 3.3.1 (see resulting output below). I tried another case for a system with harmonic bond and angle potentials, and the bonded energies were identical for both versions, which makes me believe that the Morse and G96Angle potentials are somehow different in 3.3.2. Perhaps the one source for the problem may be how these potentials are being calculated under FULL pbc. This test case was for an infinite CNT.

Initial set of energy obtained from the SAME tpr file (grompp'ed with 3.3.1). Both output were obtained with the single precision versions.

Output from Gromacs-3.3.2:
Energies (kJ/mol)
Morse G96Angle Proper Dih. LJ (SR) Disper. corr.
5.78994e+03 1.44076e+04 5.47403e+02 -1.57601e+02 -2.46982e+01
Coulomb (SR) Potential Kinetic En. Total Energy Temperature
0.00000e+00 2.05627e+04 3.32197e+01 2.05959e+04 1.11447e+01
Pressure (bar)
-3.06280e+02

Output from Gromacs-3.3.1:
Energies (kJ/mol)
Morse G96Angle Proper Dih. LJ (SR) Disper. corr.
4.38162e+01 4.15264e+01 5.53398e+02 -1.57601e+02 -2.46982e+01
Coulomb (SR) Potential Kinetic En. Total Energy Temperature
0.00000e+00 4.56441e+02 9.54848e+00 4.65990e+02 3.20338e+00
Pressure (bar)
-5.04502e+02

I am attaching the tpr file. I also tried by creating the trp with the respective grompp version and the same output resulted. There were no errors or warnings when I ran grompp to create the trp file.

Both Gromacs distributions (3.3.1 and 3.3.2) were compiled in a Linux x86_64 system: single precision, gcc 3.4.6. After compilation, the 3.3.2 version was checked by performing all the test cases and all returned normally.

qa_s331.tpr (158 KB) qa_s331.tpr tpr file, created with grompp 3.3.1 Amadeu empty, 11/18/2007 06:53 PM
pbc.c (19.4 KB) pbc.c FIxed version of pbc.c David van der Spoel, 11/19/2007 02:45 PM

History

#1 Updated by David van der Spoel almost 12 years ago

This is definitely a periodic boundary problem. I have reproduced it in 3.3.2, whereas it works in 3.3.1 and in 4.0beta.

#2 Updated by David van der Spoel almost 12 years ago

Created an attachment (id=260)
FIxed version of pbc.c

This fixes the problem.

#3 Updated by David van der Spoel almost 12 years ago

The bug is fixed by replacing src/gmxlib/pbc.c by the uploaded version, which is also in CVS now. This bug was introduced in 3.3.2 in order to fixe a compiler problem!

Also available in: Atom PDF