question about group dynamic

Dear all

I would try this first by writing logic like:

run N
define the group you want
velocity command on the group
run N
repeat

If you can get that to work, then you could put
the commands into a loop. Or perhaps you
could use them with the “run every” option of
the run command.

To define the group you want (random subset of
another group), I suggest you look at atom-style
variables. There is a random # generator, and
a group operator (select atoms in a group), so
you can write a boolean atom-style variable
that selects a random subset. The group command
lets you clear an existing group and assign again
to it using the group variable option.

Steve

Dear Steve
Thanks a lot

I will try what you suggest and keep you informed.
More precisely, I wish to select randomly one atom in a defined group, change its velocity at this time, and repeat such an event every N timesteps. So I will apply the velocity for each selected atoms only once. These atoms with new velocities will interact with other atoms in the simulation box until end of the simulation.
Regards
Pascal