The Effect of Space Charge and Residual Gases on Thermionic Currents in High Vacuum