In some cases, chemical trap is used to detect or infer a compound when present at concentrations below its detection limit or is  present in a mixture, where other components interfere with its detection. The trapping agent, for example a dye, reacts with the chemical to be detected, giving a product that is more easily detected.