# Integrated GNSS/IMU-Gyrocompass with Rotating IMU. Development and Test Results
## 4 Methods
### Filtering Algorithms Used for GNSS/IMU Gyrocompass Measurements
\[z_{\dot{\rho}i}=\dot{\rho}^{iINS}-\dot{\rho}^{iGNSS}, \tag{11}\]  
\[z_{\Delta\varphi i}=\left(L^{i}\Delta\varphi^{iINS}-L^{i}\Delta\varphi^{iGNSS} \right)/\left|\overrightarrow{B}\right|. \tag{12}\]  
Assuming that inertial sensors determine the initial rotation angles at least accurate to \(5^{\circ}\), measurements (10)-(12) can be presented in linearized form:  
\[\overline{z}_{\dot{\rho}i}=\left(M_{1}\cdot\left[\frac{\partial\dot{\rho}_{i} }{\partial x_{e}},\frac{\partial\dot{\rho}_{i}}{\partial y_{e}},\frac{\partial \dot{\rho}_{i}}{\partial z_{e}}\right]\right)^{T}\cdot\delta\mathbf{p}-\delta \rho+\varepsilon_{\rho}, \tag{13}\]  
\[\overline{z}_{\dot{\rho}i}=\left(M_{1}\cdot\left[\frac{\partial\dot{\rho}_{i} }{\partial x_{e}},\frac{\partial\dot{\rho}_{i}}{\partial y_{e}},\frac{\partial \dot{\rho}_{i}}{\partial z_{e}}\right]\right)^{T}\cdot\delta\mathbf{p}+\left( M_{2}\cdot\left[\frac{\partial\dot{\rho}_{i}}{\partial x_{e}},\frac{\partial \dot{\rho}_{i}}{\partial y_{e}},\frac{\partial\dot{\rho}_{i}}{\partial z_{e}} \right]\right)^{T}\left[ \begin{array}{c}\delta\mathbf{V}_{\mathbf{n}}^{e}\\ \delta\mathbf{p}\end{array} \right]-\delta v+\varepsilon_{\dot{\rho}}, \tag{14}\]  
\[\overline{z}_{\Delta\Phi i}\cong\left(b_{N}\cdot s_{E}^{i}-b_{E}\cdot s_{N}^{i }\right)\alpha+\delta Cf^{i}+v_{zi}, \tag{15}\]  
where \([x_{e},y_{e},z_{e}],\left[\dot{x}_{e},\dot{y}_{e},\dot{z}_{e}\right]\) are the Cartesian coordinates and the components of relative linear velocity vector projected on e-frame, \(v_{zi}\) are the measurement errors including mainly GNSS receiver errors in carrier phase (including multipath errors) and fluctuation errors in attitude of antenna baseline unit vector \(\overrightarrow{b}\) with respect to IMU axes (for example due to the vibrations). Matrices \(M_{1}\) and \(M_{2}\) contained in (13) and (14) are given by  
\[M_{1}=\left[ \begin{array}{ccc}-s\lambda&c\lambda&0\\ -s\varphi c\lambda&-s\varphi s\lambda&c\varphi\\ c\varphi c\lambda&c\varphi s\lambda&s\varphi\\ c\varphi c\lambda&c\varphi s\lambda&s\varphi\end{array} \right],\] \[M_{2}=\left[ \begin{array}{ccc}-s\lambda&c\lambda&0\\ -s\varphi c\lambda&-s\varphi s\lambda&c\varphi\\ c\varphi c\lambda&c\varphi s\lambda&s\varphi\end{array} \right]. \tag{16}\]  
Here \(s\varphi,s\lambda,c\varphi,c\lambda\) denote \(\sin\varphi,\sin\lambda,\cos\varphi,\cos\lambda\), respectively. To estimate the state vector (8) using differential measurements (10)-(12), extended Kalman filter is applied (block EKF in Figure 4) with feedbacks over the complete state vector \(x\). Its estimated components \(\hat{x}_{\textit{INS}},\hat{x}_{\textit{IMU}},\hat{x}_{\textit{GNSS}}\) generated by EKF are used to update INS output and accelerometer, gyro, and satellite measurements under no failures of GNSS receivers and satellite visibility (\"Closed loop correction\" in Figure 5). This actually defines the mode with feedbacks over the complete state vector. As seen from measurements (15), heading can be updated using phase measurements from only one satellite, which would be confirmed by experimental results. The residual phase ambiguity \(\delta Cf^{i}\) is excluded due to rotation because antenna baseline orientation with respect to satellite direction changes, and gyro data are applied. Note that even with significant INS heading errors, filtering using differential phase measurements (15) by data from a single satellite is sufficient. Then using a common clock is very important, which excludes the clock error of satellite navigation receivers from measurements (15). In filtering algorithms, rejection of unreliable measurements is very important. Further we describe the algorithms applied to reject phase measurements with enhanced errors and to compensate the effect of low-frequency noise in the measured single phase differences for each satellite occurring randomly for instance due to multipath.