The three-body problem is the problem in celestial mechanics of determining the paths and velocities of three objects, interacting only through the force of gravity.
One might expect, that with only seven independent parameters per object (mass, 3 dimensions of initial location, 3 dimensions of initial velocity) that things might have relatively simple, clock-work behavior.
One would be wrong.
It turns out that these dynamics are highly chaotic. Euler & Lagrange determined there were 5 arrangements of equilibrium in any 3 body system with two large bodies. Those arrangements define the Lagrange points.
Lagrange points are pretty cool. The stable ones are 60 degrees in front (L4) and 60 degrees behind (L5) the mid-sized object in its orbit about the largest object. The Trojan asteroids have collected themselves there with respect to Jupiter in its orbit.
But in general, there's no closed form expression for where and at what speed your three bodies will be at any future or past time. You can't write a function of time, drop a value in, and know that that is where & how fast your objects will be in the future
So you have to act like a computer program - you have to use computer programs to make short steps in time and move everything forward a little bit, and keep going - and if you're working in the real universe, make corrections as you go. It's kinda like weather forecasting
It's chaotic - literally. The mathematics fit within what is called "chaos theory". But it's also beautiful, and this bot is a nifty little toy.