## 2 INS/GNSS Concepts
### Extended Kalman Filter (EKF)
#### 2.4.1 Direct Mode (State Model)  
In the Direct EKF (DEKF), also known as the state model, the states are estimated based on the mathematical model of the system rather than the error dynamics of the states [39]. Thus, the DEKF directly estimates the navigation states, which in this work are represented by the following state vector:  
\[\mathbf{x}=[\mathbf{p}^{T},\ \mathbf{v}^{T},\ \boldsymbol{\epsilon}^{T}]^{T}, \tag{4}\]  
where \(\boldsymbol{\epsilon}\) represents the attitude in Euler angles, specifically roll (\(\phi\)), pitch (\(\theta\)), and yaw (\(\psi\)). The general system of differential equations that governs the state-space model used by the EKF can be expressed as follows:  
\[\dot{\mathbf{x}}(t)=\mathbf{f}(\mathbf{x}(t),\mathbf{u}(t),t)+ \mathbf{w}(t), \tag{5}\] \[\mathbf{z}(t)=\mathbf{h}(\mathbf{x}(t),t)+\mathbf{v}(t), \tag{6}\]  
where \(\mathbf{x}(t)\) is the state vector as a function of the time \(t\), \(\mathbf{u}(t)\) is the deterministic forcing function, \(\mathbf{w}(t)\) is the model noise, \(\mathbf{z}(t)\) is the measurement vector, \(\mathbf{v}(t)\) is the measurement noise, and \(\mathbf{f}\) and \(\mathbf{h}\) are nonlinear known functions [40]. The discrete state of process and measurements of the DEKF are defined as follows:  
\[\mathbf{x}_{k}=\mathbf{\Phi}_{k-1}\mathbf{x}_{k-1}+\mathbf{w}_{k-1}, \tag{7}\] \[\mathbf{z}_{k}=\mathbf{H}_{k}\mathbf{x}_{k}+\mathbf{v}_{k}, \tag{8}\]  
where \(\mathbf{x}\) represents the state vector as defined in Vector (4), \(\mathbf{\Phi}\) is the transition matrix, \(\mathbf{H}\) is the observation matrix, and \(k\) denotes the discrete time step. The transition matrix \(\mathbf{\Phi}_{k-1}\) can be found based on the first-order Taylor series approximation [41; 42]:  
\[\mathbf{\Phi}_{k-1}\approx\mathbf{I}_{9}+\Delta t \begin{bmatrix}\mathbf{0}_{ 3\times 3}&\mathbf{I}_{3}&\mathbf{0}_{3\times 3}\\ \mathbf{0}_{3\times 3}&\mathbf{0}_{3\times 3}&-\mathbf{F}_{23}\\ \mathbf{0}_{3\times 3}&\mathbf{0}_{3\times 3}&\mathbf{F}_{33}\end{bmatrix} , \tag{9}\]  
\[\mathbf{F}_{23}=\mathbf{R}_{b}^{n}\cdot \begin{bmatrix}0&-f_{D}&f_{E}\\ f_{D}&0&-f_{N}\\ -f_{E}&f_{N}&0\end{bmatrix} ,\]  
\[\mathbf{F}_{33}= \begin{bmatrix}0&-\omega_{D}&\omega_{E}\\ \omega_{D}&0&-\omega_{N}\\ -\omega_{E}&\omega_{N}&0\end{bmatrix} ,\]  
where  
* \(\Delta t\) is the time step interval;
* \(\mathbf{I}_{9}\) is the \(9\times 9\) identity matrix;
* \(\mathbf{I}_{3}\) is the \(3\times 3\) identity matrix;
* \(\mathbf{0}_{3\times 3}\) is a \(3\times 3\) zero matrix;
* \(\mathbf{R}_{b}^{n}\) is the rotation matrix from body frame to navigation frame, which follows the 3-2-1 (yav-pitch-roll) rotation sequence;
* \(f_{N}\), \(f_{E}\), and \(f_{D}\) are components of specific force in the north, east, and down directions, respectively;* \(\omega_{N}\), \(\omega_{E}\), and \(\omega_{D}\) are the angular velocities in the north, east, and down directions, respectively. In the next equations, \(\mathbf{I}_{m}\) represents an identity matrix of order \(m\), and \(\mathbf{0}_{m\times n}\) represents a zero matrix of dimension \(m\times n\). The observations of the algorithm consist of GNSS positions and velocities; therefore, \[\mathbf{H}= \begin{bmatrix}\mathbf{I}_{3}&\mathbf{0}_{3\times 3}&\mathbf{0}_{3 \times 3}\\ \mathbf{0}_{3\times 3}&\mathbf{I}_{3}&\mathbf{0}_{3\times 3}\end{bmatrix}