# Approximate spectral type and luminosity given apparent magnitude and distance

I am looking at the data acquired from the Gaia DR2 survey. I found that most of the stars had their distance and apparent magnitude catalogued, but not their spectral type and luminosity class. Is there a way to approximate this?

You can calculate the absolute magnitude of a star: $$M=m-5\log_{10}(\frac{d}{10\,\text{pc}})$$ where $$M$$ is absolute magnitude, $$m$$ is apparent magnitude and $$d$$ is the distance.

Then you take a look at the HR diagram.

One can easily see, that you need two data to obtain the third one, but we have only one data (absolute magnitude). That means, that you also have to know the luminosity classification of a star:

• I: supergiants
• II: bright giants
• III: giants
• IV: subgiants
• V: main sequence
• VI: white dwarfs

Then you just look at the intersection of the class and absolute magnitude.

If you know radius, then this is even easier. All you need is this formula: $$T={\Big{(}\frac{10^{0.4(4.77-M)}}{4\pi R^2 \sigma}\Big{)}}^{0.25}$$ $$T$$ is the temperature in Kelvins, $$M$$ is absolute magnitude of the star, $$R$$ is radius of the star, $$\sigma$$ is Stefan-Boltzmann constant.

With these data you look at the table of temperature and spectral classes or HR diagram.

If you are given color, then you already have an answer (spectral class is defined with color). If you are given temperature, you can look at the HR diagram.

• The Gaia data contains both colours and magnitudes. You don't know the radius. Finding the absolute magnitude only rules some things out. And your equation for absolute magnitude isn't correct! – ProfRob Jan 18 at 21:23
• @ProfRob He asked for the spectral class from the apparent magnitude and distance. I said that this isn't enough data and gave some ways with different data. – User123 Jan 18 at 21:54
• @ProfRob If you are given color, you can really easily convert it into spectral class. But that wasn't the question. – User123 Jan 18 at 21:58
• But given that it is DR2 data, you do have a colour, so why make things difficult? – ProfRob Jan 18 at 23:22
• I didn't knew that color is given. I will add one paragraph for color. – User123 Jan 19 at 7:36