The ARIES project has developed a prototype electron gun to compensate the effect of space charge with electron lenses in hadron synchrotrons