Is the color exactly between two opposite colors always medium gray?

I was trying to find the opposite of a web color (let’s take #917AFA as an example) and an online tool told me that it is #6E8505. Then, I used another online tool to find the color that is exactly in the middle between two arbitrary web colors, typed in these two opposite hexes, and got #808080 (medium gray, exactly). Then I tried doing the whole “experiment” a couple more times and always got #808080, from which it became obvious that it was no coincidence, however it was surprising to me.

My question: In general, does taking two opposite colors (not specifically web colors) and finding the one exactly in the middle always result in medium gray?

Answer

When we talk about two RGB colors being “opposite to each other” we are talking pure math.

Two colors opposite to each other in the RGB color model isn’t necessarily the same as what our eyes would perceive as “opposite” or “complimentary”.

By definition we have chosen that if one of the colors is

[r, g, b],

the opposite color would be

[255 - r, 255 - g, 255 - b].

So the midpoint between these two opposite colors (or the average) is also by definition a medium gray:

[(255 - r + r) / 2, (255 - g + g) / 2, (255 - b + b) / 2] = [127.5, 127.5, 127.5].

In other words, talking about two RGB colors being “opposite to each other” is the same as talking about two colors that “averages to a medium gray”.

Attribution
Source : Link , Question Author : Alex , Answer Author : Wolff

Leave a Comment