From: alberto (
Date: Thu Mar 07 2019 - 09:42:48 CST

I'm trying to prepare a script to calculate center of mass of molecules in
trajectory lammps.
I' would obtain a file to calculate RDF with VMD.

set sel [atomselect top all]
set n [molinfo top get numframes]
for {set i 0} {$i < $n} {incr i} {
    set sel [atomselect top all]
    $sel frame $i
    set com [measure center $sel weight mass]
    puts "$com"

can you help me