The colour images produced by computer monitors and TV screens are generated by pixelwise mixing of the three primary colours red (R), green (G) and blue (B). This is called additive mixing of light. Digital images where the colour information is encoded by intensities of the primary colours are commonly referred to as RGB images. The three light components are called colour channels. For example, a 1:1 mixture of red (ca. 650 nm) and green (ca. 510 nm) at full intensity is perceived by the human eye as yellow (Y), the spectral wavelength of which is in between red and green at around 580 nm. Similarly, red and blue yield magenta (M) while green and blue give cyan (C). Cyan, magenta and yellow are so-called secondary colours. (See also Bit Depth of Digital Images)

Additive 1:1 mixing of the primary colors leads to the secondary colors yellow, magenta and cyan. The sum of all primary colors is white.

The three examples above show how different colours are generated in standard 24 bit RGB images by changing the intensities of the three colour channels. (Maximum intensity is 255.)
In colour printing the mixing is principally different because here it is not light sources that are mixed (such as the tiny phosphor dots of the monitors) but pigments, which are light absorbers. A yellow pigment absorbs in the blue range and a cyan pigment in the red, a mixture of both appears green. This is called subtractive mixing because each component removes part of the light spectrum from the reflected light. In this case the red and blue components are removed from white light and the remaining truncated spectrum (green-yellow-orange) appears yellow. Similarly, magenta pigments (absorbing green) mixed with yellow produce red while magenta and cyan give blue. The corresponding images are accordingly referred to as CMY images. A 1:1:1 mixture of the three types of pigments results in black. In practice, however, it appears rather dirty brown; this is why common colour printers contain black ink as well to generate four channel CMYK prints. K stands for "key" or "depth" and is used because B as in "black" is reserved for "blue").

Subtractive 1:1 mixing of the secondary colors leads to the primary colors red, green and blue.
Furthermore, there are other colour models such as HSB (Hue, Saturation or difference from white, Brightness or difference from black; also called HSV, V for value) and HLS (Hue, Lightness, Saturation). The latter shall be briefly discussed here. It is useful, for example, to generate overlay images of transmission and fluorescence data.
Hue defines the rainbow colour tone; it can be generated as a binary mixture of the RGB colours. The lightness dimension is a black-to-colour-to-white gradient. It gives the illumination or "whiteness" of a colour. The saturation measures how much a colour differs from neutral grey. A pure spectral colour has a lightness of 50% (127 in 24bit data) and a saturation of 100% (255 in 24bit data). A three-dimensional representation of this colour space is a double cone. In it the lower point is black, the upper one white and the centre of gravity grey. The pure rainbow colours are positioned along the circular edge with red being at 0° and cyan at 180° (127 in 24bit data). A perspicuous two-dimensional representation is shown below (modified from the graphics editing software.

R8 / G16 / B123 is converted into H166 / L224 / S66 (or H235° / L88% / S26%). H166 equals R0 / G24 / B254.