  Laser cooling and trapping of atoms and atomic ions has led to numerous
advances including the observation of exotic phases of matter, development of
exquisite sensors and state-of-the-art atomic clocks. The same level of control
in molecules could also lead to profound developments such as controlled
chemical reactions and sensitive probes of fundamental theories, but the
vibrational and rotational degrees of freedom in molecules pose a formidable
challenge for controlling their quantum mechanical states. Here, we use
quantum-logic spectroscopy (QLS) for preparation and nondestructive detection
of quantum mechanical states in molecular ions. We develop a general technique
to enable optical pumping and preparation of the molecule into a pure initial
state. This allows for the observation of high-resolution spectra in a single
ion (here CaH+) and coherent phenomena such as Rabi flopping and Ramsey
fringes. The protocol requires a single, far-off resonant laser, which is not
specific to the molecule, so that many other molecular ions, including
polyatomic species, could be treated with the same methods in the same
apparatus by changing the molecular source. Combined with long interrogation
times afforded by ion traps, a broad range of molecular ions could be studied
with unprecedented control and precision, representing a critical step towards
proposed applications, such as precision molecular spectroscopy, stringent
tests of fundamental physics, quantum computing, and precision control of
molecular dynamics.
