# Semi-Analytical Planetary Landing Guidance with Constraint Equations Using Model Predictive Control
## 3 Motion Mode Analysis and Reachability Determination
### Reachability Analysis and Motion Mode Judgment  
To analyze the reachability of the landing point under the control mode mentioned above, we begin with an analysis of the vertical motion. Because of the vertical motion dominates, the soft landing in the \(Z\) direction should be ensured first. Therefore, the first step of reachability analysis is to determine the feasibility of the vertical soft landing. If the vertical soft landing can be guaranteed, the minimum \(\mu_{\rm z}\) required is calculated, which is equivalent to obtaining the lander's maximum maneuverability for horizontal adjustment. As mentioned in Section 2.1, the lander's vertical motion is free-fall motion first and then decelerating. We use \(F(\mu_{\rm z},t_{\rm f},t_{\rm f})=0\) and \(G(\mu_{\rm z},t_{\rm f},t_{\rm f})=0\) to represent Equations (28) and (29), respectively. Then, \(\rm d{}t_{\rm f}/\rm d{}\mu_{\rm z}\) and \(\rm d{}t_{\rm f}/\rm d{}\mu_{\rm z}\) can be expressed as:  
\[ \begin{bmatrix}\frac{\rm d{}t_{1}}{\rm d{}\mu_{\rm z}}\\ \frac{\rm d{}t_{\rm f}}{\rm d{}\mu_{\rm z}}\end{bmatrix} =- \begin{bmatrix} \frac{\partial F}{\partial t_{1}}&\frac{\partial F}{\partial t_{\rm f}}\\ \frac{\partial G}{\partial t_{1}}&\frac{\partial G}{\partial t_{\rm f}}\end{bmatrix}  ^{-1} \begin{bmatrix}\frac{\partial F}{\partial\mu_{\rm z}}\\ \frac{\partial G}{\partial\mu_{\rm z}}\end{bmatrix} = \begin{bmatrix}-\frac{ \partial G}{\partial\mu_{\rm z}}/\frac{\partial G}{\partial t_{1}}\\ \left(-\frac{\partial F}{\partial\mu_{\rm z}}+\frac{\partial G}{\partial\mu_{ \rm z}}\cdot\frac{\partial F}{\partial t_{1}}/\frac{\partial G}{\partial t_{1} }\right)/\frac{\partial F}{\partial t_{\rm f}}\end{bmatrix}  \tag{32}\]  
where\[\frac{\partial F}{\partial t_{1}} =-\frac{\mu_{x}T_{\max}}{m_{0}-\eta(t_{\rm f}-t_{1})}<0 \tag{33}\] \[\frac{\partial G}{\partial t_{1}} =-\frac{\mu_{x}T_{\max}}{\eta}\left[\ln\!\left(\frac{m_{0}}{\eta} \right)-\ln\!\left(\frac{m_{0}}{\eta}-(t_{\rm f}-t_{1})\right)\right]<0\] (34) \[\frac{\partial F}{\partial t_{\rm f}} =-g+\frac{\mu_{x}T_{\max}}{m_{0}-\eta(t_{\rm f}-t_{1})}>0\] (35) \[\frac{\partial G}{\partial t_{\rm f}} =v_{x}(t_{\rm f})=0\] (36) \[\frac{\partial F}{\partial\mu_{x}} =\frac{T_{\max}}{\eta}\left[\ln\!\left(\frac{m_{0}}{\eta}\right) -ln\!\left(\frac{m_{0}}{\eta}-(t_{\rm f}-t_{1})\right)\right]>0\] (37) \[\frac{\partial G}{\partial\mu_{x}} =-\frac{T_{\max}}{\eta}\left(\frac{m_{0}}{\eta}-(t_{\rm f}-t_{1} )\right)\left[\ln\!\left(\frac{m_{0}}{\eta}\right)-\ln\!\left(\frac{m_{0}}{ \eta}-(t_{\rm f}-t_{1})\right)\right]+\frac{T_{\max}}{\eta}(t_{\rm f}-t_{1}) \tag{38}\]  
We use \(t_{a}\) to represent \(t_{\rm f}-t_{1}\), and \(g(t_{a})\) to represent \(\partial G/\partial\mu_{x}\). It is easy to know that \(g^{\prime}(t_{a})>0\), so that \(\partial G/\partial\mu_{x}=g(t_{a})>g(0)=0\). Then, we have \(\mathrm{d}t_{1}/\mathrm{d}\mu_{x}>0\). A similar method is used to determine that \(\mathrm{d}t_{\rm f}/\mathrm{d}\mu_{x}<0\). In summary, if \(\mu_{x}\) decreases, the ignition time \(t_{1}\) will decrease and the final time \(t_{\rm f}\) will increase to meet the vertical terminal position and velocity constraints. The critical case is that the ignition time \(t_{1}\) decreases to zero. At this point, \(t_{\rm f}\) reaches the maximum, and \(\mu_{x}\) reaches the minimum, denoted as \(t_{\rm f,max}\) and \(\mu_{x,\min}\), respectively, as shown in Figure 4. By setting \(t_{1}\) to zero, we can solve Equations (28) and (29) to obtain the values of \(t_{\rm f,max}\) and \(\mu_{x,\min}\). Note that when the residual fuel is limited, the solved fuel consumption \(\eta t_{\rm f,max}\) may be greater than the mass of the residual fuel \(m_{\rm fuel}\). In this case, we can set \(t_{1}\) equal to \(t_{\rm f}-m_{\rm fuel}/\eta\) and resolve Equations (28) and (29) to update the values of \(t_{\rm f,max}\) and \(\mu_{x,\min}\). If \(\mu_{x,\min}>1\) is solved, the lander cannot land safely in the Z direction.