# Calibrated Phase-Shifting Digital Holographic Microscope Using a Sampling Moire Technique
## 4 Numerical Simulation  
In the microscopic field, many specimens are mostly transparent, such as biological cells and glass. Hence, we suppose that the object in the numerical simulation is a transparent object. Images with dimensions of 1024 \(\times\) 1024 pixel and a 3.45 \(\upmu\)m pixel pitch were treated as the amplitude and phase distributions of the object, as shown in Figure 4a,b. The distance between the object and the image sensor was set to 0.5 mm. The maximum pixel value of the amplitude image was normalized to 255. The values of the phase distribution were set from \(-\pi\) to \(\pi\). In the actual experiment, the angle between the object wave and the reference wave was difficult to adjust to zero despite the in-line digital holography. Therefore, we introduced a small angle between the object wave and the reference wave. Figure 4c shows an example of the generated hologram in which the interference fringes appeared, and part of the generated hologram is magnified in Figure 4d. The wavelength of the light source was assumed to be 532 nm. The phase-shifting errors at a maximum of 20% were randomly introduced when holograms and interferograms were generated. The four phase-shifted holograms--\(I(x,\ y;0)\), \(I(x,\ y;\ \pi/2+\Delta\delta_{1})\), \(I(x,\ y;\ \pi+\Delta\delta_{2})\), and \(I(x,\ y;3\pi/2+\Delta\delta_{3})\)--and four phase-shifted interferograms were obtained. The reconstructed images by using the conventional phase-shifting method [11] and the phase-shifting error compensation algorithm are illustrated in Figures 5 and 6. We can see that the residual interference fringes appear in Figures 5b and 6b because the phase-shifting calculation of the conventional method is incorrect owing to the phase-shifting errors. On the other hand, both the amplitude and phase images of the object were correctly reconstructed by the phase-shifting error compensation algorithm, as shown in Figures 5d and 6d. Here, the detected phase-shifting errors by the sampling Moire technique were 0.2846, 0.0399 and 0.2869 rad, respectively. Additionally, the normalized root-mean-square errors (NRMSEs) of the reconstructed amplitude and phase images were calculated. The results are revealed in Table 1. Note that the NRMSE of the proposed method is not equal to zero because a little linear interpolation errors existed in the down-sampling processing [18]. However, the proposed method greatly reduced the errors even though interpolation errors occurred.  
Figure 4: Simulated object and an example of the generated hologram. (**a**,**b**) Amplitude and phase distributions; (**c**) Example of the generated hologram; (**d**) Magnified image of the area indicated in (**c**).  
Figure 5: Simulation results of the amplitude images. (**a**,**c**) Amplitude images reconstructed by the conventional method and the proposed method, respectively; (**b**,**d**) Magnified images of the areas indicated in (**a**,**c**), respectively.  
Figure 6: Simulation results of the phase images. (**a**,**c**) Phase images reconstructed by the conventional method and the proposed method, respectively; (**b**,**d**) Magnified images of the areas indicated in (**a**,**c**), respectively.