  We present a nanoscale color detector based on a single-walled carbon
nanotube functionalized with azobenzene chromophores, where the chromophores
serve as photoabsorbers and the nanotube as the electronic read-out. By
synthesizing chromophores with specific absorption windows in the visible
spectrum and anchoring them to the nanotube surface, we demonstrate the
controlled detection of visible light of low intensity in narrow ranges of
wavelengths. Our measurements suggest that upon photoabsorption, the
chromophores isomerize from the ground state trans configuration to the excited
state cis configuration, accompanied by a large change in dipole moment,
changing the electrostatic environment of the nanotube. All-electron ab initio
calculations are used to study the chromophore-nanotube hybrids, and show that
the chromophores bind strongly to the nanotubes without disturbing the
electronic structure of either species. Calculated values of the dipole moments
support the notion of dipole changes as the optical detection mechanism.
