Spatial-selective excitation rf pulses enable to enhance resolution in magnetic resonance imaging as well as spectroscopy, where it also minimalize contamination of spectra from surrounding tissue. For their efficient use it is central to have fast tools to generate rf pulses of required properties.
Here we propose a Krotov-based algorithm and compare it with quasi-Newton algorithm on specific examples.