[lammps-users] feature request

Hey Steve;

It seems like you can’t easily get the mass of the entire simulation from LAMMPS (please correct me if I’m wrong here). It seems like the ability to write out the bulk mass using thermo_style would be a natural addition since you can already write out the volume. Yes I know this is absurdly simple, but it just ‘feels’ like it should be there (and I’m super lazy). Let me know what you think.

-AdamC

Hey Steve;
It seems like you can't easily get the mass of the entire simulation from
LAMMPS (please correct me if I'm wrong here). It seems like the ability to
write out the bulk mass using thermo_style would be a natural addition since
you can already write out the volume. Yes I know this is absurdly simple,
but it just 'feels' like it should be there (and I'm super lazy). Let me

adam,

it is already. have a look at compute property/atom and compute reduce.

cheers,
   axel.

Thanks Axel, and yes that is pretty straight forward but it seems like there is this really nice command (thermo_style) for getting at 99% of the raw properties of your simulation but you’re unable to get the mass.

-AdamC

Thanks Axel, and yes that is pretty straight forward but it seems like there
is this really nice command (thermo_style) for getting at 99% of the raw
properties of your simulation but you're unable to get the mass.

you can output _any_ compute through thermo style.

use compute property/atom and compute reduce to
compute the total mass and then c_<compute id>
to output it.

viola,
   axel.

Yes, I understand, I was just suggesting the use of a ‘mass’ keyword to go with the ~30 other keywords available. Of course now this feels horribly nit-picky…

-AdamC

Try this:

variable m equal mass(all)
thermo_style custom step temp v_m

You can get many group properties this way, see the variable doc page
for details.

Steve