Our processing sketch contains balls which can move around the workspace. The space is initially set to contain only one ball, although the user can use the “n” key to add more. If left alone, the balls will simply bounce up and down, but they can also be “picked up” with the mouse and moved around the screen, or thrown to change their directions. The balls stay contained within the limits of the screen; bouncing off the sides when they hit it. They also bounce off of each other if they hit each other.
-
Recent Posts
Recent Comments
cyberprofgus on Online Education cyberprofgus on Public Underwater Video Feed L… cyberprofgus on Thought on Meredith Kahn’s… cyberprofgus on What Women Want cyberprofgus on Data to Information Infog… Archives
Categories
Meta
It would be an interesting exercise to use smaller circles and generate many (100’s to 1000’s) of new ones. Your code’s time per step will scale as N*N (N-squared), so the you should see a slowdown of a factor of 10,000 in going from N=10 to N=1000.