[gmx-users] RE:How to check for bad contacts.

Justin A. Lemkul jalemkul at vt.edu
Fri Nov 20 14:15:22 CET 2009

Lum Nforbi wrote:
> Hello Dr. Warren,
> Thank you for the useful information.
> I did use vmd to view my molecule, but in a system of 2000 molecules, it 
> is quite difficult to locate atom 2065 (an O atom) which is actually the 
> offending atom. I have described the way I did the work below. I used a 
> random generator software for starting coordinates. How do you reassign 
> a randomly generated coordinate?

By using a text editor, or finding a different method for generating the 
coordinates.  It is not terribly difficult to parse out the relevant molecules 
in VMD, by using "resid" or "index" specifiers.  See the VMD manual.

> The way I generated my initial coordinates for 2000 water is by first 
> drawing one molecule in ghemical, exported as a .pdb file, then used the 
> command below to add 2000 molecules of water to a box of dimensions 40 A 
> using a software for random coordinate generation called Packmol:
> tolerance 2.0
> output waters2000.pdb
> filetype pdb
> structure water.pdb
>   number 2000
>   inside cube 0. 0. 0. 40.
> end structure
> I then used editconf to change from .pdb to .gro since charmm27, which 
> is the forcefield I use, is not among the force fields displayed when I 
> use the pdb2gmx command.
> editconf -f waters2000.pdb -o waters2000.gro
> This editconf command reduces the previously defined box dimensions to 
> zero. So, I use this command to re-define the box dimensions and I don't 
> know if it is correct:
> editconf -bt cubic -box 4.0 -f waters2000.gro -o waters2000d.gro

This should be fine; I don't know if you might also need to use the -c flag to 
center the system in the box.

> I then minimize the system via grompp and further minimize the system 
> via mdrun, then I get the error message that my system cannot be settled.

You don't minimize with grompp, only mdrun :)

> grompp -f waters_min.mdp -c waters2000d.gro -p water.top -o wmin_.tpr
> mdrun -nice 0 -v -s wmin_.tpr -o wmin.trr -c waters2000d.gro -e 
> wmin_ener.edr
> Output of minimization:
> Steepest Descents:
>    Tolerance (Fmax)   =  1.00000e+03
>    Number of steps    =          500
> Step=    0, Dmax= 1.0e-02 nm, Epot=  4.93923e+14 Fmax= 1.81064e+17, 
> atom= 2035 Step=    1, Dmax= 1.0e-02 nm, Epot=  3.85283e+11 Fmax= 
> 8.96443e+13, atom= 2035
> Step=    2, Dmax= 1.2e-02 nm, Epot=  2.83666e+09 Fmax= 4.79912e+11, 
> atom= 2035
> Step=    3, Dmax= 1.4e-02 nm, Epot=  5.92577e+07 Fmax= 7.02630e+09, 
> atom= 2035
> Step=    4, Dmax= 1.7e-02 nm, Epot=  5.71720e+06 Fmax= 2.14598e+08, 
> atom= 793
> Step=    5, Dmax= 2.1e-02 nm, Epot=  1.46839e+06 Fmax= 2.37662e+07, 
> atom= 4936
> Step=    6, Dmax= 2.5e-02 nm, Epot=  6.41000e+05 Fmax= 2.52111e+06, 
> atom= 3232
> Step=    7, Dmax= 3.0e-02 nm, Epot=  2.73384e+05 Fmax= 5.96696e+05, 
> atom= 3688
> Step=    8, Dmax= 3.6e-02 nm, Epot=  1.64413e+05 Fmax= 1.55972e+05, 
> atom= 2686
> Step=    9, Dmax= 4.3e-02 nm, Epot=  1.09639e+05 Fmax= 3.25690e+04, 
> atom= 2389
> Step=   10, Dmax= 5.2e-02 nm, Epot=  5.32635e+04 Fmax= 2.60651e+04, 
> atom= 2065
> t = 0.022 ps: Water molecule starting at atom 2065 can not be settled.
> Check for bad contacts and/or reduce the timestep.
> Wrote pdb files with previous and current coordinates

The magnitude of the potential and the forces indicates that there should be 
some very obvious atomic overlap in the starting structure.  Visual inspection 
in VMD (see above) should show you what's going on.

The other option that I can think of to build a suitable system is simply to 
make use of genbox and the built-in, pre-equilibrated water boxes that are 
distributed with Gromacs.


> Thank you,
> Lum


Justin A. Lemkul
Ph.D. Candidate
ICTAS Doctoral Scholar
Department of Biochemistry
Virginia Tech
Blacksburg, VA
jalemkul[at]vt.edu | (540) 231-9080


More information about the gromacs.org_gmx-users mailing list