We show that the unitary evolution of a harmonic oscillator coupled to a
two-level system can be undone by a suitable manipulation of the two-level
system -- more specifically: by a quasi-instantaneous phase change. This
enables us to isolate the dissipative evolution to which the oscillator may be
exposed in addition. With this method we study the decoherence of a photon mode
in cavity QED, and that of the quantized harmonic motion of trapped ions. We
comment on the relation to spin echoes and multi-path interferometry.Comment: 4 pages, 2 figures; submitted to Physical Review A as a Rapid
Communicatio