Two atoms that can form a bond will do so to create a diatomic molecule when they approach each other closely. We describe the energy minimum with a potential energy curve, called a potential well. Morse Potential
where De is the well depth, R is internuclear distance, Re is the equlibrium internuclear distance (bond length), and
e is the vibrational constant and µ is the reduced mass.
The following figure shows the ground state potential well of the H2 molecule. The curve is calculated from the Morse potential and the energy levels are calculated using the harmonic oscillator model with the first anharmonic correction.