Gravity and geomagnetism