Because a bound system is at a lower energy level its mass must be less than its unbound constituents. Nuclear binding energy can be computed from the difference in mass of a nucleus and the sum of the mass of the neutrons and protons that make up the nucleus. Once this mass difference (also called the mass defect) is known Einstein's formula (E = mc²) can then be used to compute the binding energy of any nucleus.
The energy given off during either nuclear fusion or nuclear fission is the difference between the binding energies of the fuel and the fusion or fission products.
The Binding Energy of Deuteron 2H
The mass difference = 2.015941 - 2.013553 = .002388 amu, and conversion between rest mass and energy is 931.494MeV per amu, so a deuteron's binding energy is
The series of light elements from Hydrogen up to Sodium have increasing binding energy per nucleon as the atomic mass increases, a region of stability (saturation) occurs from Magnesium through Xenon, and then binding energy per nucleon decreases as the atomic mass increases. Iron is the most stable and tightly bound element. Fusion produces energy by combining lighter elements into a more stable tighter bound element such as Hydrogen into Helium, and fission produces energy by splitting heavier elements such as Uranium or Plutonium into more tightly bound stable elements.
See also nuclear fusion, nuclear fission, strong nuclear force