*What are pigments used for?*
Pigments are used for adding colour to a material that might otherwise be colourless or have a dull colour.
*How do they work?*
Light is made up of different wavelengths. Each wavelength range translates to a different colour when perceived by the human eye. White light appears white because it combines all the different wavelengths together.
Pigments absorb all ranges of wavelengths except one, which is reflected. This is the wavelength range that is then transmitted to the eye. The eye perceives this wavelength range as a particular colour.
Different pigments reflect different ranges of wavelengths. For example, a blue pigment appears blue because it reflects the range of wavelengths that make up blue light, but absorbs all other wavelengths.