# Exploiting Lunar Navigation Constellation for GNC Enhancement in Landing Missions
## 3 GNC Algorithms
### Navigation  
Similarly to our previous work in [14], the navigation is performed through an Extended Kalman Filter, which employs, as in the previous study, the GNSS/INS strategy. In the current scenario, however, an altimeter is considered as well, deemed as fundamental for both state estimation enhancement and safety reason. The work we performed in [16] already analysed the improvements that can be achieved by combining these sensors for orbital users. Specifically, it highlighted that by providing a direct estimate of the spacecraft vertical components, the altimeter allows the reduction by one of the actual number of visible LNS satellites that are requested to reconstruct the user position, and thus becomes particularly beneficial for small-sized LNS constellations. The resulting navigation architecture is schematised in Figure 2.  
Figure 1: Architecture of the GNC scheme used for the landing analysis. Figure 2: Description of the GNSS/INS navigation formulation with the altimeter. The presence of the IMU, used in dynamic model replacement, outputs the acceleration, \(\bar{\mathbf{a}}_{IMU}\), which is added to the on-board dynamics for the state prediction step in the filter, providing the a priori estimate, \(\hat{\mathbf{x}}_{k+1}^{-}\), at time step \(k+1\). Such an approach provides the possibility to directly retrieve a measurement of control acceleration, \(\bar{\mathbf{u}}_{k}\), to be fed in the EKF prediction step, avoiding using the acceleration predicted by the controller \(\mathbf{u}_{k}\). Indeed, the measurement error introduced by the accelerometer is much lower than the error between the commanded and executed actuator action. The accelerometer is employed, however, only during the thrusted phase, while in the preceding one it is disregarded. Indeed, during natural motion, the error introduced by the accelerometer is larger than the unmodelled dynamics of SRP and higher-order irregular mass distribution. The observables of the LNS are composed of pseudorange, \(\hat{p}_{i}\), pseudorange-rate, \(\hat{p}_{i}\), and the servicers' ephemerides. Such measurements are passed to the filter, together with the altimeter reading, \(\hat{\zeta}\), in order to provide, through the Kalman update step, the a posteriori corrected state, \(\hat{\mathbf{x}}_{k+1}^{+}\). Such GNSS/INS formulation, known as _tightly coupled_, takes a different approach than the _loosely coupled_ alternative (see [31]), since the GNSS (or LNS) receiver is not treated as a mere black box that outputs the complete state. Instead, this approach offers distinct advantages by exploiting LNS signals, even when fewer than four satellites are visible, a condition which is a likely scenario in our proposed context due to the limited constellation elements. In scenarios where LNS signals are absent, our proposed architecture seamlessly continues the onboard propagation of the user's position, using only the information provided by the IMU. Opting to incorporate the clock bias, \(b_{c}\), and drift, \(d_{c}\), as part of the parameter estimation, we augment the spacecraft state, \(\mathbf{x}_{S/C}\), by including these components. This is obtained by considering a stacked filter state, \(\mathbf{x}=[\mathbf{x}_{S/C}^{\top},\ b_{c},\ d_{c}]^{\top}\). The prediction step of the EKF is characterised by a simplified spacecraft dynamical model, \(\mathbf{f}_{S/C}(\mathbf{x}_{S/C},\bar{\mathbf{a}}_{IMU})\), and a clock dynamical model governing the propagation and measurement function, \(\mathbf{h}(\mathbf{x},\bar{\mathbf{x}}_{s,i})\), outlined respectively in Equations (17) and (18).