Bago's Rename sph basis functions corrected after rebasing and other minor lateral fixes

This is a replacement for PR #198.