# Can the color of an alien sky be calculated solely from atmospheric composition and the star's (or stars') spectral type(s)?

What exactly are the relevant numbers for such a calculation, and can it account for the color of the sky?

By sky color, I mean the day to day hue that humans (or something else with very similar eyes) would experience if present on the surface. Earth is "light blue" or "robin egg blue", I don't need all the possible variations for any conceivable weather condition. Oh, and this being for a computer game, it'd be nice if it was easily convertible to rgb() colorspace.

I'll have the star or stars' stellar classification. The planet's distance from the star(s), its atmosphere down to the 0.1% components (give or take), and a whole host of other numbers that don't seem relevant. I'm hoping to be able to generate crude landscapes from this. If I'm missing the relevant data, I can work that into the simulation possibly and have it available.

• I'm not sure how to formulate the math here into an answer, but there are some possibly helpful equations in the Rayleigh Scattering wikipedia article: en.wikipedia.org/wiki/Rayleigh_scattering Mar 24, 2020 at 22:29
• Color is a sensation; it exists in the mind. It is not a physical quantity; it does not exist in nature. It is true that what color the human mind perceives depends on the spectrum of the illuminant (= ambient ligtht) and on the properties of the illuminated object; but the human visual system has a built-in automatic white-balance correction system which will compensate for the illuminant so that familiar objects are perceived as having familiar colors. This is why the world around us doesn't change colors throughout the day, although the spectral composition of the light changes. Mar 24, 2020 at 22:30
• Shorter: you could maybe compute the spectral composition of the light. This won't tell you what color would be perceived. Mar 24, 2020 at 22:31
• transmission/reflection spectra of the object, the atmosphere in this case. Don't forget the Rayleigh scattering - blue sky, warm yellow light on Earth surface, even if the spectral maximum is between 500-550nm - i.e. green. Mar 25, 2020 at 1:37