The lateral force induces a torsional motion in the cantilever for an atomic force microscope. This phenomenon affects not only the surface image but also the force curve. The two-dimensional deflections of the cantilever under several force curve measurement conditions are investigated using the heterodyne interferometer. In most cases, the deflection agrees well with that obtained theoretically from linear static analysis. At some points on a rough sample surface, undesirable behaviors are seen in both force curve and two-dimensional deflection of the cantilever. The relation between the force curve and the deflection of the cantilever is investigated in detail experimentally and theoretically.