Why do red, green, and blue make up all the colors?

17

6

Why do red, green, and blue combinations can make up all the visible colors?

Hedayat

Posted 2017-10-27T14:17:11.860

Reputation: 88

what about CMYK? – user3526 – 2017-10-27T17:17:54.027

CMYK is a process by which we can print colors onto a substrate (and a much smaller selection of colors than we can see) but the way we see is RGB. – Gábor – 2017-10-27T23:12:42.657

12They don't make up all the colors. They just make up a sufficient range of them that most scenes can be represented with acceptable fidelty. – Peter Green – 2017-10-28T00:08:27.377

6Because humans have red, green and blue receivers in their eyes. – immibis – 2017-10-28T02:43:44.590

2This would be better for biology stack exchange (if there is one) because it is more a question about the human visual system than one of computer graphics. – mathreadler – 2017-10-28T18:57:16.603

2

@mathreadler https://biology.stackexchange.com

– briantist – 2017-10-28T19:06:34.587

@briantist wow cool, who knew. – mathreadler – 2017-10-28T19:09:28.190

Good answers here and good answers on Biology.SE will give different perspectives, so I'm glad the question has been asked on both sites. – trichoplax – 2017-10-28T19:18:57.623

Similar/related questions on Biology.SE for comparison – trichoplax – 2017-10-28T19:29:09.067

@mathreadler Actually this is better for cognitive sciences.se. More accurately the place that mixes all that's needed. But its fine here as well.

– joojaa – 2017-10-28T19:53:42.347

4

Apparently there is at least one tetrachromat woman (see https://en.wikipedia.org/wiki/Tetrachromacy) that is able to distinguish more colours than those of us who are trichromat.

– Bill Bell – 2017-10-29T03:53:59.353

@immibis that is a gross over-simplification and really quite inaccurate. – Dawood ibn Kareem – 2017-10-29T05:54:20.360

1

@BillBell and probably its digital counterpart: Quattron, adding yellow color subpixels on Sharp Aquos LCD TV.

– Andrew T. – 2017-10-29T07:51:34.757

1@AndrewT.: I expect that a lot of this is lost on people like me that can't see the difference between 'Saddle Brown' and 'Sienna'. :) – Bill Bell – 2017-10-29T16:16:11.667

Answers

24

Let's reminds ourselves what light is.

Radio waves, micro waves, X rays and gamma rays are all electromagnetic radiation and they only differ by their frequency. It just so happens that the human eye is able to detect electromagnetic radiation between ~400nm and ~800nm, which we perceive as light. The 400nm end is perceived as violet and the 800nm end is perceived as red, with the colors of the rainbow in between.

A ray of light can be a mix of any of those frequencies, and when light interacts with matter, some frequencies are absorbed while other might not: this is what we perceive as the colors of objects around us. Unlike the ear though, which is able to distinguish between a lot of sound frequencies (we can identify individual notes, voices and instruments when listening to a song), the eye is not able to distinguish every single frequency. It can generally only detect four ranges of frequencies (there are exceptions like daltonism or mutations).

This happens in the retina, where there are several kinds of photo-receptors. A first kind, called "rods", detects most frequencies of the visible light, without being able to tell them apart. They are responsible for our perception of brightness.

A second kind of photo-receptors, called "cones", exists in three specializations. They detect a narrower range of frequencies, and some of them are more sensitive to the frequencies around red, some to the frequencies around green, and the last ones to the frequencies around blue.

Because they detect a range of frequencies, they cannot tell the difference between two frequencies within that range, and they cannot tell the difference between a monochromatic light and a mix of frequencies within that range either. The visual system only has the inputs from those three detectors and reconstruct a perception of color with them.

For this reason, the eye cannot tell the difference between a white light made of all the frequencies of the visible light, and the simple mix of only red green and blue lights. Thus, with only three colors, we can reconstruct most colors we can see.

By the way, rods are a lot more sensitive than cones, and that's why we don't perceive colors in the night.

Julien Guertault

Posted 2017-10-27T14:17:11.860

Reputation: 2 745

5"Thus, with only three colors, we can reconstruct all the colors we can see." This sentence is incorrect. Starting from three primaries, you can only reconstruct certain colors. The range of colors that can be reconstructed is called the "gamut". You can search for "sRGB gamut" and find pictures that show a triangle inside a larger parabola. The triangle represents the colors that we can make from the sRGB primaries, and the parabola is all the colors we can see. From this it's clear that any triangle inside the parabola will be smaller than it. – Dietrich Epp – 2017-10-28T02:20:25.410

woops, you're right. I've replaced "all" with "most" and will try to think of an explanation for the remaining visible colors. – Julien Guertault – 2017-10-28T07:38:27.817

4Also the concept of white light is governed by our really fancy white balance system it dont mich matter what the color is it will be precieved as white. Incandescent lightbulbs are orange but if we are inside the house we precieve them as white. As for the extra colors, if you integrate the energies of your color distribution multiplied by curves ratchet freaks show you youll notice that sometimes you get unique signals because the overlap is different. – joojaa – 2017-10-28T07:45:14.310

18

They don't.

The problem with the diagrams representing the visible and RGB gamuts is that they're presented on RGB displays. They obviously cannot show you what they cannot show you : the area inside the parabola but outside of the triangle.

RGB gamut

The region outside of the triangle cannot be shown on your screen in a faithful way. For example, RGB cannot display a true, deep cyan. All you see is an approximation using green and blue. Some diagrams don't even try and only show a gray area :

enter image description here

To see what cyan can look like, you could stare at the white dot on this drawing for at least 30 seconds (2 minutes are recommended) and then slowly move your head towards a white wall:

cyan illusion

Similarly, RGB displays cannot show deep, saturated oranges or browns.

Eric Duminil

Posted 2017-10-27T14:17:11.860

Reputation: 281

The region outside of the triangle cannot be shown on your screen. Well, I can see this region on screen with colors. So how can it be more precisely stated? – narthex – 2017-10-28T12:14:57.297

2@narthex: Thanks for the comment. I updated the answer. Is it any better now? – Eric Duminil – 2017-10-28T12:28:30.443

Ok, thats fine. But what acually the values on each axis mean? This is never explained. – narthex – 2017-10-28T12:39:43.350

1And also, (staring at that last image), the red circle dances around. Fun – None – 2017-10-28T16:47:20.703

4The problem with CIE colorspace plots is that they are very hard to understand, hell we dont even know if some of the areas in the graph happen to make metamers. Also the reason why you simply can not make a bigger triangle is not apparent (hint there is nothing outside the shape). – joojaa – 2017-10-28T18:33:18.013

2

@joojaa: https://xkcd.com/1882/

– Eric Duminil – 2017-10-28T19:24:20.387

1@narthex The screen can show a diagram that represents the CIE color space. You don't even need a color screen for that: You can just have text labels "red", "orange"', "yellow",... What the screen can't show is all of the actual colors that exist in that space. – james large – 2017-10-28T19:33:24.810

4Great, now I have a cyan dot in the middle of my vision :-( – Kevin – 2017-10-29T00:32:15.310

It's worth noting that the CIE 1931 diagrams are somewhat misleading in the sense that the distance between two arbitrary points within it does not correspond to the perceived difference in colour. In other words, the area within and without the sRGB triangle is not representative of the perceived gamut: the difference is not that dramatic. (On the 1931 diagram, sRGB occupies less than half of the area). The 1976 version is much better in this regard. – Zeus – 2017-10-30T05:01:06.800

17

Humans are trichromatic, which means we have 3 different kinds of color receptors (better known as cone cells), each sensitive to a different set of wavelengths:

frequency responses of different cone cells
Image source: wikipedia

So it only takes 3 different monochromatic stimuli to fool our eye into thinking it sees a color that is the same as another. Red, green, and blue are good fits to the peaks of the frequency response curves of each type of color receptor.

ratchet freak

Posted 2017-10-27T14:17:11.860

Reputation: 4 695

4

One more thing: "violet" and "purple" are not the same color. Violet is a pure color around 400 nm; but purple is a combination of red and blue. To our not-quite-perfect human eyes they look the same.

If you pass a beam of pure violet through a triangular prism, the light will be bent but not broken up into components. If you then shine a beam of purple through the same prism, it will be separated into a blue and a red beam, with different amounts of "bend" to them.

Jennifer

Posted 2017-10-27T14:17:11.860

Reputation: 141

Depends what you mean by "color." In many contexts, it makes a lot of sense to say that if nobody can see the difference between two different patches on a surface, then both patches must be the same "color." On the other hand, when a painter says "color," she or he is talking about the physical substance into which he/she dips a brush. In that case, see https://en.wikipedia.org/wiki/Metamerism_(color)#Metameric_failure

– james large – 2017-10-28T19:38:32.483

1@jameslarge: It really doesn't. Just because they look the same under one light source doesn't mean they'll look the same under a different one, even if both light sources look identical on a white surface. – R.. – 2017-10-28T21:02:00.480

I don't think this answers the question in any way. It also applies to any colours - not just violet and purple. Monochromatic light of any hue from red through to violet won't get split by a prism, and any mixed light will get split. – Dawood ibn Kareem – 2017-10-29T05:59:17.800

4

They don't. Aside from what others have said about the physical reasons not, from a practical computer graphics standpoint, representing either surface pigments or light sources with RGB color is insufficient to model colored lighting of a scene. For example there is no way to represent a material which is translucent or reflective only in a narrow band; you can only represent translucency or reflectivity of wide bands corresponding roughly to what the red, green, and blue cones in the human eye pick up. This actually matters for a lot of real-world colors in the pink/purple/violet family, which look radically different under different types of light, even different "white" light that looks identical when viewed on a white surface.

R..

Posted 2017-10-27T14:17:11.860

Reputation: 141

1One common example for that is the quasi-monochromatic sodium vapor lamps, which are commonly used for city lamps and look always different in reality than on photos. – Julien Guertault – 2017-10-29T09:03:15.753

but those are fringe issues, I would consider very advanced. The issue doesn't materialize in most cases, RGB is just a fourier encoding with 3 harmonics of some signal that happens to be enough for most cases. – v.oddou – 2017-10-30T02:14:26.250

@JulienGuertault: While that's a nice example, I don't think it's quite an example of what my answer is pointing out - as long as your photosensor's/film's responses to the light in its 3 components matches the human eye's well enough, it should faithfully represent what a human would see. Where RGB (or any other model that lumps whole ranges of the frequency spectrum together) is insufficient is for actually modelling surfaces and light sources in a way that you can predict the perceived color of a light on a surface. – R.. – 2017-10-30T02:40:58.363

@v.oddou: "I don't care, it looks good enough" is a reasonable position to take, but there really is a difference. You won't be able to model the way the color of a wall looks different under daylight vs incandescent light vs led light that's supposed to be the same color temp as one or the other. – R.. – 2017-10-30T02:52:23.420

hmm, I might have misunderstood. Do you have a concrete example of the limitation you are referring to? – Julien Guertault – 2017-10-30T03:42:51.897

I've seen plenty of visual phenomena that seem to be examples of what I'm saying, but haven't done experiments or anything to confirm. The canonical example would be something like a narrow-band yellow light source on a material that reflects most light but absorbs a band around the particular yellow of the light source. In an RGB model, the material's color would be close to white (1.0,1.0,1.0), the light's color would be something near (1.0,1.0,0.0), and a rendering would show a yellow-lit surface whereas in reality the surface would be barely-lit. – R.. – 2017-10-30T16:22:51.063