## 4 Model Predictive Controller Design for Gas Turbine Engine
\tag{11}\]  
To simplify the constants in Equation (11):  
\[\mathrm{Y=E\cdot X(k)+F\cdot\Delta U(k)}. \tag{12}\]  
To optimize the engine transient performance, optimal control inputs should be achieved by minimizing the objective function, as shown in Equation (13), so that the predicted outputs (\(\mathrm{Y}\)) can accurately reach the final control target (\(\mathrm{W}\)) in the cost function:  
\[\mathrm{J=(W-(F\Delta U+EX(k)))^{T}(W-(F\Delta U+EX(k)))+\Delta U^{T}\overline {W}\Delta U}. \tag{13}\]  
The minimization of the cost function is obtained from the derivation of Equation (13) for the optimal control solution as follows:  
\[\frac{\partial\mathrm{J}}{\partial\Delta U}=2(F^{T}F+\overline{W})\Delta U-2F^ {T}(W-EX(k))=0. \tag{14}\]  
That results in Equation (15):  
\[\Delta U=(F^{T}F+\overline{W})^{-1}F^{T}(W-EX(k)). \tag{15}\]  
\"\(\overline{W}\)\" is a weighting factor matrix to the future control inputs, which is used to restrict the amount of change in the control inputs to the plant. This matrix has the length of the prediction horizon (\(\mathrm{Np}\)), and all of its parameters are chosen between 0 and 1. Each value in the matrix can be different depending on the system dynamics, the natural frequencies of the state and output parameters, and the control task. When the value is close to 0, the input is more responsive to the change of output. While for values closer to 1, more control weight is added, and a slower change of fuel flow rate is being supplied to the engine's combustor, which is suitable for obtaining a smooth power transition. The constraints required for the safe and optimal operation of the engine are defined in the form of Equation (16). These constraints are to limit the change rate of fuel flow, the shaft rotational speed, the compressor surge, and the turbine entry temperature. \[\left\{ \begin{array}{c}\mathrm{U_{min}\leq U\leq U_{max}}\\ \Delta U_{min}\leq\Delta U\leq\Delta U_{max}\\ X_{min}\leq X\leq X_{max}\\ Y_{min}\leq Y\leq Y_{max}\end{array} \right. \tag{16}\]For the convenience of computation, the constraint values are moved to the right-hand side of Equation (16), and the left side of the inequality becomes a unity. The result for the input parameters is shown by Equation (17), in which the constraints can be added to monitor the magnitudes and the rate of change. However, monitoring the output parameters (output (Y) parameters) requires substituting the prediction functions, as shown in Equation (12), to Equation (16), which gives Equation (18) followed by the same rearranging process as the input parameters. \[\left[ \begin{array}{c}1\\ -1\\ 1\\ -1\end{array} \right]\Delta\mathrm{U}(\mathrm{k})\leq\left[ \begin{array}{c} \mathrm{U}_{\mathrm{max}}\mathrm{U}(\mathrm{k}-1)\\ -\mathrm{U}_{\mathrm{min}}+\mathrm{U}(\mathrm{k}-1)\\ \Delta\mathrm{U}_{\mathrm{max}}\\ \Delta\mathrm{U}_{\mathrm{min}}\end{array} \right] \tag{17}\]  
\[\left\{ \begin{array}{c}\mathrm{I}\cdot\left[\begin{array}{c}\Delta\mathrm{ U}(\mathrm{k})\\ \vdots\\ \Delta\mathrm{U}(\mathrm{k}+\mathrm{N}_{\mathrm{c}})\end{array}\right]\leq \mathrm{F}^{-1}\cdot\left(\mathrm{I}\cdot\mathrm{Y}_{\mathrm{max}}-\mathrm{E} \cdot\mathrm{X}(\mathrm{k})\right)\\ -\mathrm{I}\cdot\left[\begin{array}{c}\Delta\mathrm{U}(\mathrm{k})\\ \vdots\\ \Delta\mathrm{U}(\mathrm{k}+\mathrm{N}_{\mathrm{c}})\end{array}\right]\leq \mathrm{F}^{-1}\cdot\left(-\mathrm{I}\cdot\mathrm{Y}_{\mathrm{min}}-(-\mathrm{E })\cdot\mathrm{X}(\mathrm{k})\right)\end{array} \right. \tag{18}\]  
Other engine parameters, such as the compressor pressure ratio, shaft speed, turbine entry temperature (TET), and Specific Fuel Consumption (SFC) to monitor the engine performance or engine health, can also be included in the Equation (18). The dynamics of the constrained parameters are also predicted linearly in the same way as the outputs, as shown in Equation (12). The right-hand side of Equation (18) is the difference between the outputs/constraints' limits and the predicted values.