Sunspots and solar flares, created by the sun’s magnetism, can affect the Earth’s surface