## 3 Measurement Principles
Taking the signal \(S_{1}(t)\) as an example, it is multiplied with the sinusoidally modulated signal \(cos\omega_{c}t\) and its second harmonic carrier signal \(cos2\omega_{c}t\), and a pair of sinusoidal and cosinusoidal signals can be obtained by  
\[I_{x}(t)=LPF[S_{1}(t)\times\cos\omega_{c}t]=a(t)\sin(\varphi_{1}+\varphi_{tri} )+x_{0}(t) \tag{4}\]  
\[I_{y}(t)=LPF[S_{1}(t)\times\cos 2\omega_{c}t]=b(t)\cos(\varphi_{1}+\varphi_{tri} )+y_{0}(t) \tag{5}\]  
where a(t) and b(t) are the amplitudes of the signal \(I_{x}(t)\) and \(I_{y}(t)\), \(x_{0}(t)\) and \(y_{0}(t)\) are the DC offsets of the signal \(I_{x}(t)\) and \(I_{y}(t)\). Real-time ellipse fitting is used to calculate the correct DC offsets and amplitudes of \(I_{x}(t)\) and \(I_{y}(t)\), thereby eliminating the influences of modulation depth drift and carrier phase delay. After arctangent calculation and removing the triangular modulated phase \(\varphi_{tri}\) with mean filter, the phases \(\varphi_{1}\) and \(\varphi_{2}^{n}\) can be recovered. During the movement of \(M_{2}\), the phases are demodulated in real time, and the phase changes \(\Delta\varphi_{1}\) and \(\Delta\varphi_{2}^{n}\) before and after the movement can be obtained. By averaging the phase changes \(\Delta\varphi_{2}^{n}\) and substituting them into Equation (1) with \(\Delta\varphi_{1}\), the displacement can be re-expressed as  
\[\Delta z=\frac{\lambda}{4\pi}(\Delta\varphi_{2}-\Delta\varphi_{1})=\frac{ \lambda}{4\pi}\Bigg{[}\frac{1}{4}\sum_{n=1}^{4}\Delta\varphi_{2}^{n}-\Delta \varphi_{1}\Bigg{]} \tag{6}\]  
Using the differential design, the measurement deviation caused by the unbalanced environmental disturbance can be minimized. However, the measurement deviation caused by the rotation of the measuring mirror \(M_{2}\) with the measured object during the movement still remains. To compensate for the rotation error, the DWS technology with APD was adopted. As shown in Figure 2, when \(M_{2}\) tilts with the measured object, the direction of the returned measuring beam changes. Since the reference beam direction does not change, the OPDs between the reference and measuring beams on each detector of APD become unequal. Using this OPD unbalance and the geometric relationship between the direction of the measuring beam and the rotational angle of \(M_{2}\), the yaw angle \(\theta_{x}\) and the pitch angle \(\theta_{y}\) can be derived as  
\[\left\{ \begin{array}{l}\theta_{x}=\arctan\Big{[}\frac{1}{2\Omega_{1}}\Delta L _{1-2}\Big{]}=\arctan\Big{[}\frac{1}{2\Omega_{1}}\times\frac{\lambda}{2\pi} \big{(}\Delta\varphi_{2}^{1}-\Delta\varphi_{2}^{2}\big{)}\Big{]}\\ \theta_{y}=\arctan\Big{[}\frac{1}{2\Omega_{2}}\Delta L_{1-3}\Big{]}=\arctan \Big{[}\frac{1}{2\Omega_{2}}\times\frac{\lambda}{2\pi}\big{(}\Delta\varphi_{2} ^{1}-\Delta\varphi_{2}^{3}\big{)}\Big{]}\end{array} \right. \tag{7}\]  
where \(d_{1}\) and \(d_{2}\) are the distance in the x-direction between first and second detectors, and the distance in the z-direction between first and third detectors of APD, respectively;and \(\Delta\)L\({}_{1-3}\) are the difference between the OPDs of the reference and measuring beams on first and second detectors, and on first and third detectors of APD, respectively. With the obtained rotational angles and the compensation analysis model [16], the displacement can be compensated as  
\[\Delta z^{\prime}\approx\frac{2\Delta z+2\text{S}_{0}{+}2\text{S}_{1}}{1{+} \sqrt{1+\text{tan}^{2}2\text{\theta}_{\text{x}}{+}\text{tan}^{2}2\text{\theta}_ {\text{y}}}}{-}\text{S}_{0}{-}\text{S}_{1}{+}\text{H}_{\text{x}}\text{tan} \text{\theta}_{\text{y}}{+}\text{H}_{\text{y}}\text{tan}\text{\theta}_{\text{x}} \tag{8}\]  
where S\({}_{0}\) and S\({}_{1}\) are the distances from M\({}_{2}\) to PBS and from PBS to APD, respectively; H\({}_{\text{x}}\) and H\({}_{\text{y}}\) are the distances from the center of the measuring beam on M\({}_{2}\) to the rotational center of M\({}_{2}\) in the x-direction and y-direction, respectively.