The sun is not a big ball of gas, but of plasma. Plasma can hold a magnetic charge, but gas can't. This charge is what brings the sun's energy from its core to the surface, so that we on earth can benefit from it. It also causes solar flares to erupt in those impressive arcs. End of lesson. See you tomorrow.