Automatic lateral calibration of tunneling microscope scanners

A practical method is described to find automatically the calibration coefficients and residual nonorthogonality of a tunneling microscope scanner. As initial data, the coordinates of three atoms were used forming a triangle in a highly oriented pyrolytic graphite surface appearing in the form of a spatially geometrical measure. A recognition procedure is described which can be applied to determine the lateral coordinates of the atoms. Length and orientation distortions were calculated, estimates of calibration errors were given and the requirement on the nonorthogonality limit was formulated for manipulator a given that ensures measurements of the predetermined accuracy. The sensitivity of the method to a noise in atom coordinates was determined. Experimental data showing the practical suitability of the method developed are presented. © 1998 American Institute of Physics.@S0034-6748 ~98!00308-6#


I. INTRODUCTION
Today the scanning tunneling microscope ͑STM͒ is the ideal instrument for surface investigations of matter on an atomic scale; nevertheless, it possesses certain shortcomings which are mainly various kinds of distortion in obtained data.
It is known, for example, that in due course piezoceramics of the STM manipulators are dipoling, which leads to changes in the strain coefficients and errors in measurement.For elimination of the latter it is necessary to recalibrate the microscope periodically.However, manual calibration is a rather laborious process.
The subject of the present article includes questions concerning procedures of automatic determination of calibration coefficients 1 and an oblique angle, analysis of encountered errors, as well as finding the most suitable calibration objects.
This article also can be considered as an introduction to a special scanning method based on local recognition and connection of surface features. 1The approach permits us to suppress noise and to get rid of image distortions caused by thermodrift, [2][3][4][5] creep, 6 and hysteresis 2,5 practically completely.As a result the image contains only distortions produced by errors in determination of the calibration coefficients and oblique angle 3,4,7 as well as by size and form of the tip. 8Since the tip distortions do not disturb relative positions of the features composing calibration structure, true values of the calibration coefficients and oblique angle can be extracted from the image.

A. Procedure for the determination of the lateral coordinates of atoms
Often when investigating a surface of solids at the atomic scale, it is sufficient to have only information about the atom coordinates.Since the locations of the atom centers on the surface image obtained with the help of STM are not defined, a procedure should be developed which permits them to be found.The procedure desired is a recognition program that operates as follows.
The atomic relief of a surface given in a certain window is cut by a horizontal plane at height z.In other words, an operation of image segmentation is being carried out where the image components of interest are separated ͑i.e., atoms from the background͒ by threshold z.At that, a set of a priori noncrossing plane domains are being formed; at times, they have local violations of convexity, and are of noncircular shape.
The domain differences are brought forth by noise in a tunnel current stabilization system and scanning channels, which gives ''torn'' edges, by thermodrift and creep as well as by uneliminated distortions connected, in general, with geometrical dimensions of the probe tip and its shape.Quantitatively these differences can be evaluated by calculating the domain ''compactness:'' 9 Cϭ4S/L 2 , where S is the domain square, and L is the domain border length ͑it is easy to check out that in the case of a circle this magnitude is ''perfect,'' i.e., equal to unity͒.Thus, by defining the gravity centers of the obtained domains, the lateral coordinates of the atom centers on the surface can be found.
To determine the gravity centers it is necessary to know the coordinates of the points lying inside a domain and on its border, i.e., to be able to find out the domain contour and its closure, as well as to distinguish domains from each other.
The algorithm developed invokes steps similar to those described in the works of Sidhu and Boute, 9 Freeman, 10 Rosenfeld and Kak, 11 and represents the following sequence of operations: ͑1͒ An image given in a certain window is looked through until a point that has the height greater or equal to z is met.This is the first point belonging to the contour of a regular domain.The point found becomes the current point.
͑2͒ Eight points neighboring on the current one and forming the chain code 10 are looked through until a point is found with a height greater or equal to z.The point found that way becomes the current point.͑3͒ Item ͑2͒ is repeated until the first point of the domain border is met, i.e., the closure of the domain contour occurs.͑4͒ Knowing the coordinates of the domain contour, the coordinates of the gravity center of the domain at subpixel level can be calculated.͑5͒ Image points belonging to the recognized domain are assigned zero values.Provided the row and the column counters of the window being looked through do not reach the maximum value, a jump is made to item ͑1͒.
Note, that item ͑2͒ of the algorithm implies that the round trip over the neighbors is made, first, each time in the same direction and, second, in such a way that the initial point of the trip be an external point.
The recognition procedure permits direct calculation of the average lattice constant as well as, beside the atoms, to detect and to run statistics of other objects encountered in the image, such as isolated noise peaks ͑solitary pixels͒, isolated noise islets and threads ͑chains of pixels͒, merged atomic domains.Those recognized atoms situated near the edge of the image or cut by it are automatically rejected since the data collected on those domains are either much distorted because of the influence of edge effects or just wrong.Note here that long threads appearing parallel to the fast scan direction reveal surface contamination.
The larger squares of the atomic domains under investigation are, the more precisely the atom centers can be determined.The domain sizes depend on the cutting height z.Therefore, making ''scanning'' of surface relief along z from top to bottom and doing recognition iterations ͑25...35 times for image with 2 16 gray levels͒ it becomes possible to find such a height that being decreased by a minimum step, the atom domains start to merge with each other.The height thus obtained may be accepted as the optimal cut height.
The procedure is written in Pascal, the rate of recognition of atoms with 10...12 pixel contour, with simultaneous classification of the objects mentioned above, and statistics accumulation on a computer like the IBM PC 386DX/33 MHz, makes up 1000 atoms/s, approximately.For application of the procedure the image is recommended to be presmoothed, and the trend to be removed from it.
As an illustration to recognition procedure working the stylized image ͑272 atoms, average lattice constant 2.717 Å͒ is shown in Fig. 1͑b͒.This picture is obtained as a result of recognition of midsize STM 12 scan of highly oriented pyrolytic graphite ͑HOPG͒ in Fig. 1͑a͒.
The recognition procedure can be considered as a kind of filter-compressor since, at one hand, it ''smooths'' initial image producing a stylized surface, at other hand, it ''squeezes'' the data extracting the most valuable information from the picture.

B. Determination of the calibration coefficients and the angle of obliquity
The idea of the method consists in searching for the parameters for linear transformation of a distorted image with an a priori known structure which leads to obtaining the correct image.After that, using the parameters found, the same kind of manipulation is produced but now with images whose structure is unknown.
In order to find three unknowns, i.e., the K ¯x , K ¯y gains along the X, Y axes of the microscope piezomanipulators, respectively, and the oblique angle ␣, it is necessary to form a system of three equations.For that, in the general case it is sufficient to know the lateral coordinates of calibration surface six atoms, which form three different segments ͉AB͉ ϭk 1 a 1 , ͉CD͉ϭk 2 a 2 , and ͉EF͉ϭk 3 a 3 ͑where a 1 ,a 2 ,a 3 are lattice constants, k 1 ,k 2 ,k 3 are integer coefficients͒.
Since in an oblique coordinate system Pythagoras's theorem is not valid, for the next constructions the following linear transformation from an oblique system x ¯oy ¯connected with X, Y STM piezomanipulators to the rectangle xoy will be used xϭK ¯xx ¯ϩK ¯yy ¯sin ␣, yϭK ¯yy ¯cos ␣. ͑1͒ Further, a HOPG surface will be used as the calibration surface where the distances between ␤ atoms 13 are the same a 1 ϭa 2 ϭa 3 ϭa and equal to 2.464 Å. 14 To fix ideas, a particular case is considered where k 1 ϭk 2 ϭk 3 ϭkϭ2,4,8,..., and the measure segments placed so that their center points cross in one point, and the ends form a rectilinear hexagon; this will be named a ''star'' scheme.Thus, in the method under description, HOPG surface atoms and geometrical structure resulting from them serve as a spatially geometrical standard.
Using expression ͑1͒ we solve the system of equations composed for star beams.Finally, we obtain where y CD Ϫx CD y AB ); Jϭx AB ; Kϭy AB ; the designation x AB means the x A Ϫx B difference and y AB Ϫy A Ϫy B ͑the same for the other point pairs͒.
The last result can be obtained by using the property of equality of star beams.From the property only two independent equations can be formed but there are three variables.If Eq. ͑3͒ is divided by Eq. ͑2͒, the quantities a in the both coefficients will cancel out and the ratio K ¯y /K ¯x will then not depend on the a.Hence, introducing instead of the K ¯x , K ¯y coefficients the reduction coefficients K ¯x *ϭ1, K ¯y *ϭK ¯y /K ¯x , and solving the system with respect to the variables K ¯y * , ␣ we obtain where Nϭx CD y CD Ϫx AB y AB .
Thus, using the reduction calibration coefficients it is sufficient to carry out the calibration of one microscope manipulator in the usual way; the calibration coefficient of another manipulator can be made from their ratio, first having calculated a value of the reduction coefficient by the means of formula ͑5͒.
Let us now consider another particular case when the initial calibration structure is an equilateral triangle ͑kϭ1,2,3,...͒.It is easy to see that the formulae for calculation of the calibration coefficients and the oblique angle by ''triangle'' scheme have the form of Eqs.͑2͒-͑4͒, ͑5͒, ͑6͒ deduced earlier for the star; where instead of the former CD, EF indexes, the BC, AC ought to be used, accordingly.

C. Character and distortion values of a nonorthogonal STM scanner
In practice, in measurements carried out by STM images, the lattice constants and the angles between directions have most frequently to be determined.Therefore, if in the capacity of a characteristic element of the image a segment is chosen, its distortions caused by the scanner nonorthogonality can be subdivided into the distortions connected with the change of its length ⌬l and orientation ⌬o.
Using polar coordinates ͑xϭl 0 cos ␤ 0 , yϭl 0 sin ␤ 0 ͒, and also assuming K ¯xϭK ¯yϭ1, the distortions can be presented as follows: where l 0 , ␤ 0 are length and orientation ͑counted from ox axis in counter clockwise direction͒ of an initial nondistorted segment, accordingly.It is obvious from the above formulas that, if a segment under investigation is parallel to some coordinate axis, that is, ␤ 0 ϭ0 or ␤ 0 ϭ/2Ϫ␣, then the distortions ␦lϭ0, ⌬oϭ0 or ␦lϭ0, ⌬oϭ␣, accordingly.
Thus, the distortions of a nonorthogonal scanner are such that the segments placed parallel to the axes of the manipulators or to the coordinate axes on the screen do not suffer length distortions.Therefore, the commonly used method for microscope calibration by orienting the segment to be measured parallel to the axes works properly, though in practice it is not very suitable as it requires a sample rotation.It should be taken into consideration that the segments oriented in other directions are distorted, the degree of the distortions depending on the direction.
Let us determine the direction along which the segment is distorted most.For this, it will be rotated about the origin of coordinates and that direction will be sought where ␦l and ⌬o are maxima.Differentiating Eqs.͑7͒ and ͑8͒ by the variable ␤ 0 yields that the maximum length distortion of segment appears when it is oriented at an angle of for Ϯ␣, accordingly, and the maximum orientation distortion The dependencies ␦l(␣) and ⌬o(␣) which are shown in Fig. 2 are derived by substituting, respectively, ␤ 0 ϭ␤ 0 max into formulas ͑7͒ and ͑8͒.

D. Calibration object for direct determination of the calibration coefficients and angle of obliquity
Let us find now eigenvalues and eigenvectors of linear transformation inverse to Eq. ͑1͒.For that purpose a characteristic equation is composed solving which, one readily find that 1 ϭ1/(K ¯y cos ␣), 2 ϭ1/K ¯x .Substituting the eigenvalues obtained into system of equations and solving, we deduce that a set of segments placed along abscissa axes ␤ϭ␤ 0 ϭ0, as well as at an angle of ␤ϭ␤ 0 ϭ Ϫ␣/2 (K ¯xϭK ¯y) represents a family of eigenvectors of the linear transformation inverse to Eq. ͑1͒.Therefore, the orientation of the vectors in the transformation remains undistorted.Thus, the above analysis shows that the calibration object for direct measurements of calibration coefficients and an oblique angle must possess circular symmetry for excluding the necessity of orientation of the calibration segment along axes of coordinates and has to have a mark indicating its center.A good candidate here is a ring or series of concentric rings with known radii and height ͑for calibration of the Z manipulator͒.
The calibration procedure by the object under discussion can be reduced to the following steps.
͑1͒ Measure the lengths of two segments formed by the intersection of straight lines parallel to coordinate axes on the screen and passing through the center mark with the ring.The segments give calibration coefficients K ¯x and K ¯y .͑2͒ Transform the structural image to obtain scales along coordinates axes equal to each other (K ¯xϭK ¯y).͑3͒ Search such a direction of a straight line going through the structure center where the segment length formed at intersection of this line with the ring is equal to 1 D ͑D is the ring diameter͒.The direction obtained in that way corresponds to half the value of an obliquity angle being sought.
Note, that the method of direct calibration suggested here can be easily automated by applying the recognition procedure described in Sec.II A; for this, a mark of the structure center is no longer required.

E. Errors of STM calibration made without taking into account nonorthogonality of the scanner. Formulation of the requirement to limit allowable nonorthogonality in the manufacture of manipulators
Let us estimate the value of systematic calibration error which influences a measurement error of linear dimensions in a case when nonorthogonality of STM manipulators is neglected.For this, two pairs of calibration coefficients calculated from a skewed image must be found.One pair is K x and K y which corresponds to coefficients obtained as if the microscope scanner is orthogonal, i.e., without attention to its obliquity; and the second-K ¯x , K ¯y , vice versa, with regard for it.For this, the latter must be expressed not only in differences of initial coordinates but also through the angle ␣ which represents in that case its parameter.Finally, we obtain FIG. 2. The dependencies on obliquity angle ␣ of maxima distortions of segment length ␦l and orientation ⌬o, as well as relative error ␦l clb of measurement of linear dimensions when attention to nonorthogonality scanner at calibration is not paid (␤ 0 ϭ␤ 0 max ).

͑14͒
where Oϭx AB y CD ϩx CD y AB , Pϭx AB y CD Ϫx CD y AB , Q ϭx CD , Rϭy CD ; and a pair of K x , K y coefficients appears from the expressions above at the passage to the limit in fact, the coefficients are calibrations of the microscope with an orthogonal scanner obtained by two measured segments.Note, that by their meaning both pairs of coefficients must be positive, nonzero real numbers.
The maximum relative error of length measurement of some segment placed at an angle of Eq. ͑9͒, i.e., at an angle when its distortions manifest themselves most strongly, can be found by the formula

͑17͒
Figure 2 shows the character of change of ␦l clb as a function of an obliquity angle ␣.
Let us solve an inverse problem connected with searching for such an obliquity angle, which leads to a given error magnitude.It can be concluded from the ␦l(␣) graph that for achieving measurements of linear dimensions of surface elements with a relative error not worse than 1%, for instance, the technology of STM scanner must guarantee the nonorthogonality value of the manipulator's axes within the limits of the range Ϯ1.13°.At the same time, from the ␦l clb (␣) curve it is easy to see that manipulator nonorthogonality may be neglected agreeing to an error, for example, in 1% if ␣ by absolute value does not exceed 0.29°.

F. Sensitivity of the calibration coefficients and the oblique angle to errors in coordinates of initial data. Comparison of the triangle and star schemes
Let us define the method's sensitivity to errors in measurement of the atom positions, which are taken as the initial data for triangle and star schemes.As the calibration coefficients and the oblique angle are not being determined by a direct measurement, but rather computed by formulas, for estimation of errors ͑root mean squares͒ contained in their values the following expression must be calculated: where the atom centers' coordinates x A ,...,x F , y A ,...,y F measured with root mean square errors x A ,..., x F , y A ,..., y F , respectively, are put as variables, and the designation f, while calculating, is substituted by the functions: K ¯x ,K ¯y ,␣.
To simplify, let us assume that all errors in the atom center coordinates are equal to .For numerical estimates the value will be accepted less, at least by order, 2 than lateral resolution of the microscope, which amounts to ϳ1 Å.It corresponds to the relative error of measurement of graphite lattice constant length and makes up ϳ4%.
In view of what was said above, the formula ͑18͒ can be written as The multipliers before the partial derivatives are normalizing factors; they eliminate the error value dependence upon the particular decalibration degree of the microscope.It is necessary to note that the error values K ¯x, K ¯y, and ␣ are inversely proportional to the measure length k␣, therefore, it is reasonable to use calibration structures with large values of factor k.
Since the errors K ¯x, K ¯y themselves bring little information for the analysis of noise influence, it would be useful to pass over to error l of segment length determination ͑where l(x i ,y i )ϭͱx 2 (x i ,y i )ϩy 2 (x i ,y i )͒, which is to be found as it was done previously.
Quantities x(x i ,y i ), y(x i ,y i ) are calculated as follows.First, using transformation inverse to Eq. ͑1͒, let us express the coordinate differences x ¯,y ¯of some segment l via coordinates x,y assuming K ¯x , K ¯y , and ␣ as constants.After that, apply transformation ͑1͒ where calibration coefficients and obliquity angle are now functions of coordinates x i ,y i , i.e., K ¯x(x i ,y i ), K ¯y(x i ,y i ), ␣(x i ,y i ).By passing to polar coordinates, finally obtain where iϭA,B,...,F.Formula ͑19͒ is intended for computing the methodical errors of the star scheme.By omitting terms with D,E,F indexes and using the appropriate expressions for K ¯x , K ¯y , and ␣, it is possible to get the formula for definition of the errors in the triangle scheme.Since expression ͑19͒, when resolved analytically, looks bulky, the errors were determined numerically.
The obtained results can be analyzed by means of Fig. 3, which shows: the root mean square error ␣ of determination of an obliquity angle and relative error ␦l sys ϭ l /l 0 100% of determination of segment length produced by systematic errors of calculation of calibration coefficients and obliquity angle.The errors shown in the figure were obtained for two different schemes of calculations-triangle and star.
Analysis of the graphs leads to the conclusion that the oblique angle, determined by the triangle scheme, has a systematic error slightly less than the one obtained by the star scheme.As for the errors of segment length determination, there is practically no difference detectable between the schemes.The presented graphs show that at the error value ϭ0.1 Å ͑kϭ2, Ϫ15°р␣рϩ15°͒ the methodical error ␣ ͑triangle scheme͒ lies in the range of 2.24°-2.33°.Therefore, the method offered does not provide a precise determination of small oblique angles under high level of noise in the microscope.For example, at the error in determination of the atom center as low as ϳ0.03 Å, the relative error of measurement of a linear segment does not exceed 1% and the error of an oblique angle-1°.

A. Automatic calibration of the microscope and obliquity correction of the graphite image
Figure 4͑a͒ shows a distorted STM 15 image of HOPG surface undergone smoothing, with trend removed.By using the recognition procedure the lateral coordinates of the carbon atoms were determined ͓see Fig. 4͑b͒, a short summary of recognition results is adduced͔ and a surface image was built stylized by hemispheres ͓see  4͑a͒, and the second one, by directly applying formula ͑1͒ to the data shown in Fig. 4͑b͒.Coordinates z of atoms in all stylized images are reduced to monolayer ͑i.e., they are supposed to be equal͒.

B. Examples of application of recognition procedure
In Fig. 5͑a͒ an atomic force microscope 12 ͑AFM͒ image ͑tapping mode͒ of nanostructured aluminum surface 16 which was formed by electrochemical polishing of textured aluminum foil is shown.Using recognition procedure ͓see Fig. 5͑b͔͒ one can find number of elements, their average diameter ͑884 Å͒, average spacing between features ͑2034 Å͒, average height ͑41 Å͒.In addition variances and histograms of distributions for these magnitudes can be built.
The method described has been employed also for studying properties of atomically smooth films: MePhSiCl 2 , VOCl 3 , TiCl 4 , which are themselves ordered structures 17 made by the method of chemical assemblage.As the substrate, HOPG and mica ͑muscovite͒ were used serving as a conducting and dielectric matrix, respectively.With this, the matrix surface was accessible because of the discontinuity of the thin ͑30 Å͒ film.Since the research was carried out in air, where trustworthy spectroscopic data can hardly ever be obtained, the ''rightness'' of the surface topography has been of extreme significance for analysis of the structures under investigation.That is why a great attention was dedicated to revealing and compensating systematic errors as well as to searching for reliable calibration procedures for the instrument.

IV. DISCUSSION
The recognition procedure described is used for measurement of lattice constants, determination of the calibration coefficients and the manipulators' nonorthogonality.The procedure is useful because, first, it excludes a subjective factor from the measuring process, and second, saves much memory ͑15-20 times͒ and processing time while picture generation since now, instead of a surface image array, it is sufficient to store the coordinates of atom centers, displaying the image of atoms in a stylized form.
The triangle scheme proved to be a preferred solution compared with the star scheme since the former requires twice fewer initial data for realization as the latter with comparable methodical errors.It is also necessary to keep in mind that the calculated values of calibration coefficients and oblique angle are noise sensitive.This circumstance limits the precision achieved by the method in the determination of those quantities.
The compactness value averaged by several domains is a useful numerical characteristic that shows the microscope noise value and/or points out to the presence of local distortions.
It is important that the process of microscope calibration can be readily automated.By the way, recognition of the atom center within some set of calibration structures necessary for averaging of calibration coefficients and the obliquity angle could be substituted by determination of maxima in the space frequency spectrum calculated by a fast Fourier transform algorithm.After that, it becomes possible to extract the parameters of affine transformation directly from the spectrum as was suggested in works of J. F. Jo "rgensen et al. 4 and S. Carrara et al. 7 Choice of the best method here depends on the particular task under investigation.
As a rule, since different sources lead to the same sort of distortion, it is hard to point out their real origin or separate the influence of one source from another.Therefore, provided the surface image is subjected to the influence of a whole ''bouquet'' of systematic distortion factors, the method described permits one to determine the calibration coefficients and the oblique angle of some hypothetical scanner.Then, the correction procedure will help partially correct the image by deleting the linear parts of distortions caused by all those factors.

FIG. 1 .
FIG. 1. ͑a͒ An example of midsize graphite scan ͑128ϫ128 pixels, microscope is decalibrated͒.The measurements were made in constant Z mode at U tun ϭϪ100 mV, I tun ϭ300 pA.Average compactness 97.2%.͑b͒ The result of recognition-stylized surface of graphite.Carbon atoms are shown as hemispheres.
Figure4͑a͒shows a distorted STM15 image of HOPG surface undergone smoothing, with trend removed.By using the recognition procedure the lateral coordinates of the carbon atoms were determined ͓see Fig.4͑b͒, a short summary of recognition results is adduced͔ and a surface image was built stylized by hemispheres ͓see Fig.4͑c͔͒.With triangles A 1 B 1 C 1 and A 2 B 2 C 2 using formulas ͑2͒, ͑3͒, ͑6͒ the calibration coefficients K ¯xϭ0.965,K ¯yϭ0.940, and the oblique angle ␣ϭ9.037°͑kϭ4͒ were calculated and averaged.Figures 4͑d͒ and 4͑e͒ demonstrate the corrected images ͑average lattice constant is equal to 2.473 Å, ␦aϭ0.4%͒.The first picture was obtained by applying a lineshifting algorithm to the image in Fig.4͑a͒, and the second one, by directly applying formula ͑1͒ to the data shown in Fig.4͑b͒.Coordinates z of atoms in all stylized images are reduced to monolayer ͑i.e., they are supposed to be equal͒.

FIG. 3 .
FIG. 3. Methodical error ␣ of determination of oblique angle and relative methodical error ␦l sys of measurement of a linear segment for schemes of triangle and star (␤ 0 ϭ␤ 0 max ).

FIG. 5 .
FIG. 5. ͑a͒ AFM scan of aluminum surface which was made at electrochemical polishing process.͑b͒ Plane domains belonging to recognized surface elements are shown in lighter color.