delete atoms from dynamic group

Respected LAMMPS users

in my MD simulation i am going to implement graphene growth on 6H-SiC substrate through high temperature annealing process. Within this process on the substrate surface the desorption of Si atoms is modeled by gradually removing unstable Si atoms. In order to simulate it i create dynamic group where atoms with high kinetic energy are put every 100 timesteps and then are deleted (see the part of LAMMPS script below).

Dynamic groups are defined by applying a selection rule to a parent group. Thus if you want to remove atoms from that dynamic group, you could just remove them from the parent.


If I understand, you are wanting to remove
Si atoms from the SURF group when their per-atom
energy is < 0.31. In principle, that should work.

Note that the group doc page explains that
for dynamic groups, the assignment (based on
the PE criteria) is applied at the beginning
of a run and on steps that are multiple of N (100 in your case).
So I don’t think your delete_atoms group command
will do anything.

Since Si_atoms is presumably a static group,
the re-assignment may add or delete
Si atoms to the SURF group. If you want
to only delete, then you should make SURF equal
to the SI_atoms group initially, and make SURF the
parent group in the group dynamic command.

Also, how are you monitoring what is in your SURF group?
I don’t see any commands that use it. E.g. are you
dumping atoms in the SURF group every 100 steps,
with their peratom energy to check that group
membership is correct? Note that the group assignments
are made before force/energy is computed (e.g. on step 300),
so the membership check may not be exact.