use the the variable command to flag specific atoms to exclude from a group

Submitted by zpy2021 on
zpy2021

this command do can not to exclude the particles, and I used the run every command to achieve my goals, thank you!

Tue, 19 Jan 2021 - 09:00 Permalink

Dear LIGGGHTS users!
I want to use the variable command to include and exclude the specific particles from a group, and I used the similar commands like that in the Docs as following:

compute 1 all pe/atom
compute 2 all reduce sum c_1
thermo_style custom step temp pe c_2
run 0
variable eatom atom "c_1 > -3.0"
group hienergy variable eatom

But there is a problem that the number of the particles in the group is not update between runs, so I wonder that if this command can be used to include particles only or it can do both include and exclude???