In our development of a computational model of planetary systems we’ve seen that moving the planets around (specifically the velocity of the planets) depends on a force, generally denoted by the letter F. As we’ll see, evaluating this force is usually the most complex and “costly” part of a computer simulation, and, as such, deserves careful attention.

To start with, the force acting on discreet bodies, such as planets, is typically represented by a pairwise expression. For instance, if there are three particles in a system, the force associated with interactions between particles 1 and 2 is F12; between particles 2 and 3, F23; and between particles 1 and 3, F13. In general then, for a system of N particles, or planets in this case, there are (N)*(N-1)/2 forces which need to be evaluated. Furthermore, because the force depends on the distance between the particles, it must be evaluated at every time step (because the distance changes at every time step). The number of force evaluations to be done can obviously grow very quickly to unwieldy proportions, and for this reason, several methods have been developed to reduce this burden somewhat while still maintaining the integrity of the simulation. In future articles we’ll look at some of these techniques, but for now we’ll assume that we have to compute all of the forces at each time step.

The pairwise representation of forces on particles in a system is not completely realistic, especially at atomic and subatomic levels where so-called “three-body effects” (e.g., F123) can come into play. However, for the situation of relatively large planets interacting with each other, this is approximation is quite acceptable. Given this approximation, it is pretty straightforward to derive an expression for the forces at play between interacting planets.

All forces can be derived from the expression for the potential energy that describes interactions between two objects. In the case of a solar system, the potential energy “felt by” one planet, Planet A, due to another planet, Planet B, is V = -mgR*R/rab, where V is the potential energy, m is the mass of of Planet B, g is acceleration due to gravity on Planet B, R is the radius of Planet B, and rab is the distance between Planet A and Planet B. To get the force from this expression, we simply need to find the change in the potential with respect to a change in the distance between the two planets. This is simply the calculus derivative of V, the potential, which for this system is Fab = -mgR*R/(rab*rab), where Fab is the force exerted on Planet A by Planet B (for a discussion of derivatives, please consult a Calculus text book or web site). One thing that can be seen pretty easily is that the magnitude of the force becomes really small quite quickly as the distance between the two planets increases.