Radiofrequency pulse design with numerical optimization in the Fourier domain