# Hierarchical Coordinated Predictive Control of Multiagent Systems for Process Industries
## 3 Methodology
### Sequential Game-Based Dynamic Predictive Control of MASs  
A dynamic predictive control method for multiple agents with sequential games based on the priorities obtained in Section 3.2 is proposed in this section. At each time step, the cost function of the agent \(v_{i}\) is established based on the system outputs, the control inputs of agent \(v_{i}\) and its high priority neighbors, which is expressed as  
\[J_{i}^{\text{DPC}}(k)=J_{i}^{\text{DPC1}}(k)+J_{i}^{\text{DPC2}}(k)+J_{i}^{ \text{DPC3}}(k) \tag{26}\]  
where the superscript \"DPC\" represents the SG-DPC phase. The cost function \(J_{i}^{\text{DPC1}}(k)\) impacts the deviation between the system outputs and their targets, and the larger \(J_{i}^{\text{DPC1}}(k)\) is, the larger the deviation, which is shown as Equation (27). The cost function \(J_{i}^{\text{DPC2}}(k)\) is the cost corresponding to the magnitude of change in control inputs, the larger \(J_{i}^{\text{DPC2}}(k)\) means the larger the magnitude of change in control inputs, which will affect the smoothness of the control, and it is shown as Equation (28). The cost function \(J_{i}^{\text{DPC3}}(k)\) affects the control inputs, the larger \(J_{i}^{\text{DPC3}}(k)\) means the larger the control inputs, which is shown as Equation (29)  
\[J_{i}^{\text{DPC1}}(k) =\left\|\mathbf{y}_{\text{t}}(k)\otimes\mathbf{I}_{\text{y}}-(\hat{\mathbf{y}} _{\text{PoL},i}(k)+\mathbf{R}_{i}\Delta\mathbf{u}_{\text{P}i}(k)+\sum_{j\
eq i,\bar{ \
u}_{j}\in\mathbf{\mathcal{N}}_{i}^{\text{H}}}\mathbf{R}_{j}\Delta\mathbf{u}_{\text{P}j}(k ))\right\|_{\mathbf{Q}^{\text{DPC1}}}^{2} \tag{27}\] \[J_{i}^{\text{DPC2}}(k) =\left\|\Delta\mathbf{u}_{\text{P}i}(k)\right\|_{\mathbf{Q}^{\text{DPC2}}} ^{2}\] (28) \[J_{i}^{\text{DPC3}}(k) =\left\|\mathbf{u}_{\text{P}i}(k)\right\|_{\mathbf{Q}^{\text{DPC3}}}^{2}= \left\|u_{i}(k-1)\otimes\mathbf{I}_{\text{u}}+\mathbf{M}_{\text{u},i}\Delta\mathbf{u}_{ \text{P}i}(k)\right\|_{\mathbf{Q}^{\text{DPC3}}}^{2} \tag{29}\]  
where \(\mathbf{Q}^{\text{DPC1}}\), \(\mathbf{Q}^{\text{DPC2}}_{i}\) and \(\mathbf{Q}^{\text{DPC3}}_{i}\) are the output deviation weighting matrix and control weighting matrices in SG-DPC phase, respectively, and \(\mathbf{Q}^{\text{DPC2}}_{i}\) weights the control input increments while \(\mathbf{Q}^{\text{DPC3}}_{i}\) weights the total control input. The forms of the three aforementioned weighting matrices are provided in Appendix B. \(\mathbf{u}_{\text{P}i}(k)=u_{i}(k-1)\otimes\mathbf{I}_{\text{u}}+\mathbf{M}_{\text{u},i} \Delta\mathbf{u}_{\text{P}i}(k)\) is the prediction sequence of agent \(v_{i}\)'s control input at time step \(k\) and its form is provided in Appendix A. Notably, cost function (27) shows that each agent obtains the sequence of optimal control input increments by solving optimization problem (30) under the impact of high-priority neighbors, which is the significant difference from cost function (18) and optimization problem (21). \[\min_{\Delta\mathbf{u}_{\text{P}i}(k)}J_{i}^{\text{DPC}}(k)=\left\|\bm {y}_{\text{t}}(k)\otimes\mathbf{I}_{\text{y}}-(\hat{\mathbf{y}}_{\text{PoL},i}(k)+\bm {R}_{i}\Delta\mathbf{u}_{\text{P}j}(k)+\sum_{j\
eq i,\bar{\
u}_{j}\in\mathbf{\mathcal{ N}}_{i}^{\text{H}}}\mathbf{R}_{j}\Delta\mathbf{u}_{\text{P}j}(k))\right\|_{\mathbf{Q}^{ \text{DPC1}}}^{2}+\left\|\Delta\mathbf{u}_{\text{P}i}(k)\right\|_{\mathbf{Q}^{\text{ DPC2}}}^{2}+\left\|\mathbf{u}_{\text{P}j}(k)\right\|_{\mathbf{Q}^{\text{DPC3}}}^{2} \tag{30}\] \[\text{s.t. }\left\{