Glaser magnets used for focusing low-energy charged particle beams show app
reciable spherical aberration causing an increase in the beam emittance. By
using the variational method we have shown that the spherical aberration c
an be minimized if the axial field in the magnet follows a cosine-squared f
orm. We have shown that by shaping the pole pieces one can make the field h
ave a shape closer to the cosine-squared function.