Trichromatic vision

Trichromatic color vision is the ability of humans and some other animals to see different colors, mediated by interactions among three types of color-sensing cone cells. The trichromatic color theory began in the 18th century, when Thomas Young proposed that color vision was a result of three different photoreceptors.

Hermann von Helmholtz later expanded on Young's ideas using color-matching experiments which showed that people with normal vision needed three wavelengths to create the normal range of colors. Each of the three types of cones in the retina of the eye contains a different type of photosensitive pigment, which is composed of a transmembrane protein called opsin and a light-sensitive molecule called 11-cis retinal. Each different pigment is especially sensitive to a certain wavelength of light (that is, the pigment is most likely to produce a cellular response when it is hit by a photon with the specific wavelength to which that pigment is most sensitive). The three types of cones are L, M, and S, which have pigments that respond best to light of long (especially 560 nm), medium (530 nm), and short (420 nm) wavelengths respectively.


So, this is how RGB was born.
The choice of primary colors is related to the physiology of the human eye.

One common application of the RGB color model is the display of colors on a cathode ray tube (CRT), liquid crystal display (LCD), plasma display, or LED display such as a television, a computer’s monitor, or a large scale screen. Each pixel on the screen is built by driving three small and very close but still separated RGB light sources.

Ref: Wikipedia