I want to let the user specify how many circles there are to be plotted, each circle having a different size and all of them are in the center of the plot. Then I want to animate them so each circle gets a random speed to a random direction in the 2D plot. Is this possible?
I made this function to generate n numbers of random triangles but I don't know how to animate them with a certain speed and direction.
function circles(n) for i = 1:n size = randi(100); pos = -size/2; rectangle('Position',[pos pos size size],'Curvature',[1 1]); end
Best Answer