-
Notifications
You must be signed in to change notification settings - Fork 823
Closed
Description
Expected behaviour
Water molecules appear as fragments.
Actual behaviour
Water defined in Gromacs to use the SETTLES algorithm appear as disconnected when read from a TPR as the SETTLES definition is not read as bonds. As a consequence, the atoms appear disconnected.
I assume that the same system appears with water connected when read from any other topology source that will guess the bonds.
@davidercruz noticed the issue, but I think I remember @orbeckst mentioning it some time ago.
Code to reproduce the behaviour
import MDAnalysis as mda
from MDAnalysisTests.datafiles import TPR, XTC
u = mda.Universe(TPR, XTC)
water = u.select_atoms('resname SOL')
print('Number of water atoms', len(water))
print('Number of water molecules', len(water.split('molecule')))
print('Number of water fragments', len(water.fragments))
print('Number of bonds in the water', len(water.bonds))Currently version of MDAnalysis:
(run python -c "import MDAnalysis as mda; print(mda.__version__)")
Reactions are currently unavailable