Stars are vast collections of hot gas. A star like the Sun is more than ten billion billion billion tons of matter crammed together under the force of its own gravity. The conditions in a star (dense and hot) make it a pretty nice example of a blackbody. The stellar atoms jiggle around absorbing and re-radiating radiation in just the right way so that light pouring out at the surface has just the mix of colors (wavelengths) predicted by the blackbody curve. This is good news for astronomers. By measuring the energy emitted by the star in different colors they can work backwards to figure out it’s temperature.

If you go to the blackbody applet and change the temperature slider (at the bottom of the graph) you will see how the highest point, or peak, of the curve shifts left or right to different wavelengths (notice the visual part of the spectrum is indicated by the rainbow of colors). Since the peak of the blackbody curve is where most of the radiation is emitted, you can see how changing the star’s temperature changes it’s color.

The peak wavelength doesn't tell the whole story since your eye will pick up a mix of colors in the visible band. After you set the temperature, the actual color of the star appears in the upper left hand corner of the Applet so you can see directly how changing the temperature changes the color.

 

Stellar Luminosity: The brightness or luminosity of a star is also related to its temperature by the formula,

In this formula R is the radius of the star and s (sigma) is the constant of nature called the Stefan-Boltzmann constant, (remember that 4pR2 is the surface area of a sphere). This formula tells you that the brightness of a star is very sensitive to both its temperature and its size (area). By changing the radius of the star on the applet you can see how the brightness of the star changes.