Physical simulation and visualization of bead moving on rotating ring