Problem in compute com

I’m using lammps to calculate position of the center of mass (com) of a polymer chain. The coordinates of the atoms of the polymer are all positive. Besides, the box length is nearly 70A in each direction. However, I get negative values for x coordinate of com, and the z values more than 70A for com:

Commands:

compute comP01 Polymer com
fix comP01 Polymer ave/time 1 500 500 c_comP01[1] c_comP01[2] c_comP01[3] file Polymer.com

Output:

TimeStep c_comP01[1] c_comP01[2] c_comP01[3]

500 -35.7224 35.8898 92.5117
1000 -35.0634 36.3794 92.4888
1500 -34.9073 36.8343 92.7679
2000 -34.7589 37.1734 93.0236
2500 -34.487 37.3728 93.0588
3000 -34.0996 37.5306 93.0176
3500 -33.7963 37.679 93.0585


Upon visualization, I could’t find anything strange. Polymer chain vibrates slightly in the simulation box, as expected.

I appreciate if you can say your opinion about this problem. I’m using lammps/28Jun14. Is there anything I’m implementing wrong?

2014-11-14 5:41 GMT+01:00 Xiaolin Xu <[email protected]...>:

I'm using lammps to calculate position of the center of mass (com) of a
polymer chain. The coordinates of the atoms of the polymer are all
positive. Besides, the box length is nearly 70A in each direction. However,
I get negative values for x coordinate of com, and the z values more than
70A for com:

Probably, your system moved through x and z periodic walls. The com compute
uses unwrapped coordinates. So you'll have to see were this happens (maybe
during equilibration, or you create your system "outside" of the box).

Kristof