Positron emission versus electron capture
The emission of a positron and the capture of an electron are twin reactions which both result in the diminution of the number of protons by 1 (from Z to Z-1) and the production of a neutrino. In the formula, the positron observed at the final stage of the beta decay appears as an electron in the initial stage of the capture. When comparing the energies, we can see that the 0.511 MeV rest mass energies of the electron and positron cancel each other out, revealing that the electron capture saves 1.022 MeV on the beta decay.