## Abstract

The study compares three variants of focus sensors designed for the optical topography measurement of rough surface specimens with submicron accuracy. We present a theoretical analysis of the focus sensor principles and the experimental measurements with a single point laser probe. A low coherent illumination beam was provided by a monochromatic laser source and a rotating diffuser, which reduced the speckles generated by the rough surface. The reflected beam was modulated by three specific optical elements (axicon, double wedge prism, four spherical lenses) realized by a spatial light modulator. A digital camera detected the output intensity patterns that were evaluated by the intensity centroid method. The results showed a good coincidence of the surface profiles obtained by the three sensor variants with the root-mean-square deviations below one micron. We discuss the results obtained for several specimens with various surface roughness and compare the differences between the three focus sensor variants.

© 2019 Optical Society of America under the terms of the OSA Open Access Publishing Agreement

## 1. Introduction

Optical measurement of surface topography represents an important area of scientific and industrial practice which deals with the specimen surface characterization and the detection of deviations from the intended shape. The optical measurement methods developed over the past decades [1–3] include for example phase-shifting interferometry [4], white light interferometry [5], confocal microscopy [6], structured light projection [7], point autofocus instruments [8], or digital holography microscopy [9]. Each method has its advantages and limitations that determine its accuracy and the corresponding class of measurable specimens or workpieces. For optical quality surfaces, the most accurate measurement methods use the laser interferometry that provides nanometer (or even subnanometer) resolution. For optically rough surfaces, other methods showing higher uncertainty are needed as the measurement is complicated by speckles generated by a diffuse reflection of coherent or partially coherent light from the illuminated surface.

The deviations from the intended specimen shape are widely recognized as errors of form, waviness and surface roughness [3]. The form measurement of the rough surface specimens is especially important between the consecutive steps of their manufacturing process. For example in the fabrication of the glass optical elements, such as lenses, it is desirable to verify (measure) the correctness of the overall form of the rough surface specimen after grinding or milling before the final fine polishing. Here, the form topography measurement that averages the surface profile over a larger area is needed because the grinding process affects the lens surface even over several square millimeters. A single point autofocus instrument represents a suitable option that provides submicron accuracy and the optional scanning density that should reflect the size of the grinding tool and thus does not necessarily go to too fine details. The resolution on a submicron level might allow an overlap with a measuring range of an interferometer (one interference fringe) on specimens with roughness close to polished optical quality and thus a potential design of a combined sensor. A commercially available point autofocus instrument has an optical focus sensor system based on the beam offset method [10,11]. Other possible setups of the focus sensor, also known from the optical pickups in the storage devices, could be based on astigmatic lens [12,13], ring lens [14], double wedge prism [15], knife-edge [16], or the critical angle method of total reflection [17].

In this paper, we present a comparative study of three optical focus sensor variants designed primarily for the form measurement of the rough surface specimens with the desired submicron accuracy. We deal with the theoretical analysis of the focus sensor principles and the experimental measurements realized by a single point laser probe with a high-numerical-aperture objective lens. The experimental probe used a monochromatic laser beam with a low spatial coherence achieved by a rotating diffuser in order to reduce the speckles generated by the rough surface. The reflected beam was modulated by one of the specific optical elements (axicon, double wedge prism, four spherical lenses) representing the three focus sensors. This was flexibly realized by computer generated holograms (CGH) displayed on a spatial light modulator (SLM). The output intensity patterns were spatially scaling proportionally to the distance of the specimen surface from the objective focal plane. The output patterns were detected by a digital camera and evaluated by the intensity centroid method. With the probe, we carried out transverse scanning along the surface of several specimens with a different surface roughness using a nano-positioning linear stage. The results showed a close coincidence of the surface profiles measured by the three focus sensors with the root-mean-square deviations in the submicron range. We discuss the results obtained for the tested specimens and compare the differences between the three focus sensors.

The paper is organized as follows: Section 2 deals with the theoretical principles of the three focus sensors and the evaluation procedure of the output intensity patterns. Section 3 describes the experimental setup and the measurement procedure. Section 4 presents and discusses the experimental results and Section 5 concludes the paper.

## 2. Principles

#### 2.1 Focus sensor

The general concept of the optical focus sensor, shown in Fig. 1(a), uses an input laser beam that propagates through a beam splitter and is focused by an objective lens onto the surface of the specimen. The reflected beam propagates to a modulation element that generates an output intensity pattern in the detector plane. The displacement $\mathrm {d}z$ of the specimen surface relative to the objective focal plane results in the spatial transformation of the output intensity pattern, e.g. shearing, scaling or rotation. The pattern change is detected and converted to a focus error signal that is proportional to the displacement $\mathrm {d}z$ in the corresponding measurement range. The focus error signal is used to detect the in-focus position of the specimen surface, which allows for the profile height determination.

The focus sensors tested in this paper are based on three specific modulation elements for which the transformation of the output patterns is given by spatial scaling. The first case, shown in Fig. 1(b), is a combination of an axicon with a spherical lens that generates a thin circular ring in the lens focal plane [18–20]. To our knowledge, this configuration has not been used as a focus sensor so far, but is similar to the ring lens [14]. The second case, shown in Fig. 1(c), is a previously described combination of a double wedge prism with a spherical lens [15] that generates two spots in the lens focal plane. The third case, shown in Fig. 1(d), is a set of four identical coplanar spherical lenses with their centers in vertices of a square (each lens touches two of the others) that generate four spots in a common focal plane. This configuration was inspired by an autofocus sensor system used in the digital cameras [21,22].

The optical setup of the focus sensors shown in Fig. 1 is characterized by an effective focal length $f$ and a numerical aperture $N\!A$ of the microscope objective, the focal length $F$ of the spherical lens (or lenses), and a refractive index of air $n_0$. The axicon and the wedge are described by a refractive index $n$ and an inclination angle $\beta$. When illuminated by a collimated beam corresponding to $\mathrm {d}z = 0$, the refracted light rays behind the axicon or the wedge make with the optical axis an angle $\alpha = \arcsin (\frac {n}{n_0}\sin \beta )-\beta \approx \frac {n-n_0}{n_0} \beta$. The four lenses are parametrized by a distance $r_{\mathrm {l}}$ between an individual lens center and the optical axis, and a lens diameter $D_{\mathrm {l}} = \sqrt {2}\, r_{\mathrm {l}}$. The circular ring generated by an axicon is characterized by its radius $\rho _{\mathrm {a}}$. The individual spots generated by a wedge or four lenses are described by their distance $\rho _{\mathrm {w}}$ or $\rho _{\mathrm {l}}$ from the optical axis, respectively.

The spatial scaling of the output intensity patterns can be analyzed using the geometrical optics and the paraxial approximation. Using [19,21] we found that the ring radius $\rho _{\mathrm {a}}$ and the spot distances $\rho _{\mathrm {w}}$ and $\rho _{\mathrm {l}}$ depend on the displacement $\mathrm {d}z$ according to the following formulas:

The quantities $\rho _{\mathrm {a}0}$, $\rho _{\mathrm {w}0}$ and $\rho _{\mathrm {l}0}$ represent the in-focus values of the ring radius and the spot distances, respectively, corresponding to $\mathrm {d}z = 0$. The quantities $H_{\mathrm {a}}$, $H_{\mathrm {w}}$ and $H_{\mathrm {l}}$ denote the proportionality constants given by the parameters of the optical setup and represent the slope of the dependence curves (lines) $\rho _{\mathrm {a}} (\mathrm {d}z)$, $\rho _{\mathrm {w}} (\mathrm {d}z)$ and $\rho _{\mathrm {l}} (\mathrm {d}z)$, respectively. Note that $H_{\mathrm {a}}$ and $H_{\mathrm {w}}$ are negative constants while $H_{\mathrm {l}}$ is positive, which is given by the different configuration of the modulation elements. The Eqs. (1) – (3) reveal that $H_{\mathrm {a}}$, $H_{\mathrm {w}}$ and $H_{\mathrm {l}}$ are proportional to the factors $N\!A / f$ or $1 / f^2$ which are essentially equivalent. This indicates that a microscope objective with short focal length and high numerical aperture has to be used in order to achieve the high slope of the dependence curves $\rho _{\mathrm {a}} (\mathrm {d}z)$, $\rho _{\mathrm {w}} (\mathrm {d}z)$, $\rho _{\mathrm {l}} (\mathrm {d}z)$ and, therefore, a sufficient signal-to-noise ratio in the experimental measurement. This issue is also closely related to the known dependence of the measurement uncertainty on the numerical aperture of the optical sensors [23].#### 2.2 Wavefront modulation with SLM

The modulation elements of the three focus sensors can be flexibly realized by computer generated holograms displayed on a phase-only spatial light modulator. To keep a close analogy with refractive optical elements, we used the off-axis Fresnel holograms [24] which directly generate the output patterns in the detector plane without additional optics. Denoting the laser wavelength $\lambda$ and the wave number $k = 2 \pi / \lambda$, we expressed the wave modulation functions of the CGHs using the Cartesian coordinates $(x,y)$ and the radial distance $r = (x^2+y^2)^{1/2}$. The complex modulation functions $T_{\mathrm {a}}$, $T_{\mathrm {w}}$ and $T_{\mathrm {l}}$ corresponding to the three focus sensor variants (see Fig. 2) were given by the formulas:

- • Four lenses:$$\begin{aligned} T_{\mathrm{l}} (x,y) =\, & A_{\mathrm{l}} \exp( \mathrm{i} \phi_{\mathrm{l}} ) = \{ \mathrm{circ}\left(2r/D_{\mathrm{l}}\right) \exp[ - \mathrm{i} k r^2 / 2 F ] \}\\ & \ast [ \delta(x-r_{\mathrm{l}},y) + \delta(x+r_{\mathrm{l}},y) + \delta(x,y-r_{\mathrm{l}}) + \delta(x,y+r_{\mathrm{l}})], \end{aligned}$$

To correctly implement the Fresnel holograms corresponding to Eqs. (4) – (6), it was necessary to detect the intersection of the optical axis with the SLM plane which defines the origin of the coordinate system. This issue is described in more detail in Section 3.2.

#### 2.3 Evaluation of output intensity patterns

The output intensity patterns were detected by the digital camera and the pixelated images were evaluated by an intensity-weighted centroid method (see Fig. 3). The intensity values $I(x,y)$ given in the Cartesian coordinates were evaluated within the predefined domains chosen with respect to the symmetry and spatial transformation of the output patterns. For axicon, the intensity-weighted ring radius $\rho _{\mathrm {a}}$ was calculated in an annular domain $\Omega _{\mathrm {a}}$ with the mean radius $\rho _{\mathrm {a}0}$ and width $c_{\mathrm {a}}$. For wedge prism, the distance $\rho _{\mathrm {w}}$ was obtained as the average of the individual spot positions on the $x$-axis calculated within two rectangular domains $\Omega _{\mathrm {wi}}$ of width $c_{\mathrm {w}}$ and height $d_{\mathrm {w}}$ centered at the in-focus spot positions. Similarly for four lenses, the distance $\rho _{\mathrm {l}}$ was obtained as the average of the individual spot positions on the $x$- or $y$-axis calculated within four rectangular domains $\Omega _{\mathrm {li}}$ of width $c_{\mathrm {l}}$ and height $d_{\mathrm {l}}$ centered at the in-focus spot positions. Using the radial distance $r = (x^2+y^2)^{1/2}$, the quantities $\rho _{\mathrm {a}}$, $\rho _{\mathrm {w}}$ and $\rho _{\mathrm {l}}$ and the evaluation domains were given by the following equations:

- • Four lenses:$$\rho_{\mathrm{l}} = \frac{1}{4} \left ( \frac{\sum_{\Omega_{\mathrm{l}1}} x I(x,y) }{\sum_{\Omega_{\mathrm{l}1}} I(x,y) } - \frac{\sum_{\Omega_{\mathrm{l}2}} x I(x,y) }{\sum_{\Omega_{\mathrm{l}2}} I(x,y) } + \frac{\sum_{\Omega_{\mathrm{l}3}} y I(x,y) }{\sum_{\Omega_{\mathrm{l}3}} I(x,y) } - \frac{\sum_{\Omega_{\mathrm{l}4}} y I(x,y) }{\sum_{\Omega_{\mathrm{l}4}} I(x,y) } \right ),$$$$\begin{aligned}&\Omega_{\mathrm{l}1} : |x - \rho_{\mathrm{l}0}| \leq \tfrac{1}{2} c_{\mathrm{l}} \,, |y| \leq \tfrac{1}{2} d_{\mathrm{l}} \,, \qquad \Omega_{\mathrm{l}2} \, : |x + \rho_{\mathrm{l}0}| \leq \tfrac{1}{2} c_{\mathrm{l}} \,, |y| \leq \tfrac{1}{2} d_{\mathrm{l}} \nonumber \,, \\ &\Omega_{\mathrm{l}3} : |y - \rho_{\mathrm{l}0}| \leq \tfrac{1}{2} c_{\mathrm{l}} \,, |x| \leq \tfrac{1}{2} d_{\mathrm{l}} \, , \qquad \Omega_{\mathrm{l}4} \, : |y + \rho_{\mathrm{l}0}| \leq \tfrac{1}{2} c_{\mathrm{l}} \,, |x| \leq \tfrac{1}{2} d_{\mathrm{l}} \nonumber \,.\end{aligned}$$

#### 2.4 Detection of in-focus position

The surface topography measurement using the optical focus sensor is based on the detection of the specimen surface position relative to the objective focal plane (see Fig. 4). In a given measurement point, the in-focus position is found by scanning along the normal to the specimen surface ($z$-axis) which is usually realized by moving the objective lens with a piezoelectric positioner. An alternative option we used in our experiments with a fixed objective is moving the specimen with a piezoelectric linear stage. For a discrete set of displacements $\mathrm {d}z_{\mathrm {i}}$ we detected the values $\rho _{\mathrm {i}}$ of the ring radius or the spot distance. For the measured dependence curve $\rho (\mathrm {d}z)$ we used the known in-focus value $\rho _0$ given by Eqs. (1) – (3) to calculate the displacement $\mathrm {d}z_0$ for which the specimen surface was located in the objective focal plane. Using a linear interpolation between the two nearest points $[\mathrm {d}z_{\mathrm {i}},\rho _{\mathrm {i}}]$ and $[\mathrm {d}z_{\mathrm {i+1}},\rho _{\mathrm {i+1}}]$ we found that

## 3. Experimentation

#### 3.1 Experimental setup

The experimental setup, shown in Fig. 5, used a 100 mW diode pumped solid state laser source (Cobolt Samba) with the temperature stabilization operating at the wavelength $\lambda = 532.1\,\mathrm {nm}$. The laser beam power was adjusted by a neutral-density filter. An optical isolator prevented the laser source from the possible unwanted back-reflections from the optical setup. The laser beam was spatially filtered and collimated by a fiber optic delivery system that consisted of a zero-order half-wave plate, a focusing aspheric lens, a polarization maintaining optical fiber and a collimator. A second half-wave plate was used to rotate the polarization plane of the linearly polarized Gaussian laser beam. The spatial coherence of the laser beam was reduced by a rotating diffuser located in a common focal plane of a two-lens telescope consisting of a focusing lens L1 (achromatic doublet, 100 mm focal length) and a collimating lens L2 (tube lens, 200 mm focal length). The in-house built rotating diffuser made from the 50.8 mm diameter ground glass (Thorlabs DG20-1500, grit 1500) was powered by a high-speed DC motor (Maxon A-max 22) rotating with the frequency of 77 Hz. The diffuser was mounted on a two-axis linear stage with the micrometric screws that allowed for its precise positioning into the common focal plane of the telescope lenses. A 25.4 mm cube polarizing beam splitter directed the input beam to a quarter-wave plate that changed the linear polarization to circular and vice versa. An infinity-corrected microscope objective (50X Mitutoyo Plan Apochromat, $f = 4.0\,\mathrm {mm}$, $N\!A = 0.55$) with a long working distance of 13 mm focused the input laser beam onto the specimen surface where the laser spot had a diameter of $1.2\,$µm. The precise positioning and the scanning of the specimen surface was enabled by a piezo ceramic nano-positioning linear stage (PI P-527.3CL) with integrated capacitive sensors and $200\,$µm travel range in both $x$- and $z$-axis. The reflected beam propagated further through a pair of identical tube lenses L3 and L4 (200 mm focal length) forming a 4-f optical system that imaged the objective rear focal plane to the SLM plane. The laser beam was modulated by the computer-generated holograms displayed on a phase-only LCoS-SLM (Hamamatsu X13138-01) with an active area 16.0 mm $\times$ 12.8 mm and $12.5\,$µm pixel pitch. The output intensity patterns formed in the first diffraction order were detected by a monochrome digital CCD camera (Basler avA2300-25gm) with the sensor dimensions 12.8 mm $\times$ 9.6 mm (or 2330 $\times$ 1750 pixels), $5.5\,$µm pixel pitch and 8 bit resolution. A personal computer with Matlab software was used to operate the electronic devices (nano-positioning stage, SLM, digital camera) during the experimentation and to evaluate the measured data. The whole optical setup was covered by an enclosure to minimize airflow.

#### 3.2 Measurement procedure and parameters

The experimentation started with the calibration procedures performed without the rotating diffuser for a Gaussian laser beam and a plane mirror (Thorlabs BB1-E02) located in the objective focal plane. First, we used a self-developed method to detect the intersections of the optical axis with the digital camera and the SLM which define the origins of the Cartesian coordinate systems in the corresponding planes. The origin point in the camera plane was found as an intensity centroid calculated from the detected transverse intensity profile of the collimated Gaussian beam. The origin point in the SLM plane was identified as the center of the Fresnel lens that focused the Gaussian beam into the origin point in the camera plane. This was found by moving the lens center in a rectangular grid, detecting the corresponding focused spot positions and calculating the mutual coordinate transformation by solving an overdetermined system of linear equations using the least squares method [27]. The approximate solution for the origin point coordinates in the SLM plane was associated with an error expressed by the standard deviation of $2.0\,$µm in both x- and y-axis, which corresponds to 16% of the SLM pixel pitch. As a next step, we used a wavefront correction method [28] to eliminate the wavefront aberrations caused by the imperfections of the optical setup adjustment. The detected phase correction pattern was added to the CGHs in all subsequent measurements.

The surface topography measurements using the three focus sensors described in Section 2 were conducted with the rotating diffuser on a total of six specimens with a different surface roughness. As a first specimen, the plane mirror (Thorlabs BB1-E02) was used to investigate the differences in performance of the tested methods between the polished, optical quality surfaces and the rough surfaces. Five flat ground glass specimens provided by our partner company (Meopta – optika, s.r.o., Přerov, Czech Republic) represented varying surface roughness corresponding to the different stages of the grinding process. The specimens were characterized by the indicative values of the root-mean-square roughness parameter $R_{\mathrm {q}} \in \{0.4, 0.5, 0.7, 0.9, 1.1\}$ µm.

The axicon and the wedge generated by the SLM had the same angle $\alpha = 0.138^{\circ }$ which would be achieved by an equivalent glass optical element with the inclination angle $\beta = 0.3^{\circ }$ and the refractive index $n = 1.46$. The accompanying Fresnel lens had the same focal length $F = 400\,\mathrm {mm}$. The output intensity patterns were characterized by the in-focus ring radius and spot distance $\rho _{\mathrm {a}0} = \rho _{\mathrm {w}0} = 0.963\,\mathrm {mm} = 175.2 \,\mathrm {px}$. The evaluation domains were specified by the parameters $c_{\mathrm {a}} = c_{\mathrm {w}} = d_{\mathrm {w}} = 200 \,\mathrm {px}$. The four Fresnel lenses generated by the SLM were characterized by the distance $r_{\mathrm {l}} = 1.35\,\mathrm {mm}$, the diameter $D_{\mathrm {l}} = 1.90\,\mathrm {mm}$ and the same focal length $F = 400\,\mathrm {mm}$. The in-focus spot distance was $\rho _{\mathrm {l}0} = 1.35\,\mathrm {mm} = 245.5\,\mathrm {px}$ and the evaluation domains were given by the parameters $c_{\mathrm {l}} = 300 \,\mathrm {px}$ and $d_{\mathrm {l}} = 200 \,\mathrm {px}$. A common measurement parameter was the integration time of the digital camera set to 13 ms, which was equivalent to one period of diffuser rotation. The relative laser power used for axicon, wedge and four lenses was given by the ratio $25.1 : 1.0 : 4.0$. The scanning of the specimen surface along the $x$-axis was conducted in the $200\,$µm range with $0.5\,$µm step. At each measurement point $x$ the scanning along the $z$-axis was performed from $\mathrm {d}z = -5\,$µm to $\mathrm {d}z = +5\,$µm with $0.5\,$µm step. The trajectory scanned on a single specimen was virtually identical for the measurements with all three focus sensors, which was achieved by the high-precision nano-positioning linear stage. The camera images of the output intensity patterns were stored in the PC for subsequent evaluation.

## 4. Results and discussion

The camera images shown in Fig. 6 demonstrate the scaling of the output intensity patterns due to the displacement $\mathrm {d}z$ and reveal the differences between the polished and rough surfaces. For a plane mirror, the change of the ring radius and the spot distances is clearly visible since their intensity profiles are relatively symmetrical. For a ground glass specimen, the output ring and spots are deformed by the intensity fluctuations caused by the surface roughness and the imperfect speckle reduction with the rotating diffuser. Even though the change of the mean ring radius and spot distances is less visible, it is still detectable by the intensity centroid method with the sufficient signal-to-noise ratio. In order to achieve these results, it was crucial to have the rotating diffuser well implemented so that the axis of its rotation was stable. An unwanted precession motion or other instabilities might result in the deformations and blurring of the output patterns and the decrease of the signal-to-noise ratio.

The dependence curves $\rho (\mathrm {d}z)$ between the displacement $\mathrm {d}z$ and the ring radius or spot distances are presented in Fig. 7 to illustrate their different character for the three focus sensor variants and different surface roughness. For the plane mirror, the experimentally measured curves $\rho (\mathrm {d}z)$ are relatively smooth and approximately linear within the range $\mathrm {d}z \in [-3,3]$ µm but their slope is slightly different from the slope of the theoretically calculated lines. The Eqs. (1)–(3) provided the theoretical values for axicon and wedge $H_{\mathrm {a}} = H_{\mathrm {w}} = -10\,\mathrm {px}/$µm and for four lenses $H_{\mathrm {l}} = 12.3\,\mathrm {px}/$µm. The linear regression of the experimentally measured curves within the interval $\mathrm {d}z \in [-3,3]$ µm yielded the values $H_{\mathrm {a}} = -11.7\,\mathrm {px}/$µm, $H_{\mathrm {w}} = -7.6\,\mathrm {px}/$µm and $H_{\mathrm {l}} = 10.9\,\mathrm {px}/$µm. The differences between theory and experiment can be explained by the intrinsic shape change of the output intensity patterns which is most visible for the two spots generated by the wedge. This change caused by the wave nature of light was not considered in the theoretical calculations made within the frame of geometrical optics. For the ground glass specimen, the experimentally measured dependence curves $\rho (\mathrm {d}z)$ significantly vary in shape along the $x$-axis due to the surface roughness. The deformations are most visible for the wedge generating only two small spots and least apparent for the axicon forming a full circular ring. Further analysis showed that the dependence curves $\rho (\mathrm {d}z)$ are generally more deformed for the specimens with the higher surface roughness. The results indicate that the output patterns with the larger illuminated area can provide higher signal-to-noise ratio but at the cost of more time-consuming evaluation. Note that the total area of the circular ring, two spots and four spots generated by the axicon, wedge and four lenses, respectively, approximately corresponded to the ratio of $25 : 1 : 4$. The average evaluation time for a single camera image in the Matlab software was 17 ms, 4 ms and 12 ms for axicon, wedge and four lenses, respectively.

The main experimental results shown in Fig. 8 represent the surface profiles of the five ground glass specimens measured by the three focus sensors. In metrological terminology, the displayed primary profiles $z(x)$ were obtained from the extracted profiles by subtracting their mean values. The comparison of the primary profiles obtained for individual specimens by the three focus sensors exhibit a close coincidence which indicates the consistency of the measurement results obtained by different methods. To analyze the primary profiles, we considered the traverse length of $200\,$µm to be equal to an evaluation length and to a sampling length. This was justified by the short traverse length which allowed for the experimental testing of the focus sensors but was insufficient for the distinction between the surface roughness and the waviness. Therefore, the entire primary profiles without any additional filtering were used to calculate the parameters describing their roughness, maximum height, mutual deviations and random noise.

The root-mean-square roughness parameter $P_{\mathrm {q}}$ is shown in Fig. 9(a) together with the indicative reference values of the root-mean-square roughness parameter $R_{\mathrm {q}}$ provided by the specimen manufacturer. The $P_{\mathrm {q}}$ values obtained for the individual specimens by the three focus sensors differ only in tens of nanometers and approximately match the reference value $R_{\mathrm {q}}$ ranging from $0.4\,$µm to $1.1\,$µm. The maximum profile heights $P_{\mathrm {t}}$ presented in Fig. 9(b) reach several micrometers and differ in hundreds of nanometers for a single specimen. Large differences in $P_{\mathrm {t}}$ values were usually caused by the erroneous peaks in the primary profiles which were most frequent for the wedge and least frequent for the axicon. The erroneous peaks occurred when the measured dependence curves $\rho (\mathrm {d}z)$ were significantly deformed and had the misleading local minima or maxima.

To compare the profiles obtained for a single specimen by the different focus sensors, we calculated the root-mean-square deviations RMS between the three possible profile pairs. The results summarized in Fig. 9(c) show that the RMS deviations are in the range from $0.21\,$µm to $0.46\,$µm and their values generally increase with increased surface roughness. The RMS deviations between the profiles obtained for axicon and wedge or axicon and four lenses are relatively lower, the deviations for wedge and four lenses are relatively higher. However, the RMS deviations still remain within the submicron range for all compared profile pairs.

The random noise was determined using the multiple measurements ($N = 10$) acquired at eleven equidistantly spaced points along the $x$-axis for the displacement $\mathrm {d}z = 0$. At each point $x$, we used $N$ values of the displacement $\mathrm {d}z$ measured by the nano-positioning stage and $N$ detected values of the ring radius or the spot distances to determine the corresponding standard deviations. Averaging over the eleven points $x$, we obtained the standard deviations $\sigma _{\mathrm {d}z}$ and $\sigma _{\mathrm {\rho }}$ which were further associated with the points $\mathrm {d}z_{\mathrm {i}}$, $\mathrm {d}z_{\mathrm {i+1}}$ and $\rho _{\mathrm {i}}$, $\rho _{\mathrm {i+1}}$ considered in Eq. (10) for the in-focus displacement $\mathrm {d}z_0$. Using the law of error propagation, we found the corresponding standard deviation $\sigma _{\mathrm {d}z_0}$ given by the formula

The mutual comparison of the parameters presented in Fig. 9 shows that the RMS deviations represent approximately 40% to 60% of the profile roughness $P_{\mathrm {q}}$ and about 7% to 12% of the maximum profile height $P_{\mathrm {t}}$ (the higher percentage corresponds to the lower surface roughness). This means that all tested focus sensors provide the primary profiles with a sufficient signal-to-noise ratio. The random noise $\sigma _{\mathrm {z}}$ is about ten to hundred times smaller than the profile roughness $P_{\mathrm {q}}$ which indicates good potential for high measurement precision when the systematic errors are minimized or calibrated. Together, the RMS deviations and the random noise $\sigma _{\mathrm {z}}$ indicate that all tested focus sensors can measure the primary profiles with the desired submicron accuracy.

However, a thorough assessment of measurement uncertainties is a very demanding process which is beyond the scope of this comparative study. In general, a combined measurement uncertainty corresponding to the detected primary profiles is given by the contributions from the random and systematic error sources. The random errors are caused by the amplitude modulation of the laser beam, the fluctuations of the refractive index along the beam path, the vibrations of the rotating diffuser and the noise of the nano-positioning linear stage, SLM chip and CCD sensor. The systematic errors are caused by the misalignment of the optical elements, the hysteresis of the nano-positioning stage, imperfect speckle reduction or misdetection of the origin points in the SLM plane and the camera plane.

In summary, the described experimental results showed that all three tested focus sensors are applicable for the optical topography measurement of the rough surface specimens. The observed differences between the focus sensors were given by different modulation elements and output intensity patterns. The axicon generated the circular ring with the large illuminated area which resulted in the low number of the erroneous peaks in the primary profiles and the low random noise. However, the calculation of the ring radius was more time-consuming and more prone to the systematic error due to the possible mispositioning of the coordinate origin in the camera plane. The wedge and four lenses generated two or four spots, respectively, with relatively small illuminated areas which caused the higher number of the erroneous peaks in the primary profiles and the higher random noise. On the other hand, the calculation of the spot distances was relatively faster and virtually independent of the coordinate origin position in the camera plane. The results obtained for four lenses were generally slightly better compared to the wedge which was given by higher number of spots in the output intensity pattern. For all three focus sensors, the effective measurement range along the $z$-axis where the intensity-weighted centroid method provided relevant values of the ring radius or spot distances was estimated to the interval $\pm 3\,$µm above and below the objective focal plane. The narrow effective measurement range implies that the surface topography measurement of more complex specimens would require a closed-loop focus sensor system with independent positioning of the specimen or the microscope objective.

## 5. Conclusion

We presented a comparative study of three focus sensors designed for optical topography measurement of rough surface specimens. We described the theoretical principles and the experimental measurements realized by a single point laser probe. The theoretical analysis showed the importance of using a high-numerical-aperture objective for the specimen surface illumination. The low coherent illumination beam provided by the laser source and the rotating diffuser allowed for the efficient speckle reduction. It should be emphasized that the proper implementation of the rotating diffuser was crucial in order to achieve the sufficient signal-to-noise ratio in the experimental measurement. The specific modulation elements (axicon + lens, double wedge + lens, four lenses) were realized by the spatial light modulator which allowed for the comparison of the three focus sensor variants using a single experimental setup and repeated measurement over the same particular cross section of the specimens. The output intensity patterns detected by the digital camera were evaluated by the intensity-weighted centroid method which proved to be efficient and robust despite the observed intensity fluctuations. The experimental measurements conducted for the plane mirror and five ground glass specimens revealed the differences between the three tested focus sensors which were given by the different output intensity patterns. Although we were limited only to the linear scanning of the specimen surface along relatively short traverse length, we demonstrated the applicability of the focus sensors for the optical topography measurement. The primary profiles measured for the individual rough surface specimens by the three focus sensors were consistent, and their RMS deviations were only in tenths of a micrometer. Since the RMS deviations were generally given by both random and systematic errors, we concluded that the tested focus sensors can provide the submicron measurement accuracy. More detailed assessment of the measurement uncertainties would be necessary for the specific configuration and application of the tested focus sensors.

## Funding

Ministerstvo Školství, Mládeže a Tělovýchovy (CZ.02.1.01/0.0/0.0/16_026/0008460); Technology Agency of the Czech Republic (TE01020233, TN01000008); Akademie Věd České Republiky (RVO:68081731); European Commission (CZ.1.05/2.1.00/01.0017, LO1212).

## Acknowledgments

The authors thank the company Meopta (Meopta – optika, s.r.o., Přerov, Czech Republic) for providing the ground glass specimens.

## References

**1. **R. Leach, * Optical Measurement of Surface Topography*, (Springer-Verlag, 2011).

**2. **D. Malacara, * Optical Shop Testing*, (Wiley-Interscience, 2007).

**3. **D. J. Whitehouse, * Handbook of Surface and Nanometrology*, (IOP Publishing, 2003).

**4. **P. de Groot, “Principles of interference microscopy for the measurement of surface topography,” Adv. Opt. Photonics **7**(1), 1–65 (2015). [CrossRef]

**5. **J. C. Wyant, “White light interferometry,” Proc. SPIE **4737**, 98–107 (2002). [CrossRef]

**6. **G. Udupa, M. Singaperumal, R. S. Sirohi, and M. P. Kothiyal, “Characterization of surface topography by confocal microscopy: I. Principles and the measurement system,” Meas. Sci. Technol. **11**(3), 305–314 (2000). [CrossRef]

**7. **S. Van der Jeught and J. J. J. Dirckx, “Real-time structured light profilometry: a review,” Opt. Lasers Eng. **87**, 18–31 (2016). [CrossRef]

**8. **K. Miura and A. Nose, “Point Autofocus Instruments,” in *Optical Measurement of Surface Topography*, R. Leach, ed. (Springer-Verlag, 2011).

**9. **M. K. Kim, “Principles and techniques of digital holographic microscopy,” J. Photonics Energy **1**(1), 018005 (2010). [CrossRef]

**10. **G. Maculotti, X. Feng, M. Galetto, and R. Leach, “Noise evaluation of a point autofocus surface topography measuring instrument,” Meas. Sci. Technol. **29**(6), 065008 (2018). [CrossRef]

**11. **Ch.-S. Liu and S.-H. Jiang, “Precise autofocusing microscope with rapid response,” Opt. Lasers Eng. **66**, 294–300 (2015). [CrossRef]

**12. **D. K. Cohen, W. H. Gee, M. Ludeke, and J. Lewkowicz, “Automatic focus control: the astigmatic lens approach,” Appl. Opt. **23**(4), 565–570 (1984). [CrossRef]

**13. **J. Zhang and L. Cai, “Profilometry using an optical stylus with interferometric readout,” Meas. Sci. Technol. **8**(5), 546–549 (1997). [CrossRef]

**14. **J. J. Zambuto, R. E. Gerber, J. K. Erwin, and M. Mansuripur, “Ring-lens focusing and push-pull tracking scheme for optical disk systems,” Appl. Opt. **33**(34), 7987–7994 (1994). [CrossRef]

**15. **R. Haberland, “In-Process Optical Metrology For Precision Machining,” Proc. SPIE **0802**, 146–149 (1987). [CrossRef]

**16. **H. Fukatsu and K. Yanagi, “Development of an optical stylus displacement sensor for surface profiling instruments,” Microsyst. Technol. **11**(8-10), 582–589 (2005). [CrossRef]

**17. **T. Kohno, N. Ozawa, K. Miyamoto, and T. Musha, “High precision optical surface sensor,” Appl. Opt. **27**(1), 103–108 (1988). [CrossRef]

**18. **J. W. Goodman, * Introduction to Fourier Optics*, 2nd ed. (McGraw-Hill, 1996).

**19. **O. Brzobohatý, T. Čižmár, and P. Zemánek, “High quality quasi-Bessel beam generated by round-tip axicon,” Opt. Express **16**(17), 12688–12700 (2008). [CrossRef]

**20. **M. Šarbort, Š. Řeřucha, M. Holá, Z. Buchta, and J. Lazar, “Self-referenced interferometer for cylindrical surfaces,” Appl. Opt. **54**(33), 9930–9938 (2015). [CrossRef]

**21. **S. F. Ray, * Applied Photographic Optics: Lenses and Optical Systems for Photography, Film, Video, Electronic and Digital Imaging*, (Focal, 2002).

**22. **J. Jang, Y. Yoo, J. Kim, and J. Paik, “Sensor-Based Auto-Focusing System Using Multi-Scale Feature Extraction and Phase Correlation Matching,” Sensors **15**(3), 5747–5762 (2015). [CrossRef]

**23. **G. Häusler and S. Ettl, “Limitation of optical 3D sensors,” in *Optical measurement of surface topography*R. Leach, ed. (Springer-Verlag, 2011).

**24. **A. Jesacher, S. Fürhapter, S. Bernet, and M. Ritsch-Marte, “Diffractive optical tweezers in the Fresnel regime,” Opt. Express **12**(10), 2243–2250 (2004). [CrossRef]

**25. **A. Sabatyan and B. Meshginqalam, “Generation of annular beam by a novel class of Fresnel zone plate,” Appl. Opt. **53**(26), 5995–6000 (2014). [CrossRef]

**26. **A. Sabatyan and B. Fathi, “High efficiency arrays of any desired optical beams using modified grating based elements,” Opt. Quantum Electron. **50**(9), 338 (2018). [CrossRef]

**27. **W. Y. Yang, W. Cao, T.-S. Chung, and J. Morris, * Applied Numerical Methods Using Matlab*, (Wiley-Interscience, 2005), Chap. 2.

**28. **T. Čižmár, M. Mazilu, and K. Dholakia, “In situ wavefront correction and its application to micromanipulation,” Nat. Photonics **4**(6), 388–394 (2010). [CrossRef]