More about star types
When stars form, they have different masses, mostly somewhere between one-tenth and ten times the mass of our Sun. Sometimes there are more extreme examples, of course. The mass of the star determines how fast its nuclear reactions take place and therefore how much energy it releases. The more massive the star, the hotter its surface and the shorter its lifetime. The temperature of the star determines its colour.
The Sun is a yellow star with a temperature of about 6000K. About 90% of the stars are smaller than the Sun. Called red dwarf stars, they have temperatures of just a few thousand Kelvin. At the other end of the scale, are stars larger than the Sun. They are called blue supergiant stars and have extreme temperatures of more than 10 000K.
In 1918, astronomers and their assistants from Harvard University, United States, proposed a system of classification known as the Harvard Spectral Classification. It grouped stars into seven classes, each designated with a letter, according to their surface temperature. The scheme had O, B, A, F, G, K, M, with O for the hottest stars and M indicating the coolest. The Sun, for example, is a G-type star. Astronomers still use this scheme today.
Are older stars part of the classification? Yes, even though they have left the main sequence. Old stars are bloated stellar objects, often hundreds of times the radius of the Sun. Astronomers call them red giants or red supergiants, depending upon their exact size.