Making an N body gravity simulator in C#
Why? I wanted to model how to fire something at the earth-moon L1 Lagrange point and have it enter a stable earth orbit. Also for fun. Goals: Use high school maths plugged into C# with some kind of UI that lets me specify a speed, angle, and height to fire a projectile to be caught by the moons gravity and dragged into a stable earth orbit. Add frictional simulation to model the effects of the earths atmosphere. Planned steps: Create a Newtonian calculator that returns gravitic forces given object of specified mass and distance. Use temporary unit tests to verify outputs. Create a vector calculator that can calculate a final vector given a number of input vectors. Use temporary unit tests to verify outputs. Create models to represent bodies including vectors and influences. Create a UI and controller classes that can specify bodies and vectors Create a calculator class that loops through the specified bodies and calculates new positions given the starting vectors...