# Design of a Morphing Aircraft Based on Model Predictive Control
## 3 Controller Design
### Model Predictive Controller Design
Further simplifying Equation (33), \(\mathbf{M}\triangleq\overline{\mathbf{\mathcal{M}}}\mathbf{\Gamma}+\overline{\mathbf{\mathcal{ F}}},\mathbf{b}\triangleq-(\mathbf{\bar{\mathcal{M}}}+\overline{\mathbf{\mathcal{M}}}\mathbf{ \Phi})\), then, Equation (24) can be rewritten as follows:  
\[\mathbf{M}\mathbf{U}_{[k]}\leq\mathbf{\tilde{\beta}}+\mathbf{b}\mathbf{x}_{[k]k} \tag{34}\]  
Equations (26) and (34) together form a constrained quadratic programming problem. In Equation (34), only the control sequence to be solved, \(\mathbf{U}_{[k]}\), and the initial value at time \(k\), \(\mathbf{x}_{[k]k}\), are included. Therefore, the expression on the right-hand side of the inequality can be considered as a known quantity. The objective is to find the optimal control sequence \(\mathbf{U}_{[k]}^{*}\), that is, to obtain the solution of Equation (26), subject to the constraints given in Equation (34). Design of a Robust Model Predictive Control Strategy Using Set Containment as an Optimization Metric  
The system disturbances in Equation (11) can be rewritten as follows:  
\[\left\{ \begin{array}{l}\Delta\mathbf{x}(t)=\mathbf{A}(\mathbf{\tilde{x}}_{b})\Delta\mathbf{ x}(t)+\mathbf{B}\Delta\mathbf{u}(t)+\mathbf{d}(t)\\ \Delta\mathbf{y}(t)=\Delta\mathbf{x}(t)\end{array} \right. \tag{35}\]  
where \(\mathbf{d}(t)\) represents the system disturbance. Inspired by the literature [28; 29; 30], this section designs a robust predictive controller based on an approximate reachable set prediction. Building upon this work, this section proposes a robust model predictive controller (RMPC) based on the approximate predictive reachable set. The controller employs the inclusion degree of the terminal state constraint set within the reachable set as an optimization criterion and adopts a strategy of gradually shortening the prediction horizon. This approach ensures that states within the attraction domain are guided to the terminal state constraint set within a finite number of steps. Once the state enters the terminal state constraint set, predictive control continues to be applied to ensure that the system state remains within the set. Consider the following discrete model with bounded disturbances:  
\[x_{k+1}=f(x_{k},u_{k})+w_{k} \tag{36}\]  
where \(w_{k}\in R^{w}\) represents the system disturbances, and the nonlinear mapping \(f\) satisfies \(f(0,0)=0\). The state and input constraints of the system are given by \(x(k)\in X\), \(u(k)\in U\), where both \(X\) and \(U\) are compact convex sets containing the origin. The system disturbance \(w_{k}\in W\) does not decay to zero over time but is bounded in the 2-norm, \(w_{k2}\leq\tilde{W}\), where \(W\) is the upper bound of its 2-norm. Now, consider the following assumptions:  
**Assumption 1**. : _The system state is known exactly._  
**Assumption 2**. : _There exists a neighborhood of the origin, denoted as \(\Omega\subseteq X\), that satisfies the following robust control invariant set (RCIS) condition: for all \(\forall x\in\Omega\), there exists a control input \(u\in U\) such that for all disturbances \(\forall w\in W\), \(f(x,u)+w\in\Omega\)._  
The set \(\Omega\) is referred to as the Robust Control Invariant Set (RCIS). When the system disturbance does not gradually decay to zero over time, it is impossible to stabilize the system state at the origin. Instead, the control objective shifts to maintaining the state within a neighborhood of the origin.Taking the inclusion degree of the predicted reachable set as the optimization metric, a control strategy with a gradually decreasing prediction horizon is adopted, and \(\Omega_{f}\) is used as the terminal state constraint set for predictive control. At the initial time step, the optimization problem for predictive control can be formulated as follows:  
\[\min_{\mathbf{u}(i,x_{0})\in U}J(\mathbf{u},x_{0})= \sum_{i=0}^{N-1}D_{s}(X_{i}(x_{0},\mathbf{u}(x_{0})),\Omega)+\delta D _{s}(X_{N}(x_{0},\mathbf{u}(x_{0})),\Omega)\] (37) s.t.