compute center of mass for clumped particle

richti83's picture
Submitted by richti83 on Wed, 04/10/2013 - 15:08

Hi,

is it possible to calculate and dump the center off mass for clumped particles ? I tried compute com/molecule and varius dymp-styles but without success. Or is there a post-prozess option in pizza ?

Thanks,
Christian.

cstoltz | Wed, 04/10/2013 - 16:09

Christian,

I'm not sure how to dump it live during a simulation, but I do have a Fortran routine that I wrote a while back that will calculate the center-of-mass and the moment of inertia for a clumped particle. The coding isn't terribly pretty, but it should give an idea of one way to do the post-processing. Will send separately.

Regards,
Chris

NielsD | Thu, 04/11/2013 - 10:11

Hi Christian,

i had the same problem. I used the command fix ave/time. This works because the fix rigid calculates the COM for every timestep and writes it into an global array. The array consists of n_mol rows and 15 colums (x y z vx vy vz fx fy fz omegax omegay omegaz ix iy iz ).

an example:

fix nameOfFix ave/time 2500 1 2500 f_(nameOfTheFixRigid) file FileName.txt mode vector

I hope this is a little help.

Regards Niels