- Extract the YALMIP zip file to the location of the REAP-T file.
- Run the
DisREAP_UI
function in MATLAB.
- Import your system and desired configurations:
- After running
DisREAP_UI
, import your system model and specify your desired configurations, enable plots, and simulate the system to observe results.
- After running
- Execute the package to start the control process.
-
Matrix A
Represents the state-transition matrix of the system.
Example:
A = [0 1; -2 -3] -
Matrix B
Input matrix defining how the control inputs affect the system.
Example: B = [0; 1] -
Matrix C
Output matrix, mapping the state to system outputs.
Example:
C = [1 0] -
Matrix D
Feedthrough matrix, directly connecting input to output.
Example: D = 0
-
X Constraint U.B. (Upper Bound)
Upper bounds for the system state vector (x).
Example:[5; 5]
-
X Constraint L.B. (Lower Bound)
Lower bounds for the system state vector (x).
Example:[-5; -5]
-
U Constraint U.B. (Upper Bound)
Upper bounds for the control input vector (u).
Example:[1]
-
U Constraint L.B. (Lower Bound)
Lower bounds for the control input vector (u).
Example:[-1]
-
Matrix Qx
Weighting matrix for penalizing state deviations in the cost function.
Example:
Qx = [1 0; 0 1] -
Matrix Qu
Weighting matrix for penalizing control efforts in the cost function.
Example:
Qu = [0.01] -
Initial Condition ((x_0))
Initial state of the system.
Example:[0; 0]
-
Prediction Horizon
The number of future steps the controller optimizes for.
Example:10
-
Desired Target
Desired value for the reference trajectory or desired steady-state configuration (Equilibrium point) -
# Time Instants
Total number of time steps for the simulation.
Example:100
-
Sampling Period ((\Delta T))
Time interval between successive steps.
Example:0.2
-
Terminal Constraint The mode of the terminal constraints; could be prediction-based or Lyapunov-based.
- Select Plots
Choose which aspects of the system to visualize:
- States: Display state trajectories.
- Control Inputs: Show control signals over time.
- Output: Visualize system output.
- Sigma: Plot algorithm-specific sigma values.
- Algorithm Mode Dropdown
- Automatic: Let the system decide optimal parameters (disables
Omegastar
input). - Manual: Allows customization of the
Omegastar
parameter.
This interface makes it easier to define and simulate discrete-time systems with constraints and optimization. Start exploring your systems now! 🚀
For guidance, the package includes two examples:
- Parrot Bebop 2 Drone:
- This example demonstrates the implementation of DisREAP on a Parrot Bebop 2 drone.
- F-16 Aircraft Model:
- This example showcases DisREAP applied to a F-16 Aircraft Model.
- Navigate to the examples directory:
- Open the folder containing the examples within the extracted files.
- Run the example scripts:
- Follow the instructions in the example scripts to see the results and understand how to set up and execute your own system.
For any issues or questions, please refer to the issues page on GitHub.
If you use the DisREAP Toolbox, please use the following BibTeX entry:
@INPROCEEDINGS{Amiri:REAP-T,
AUTHOR="{Mohsen Amiri and Mehdi Hosseinzadeh",
TITLE="REAP-T: A MATLAB Toolbox for Implementing Robust-to-Early Termination Model Predictive Control",
BOOKTITLE="..... ",
ADDRESS="........",
ABSTRACT="........."}