This is a program that simulates the random movement of particles. The latters are represented by non-overlapping circles and this condition is ensured with the use of a quadtree.
- Python 3.8
Figure 1. Circular zone with radius equal to 250 pixels containing 200 small circles with radius equal to 10 pixels. The circle with the green outline is the starting position and the green is the final position. The blue rectangle represents the hitbox of the movement of the green circle and the red circles are the obstacles (the moving particle will stop at the first obstacle). The squares are the partitions of a quadtree.
Figure 2. Circular zone with radius equal to 250 pixels containing 50 small circles with radius equal to 10 pixels. The positions of the circles are configured to be updated at the rate of 60 frames per second (this might not be accurate because the "after" function of tkinter is used to animate the movement).