# Gravitational pull of a non-spherical object

Newtonian gravitation is (usually) much simpler than it might be because it can be shown that any spherically symmetrical mass attracts other masses as if it’s mass were concentrated in a point at it’s center. In a handful of situations however, the special case of spherical symmetry cannot be taken for granted. Perhaps the most common example is tidal effect. Since the Earth and moon are not infinitely rigid, their mutal gravity causes a bulge towards each other, with the effect of transferring angular momentum from the rotation of the Earth to the revolution of the moon around the Earth. Another is calculating the orbit of satellites around the Earth: because the Earth rotates, it has an equatoral bulge (‘olbate spheroid’), and this effects the satellites’ paths, most notably in causing the plane of the orbits (and if elliptical, the axis of the orbits) to precess.

For a fluid rotating object, there are different configurations it can be in. At low speed you have the oblate spheroid. At higher speeds the radial symmetry breaks down and the mass begins to form two opposite lobes. At higher speed still this forms a dumbell shape connected by a narrow neck and at some critical value it breaks apart into two separate masses orbiting each other. At that point however, anything that was orbiting the original mass is now orbiting two: you now have the famous three-body problem, which probably has no general solution.

My question is, at what point in this procession from perfect sphere to two orbiting bodies do we stop having a general solution for calculating the gravitational influence on another object?

IANAPhysicist/IANAAstronomist

From a programming standpoint, in my understanding, if you only care about the effect of one, larger, object then it doesn’t matter how distorted its shape is so long as you can render it. If you have two oddly shaped objects, the problem would be significantly harder. In either solution, the simulation will have a particular margin for error depending on how finitely you want to render things.

First, you render the attracting object in 3D (at least mathematically. You don’t need to actually show it visually.)

Second, you create a point of interest–i.e. where the object being affected–as a virtual camera pointed at the first object.

Third, for every square section of the viewport you cast a ray down the center away from the camera, directly down the center of the square section. For every point of intersection of the ray and any surfaces facing towards or away from the camera, you record the distance along the ray.

Fourth, you add up the depth of the inside portion of the Attractor that the ray passed through for each section of the viewport.

Fifth, you average these out to find the gravitational center of the object.

So the more polygons you use to render the object and the greater the number of subsections that you break the viewport into, the more accurate the result will be.

If you have two complex objects that you wanted to do this for, probably your best solution would be to pick very simple shapes for each, guess a center for A and use it to test for the gravitational center of B, place a camera at the gravitational center of B and use it to test for the center of A. Increase the quality (polygon count, viewport subsection count) of both, using the new estimated center of A to detect B, use that center to determine A. Increase the quality of both->repeat.

Again, not a truly mathematical solution, though you could get perfectly good solutions to any level of accuracy depending on how much processing power and time you have.

For the gravitational field of a non-spherical object, you can treat it as a point source of equal mass located at its center of mass.

But your question is a bit difficult to answer as it depends on the accuracy needed in the calculations.

I think you need to specify the last object (second object, or third object if the first has split into two). If the last object has negligible mass relative to the first mass(es) you may get a different answer than if the last object can perturb the first objects. Also, the distance of the last object from the other two may make a difference.

This is wrong unless you are far from the object.

Hm…partially true. If you had a case like:

``````
/
/
/
/
/
/
/
/
/ o
/
/

``````

I believe that the portion of the long thin object closest to the ‘o’ would bring the center of relational gravitational center closer than the center of mass is, since gravitational force drops off by distance.

Edit: What ZenBeam said.