Regarding changing the mass of a particular region particles in the restart file

Dear All,
I am simulating a 2D atomic system. In the restart file, i want to change the mass of particles
which belong to a particular region ( or group). I have tried set mass command but get an

error : Cannot set this attribute for this atom style (…/set.cpp:153).

Can LAMMPS do this?

Thanks in advance.

Regards

Dear All,
I am simulating a 2D atomic system. In the restart file, i want to change
the mass of particles
which belong to a particular region ( or group). I have tried *set mass
command* but get an
*error : Cannot set this attribute for this atom style (../set.cpp:153).*

Can LAMMPS do this?

​yes. with most atom styles, the mass is tied to the atom type. so to be
able to change the mass without changing the atom style, you would need to
change the atom type. for that you need to change your input to include an
additional atom type for each type of atom where you want to change the
mass and give it the same potential parameters than they original type.​

​the alternative would be to change the atom style you are using, to one
that supports per atom masses, e.g. sphere (if needed via atom style
hybrid), and then set *all* masses for all atoms for each type manually.​

axel.