Skip to content

StardustGogeta/Physics-2.0

 
 

Repository files navigation

Physics-2.0

BCH compliance Build Status codebeat badge

Physics-2.0 is a simple 2D n-body gravity simulator made in Python with Pygame. Bodies follow Newton's law of universal gravitation and conservation of momentum. This application can be used to demonstrate simple systems like binary stars, and complex systems like planetary accretion and stellar dynamics. Physics-2.0 can be used in the classroom to help students develop an intuitive understanding of gravitation.

Features

  • Improved performance
  • Precise physics
  • Live simulation settings window
    • Adjust gravitational constant
    • Adjust time factor
  • Fully featured camera movement and zoom
  • Window resizing
  • Live body telemetry
    • Adjust mass and density
    • Visualize velocity and acceleration vectors on a logistic plot
  • Save simulations to files
  • Open simulations from files

Controls

Action Control
Basic camera translation Arrow keys
Cinematic camera translation WASD
Camera zoom Scroll wheel
Open properties dialogue Left click
Spawn body Right click

Screenshots

unavailable

About

Remake of simple 2D n-body gravity simulator

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%