In the real world, most oscillations are subject to damping and so the amplitude of the oscillation dies away over time. For example, the bell mentioned earlier would not be very effective if it did not lose some of its energy as sound waves. The oscillating cantilever of the AFM will, like the simple mass-spring system, be subject to frictional forces from the air, the material of the cantilever itself, and the fixing point.
For the mass-spring system the damping force Fd will be proportional to the velocity v of the oscillating mass, so:
where b is a positive constant called the damping coefficient. The negative sign appears because the force is opposing the motion. To understand how this affects the results that I obtained for the simple harmonic oscillator, see the input on the damped harmonic oscillator below.