Remix.run Logo
ddahlen 2 days ago

Its an implementation of a pretty standard integrator used by astronomers informally called "RADAU", but it is not exactly the same RADAU you would find elsewhere. Basically it is about as good as you can typically get for multi-step integrators, tuned for speed not precision though.

Note that how the code is laid out you cant really simulate non-solar system masses. Its really aimed at massless objects in the solar system, your 3-body simulations are actually quite difficult to do given the design.

nhatcher 2 days ago | parent [-]

Thanks! Understood, I was more thinking along the lines of reading your code to learn something new. I wish I had infinite time

ddahlen 2 days ago | parent [-]

I suggest the appendix of the arxiv paper if you want to see some of the math required for solar system objects beyond simple Newtonian gravity (like Relativity corrections). I wrote that section specifically because I found it a pain in the ass to source those equations in literature.