NASA successfully launches spacecraft to study magnetic fields surrounding the Earth and Sun