The sun is our closest star, and therefore it is our best opportunity for studying stars in general. We will begin by looking very closely at the sun, and then generalize to other kinds of stars. Much of the time, the sun looks like this, if you view it through a filter so that you can see details on its surface.
Image source apod.nasa.gov/apod/ap040620.html
Viewing the sun with different wavelengths of light can tell us much about the structure of the sun. The above photograph of the sun was made in extreme ultraviolet light. Different wavelengths of light, corresponding to different temperatures, have been assigned different colors. Here, red corresponds to 2 million degrees Celsius, while green and blue are 1.5 and 1 million degrees Celsius, respectively. In other words, red is the hottest, blue is the coolest.
This brings up a very puzzling aspect of the way that the temperature changes on the sun. Typically, if an object is sitting in space, which is cold, it is hottest in the center and gets colder at the edges. We believe the sun is very hot in the center and cools off as you move outward, as you would suspect. But here, we see that above the surface, the temperature rises again. We will address this anomaly when we study the transition zone.
NASA's SOlar Helioseismic Observatory probe (SOHO) also takes images of the sun in many wavelengths of light. You can see what the sun looks like right now at sohowww.nascom.nasa.gov/data/realtime-images.html
The SDO spacecraft utilizes several sensors sensitive to various wavelengths of light. The blue panels are solar panels used to collect energy for onboard instruments.
Video source: nasa.gov/content/goddard/videos-highlight-sdos-fifth-anniversary
The SDO probe, launched in 2010, has compiled many breathtaking images of the surface of the sun. Please check out this video montage to see what they've been up to.
SOHO orbits the sun at a Lagrange point, which keeps it between the sun and earth at all times. As you can see from the animation, the orbit is quite large, outside the orbit of the moon around the earth. This allows SOHO to keep filming the sun at all times and send back information to us quickly.
SOHO also collects helioseismological data from the sun. Helioseismology is the study of the propagation of waves in the sun, mainly dealing with pressure waves. Sound waves are pressure waves. Maybe you have never considered that there could be sound in the sun. If you would like to hear what the sun sounds like, check out this site at Stanford, where scientists have used measurements of the Doppler shift of the light on the surface of the sun to reproduce sound solar waves.
The idea is basically this: every object vibrates at a natural frequency, or series of frequencies, based on the object's geometry and dynamics. For instance, two bells sound different because their shapes and materials are different. In this same way, a planet or a star "rings" based on its size, structure, chemistry and dynamical nature. The image above is a very simplified, exaggerated idea of how we think the sun "rings."
Image source noao.edu/education/ighelio/solar_music.html
In much the same way as we can listen to the heartbeat of a person to infer what is going on inside, we can use the information gained from studying the Doppler shifted surface light of the sun to infer what the internal structure of the sun could be like. When we watch the behavior of the surface, we see that some regions are hotter, and rising and others are cooler and sinking. This is convection, the transport of energy via the motion of a fluid. In much the same way that hot air rises (because the molecules are moving faster, so it is less dense) and cool air sinks, hot plasma in the sun rises to the surface and cool plasma sinks. This creates convection cells, evidenced by the granulation we see on the sun's surface.
Plasma is a kind of matter, a fluid in which the atoms are ionized, so that the positive and negative charges can move independently. The plasma of the sun conducts electricity very well. This means that magnetic field lines are "frozen" into the fluid and move with it. This is what causes the great loops of material flowing out of the surface of the sun. The charged particles follow the magnetic field lines which flow upward with the hot, buoyant plasma.
Pressure also plays another very important role in the sun. Every massive particle attracts each other via the gravitational force. If that was the only force present, the matter would collapse into a very dense point. But protons and electrons are charged particles, so they also interact via the electromagnetic force. Like charged particles repel and unlike charges attract. It is this repulsion that creates pressure. Gravity pulls in and pressure pushes out. The state where these two forces balance out is called hydrostatic equilibrium.
Rotation also works against gravity. If the sun was not rotating, the pressure counteracting the gravitational force would balance out and the sun would be spherical. But since it is rotating, It is not really round, it is a bit flattened. The faster a star rotates, the flatter it is.
Recall that luminosity is the total energy output of a star per second. It is like the wattage of the star. We can measure how much of the sun's energy strikes one square meter of the earth. This is called the solar constant, which we find to be 1400 Watts per square meter. Since the sun is basically a big ball with light going out in every direction, all of the sun's light passes through a giant sphere with the radius equal to the radius of Earth's orbit. We know the radius of the sphere, which allows us to figure out how much light energy passes through this sphere. This is the same amount that the sun produces. We can calculate the total luminosity of the sun to be as much energy as 100 billion megaton nuclear bombs going off every second.
radius = 1AU ~ 90,000,000 mi
Total Luminosity of Sun = 4 x 10^26 W
~ 100 billion 1 megaton nuclear bombs per second