Skip to content

2D N-Body simulation using Python and Pygame.

Notifications You must be signed in to change notification settings

ShneM/N_body_simulation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

N_body_simulation

  • Main: contains the Pygame main loop. The simulation to be used can be selected at the bottom.
  • Particle: contains the particle classes.
  • Simulations: new simulations can easily be added here.
  • Color: some constants and functions to help with colors and gradients.
  • Ticker: controls the iterations of the Pygame main loop.

Usage

  • Run the main.py file
  • Left mouse pans the screen
  • Right mouse (hold) creates new particles in the direction indicated by the line. Longer hold increases the particles' mass.

About

2D N-Body simulation using Python and Pygame.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages