  We increase the dynamical range of a scanning tunneling microscope (STM) by
actively subtracting dominant current-harmonics generated by nonlinearities in
the current-voltage characteristics that could saturate the current
preamplifier at low junction impedances or high gains. The strict phase
relationship between a cosinusoidal excitation voltage and the
current-harmonics allows excellent cancellation using the displacement-current
of a driven compensating capacitor placed at the input of the preamplifier.
Removal of DC currents has no effect on, and removal of the first harmonic only
leads to a rigid shift in conductivity that can be numerically reversed by
adding the known removal current. Our method requires no permanent change of
the hardware but only two phase synchronized voltage sources and a
multi-frequency lock-in amplifier to enable high dynamic range spectroscopy and
imaging.
