[gmx-developers] Off-by-one error in pbd2gmx
Berk Hess
gmx3 at hotmail.com
Wed Apr 3 11:29:47 CEST 2002
>
> While creating a GRO file and topology from a PDB file
>with "pdb2gmx -f hr.pdb -o hr.gro -p hr.top -dummy hydrogens"
>and the GROMOS96 43a1 force field I got the following
>warnings:
>
>WARNING: atom CD is missing in residue LEU 26 in the pdb file
>WARNING: atom CE is missing in residue LEU 26 in the pdb file
>WARNING: atom NZ is missing in residue LEU 26 in the pdb file
>WARNING: atom CE is missing in residue TYR 42 in the pdb file
>WARNING: atom NZ is missing in residue TYR 42 in the pdb file
>WARNING: atom OD1 is missing in residue PHE 50 in the pdb file
>WARNING: atom OD2 is missing in residue PHE 50 in the pdb file
>WARNING: atom CG is missing in residue ASN 99 in the pdb file
>WARNING: atom OD1 is missing in residue ASN 99 in the pdb file
>WARNING: atom ND2 is missing in residue ASN 99 in the pdb file
>
>
> In the PDB file lysine 25 is indeed missing its CD, CE and NZ
>atoms, but the program is reporting leucine 26, the next residue
>in the chain. Likewise for the other residues.
>
> I figure there is some kind of off-by-one error in the
>functions "missing_atoms" or "name2type" in src/kernel/pdb2top.c.
I found the problem. An index to the next residue was passed to
missing_atoms which prints the warning. It will be fixed in the
next release.
Another question is if this should be a warning or an error message.
In this case a topology will be generated where some atoms are not
present. My opinion is that pdb2gmx should generate a fatal error
after printing all the missing atoms.
Thanks for the bug report,
Berk.
_________________________________________________________________
Chat with friends online, try MSN Messenger: http://messenger.msn.com
More information about the gromacs.org_gmx-developers
mailing list