How does the energy produced in the core of the sun reach the surface?