The potential energy of the system of bodies as such is the negative of the energy needed to separate the bodies from each other to infinity, while the gravitational binding energy is the energy needed to separate all particles from each other to infinity. read more
The formula for potential energy depends on the force acting on the two objects. For the gravitational force the formula is P.E. = mgh, where m is the mass in kilograms, g is the acceleration due to gravity (9.8 m / s 2 at the surface of the earth) and h is the height in meters. read more