Periodic Rotation Application

Submitted by NSalloum on Sun, 12/23/2018 - 11:38

hello,

Is there a way in which I can apply a periodic rotation for my mesh in LIGGGHTS ?
Like rotating a drum by 90°->keeping it in rest for a certain time->rotating it further by 90°, and so on.

best wishes

arnom's picture

arnom | Mon, 01/14/2019 - 11:19

You can write loops such as


variable number_rotations equals 0
label start_loop
fix rotate all move/mesh my_mesh rotate ...
run XXX # XXX should be equal to the number of time steps taken to rotate 90 degress
unfix rotate
run YYY # YYY equal to the rest time steps
variable number_rotations equals ${number_rotations}+1
if "${number_rotations} >= 10" then "jump SELF end_loop"
jump SELF start_loop
label end_loop

DCS team member & LIGGGHTS(R) core developer

NSalloum | Wed, 01/16/2019 - 08:30

Thanks Arnom,

I actually thought about something else early in which I did the following:

fix rotate all move/mesh my_mesh rotate ...
run XXX every YYY #XXX equal number of time steps to complete all rotations with rest & YYY equals to the number of time steps taken to rotate 90°
''unfix rotate'' &
''run ZZZ'' & #ZZZ equals the rest time steps
''fix rotate all move/mesh my_mesh rotate ...''
But your way is of course more professional.

best wishes,