Text this: Cleaning the beam halo using nonlinear ac magnets