A scanning probe microscope has a tilting stage on which a sample is
mounted. The sample is scanned back and forth with the stage being tilted
clockwise during a forward scan and counterclockwise during a reverse
scan. A first surface contour of the sample is determined from the
response of the probe and the tilt angle of the stage during the forward
scan. A second surface contour of the sample is determined from the
response of the probe and the tilt angle of the stage during the reverse
scan. A final surface contour of the sample is obtained by combining the
first and second surface contours.