A body in space travels in a constant direction at constant speed unless a force acts on it. By that time its position will have changed by v dt . Acceleration in space. By that time its position will have changed by v dt . The Law of Gravitation.
Gravity attracts masses one to the other.
In order to keep things simple we will not worry about the shape or composition of the bodies, and will consider only point masses . Suppose we have a mass m at position x and a mass m' at position x' . The constant G is universal and depends only on the units chosen. Putting it all together. If we have several bodies traveling through space, the gravitational force acting on each one is the vector sum of the attractive force it feels from each of the others.