# Model Predictive Control and Its Role in Biomedical Therapeutic Automation: A Brief Review
## 2 MPC Implementation
### MPC Softuares  
This subsection gives a brief introduction to some of the important software used to implement MPC architectures.  
Figure 8: Feedback and feedforward MPC [55].  
Figure 7: Distributed MPC.  
* **MATLAB:** The model predictive control toolbox of Matlab includes application, function and Simulink blocks for designing and simulating linear and nonlinear model predictive control (MPC) controllers [58]. This toolbox allows users to specify plant model parameters, horizons, constraints and weights. Closed-loop simulations can be used to assess controller performance. Controller weights and constraints can be changed during runtime to update output behaviour. In addition to deployable solvers, control designers can employ a custom optimizer from the toolbox. Nonlinear, gain-scheduled and adaptive MPCs can be used to control nonlinear plants. For applications with high sample rates, this toolbox can generate explicit MPCs from regular controllers to approximate feasible solutions.
* **[PERSON]'s MUP:** This software uses the MATLAB/Simulink toolbox to implement a robust MPC in the LMI (linear matrix inequalities) framework online [59]. The MUP toolbox is a practical and user-friendly solution for MPC control engineering. It is also an excellent choice for educational purposes. The MUP package is provided \"as is,\" with no warranties of any kind. YALMIP (yet another LMI parser and SeDuMi (self dual minimization)) are the required MUP dependencies, with Mosek as the recommended solver. These are not included in the MUP toolbox.
* **do-MPC:** do-MPC is an open-source toolbox used for moving horizon and parameter estimation to develop robust multi-stage MPC architectures. do-MPC includes specialized tools to deal with time discretization and system uncertainties. Its modular layout easily accommodates different combinations of control, estimation and simulation components in seamless integration for various applications. do-MPC is widely used for nonlinear system modeling, estimation and simulations. It supports differential algebraic equations as well [60].  
Table 4 lists a summary representation of the above-discussed commercial MPC softwares, including a brief mention of their respective owners/creators, methodologies, model types, tuning and applications.  
\begin{table}
\begin{tabular}{p{113.8 pt} p{113.8 pt} p{113.8 pt} p{113.8 pt}} \hline \hline
**Software** & **MATLAB** & **MUP** & **do-MPC** \\ \hline Year & 2004 & 2012 & 2017 \\ \hline Developed/created by & [PERSON] & [PERSON], [PERSON], [PERSON], and [PERSON] \\ \hline Methodology & – & MATLAB/Simulink toolbox for online robust MPC design in LMI-framework & Comprehensive open-source toolbox for robust model predictive control (MPC) and moving horizon estimation (MHE) \\ \hline Model type & Continuous and discrete model & Linear matrix inequalities & Differential algebraic equations (DAE) \\ \hline Approach & Calculates the sequence of control actions based on current state of the plant & Optimally and robustly stabilizes state-feedback control law & Efficient formulation and solution of control and estimation problems for nonlinear systems \\ \hline Tuning & Prediction, control horizon, constraints & – & Horizon state and parameter estimation \\ \hline Usage & Design of implicit, explicit, adaptive, and gain-scheduled MPC. For nonlinear problems, single and multi-stage nonlinear MPCs can be implemented & Practical and user-friendly solution for MPC control engineering; also an excellent choice for educational purposes. & Contains simulation, estimation and control components that can be easily extended and combined to fit many different applications \\ \hline \hline \end{tabular}
\end{table}
Table 4: MPC Commercial Softwares.