[gmx-users] trjconv, pbc and breaking of multiple peptides

ms devicerandom at gmail.com
Wed Nov 10 23:23:01 CET 2010

On 10/11/10 21:34, Justin A. Lemkul wrote:
> ms wrote:
>> On 09/11/10 21:36, Justin A. Lemkul wrote:
>>> There are numerous -pbc options with trjconv; have you tried others? I
>>> have never had luck with -pbc nojump actually working, and -pbc atom
>>> provides no guarantee that molecules will be properly reconstructed.
>>> Using -pbc mol -center is often a much better approach, in my
>>> experience.
>> I spoke too soon. -pbc mol -center doesn't indeed break molecules, but
>> it doesn't seem to always work correctly -I evidently continue to have
>> frames where the system is obviously not centered correctly in the
>> box, so even if I have a compact conglomerate of my molecules, the
>> calculated gyration radius is artificially large (In fact, I
>> discovered the issue by looking at the frames with large gyration
>> radiuses).
>> I am sure it doesn't work correctly because if I visualize the system
>> in VMD, enabling periodic copies I see the correct (compact) structure
>> at the corners between boxes. - I can provide pictures if needed.
>> Any idea on how to proceed? I am quite lost. I wouldn't like to
>> rewrite g_gyrate by myself :)
> I presume you're centering on "Protein" in this case?

Yes, sorry for not making it clear.

> You can create a
> custom index group (perhaps towards the center of one of your peptides)
> and center about it. The -center function will locate the center of mass
> of the chosen group at the center of the box, so, in a simple case (i.e.
> a dimer) you would have two peptides at the corners, but the center of
> mass still located at the box center. Choosing one residue of one of the
> monomers has, in my experience, solved this issue when centering about
> Protein has not worked.

I don't get it.

First, let me see if I understand it correctly. From your explanation 
(and intuition), it seems that the issue is that "center of mass" in a 
periodic environment is ambiguous -there are always (at least) two 
alternate configurations that have the center of mass at the center of 
the box any time, and -center doesn't necessarily choose the most 
compact one (i.e. the one where the box center is closest on average to 
atoms). So, for example, in a 1-D periodic environment, this:

... O|O      O|O ...

is equivalent to this

|   OO   |   OO  ...

the center of mass between the O's being always at the center of the box 
in both cases.

But I don't see how choosing one residue could help -I mean, the 
residues wander practically everywhere in the box during the simulation 
and none of them is privileged ; I don't see why centering only around 
one would be better. It could help if they were only two, but we talk of 
eight objects here (and possibly many more in the future)...

...now I see it: You mean that, since I force to center around one of 
the objects, and if on average it should belong to the cluster, the 
whole thing should be more often than not within the box?

I'm going to try; meanwhile let me know if I got it right (and just in 
case, I wonder how much work is to patch trjconv to "choose" the "right" 
center of mass -I guess it's similar to what -pbc cluster does? I never 
fully understood that option)


Massimo Sandal, Ph.D.

More information about the gromacs.org_gmx-users mailing list