Generation of strong inhomogeneous stray fields by high-anisotropy permanent magnets