Simulation of a 2D gas of colliding circular balls
run_sim2d(N,mass,radius)
Simple simulation of a 2D gas of colliding circular balls.
N,mass & radius are vectors of the same length specifying the
number,masses & radii of the balls.
example : run_sim2d([400 100],[1 2],[0.005 0.01])
creates a simulation with 400 balls of mass 1 and radius 0.005, and 100
balls of mass 2 and radius 0.01
The box coordinates are defined such that min(width,height) is 1 unit.
The simulation is initialized with uniformly random positions and a
constant speed in the horizontal direction.
Cite As
ofer v (2024). Simulation of a 2D gas of colliding circular balls (https://www.mathworks.com/matlabcentral/fileexchange/72157-simulation-of-a-2d-gas-of-colliding-circular-balls), MATLAB Central File Exchange. Retrieved .
MATLAB Release Compatibility
Platform Compatibility
Windows macOS LinuxCategories
Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Discover Live Editor
Create scripts with code, output, and formatted text in a single executable document.
Version | Published | Release Notes | |
---|---|---|---|
1.0.0 |