[lammps-users] About time-dependent velocity


I want to assign a time-dependent velocity on atoms, making the atoms vibrating with time. Part of the commands are as follow:

variable vz equal 100sin(0.00628step)
thermo_style custom step temp press etotal
velocity rightedge set NULL NULL v_vz units box

But it turned out atoms in group “rightedge” were not assigned with expected velocities. Could anybody help me out?
Thanks a lot for help!

Best Regards,
Zenan Qi

College of Engineering
Boston University
8 Saint Marry Street
Boston, MA, 02215

The velocity command is a one-time operation that occurs
when the input command is read. If you want to reset
the velocities continually during a run, then you
want the fix move command. It also allows for a variable
to be used with a velocity setting.