## Abstract

An instantaneous phase shifting deflectometry measurement method is presented and implemented by measuring a time varying deformable mirror with an iPhone ^{®} 6. The instantaneous method is based on multiplexing phase shifted fringe patterns with color, and decomposing them in *x* and *y* using Fourier techniques. Along with experimental data showing the capabilities of the instantaneous deflectometry system, a quantitative comparison with the Fourier transform profilometry method, which is a distinct phase measuring method from the phase shifting approach, is presented. Sources of error, nonlinear color-multiplexing induced error correction, and hardware limitations are discussed.

© 2016 Optical Society of America

## 1. Introduction

In this paper, we demonstrate an instantaneous phase shifting deflectometry measurement using an iPhone ^{®} 6, which enables snapshot phase shifting deflectometry data acquisition, measurements in high vibration environments, and a host of other scenarios inaccessible to conventional phase shifting deflectometry techniques. We show that with a multiplexed display pattern and novel data processing, we can play back a video of time varying events in the measurement path. Similar to the previous deflectometry system developed on a portable device [1], we are limited in performance by the hardware constraints and the processing power of the device. However, the mobile device allows us to investigate the core ideas and concepts behind the instantaneous measurement and prove that they are robust and well founded. We present the theory of the instantaneous phase shifting measurement and experimental data showing the capabilities of this method. We then compare the instantaneous phase shifting method to a different category of deflectometry that leverages Fourier Transform Profilometry (FTP). Finally, we discuss sources of error in these measurements, our error correction, and ways to improve the hardware for future applications.

## 2. Background

#### 2.1. Deflectometry

Deflectometry is a surface slope measuring tool that requires minimal hardware and acquires surface height data with nanometer-level precision [2–4]. It directly measures slope data, and has a very large dynamic range [5]. At the most basic level, a deflectometry system must have a screen to display a pattern, and a camera to capture images of the mirror under test, which is illuminated by the screen. A schematic of the measurement setup is shown in Fig. 1. The camera hardware can be chosen from off-the-shelf components where low signal-to-noise and fast acquisition times are desirable. The screens can also be off-the-shelf, but the patterns displayed are areas of active research. The camera is positioned such that it focuses on the mirror’s surface while close to the center of curvature of the optic. For a flat mirror, as shown in Fig. 1, the axial location is primarily determined by sampling criteria. In practice, the camera must be shifted off-axis in order to collect light from the screen that is reflected off of the test optic. It is therefore helpful to conceptualize the geometry by tracing rays from the camera to the screen to determine where they intersect the mirror and screen. The camera acts as our eye, and each pixel on its detector will correspond to a point on the mirror and screen. These three points in 3D space, across the entire optic’s surface, define the knowledge required to perform a measurement. One should think of this as a mapping between the camera and screen caused by the optic.

To create a mapping, current deflectometry systems use display patterns such as line-scanning, binary patterns, and phase shifting [6]. In this paper, we focus on the phase shifting method for acquiring data. A more detailed explanation of the following set of deflectometry calculations can be found in previous publications [1–4]. To acquire the slope data, we first display a sinusoidal pattern across the screen of a fixed frequency by modulating the output brightness of individual pixels. We then shift the pattern by a fixed phase shift until we have completed a full 2*π* phase shift. This pattern is displayed in both *x* and *y* directions separately from one another. For simplicity, we will now only show the calculation for the *x* direction because it is identical for the *y* direction. We capture an image at each phase shift value. For instance, a phase shifting measurement could use four phase shifts, where Δ*ϕ* = *π*/2. A general expression for the displayed intensity across the screen is,

*a*is the background intensity,

*b*is the amplitude of the intensity variation,

*f*is the frequency,

*x*is the local screen coordinate, Δ

*ϕ*is the phase shift, and

*n*is an integer that denotes which shift has been applied. The mirror under test will cause a change in the phase of the displayed pattern that varies across the surface, so the recorded intensity pattern (i.e. distorted screen pattern in the camera space) can be expressed as,

*x*=

_{distorted}*x̃*+ Δ(

*x̃*), which is the location on the screen, in the screen’s coordinate frame, that corresponds to the point

*x̃*on the camera, in the camera’s coordinate frame. To make this connection more clear, imagine a perfect mirror surface (i.e. 2

*πf*Δ(

*x̃*) = 0) with the screen and camera collocated. The intensity pattern that we measure on the camera is therefore identical to the pattern that we display on the screen (i.e.

*x*=

_{distorted}*x̃*). Therefore, in the scenario of an imperfect mirror, with the screen and camera not collocated, we have a transformation between the coordinate spaces (due to the mirror and geometry) that is represented by

*x̃*+ Δ(

*x̃*). In Eq. 2 we have represented the phase change due to the mirror under test as 2

*πf*Δ(

*x̃*). Note that the background and modulation values are different from the original display values. In each direction we will obtain four separate images of the phase shifted pattern. With the four images (in a single direction) we can obtain the wrapped phase of the measured pattern that was distorted by the mirror,

*, which resolves the 2*

_{wrapped}*π*ambiguity. Using the unwrapped phase, the local screen coordinate

*x*is calculated as, where if the fringe frequency

_{distorted}*f*is given in inverse pixels, then the screen coordinate has units of pixels. We can then convert from units of pixels to physical distances using the pixel pitch of the screen. This information defines a mapping between each camera pixel (where we get the value of Φ from) and each screen pixel. From this mapping, and the 3D geometry of the experiment (given in Fig. 1) we calculate the local slope of the surface under test by computing,

*s*is the local slope,

_{x}*x*is the local mirror surface coordinate,

_{m}*x*is the screen pixel coordinate,

_{s}*x*is the camera pixel coordinate,

_{c}*z*

_{m2s}is the distance from the mirror to the screen, and

*z*

_{m2c}is the distance from the mirror to the camera. Note that all the coordinates in Eq. (6) are with respect to the global coordinate frame. The slope value is calculated pixel by pixel for the entire surface of interest. To generate a surface height map, we integrate the slope in

*x*and

*y*, which can be done by fitting the slope to analytic functions (modal), or pixel-by-pixel integration (zonal).

All previously investigated phase shifting methods rely on changing the pattern with time and recording multiple images with the camera to reconstruct the optical surface under test. These methodologies cannot cope with time varying measurements because they multiplex information in the time domain. In doing this, they are limited to measurements in which the environment, or features on the surface, do not change in time. In our proposed instantaneous phase shifting deflectometry, we do not encounter such limitations because we multiplex all the necessary information into a single screen and capture it with a single snapshot.

#### 2.2. Interferometry

Similar time domain limitations were encountered in the field of laser interferometry, where phase shifting methods are also applied. Solutions to the problem of making a measurement in an unstable environment include using polarization to multiplex the phase shifted data [7, 8], using a spatial frequency carrier [9, 10], and 2D grating structures [11]. With these systems, measurements over very large path lengths and in turbulent environments are possible, which have many applications [12]. Fundamental to both solutions is the idea that we combine the unique data from each time measurement into a single frame such that, during data processing, the pieces are still distinguishable from one another. Phase shifting interferometry (PSI) requires a minimum of three phase shifted data sets (i.e. Δ*ϕ* = 0, *π*/3, and 2*π*/3) to reconstruct the surface under test [13]. An instantaneous measurement on a phase shifting deflectometry system needs to multiplex twice the amount of information that a similar phase shifting interferometry system would need to multiplex. This is because deflectometry measures slope data, which must be captured in two orthogonal directions to properly reconstruct the surface. Therefore, the direction of the slope data must also be distinguishable during data processing. For example, using the minimum number of phase shifts (three), we need six data: three for one slope direction, and three for the other orthogonal slope direction.

#### 2.3. Fourier transform profilometry

Fourier Transform Profilometry, a distinct metrology method from phase shifting deflectometry, can also be used to measure the phase of a displayed pattern. It has been employed extensively in the field of fringe projection [14,15]. More recently, an instantaneous deflectometry method using FTP has also been studied and presented in the literature [16,17]. FTP captures a single image of a fringe pattern with both *x* and *y* direction fringes and uses Fourier analysis to reconstruct the phase information from the image. The frequency spectrum is filtered and then inverse Fourier transformed, which generates a real and imaginary result. These values are then used to calculate the phase of the original object. FTP has the benefit of only requiring two pieces of information to be multiplexed because the Fourier analysis can reconstruct the phase from just a single pattern. In the most recent publication using FTP, Wu et. al. used color to multiplex the *x* and *y* fringes, which is not required by the FTP analysis, but it allowed them to reduce errors in the frequency domain due to overlapping spectra. However, as is true for all Fourier domain filtering, the exact method of filtering the frequency data is not a trivial step because the end result depends significantly on the process [18].

## 3. Concepts of the instantaneous phase shifting measurement

An instantaneous phase shifting measurement method is fundamentally different from previous phase shifting deflectometry methods because it does not multiplex information in the time domain. The theory supporting an instantaneous measurement does not impose any restrictions on how fast a measurement can be made, while a time-multiplexed measurement must occupy a finite extent in time. In practice, this means that phase shifting deflectometry may now measure objects in turbulent environments, high vibration situations, or even surfaces that are controlled via a feedback loop. An instantaneous deflectometry measurement also addresses a situation that current interferometer technology cannot. The proposed instantaneous deflectometry concepts will allow us to measure the dynamic bending modes of a large freeform/aspheric optic with active control, where previously, the large phase variations in the environment and/or the required large dynamic range of the freeform metrology prevented such a measurement.

We chose to create the instantaneous phase shifting style of deflectometry as opposed to leveraging common FTP techniques because we saw great potential for this new form of instantaneous deflectometry measurement. To do this, we multiplex the required phase shifted information in a single display pattern and create an instantaneous measurement. Another reason phase shifting deflectometry was selected is because it provides high accuracy data from a small number of images compared to line-scanning or binary patterns. It is also insensitive to spatial light variations on the screen, but it is affected by temporal variations, making it an excellent candidate for the instantaneous measurement type. FTP was also considered as a technique because it has been shown to work as an efficient instantaneous solution using only a single fringe image instead of multiple phase shifted images, but it was not selected due to the potential uncertainty in measurements and the Fourier domain processing challenges, which are discussed in detail in Sec. 4.4.

The phase shifting method of multiplexing incorporates two main ideas, each with an analogous concept in the realm of instantaneous interferometry. First, we encode the phase information using color, which requires a color display and camera. This style of registration is similar to that employed by the polarization multiplexed interferometer, where each phase shift is detected independently from the others. The number of color channels is fixed by the hardware, so we use a three-step phase shifting algorithm, the minimum required. Second, we display a large number of fringes on the screen, which acts as a carrier frequency in the image, similar to the spatial frequency carrier interferometer. When we combine both of these tools, we are able to distinctly multiplex six pieces of information corresponding to the three phase shifts in the two orthogonal directions necessary for a phase shifted deflectometry measurement. It is important to note that the analogies given here are only meant to provide an intuition into the multiplexing methods for those more familiar with interferometry. The comparison should not be understood as implying that the interferometry methods are the same as the deflectometry methods because the two metrology systems operate on fundamentally different principles.

For convenience, we define the two orthogonal directions of the fringes to be in the *x* and *y* directions, which lie in the plane of the screen as shown in Fig. 1. They are able to be in any orientation, but this coordinate system is best for displaying fringes accurately. The *x* and *y* fringe data must be displayed simultaneously, resulting in a pattern that looks more like an oscillating membrane than fringes. Furthermore, each phase shift is superimposed, so the resulting display is a multicolored membrane that does not resemble traditional fringes. This pattern is shown at the start of the data flow chart, given in Fig. 2, labeled as ‘Display Image’.

The camera captures an image of the surface under test, which is illuminated by the screen, and the resulting image is a distorted version of the display image. The camera has three color channels which are read out separately to obtain three sets of data, corresponding to the three phase shifts: red (Δ*ϕ* = 0), green
$\left(\mathrm{\Delta}\varphi =\frac{\pi}{3}\right)$, and blue
$\left(\mathrm{\Delta}\varphi =\frac{2\pi}{3}\right)$. We then Fourier transform each phase shifted image. In the Fourier domain, we observe distinct peaks at the locations corresponding to the carrier frequencies of the display fringes in the *x* and *y* directions. By dividing the Fourier domain into *x* and *y* frequencies without rejecting any information, we are able to decompose the input image into two separate images that would have been observed had we displayed one directional fringes. Note that this is fundamentally different from the FTP method, where a portion of the frequency information that contains some true information is discarded during data processing. The separation boundaries applied to the frequency data in instantaneous phase shifting deflectometry are shown in Fig. 2 labeled as ‘X Frequency Mask’, and ‘Y Frequency Mask’. We call them bow tie and hour glass masks, respectively, due to their shape. In practice, due to discrete sampling, the edge boundary is actually jagged, but in an analytic case it would be smooth. Also, the center pixel (zero frequency) is used in both masks to preserve the mean intensity value. The masks separate out a single frequency direction, while preserving the details of the fringe pattern contained in each frequency direction. They work on the principle that with a large enough carrier frequency in the display membrane, or a dense fringe pattern, the component *x* and *y* fringes are distinguished with high fidelity in the Fourier domain. We note that certain surface profiles will result in a measured fringe patterns that have closed loop fringes [19], which generate an ambiguity in the Fourier domain. To prevent issues with indistinguishable fringe direction, we adjust the geometry of the system either by tilting or translating the screen until a good set of measured fringes are obtained. We then apply an inverse Fourier transform to the separated data and reconstruct the one directional fringe patterns that made up the input image. From the single input image, we are able to obtain six unique outputs that comprise the three phase shifts in both orthogonal directions required to reconstruct the surface under test.

From this point on, we use the same data processing methods as have been developed for the other deflectometry systems because there is no difference in data. For completeness, we will briefly cover the methods used to reach the final reconstructed surface. First, we apply a three phase step algorithm to each direction. This results in four data arrays, two wrapped phases and their modulation, one in each direction. We unwrap the phases (i.e. solve the 2*π* ambiguity) using a flood fill method [20], and convert it to slope data with the system geometry parameters. Slope data is given in two directions, *x* and *y*, which we then integrate using a Southwell zonal method [21] to obtain our reconstructed surface. Further masking or post-processing with the surface may be done for specific applications.

## 4. Measurement results

To validate the concepts presented in the previous section, we used a deformable mirror to generate static and time varying surface shapes (which are independently verifiable) and measured them with the instantaneous deflectometry system. We present both single snapshots and dynamic measurements. We also quantitatively compare the measurement results to data from a conventional phase shifting deflectometry system and to a Zygo Verifire ^{®} interferometer. In the following section we also compare the instantaneous FTP method with our phase shifting method to highlight the key differences that separate the instantaneous phase shifting deflectometry from the instantaneous FTP approach.

#### 4.1. Experimental setup

The geometry of the deflectometry system used to make the measurements given in the previous section is shown in Fig. 3, where the iPhone ^{®} was secured in a 1” optic mount using a custom 3D printed case. We used a commercially available deformable mirror produced by ALPAO to generate the surface under test. The mirror’s specifications are given in Table 1. We placed the iPhone ^{®} close to the deformable mirror in order to adequately sample the mirror surface with the camera pixels, and to limit the size of the display pattern to fit within the phone’s screen. The deformable mirror is controlled via a MATLAB ^{®} program provided by the manufacturer that allows us to command actuators to move continuously throughout their total range of motion.

#### 4.2. Dynamic metrology demonstration

To demonstrate our instantaneous phase shifting measurement, we used the ALPAO deformable mirror to create a known time varying surface. We made a set of fifty uninterrupted measurements taken at approximately 10 Hz, and created a movie of the deformable mirror moving continuously (see Visualization 1 and Visualization 2), where a baseline measurement was subtracted from the data in order to measure the influence function of the driven actuator. An influence function is the relative response of an output (e.g. surface height change) due to the change of a unit input (e.g. actuator motion). In the first movie, a single actuator in the deformable mirror was moved continuously out and back along its entire stroke, causing a high point on the surface in the region of the actuator. We therefore are measuring the actuator’s dynamic influence function, a critical parameter for calibrating and evaluating a deformable mirror. The surfaces shown in Fig. 4 are frames taken from Visualization 1. We clearly observe a single high peak in the data, corresponding to the actuator that we commanded to move. This demonstrates the potential applications for an instantaneous measurement where a time varying object needs to be measured, or the object is located in an environment with large vibrations.

### Dynamic Zernike mode measurement

To further highlight the capabilities of the instantaneous measurement, we generated a continuously changing Zernike trefoil surface variations on the deformable mirror, starting with a flat, progressing towards maximum deviation, and finally back to a flat surface. The measured surface movie is provided in Visualization 2. A set of six frames from the movie are shown in Fig. 5. The lower order shape of Zernike trefoil is clearly evident across all measurements, showing that the instantaneous method is able to measure not only localized (by single actuator), but also global (low order) surface changes.

#### 4.3. Quantitative measurement accuracy

We compare the instantaneous measurement to conventional phase shifting deflectometry to a Zygo Verifire ^{®} measurement for an objective accuracy evaluation beyond simply presenting a dynamic result without quantitative investigation. We generated the surface by applying a set voltage to a single actuator in the deformable mirror, similar to one of the frames in Fig. 4. The conventional phase shifting deflectometry measurement was made using the same iPhone ^{®} hardware, but with a three step, single color, phase shifting algorithm. We subtracted a baseline measurement from all three data sets to make a fair comparison. The measured surface for the three data sets is shown in Fig. 6(a). We lost partial data during the interferometric measurement because of a defect in the surface of the deformable mirror.

We computed a horizontal line slice through each surface passing across the center of the peak in the data. The line that we evaluated over is shown in Fig. 6(a) as a black dashed line across the width of the surface. We plotted each line slice on a single axis, which is given in Fig. 6(c). We then computed the difference between the surfaces of instantaneous data and the interferometer, as well as the three phase (conventional phase shifting) and the interferometer measurements. The resulting difference map is shown in Fig. 6(b). We achieve less than 30 nm RMS difference between all three methods when we are measuring a feature with about 2 *μ*m peak-to-valley (PV). This level of agreement demonstrates that the instantaneous phase shifting deflectometry method is an accurate tool, especially considering an off-the-shelf iPhone ^{®} based hardware setup.

#### 4.4. Fourier Transform Profilometry Comparison

To compare the instantaneous phase shifting deflectometry to the instantaneous FTP method, we measured the deformable mirror with a single actuator at the same position as before using the reported FTP solution [17]. We then computed the difference between these surfaces and the data from the interferometer in the same manner as before. The results of this experiment are shown in Fig. 7, where three different filters (shown below the corresponding difference map) were used to process the same data. The precise meaning of the filters used in FTP are essentially different from the Fourier process used in the presented instantaneous phase shifting deflectometry. The instantaneous phase shifting method only uses the Fourier domain to separate the frequency information into two categories. The instantaneous phase shifting deflectometry method does not eliminate a single piece of information from the raw measurement data during the Fourier domain processing as discussed in Sec. 3. However, the FTP method must reject or select some frequency information in order to reconstruct the phase data. The surface reconstruction is very sensitive to the exact form of this filtering operation, which leads to uncertainties affecting the accuracy of the measurement. This is why a good number of papers about the best filtering method have been published [23–25]. Also, the most recent FTP-based instantaneous results were not quantitatively and experimentally cross-confirmed against other reference technologies such as an interferometer [16, 17]. Implementing these methods is not an easy task, and there is no single best solution since there are an infinite (or as many as the number of pixels in the Fourier domain) number of possible filtering mask shape parameters. Our results in Fig. 7 demonstrate the uncertainty in reconstructed surface shape caused by using the FTP method due to the filtering process. For instance, as we change the mask shape from (a) to (b) to (c), the residual RMS error, with respect to the interferometer, changes from 64 to 50 to 32 nm, respectively. The shape of the error also varies significantly with each new Fourier filter. Such a significant difference in performance without good guidelines for choosing the optimal masking shape leads to uncertainties in the accuracy of the reconstructed surface. However, the goal of this investigation is more than just the absolute value of the residual RMS errors and the error shape variations, it seeks to call to attention the difficulties in the filtering employed by FTP. One of the biggest challenges in a FTP method is making a decision in the Fourier domain to accept or reject frequency data when all the deflected pattern image information is interlaced. We acknowledge that there may be a case-specific mask that generates a correct surface shape with a similar residual error to that of the phase shifting method, but due to the high sensitivity of the reconstruction process using different filters, the FTP method suffers greatly from the masking ambiguity. On the contrary, our phase shifting instantaneous deflectometry method does not suffer from such inexactness because we use the entire frequency domain information. In other words, there is no arbitrary or weakly justified user determined parameter that impacts the accuracy of the final result. However, it is also important to state that a FTP method (especially one that does not use color-multiplexing [17]) can achieve higher spatial resolution as it does not require a color display and camera. Therefore, the FTP method is still a capable and valuable approach, it just has different strengths and weaknesses compared to the proposed instantaneous phase shifting method because it utilizes fundamentally different phase measuring methods.

## 5. Quasi-static common configuration error correction and calibration

#### 5.1. Quasi-static common configuration

The errors contributing to the data shown in Fig. 6 can be broken into two main categories: those that are common to all deflectometry systems, and those that are unique to our instantaneous method. Errors common to all deflectometry systems include screen deformations that distort the displayed pattern causing a systematic error, and camera or screen nonlinear response causing print-through. An instantaneous phase shifting measurement also has unique sources of error that come from the cross-talk between color channels in the screen and the camera, color related non-linearity issues, and the physical layout of the screen and camera pixels that cause inexact phase shifts. On the screen, the spectral output from a single color pixel is fairly wide such that it overlaps with the other channels. The camera’s pixels are also not perfectly filtered, so displaying a single color will cause a response in all three detector color channels. The cross-talk between color channels causes the phases to print through onto the other phases, creating distortions in the measured phase shifted images. This affects the system’s instrument transfer function (ITF), or how the system responds to a given input. By using a color display and detector, we also alter the ITF because the individual color filtered pixels are made into a larger super pixel. This means that we have a decrease in the spatial resolution related performance (or ITF) but gain the instantaneous capability.

While well known calibration methods can be applied to correct the common deflectometry errors associated with the traditional phase shifting approaches [26, 27], an advanced data correction that we have termed ‘Quasi-Static Common Configuration’ (QSCC) compensation was developed and applied to the dynamic data to correct the unique instantaneous phase shifting errors. The correction leverages two aspects of the instantaneous phase shifting configuration. First, the change in error due to the dynamics under test (e.g. deformable mirror) will not grossly affect our error correction (i.e. quasi-static errors). Second, all measurements are made in a common configuration. This means that nothing changes between the single color and color-multiplexed instantaneous measurements except for the pattern displayed on the screen (i.e. common configuration). This constitutes the basis for our QSCC error compensation method. Simply stated, to create the compensation map for the instantaneous errors, we compute the difference between a conventional phase shifting measurement and an instantaneous measurement for a common nominal state (e.g. zero voltage applied to the deformable mirror). We then apply the difference map as a QSCC correction to the dynamic data set in the surface height domain. One could apply it in the slope or wrapped phase domain, but the compensation is most clearly visualized as a height difference. The QSCC correction accounts for any nonlinear response or color cross-talk in both the screen and camera as well as any other errors that we have yet model or simulate. This is the beauty of such an error compensation, it is simple to apply and yet it captures all sources of error.

To demonstrate the fidelity of our error correction method, we show an uncorrected map and a corrected map in Fig. 8. Each map is the result of a single measurement of the deformable mirror with a single actuator at a fixed voltage. In Fig. 8(a) we show an instantaneous measurement where Zernike polynomials 1–100 (standard ordering) were subtracted in order to clearly show the high frequency errors. We observe significant double frequency error (nonlinear error in phase), which is common in phase shifting interferometry [28–30], and color effects that further distort the surface and lead to more high frequency errors. With the new error correction, we increase the fidelity of the surface as shown in Fig. 8(b), especially addressing the double frequency fringe print-through errors. Although there are still some higher order errors after the compensation due to the quasi-static assumption, it is still clear that the error correction takes care of most of the non-linearity and color-multiplexing related issues. We then give the difference between the corrected and uncorrected surface in Fig. 8(c) to show the amount of correction that the QSCC method generates. We note that it is especially good at removing the mid-to-high spatial frequency errors. Despite the new challenges that the phase shifting instantaneous deflectometry method faces and the hardware limitations, we are able to measure a surface that inspires confidence in the application of this technique to precision metrology.

The quasi-static component of our error correction method is limited in the range of surface deviations over which it is applicable. However, across the full range of the deformable mirror’s actuator motion (∼ 5*μ*m) it is a valid assumption. To put this in context, a HeNe interferometer operating at a wavelength of *λ* = 0.633*μ*m will generate ∼ 17 fringes across this area. In order to provide a more tangible understanding of the fringe deviations we observed, three raw images collected during the experiment are shown in Fig. 9. The first image in Fig. 9(a) is the image of the deformable mirror at zero applied voltage. This is the common nominal state used in the QSCC correction. Fig. 9(b) gives the image corresponding to the mirror surface that we analyzed in Fig. 6 and Fig. 8. The image in Fig. 9(c) is the actuator at full stroke, which generates a deviation of the fringe pattern on the order of half a fringe.

In order to implement the QSCC method, the entire data processing pipeline must remain constant for each measurement. This guarantees that the errors will propagate in the same manner, and therefore the correction generated from the nominal state is valid. In particular, during the phase unwrapping step where we apply a flood-fill method, we use a quality function that is constant across all data sets. This is necessary because the flood-fill method may return a different phase value if it is started from a different point, or if it is guided across the map on a different path between data sets. This same mentality must be applied to any other function such as zonal integration or Fourier separation. Without the consistency in data processing the principles behind QSCC are violated.

Further data processing level instantaneous error correction methods are currently being developed but we also wanted to present ideas on how to improve the error through hardware upgrades. We could fabricate a specialized detector with better color filters, reducing the cross-talk between phase shifts. As demonstrated in previous papers [31], the cross-talk error can seriously affect the measurement accuracy. More color filters could also be used to allow for a larger number of phase shifts per instantaneous measurement, driving down the nonlinear error associated with phase shifting. Understanding the chromatic aberrations and color transmission function of the camera lens would also improve the accuracy of the system. The screen filters could also be improved to give better display color discrimination. The output from each color pixel would then only register on the corresponding colored detector pixel. Many of the errors seen in the instantaneous phase shifting deflectometry measurement can be decreased through custom hardware according to a specific accuracy and precision requirement for a given application.

#### 5.2. System calibration

To obtain such good agreement between the instantaneous phase shifting deflectometry implemented on the iPhone ^{®} and the interferometer, we only performed a few calibration steps. First we must clearly state our goals in this case: we wanted to measure the deformable mirror’s dynamic influence function. This means that we insensitive to absolute shape terms, such as tip/tilt, power, astigmatism, coma, spherical, etc, which require significant calibration to measure accurately. However, we do care about the low order shape changes, which we can certainly still measure (see Fig. 5). To meet this calibration specification, we simply measured relevant distances with an accuracy of ∼ 2 mm, and did not measure the shape of the screen or camera surfaces, assuming that they were both planar. If the goal was to measure absolute surfaces down to low order terms, we have established techniques to measure and quantify all the required geometric parameters. A good example of this capability is the calibration performed for the measurement of a segment of the Giant Magellan Telescope primary [5], or measuring high precision x-ray mirrors [26]. In both methods, a laser tracker was used to accurately measure the coordinates of each component, and characterize the screen profile. Further calibration of the camera’s distortion and imaging aberrations was performed using fiducials (measured by laser tracker). A reference surface may also be used to calibrate the systematic errors. Different levels of calibration may be applied depending on the accuracy of the low order absolute surface shape that the measurement requires. For our case study with the deformable mirror, no such low order absolute shape calibration was required, so we did not perform them. The other minor calibration that we performed was a first order simple distortion correction. In essence, this is a lateral calibration that sets the pixel size on the mirror surface, or the distance between measured slope points. The lateral calibration was determined by using the interferometry data as a reference, such that the peak width was matched. Note that the interferometer data also needed a lateral calibration step, so both methods suffer from this ambiguity. The instantaneous phase shifting deflectometry system that we present does not require extensive calibration to measure the dynamic influence function of a deformable mirror and therefore we did not perform excessive calibration.

## 6. Conclusion

In this paper, we described a new realization of instantaneous deflectometry through phase shifting that enables an accurate measurement and demonstrated that the concepts can be implemented in currently available hardware. We presented data from a deformable mirror with the hope of generating excitement about the potential applications for this technology. We generated a comparison between the phase shifting method and the FTP method, which are two essentially different but also capable solutions. We showed their differences and limitations, concluding that the phase shifting method is a more robust tool and has less uncertainty when reconstructing the surface. We then discussed the sources of error in the measurements and our methods of correcting the new errors specific to instantaneous measurements so that future developments in the field of instantaneous phase shifting deflectometry can build on them and create an even more precise measurement tool.

## Funding

College of Optical Sciences at the University of Arizona (Technology Research Initiative Fund (TIRF) Optics/Imaging Program); Korea Basic Science Institute; Friends of Tucson Optics (FoTO) (Endowed Scholarships in Optical Sciences).

## Acknowledgments

The authors would like to acknowledge all of the previous internal research on instantaneous deflectometry done by Wenchuan Zhao and Logan Graves, as well as their support during this research. We would also like to thank Maham Aftab for her insightful discussions on slope integration methods. This research was made possible in part by the Technology Research Initiative Fund (TIRF) Optics/Imaging Program, through the College of Optical Sciences at the University of Arizona, the Post-processing of Freeform Optics project supported by the Korea Basic Science Institute, and the Friends of Tucson Optics (FoTO) Endowed Scholarships in Optical Sciences. The authors would also like to acknowledge the II–VI Foundation Block-Gift Program for helping support general deflectometry research in the LOFT group.

## References and links

**1. **G.P. Butel, G. A. Smith, and J.H. Burge, “Deflectometry using portable devices,” Opt. Eng. **54** (12), 025111 (2015). [CrossRef]

**2. **P. Su, R.E. Parks, L. Wang, R. P. Angel, and J.H. Burge, “Software configurable optical test system: a computerized reverse Hartmann test,” Appl. Opt. **49** (23), 4404–4412 (2010). [CrossRef] [PubMed]

**3. **M. Knauer, J. Kaminski, and G. Häusler, “Phase measuring deflectometry: a new approach to measure specular free-form surfaces,” Proc. SPIE **5457**, 366–376 (2004). [CrossRef]

**4. **T. Bothe, W. Li, C. von Kopylow, and W. Jüptner, “High-resolution 3D shape measurement on specular surfaces by fringe reflection,” Proc. SPIE **5457**, 411–422 (2004). [CrossRef]

**5. **P. Su, S. Wang, M Khreishi, Y. Wang, T. Su, P. Zhou, R. E. Parks, K. Law, M. Rascon, T. Zobrist, H. Martin, and J. H. Burge, “SCOTS: A reverse Hartmann test with high dynamic range for Giant Magellan Telescope primary mirror segments,” Proc. SPIE **8450**, 84500W (2012). [CrossRef]

**6. **G.P. Butel, G. A. Smith, and J.H. Burge, “Optimization of dynamic structured illumination for surface slope measurements,” Proc. SPIE **8493**, 84930S (2012). [CrossRef]

**7. **M. Novak, J. Millerd, N. Brock, M. North-Morris, J. Hayes, and J. Wyant, “Analysis of a micropolarizer array-based simultaneous phase-shifting interferometer,” Appl. Opt. **44** (32), 6861–6868 (2005). [CrossRef] [PubMed]

**8. **J. E. Millerd and J. Wyant., “Simultaneous phase-shifting Fizeau interferometer,” US Patent 7,230,718 (2007).

**9. **M. Takeda., “Spatial-carrier fringe-pattern analysis and its applications to precision interferometry and profilometry: An overview,” Elsevier Ind. Met., 1, 79–99 (1990). [CrossRef]

**10. **D.M. Sykora and P. de Groot, “Instantaneous measurement Fizeau interferometer with high spatial resolution,” Proc. SPIE **8126**, 812610 (2011). [CrossRef]

**11. **M. Kuchel, “Two grating lateral shearing wavefront sensor,” US Patent 7,889,356 (2011).

**12. **B. Kimbrough, J. Millerd, J. Wyant, and J. Hayes, “Low coherence vibration insensitive Fizeau interferometer,” Proc. SPIE **6292**, 62920F (2006). [CrossRef]

**13. **H. Schreiber and J. H. Bruning, “Phase shifting interferometry,” in *Optical Shop Testing*, 3, D. Malacara, ed. (Wiley, 2007). [CrossRef]

**14. **P. Xie, M. Tang, and X. Wei, “Three-dimensional shape measurement of specular surfaces by orthogonal composite fringe reflection,” Proc. SPIE **8200** (14), 1–8 (2011).

**15. **H. Yue, X. Su, and Y. Liu, “Fourier transform prfilometry based on composite structured light pattern,” Opt. and Laser Tech. **39**, 1170–1175 (2007). [CrossRef]

**16. **Y. Wu, H. Yue, J. Yi, M. Li, and Y. Liu, “Dynamic specular surface measurement based on color encoded fringe reflection technique,” Opt. Eng. **55**(22), 024104 (2016). [CrossRef]

**17. **L. Huang, C. S. Ng, and A. K. Asundi, “Dynamic three-dimensional sensing for specular surface with monoscopic fringe reflectometry,” Opt. Express **19** (13), 12809–12814 (2011). [CrossRef] [PubMed]

**18. **Z.H. Zhang, “Review of single-shot 3D shape measurement by phase calculation-based fringe projection techniques,” Opt. and Lasers in Eng. **50**, 1097–1106 (2012). [CrossRef]

**19. **T. Su, S. Wang, R. E. Parks, P. Su, and J. H. Burge, “Measuring rough optical surfaces using scanning long-wave optical test system. 1. Principle and implementation,” Appl. Opt. **52** (29), 7117–7126 (2013). [CrossRef] [PubMed]

**20. **A. Asundi and Z. Wensen, “Fast phase-unwrapping algorithm based on a gray-scale mask and flood fill,” Appl. Opt. **37** (23), 5416–5420 (1998). [CrossRef]

**21. **W.H. Southwell, “Wave-front estimation from wave-front slope measurements,” J. Opt. Soc. Am. **70** (8), 998–1006 (1980). [CrossRef]

**22. **Y. Wu, Y. Cao, Z. Huang, M. Lu, and D. Chen, “Improved composite Fourier transform profilometry,” Opt. and Laser Tech. **44**, 2037–2042 (2012). [CrossRef]

**23. **L. Huang, Q. Kemao, and A. K. Asundi, “Comparison of Fourier transform, windowed Fourier transform, and wavelet transform methods for phase extraction from a single fringe pattern in fringe projection profilometry,” Opt. and Lasers in Eng. **48**, 141–148 (2009). [CrossRef]

**24. **Q. Kemao, “Two-dimensional windowed Fourier transform for fringe pattern analysis: Principles, applications, and implementations,” Opt. and Lasers in Eng. **45**, 304–317 (2007). [CrossRef]

**25. **Q. Kemao, “Windowed Fourier transform for fringe pattern analysis,” Appl. Opt. **43**(13), 2695–2702 (2004). [CrossRef] [PubMed]

**26. **P. Su, Y. Wang, J. H. Burge, K. Kaznatchev, and M. Idir, “Non-null full field X-ray mirror metrology using SCOTS: a reflection deflectometry approach,” Opt. Express **20**(11), 12393 (2012). [CrossRef]

**27. **C. Faber, E. Olesch, R. Krobot, and G. Häusler, “Deflectometry challenges interferometry–the competition gets tougher!” Proc. SPIE **8493**, 84930R (2012). [CrossRef]

**28. **F. Liu, Y. Wu, and F. Wu, “Correction of phase extraction error in phase-shifting interferometry based on Lissajous figure and ellipse fitting technology,” Opt. Express **23** (8), 10794–10807 (2015). [CrossRef] [PubMed]

**29. **P. de Groot, “Generating fringe-free images from phase-shifted interferometry data,” Appl. Opt. **44** (33), 7062–7069 (2005). [CrossRef] [PubMed]

**30. **Z. Wang and B. Han, “Advanced iterative algorithm for phase extraction of randomly phase-shifted interferograms,” Opt. Lett. **29** (14), 1671–1673 (2004). [CrossRef] [PubMed]

**31. **J. L. Flores, J. A. Ferrari, G. G. Torales, R. Legarda-Saenz, and A. Silva, “Color-fringe pattern profilometry using a generalized phase-shifting algorithm,” Appl. Opt. **54** (30), 8827–8834 (2015). [CrossRef] [PubMed]