page_title: Potential energy
section_title: General formula
hierarchical_section_title: Potential energy / Gravitational potential energy / General formula
caption_attribution_description: English: U = &#x2212; m 1 &#x2211; G M r {\displaystyle U=-m_{1}\sum G{\frac {M}{r}}} in this case, M_1 = 100 000 kg and r_1 = -3 m , M_2 = 10 000 kg and r_2 = +2 m. The potential energy of the test mass (red) is given by the formulahttp://weelookang.blogspot.com/2010/08/ejs-open-source-gravitational-field.html
context_page_description: In physics, potential energy is the energy held by an object because of its position relative to other objects, stresses within itself, its electric charge, or other factors.
  Common types of potential energy include the gravitational potential energy of an object that depends on its mass and its distance from the center of mass of another object, the elastic potential energy of an extended spring, and the electric potential energy of an electric charge in an electric field. The unit for energy in the International System of Units is the joule, which has the symbol J.
  The term potential energy was introduced by the 19th-century Scottish engineer and physicist William Rankine, although it has links to Greek philosopher Aristotle's concept of potentiality.
  Potential energy is associated with forces that act on a body in a way that the total work done by these forces on the body depends only on the initial and final positions of the body in space. These forces, that are called conservative forces, can be represented at every point in space by vectors expressed as gradients of a certain scalar function called potential.
context_section_description: However, over large variations in distance, the approximation that g is constant is no longer valid, and we have to use calculus and the general mathematical definition of work to determine gravitational potential energy. For the computation of the potential energy, we can integrate the gravitational force, whose magnitude is given by Newton's law of gravitation, with respect to the distance r between the two bodies. Using that definition, the gravitational potential energy of a system of masses m₁ and M₂ at a distance r using gravitational constant G is
  ,
  where K is an arbitrary constant dependent on the choice of datum from which potential is measured. Choosing the convention that K=0 (i.e. in relation to a point at infinity) makes calculations simpler, albeit at the cost of making U negative; for why this is physically reasonable, see below.
  Given this formula for U, the total potential energy of a system of n bodies is found by summing, for all  pairs of two bodies, the potential energy of the system of those two bodies.
  Considering the system of bodies as the combined set of small particles the bodies consist of, and applying the previous on the particle level we get the negative gravitational binding energy. This potential energy is more strongly negative than the total potential energy of the system of bodies as such since it also includes the negative gravitational binding energy of each body. 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.
  therefore,
  ,
caption: Gravitational potential summation 
    
      
        
          U
          =
          −
          m
          (
          G
          
            
              
                M
                
                  1
                
              
              
                r
                
                  1
                
              
            
          
          +
          G
          
            
              
                M
                
                  2
                
              
              
                r
                
                  2
                
              
            
          
          )
        
      
      {\displaystyle U=-m(G{\frac {M_{1}}{r_{1}}}+G{\frac {M_{2}}{r_{2}}})}
exif: {}