Background
Tidal Forces
Because the force of gravity is dependent on distance, there is always a gradient in a gravitational field. For large bodies, such as stars and planets, the distance across them is great enough that there can actually be a significant differential force across the bodies. Two well-known effects on the Earth and Moon are caused by tidal forces from their mutual gravitational attraction.
The Tides
The first is the ocean tides on Earth. The moon's pull on Earth is strongest on the side facing it, and weakest on the side facing away from it. This causes the water on the sides of the Earth facing neither away nor toward the Moon to be drawn toward it, causing low tides in those areas, a great high tide on the side facing the moon, and a lesser high tide on the side facing away.
Tidal Locking
Tidal forces can also exert a torque on objects if the differential force is applied off axis. The moon is slightly asymmetrical, making it heavier on one side. Over time, in the presence of the Earth's gravitational field, the tidal forces slowed the Moon's rotation it matched up exactly with its orbital period. This is why we only ever see one side of the Moon from Earth.
Roche Limits
Because massive objects such as the Earth and Moon are held together by their own gravity, it is possible for the gravitational field of a large object to overcome the internal gravity of a smaller object, and tear it apart. If the small object becomes too close to a large object, the tidal differential across the small body becomes larger than the object's internal gravity and material begins streaming off its surface. Named after Éduoard Roche, the mathematician who first theorized it, the Roche limit is the distance within which a cosmic body will destroy another with its gravity.
The Model
The Math
To find the Roche limit of the Earth and Moon, my team built a model in COMSOL. COMSOL does not have a dedicated gravitational model, but it does have a mathematical module for Poisson's equation, which can be used to model Newtonian gravity.
The Poisson's equation module in COMSOL can solve the top equation on the right, finding a scalar gravitational potential, phi, from the gravitational densities of the objects, G*rho. The gradient of phi is g, the acceleration due to gravity. When a body is exactly at the Roche limit, we would expect to see a gradient of exactly 0 at the edge of that body. Thus, we can solve for that distance by iterating through various distances until that point falls on the Moon.
The Simulation
In our model, the Earth is built in layers, concentric spheres of various densities, representing the inner and outer core, lower and upper mantle, and the crust. Since the shapes, depths and densities of these layers are variable and not precisely known, this can be looked at as a reasonable, but imperfect approximation. The Moon is modeled as a single, homogeneous sphere of the average density of the Moon. The combined gravitational potential is solved iteratively with variable distance between the objects until the limit is discovered. Our model finds that the Roche limit for solid bodies to be 17,555 km center-to-center, which differs from professional models by 0.3% We chose to use solids because COMSOL does not handle fluids as well as rigid bodies. This simulation could be improved by allowing deformation of the bodies through fluid motion using a more robust simulation package.