Pātuhitia tēnei: Potential theory in gravity and magnetic applications