This repository contains the code related to the paper Remote Tube-based MPC for Tracking Over Lossy Networks (preprint available here), which has been accepted at the 2024 Conference on Decision and Control.
This paper addresses the problem of controlling constrained systems subject to disturbances in the case where controller and system are connected over a lossy network. To do so, we propose a novel framework that splits the concept of tube-based model predictive control in two parts. One runs locally on the system and is responsible for disturbance rejection, while the other runs remotely and provides optimal input trajectories that satisfy the system’s state and input constraints. Key to our approach is the presence of a nominal model and an ancillary controller on the local system. Theoretical guarantees regarding the recursive feasibility and the tracking capabilities in the presence of disturbances and packet losses in both directions are provided.
In addition to the novel MPC algorithm, this repository also contains the implementation of several other MPC approach for constrained linear systems, implementation of two algorithms to approximate the minimal robust positively invariant set, an algorithm to determine the maximum admissible set, and also several functions that implement the Minkowski sum and Pontryagin difference for convex polytopes. For more details see the more detailed description of the repository below.
First, clone the repository as follows:
git clone https://github.com/EricssonResearch/Robust-Tracking-MPC-over-Lossy-Networks.git
cd Robust-Tracking-MPC-over-Lossy-Networks
Set up a virtual environment (this step is optional)
python3 -m venv .LinMPCoverNet
source .LinMPCoverNet/bin/activate
Next, run
pip3 install --upgrade pip
pip3 install .
to install the LinearMPCOverNetworks
package.
Finally, if one wants to reproduce the results in our submitted paper in Results, one needs to run
pip3 install PyBullet
The src/LinearMPCOverNetwoks folder contains several different MPC implementations for linear system with additive disturbances under constraints that lie in convex polytopes including the origin. The algorithms either bring the plant to the origin or track a piece-wise constant reference. The MPC algorithms included are:
- D. Umsonst, F. Barbosa, "Remote Tube-based MPC for Tracking Over Lossy Networks" accepted at the 2024 Conference on Decision and Control
- D. Limon, I. Alvarado, T. Alamo, E.F. Camacho, "MPC for tracking piecewise constant references for constrained linear systems," 2008
- M. Pezzutto, M. Farina, R. Carli and L. Schenato, "Remote MPC for Tracking Over Lossy Networks," 2022
- D.Q. Mayne, M.M. Seron, S.V. Raković, "Robust model predictive control of constrained linear systems with bounded disturbances," 2005
- D. Limon, I. Alvarado, T. Alamo, E.F. Camacho, "Robust tube-based MPC for tracking of constrained linear systems with additive disturbances," 2010
Examples on how these algorithms can be used are provided in the folder Examples of Model Predictive Controllers.
The folder Results contains scripts to reproduce the results of the paper Remote Tube-based MPC for Tracking Over Lossy Networks and also a script to generate animations of the cartpole.
To be able to implement the robust tube-based MPC algorithms, we needed to implement several operations on convex polytopes, such as the Minkowski sum, the Pontryagin difference, and the support function of a polytope.
The algorithms build up on the polytope
package.
Furthermore, we implemented two algorithms to approximate the minimum robust positively invariant set of a linear discrete-time system with bounded additive disturbance. The algorithms implemented are found in
- S. V. Rakovic, E. C. Kerrigan, K. I. Kouramas and D. Q. Mayne, "Invariant approximations of the minimal robust positively Invariant set," 2005
- M. S. Darup and D. Teichrib, "Efficient computation of RPI sets for tube-based robust MPC," 2019
Finally, we also implemented a method to calculate the terminal set of a linear MPC algorithm, via the maximum output admissible set. This algorithm is based on
All these methods can be found in utils_polytope.py
and examples on how to use them are presented in the folder Examples of Set Operations
David Umsonst [email protected] and Fernando S. Barbosa [email protected]