Difference between Unwrap=True & Unwrap=False

190 views
Skip to first unread message

Mahesh Yadav

unread,
May 6, 2022, 3:42:02 AM5/6/22
to MDnalysis discussion
Hi guys,

I'm calculating center of mass using MDAnalysis with unwrap=True, but by looking at the output trajectories it seems something wrong is going on! The trajectories should be continuous, no jumps in between. I've tried unwrap=False as well, but trajectory looks the same. Please look at the attached trajectory plot. Does anyone faced the same problem? How it can be corrected? 

Here is code line:

seg.atoms.center_of_mass(unwrap=True, compound='fragments')

Thanks!!
lp75.pdf

Oliver Beckstein

unread,
May 6, 2022, 12:41:18 PM5/6/22
to mdnalysis-discussion
Hi Mahesh Yadav,

unwrap=True will not make your trajectories continuous (it will not do a “no jump” transformation). As the center_of_mass() docs say, it affects how the COM is calculated. We use “unwrap” to mean “unwrap a molecule so that it is whole across periodic boundaries” and NOT "unwrap trajectory to prevent any jumps due to PBC” — I refer to the latter as “nojump” but the semantics probably differ between different MD packages and authors. 

I don’t think that we currently have a real multiple nojump transformation — that’s actually tricky business and it would be cool if someone wanted to work on it. There have been various recent developments on how to do this in a sensible manner, especially for NPT simulations, see e.g. https://doi.org/10.1063/5.0008316 or  https://arxiv.org/abs/2111.12052 (That preprint also calls the “nojump” transformation “unwrapping”.)

Oliver
--
Oliver Beckstein (he/his/him)

GitHub: @orbeckst

MDAnalysis – a NumFOCUS fiscally sponsored project





Reply all
Reply to author
Forward
0 new messages