离散控制Matlab代码-Constrained-model-predictive-control-synthesis:一组m文

  • t6_362256
    了解作者
  • 1.9MB
    文件大小
  • zip
    文件格式
  • 0
    收藏次数
  • VIP专享
    资源类型
  • 0
    下载次数
  • 2022-05-20 06:10
    上传日期
离散控制Matlab代码约束模型预测控制综合 约束模型预测控制综合是一种尝试实现论文Lu,J.,D. Li和Y. Xi(2013)中提出的思想的尝试。 “不确定的离散时间马尔可夫跳跃线性系统的约束模型预测控制综合。” IET控制理论与应用7(5):707-719。 看 。 提供了可与或结合使用的matlab代码。 假定所有必需的软件包都已安装在MATLAB环境中。 如果不是,则必须安装它们,在主脚本中取消注释几行,并相应地进行更改。 MATLAB mfiles 主要脚本 主脚本是文件“ Example_Constrained”。 只需在提示符后键入名称,脚本将负责运行本文中给出的示例。 请记住在调用之前为yalmip,sedumi或mosek设置路径。 在脚本中,您将找到以下几行: addpath(genpath('〜/ Documents / MATLAB / yalmip')) addpath(genpath('〜/ Documents / MATLAB / cvx / sedumi')) addpath(genpath('〜/ Documents / MATLAB / cvx /
Constrained-model-predictive-control-synthesis-master.zip
  • Constrained-model-predictive-control-synthesis-master
  • images
  • image_3_u_constraint_N_1_random.png
    29.7KB
  • image_4_u_constraint_N_1_nrep_100.png
    38KB
  • image_5_u_constraint_N_3_nrep_100.png
    34.5KB
  • image_1_no_constraints_N_3_nrep_100.png
    58KB
  • image_6_u_constraint_N_1_random.png
    60.7KB
  • image_3_no_constraints_N_1_nrep_100.png
    29.2KB
  • image_2_u_constraint_N_3_random.png
    89.9KB
  • image_5_u_constraint_N_1_random.png
    32.8KB
  • image_2_u_constraint_N_1_random.png
    66.3KB
  • image_1_no_constraints_N_1_nrep_100.png
    57.6KB
  • image_4_no_constraints_N_1.png
    30.9KB
  • image_5_u_constraint_N_1_nrep_100.png
    34.2KB
  • image_2_no_constraints_N_3.png
    67.9KB
  • image_2_u_constraint_N_1_nrep_100.png
    38.1KB
  • image_4_no_constraints_N_3_nrep_100.png
    29.6KB
  • image_5_no_constraints_N_3_nrep_100.png
    29.7KB
  • image_4_no_constraints_N_3.png
    31.3KB
  • image_2_u_constraint_N_3_nrep_100.png
    36.6KB
  • image_5_u_constraint_N_3_random.png
    30.3KB
  • image_4_no_constraints_N_1_nrep_100.png
    29.3KB
  • image_5_no_constraints_N_1.png
    31.6KB
  • image_3_u_constraint_N_3_nrep_100.png
    32.3KB
  • Example_LMI_11.png
    197.3KB
  • image_1_u_constraint_N_1_random.png
    63.9KB
  • image_1_u_constraint_N_3_nrep_100.png
    61.2KB
  • image_3_u_constraint_N_1_nrep_100.png
    37.6KB
  • image_2_no_constraints_N_1_nrep_100.png
    37.4KB
  • feasreg_1_u_constraint_N_1_nrep_1000_random.png
    73.3KB
  • image_4_u_constraint_N_1_random.png
    29.5KB
  • image_1_no_constraints_N_3.png
    61.3KB
  • image_2_no_constraints_N_3_nrep_100.png
    37.8KB
  • image_4_u_constraint_N_3_random.png
    28.6KB
  • image_3_u_constraint_N_3_random.png
    28.7KB
  • image_2_no_constraints_N_1.png
    67.1KB
  • image_3_no_constraints_N_3.png
    31KB
  • feasregp_jianbo_1_u_constraint_N_1_umax_1.png
    27.7KB
  • image_1_u_constraint_N_1_nrep_100.png
    64.1KB
  • image_3_no_constraints_N_3_nrep_100.png
    29.5KB
  • image_4_u_constraint_N_3_nrep_100.png
    32.4KB
  • image_1_no_constraints_N_1.png
    62.2KB
  • image_3_no_constraints_N_1.png
    30.8KB
  • image_5_no_constraints_N_3.png
    31.5KB
  • image_6_u_constraint_N_3_random.png
    86.8KB
  • image_5_no_constraints_N_1_nrep_100.png
    29.7KB
  • image_1_u_constraint_N_3_random.png
    64.5KB
  • data
  • pfeasreg_jianbo_u_constraint_N_1_umax_1.mat
    935B
  • pre_build_lmi15_jianbo.m
    600B
  • actual_build_lmi26_jianbo.m
    940B
  • Example_Constrained_Un_N_1.m
    9.4KB
  • pre_build_lmi16_jianbo.m
    945B
  • pre_build_lmi11_jianbo.m
    2.6KB
  • pre_build_lmi25_jianbo.m
    660B
  • pre_build_lmi23_jianbo.m
    32B
  • write_check_lmi.m
    3.1KB
  • genmarkovs.m
    692B
  • model_parameters_jianbo.m
    2KB
  • script_generate_feasible_region_brute_force.m
    8.3KB
  • actual_build_lmi16_jianbo.m
    851B
  • save_results_simulation.m
    1.3KB
  • actual_build_lmi24_jianbo.m
    599B
  • script_generate_feasible_region_modified.m
    4.9KB
  • actual_build_lmi20_jianbo.m
    749B
  • procedure_jianbo_esp.m
    5.7KB
  • script_run_all_examples_paper.m
    141B
  • actual_build_lmi15_jianbo.m
    294B
  • plot_figure_sim.m
    1.1KB
  • actual_build_lmi21_jianbo.m
    968B
  • pre_build_lmi21_jianbo.m
    610B
  • README.md
    9.3KB
  • Example_Constrained.m
    9.4KB
  • actual_build_lmi25_jianbo.m
    994B
  • actual_build_lmi23_jianbo.m
    61B
  • actual_build_lmi11_jianbo.m
    1.1KB
  • define_lmi_variables_jianbo.m
    1.7KB
  • script_generate_lmi_latex.m
    2.6KB
  • Example_Constrained_C_N_3.m
    9.4KB
  • pre_build_lmi24_jianbo.m
    159B
  • pre_build_lmi20_jianbo.m
    531B
  • Example_Constrained_C_N_1.m
    9.4KB
  • .gitignore
    1.2KB
  • script_generate_feasible_region.m
    3.5KB
  • Example_Constrained_Un_N_3.m
    9.4KB
  • pre_build_lmi26_jianbo.m
    660B
内容介绍
# Constrained-model-predictive-control-synthesis Constrained-model-predictive-control-synthesis is an attempt to implement the ideas laid out in the paper Lu, J., D. Li and Y. Xi (2013). "Constrained model predictive control synthesis for uncertain discrete-time Markovian jump linear systems." IET Control Theory & Applications 7(5): 707-719. See [(Lu et al, 2013)](https://doi.org/10.1049/iet-cta.2012.0884). A matlab code is provided that uses [Yalmip](https://yalmip.github.io) with [sedumi](https://github.com/SQLP/SeDuMi) or [mosek](http://www.mosek.com). It is assumed that all the necessary packages are already installed in the MATLAB environment. If not you will have to install them, uncomment a few lines in the main script and change them accordingly. # The MATLAB mfiles ## The main script The main script is the file "Example_Constrained". Just type the name after the prompt and the script will take care of running the example given in the paper. Please remember to set the path for yalmip, sedumi or mosek before calling it. In the script you will find the following lines: addpath(genpath('~/Documents/MATLAB/yalmip')) addpath(genpath('~/Documents/MATLAB/cvx/sedumi')) addpath(genpath('~/Documents/MATLAB/cvx/sdpt3')) addpath(genpath('~/mosek/8/toolbox/r2014a')); Please change them accordingly. In the script you will find the following main flags: 1) *flagc* - if it is set to 1 the constrained problem on the input will be solved. It it is set to 2 the constrained problem on the state and input will be solved otherwise an unconstrained problem will be solved. 2) *flagx* - if *flagx* = 0, the initial conditions for the states *x* are always 1, that is, *x*(:,1)=[1;1] (You can change the values by editing the script). If *flagx* = 1, the initial conditions are chosen randomly from an uniform distribution U(-*umax*,*umax*), where the value of umax can be chosen by editing the script. The default is *flagx*=0. 3) *flagr* - if *flagr* = 0, the initial mode is set to 1 (as in the paper). If *flagr* = 1, the initial model is randomly chosen from the set {1,2,3}. The main parameters are: * The number of replication is set to 100. If there is a need to change the value, use the variable *nrep* in the beginning of the script. * The maximum input value is set to 1 using the variable *umax*. * The maximum value of the initial states is set to 1.5 using the variable *xmax*. Such a veriable not only controls the maxinum value used for generating the initial conditions (constrained problem) but also the maximum allowed value in the state constrained problem. * The number of steps in each replication (simulation) is set using the variable *ksteps*. The default is *ksteps* = 80 (as in the paper). * The prediction control estrategy can be controlled using the variable *N* in the main script. The default is *N* = 1 or *N* = 3. A couple of observations: **Obs. 1**: As it is the code fails for some initial conditions when solving the constrained problem. The reason is that **Theorem 2** is violated. When this happens, a message will come out showing the initial condition. I have not tested values outside the range *x0*=[-1.5,1.5] for the unconstrained problem (**Theorem 1**). **Obs. 2**: As it is the code is set to run using mosek instead of sedumi. **Obs. 3**: I thank Dr. Lu for patiently answering my questions. ## Some useful information All the LMIs are coded using a string variable which is later converted to LMIs. For instance if the content of *LMI 21* needs to be checked, just issue the following command after the matlab prompt `>> auxm21` and you will see auxm21 = 2×2 cell array 'G(:,:,n,i)'+G(:,:,n,i)-mathW(:,: ...' '(A{l,i}*G(:,:,n,i)+B{l,i}*Y(:,:, ...' '(A{l,i}*G(:,:,n,i)+B{l,i}*Y(:,:, ...' 'mathW(:,:,min(N,n+1),j);' The sdpvar version of the same LMI can be found in the variable called m21 which is a cell array. *LMI 21* is pilled up in the variable called *biglmi21* that together with all other LMIs (*biglmi11*, *biglmi15*, ...) results in a single big LMI - *LMIs_orig* (procedure_jianbo_esp.m) The same rationale is used for all other LMIs, that is, *LMI 11*, *LMI 15*, *LM 16*, *LMI 20*, *LMI 21*, *LMI 23*, *LMI 24*, *LMI 25* (two parts) and *LMI 26* (two parts). Depending on how the function *phi* is chosen (See page 712), LMI 24 becomes an simple inequality. The implemented code deals with that but I am not sure if this is the best way to do it. The m-files are commented as much as possible. If you find any mistake please let me know. Thanks. # Example Here it is an example of runing the script using the default values. ## Unconstrained Problem ### For *N*=1 (Unconstrained Problem) - 100 replications * State, input and mode paths for the last replication (unconstrained simulation - *N* = 1) - ![path1a](images/image_1_no_constraints_N_1_nrep_100.png) * Control Cost over all replications (unconstrained simulation - *N* = 1) - ![control1a](images/image_2_no_constraints_N_1_nrep_100.png) * Average Control effort over all replications (unconstrained simulation - *N* = 1) - ![average1a](images/image_5_no_constraints_N_1_nrep_100.png) ### For *N*=3 (Unconstrained Problem) - 100 replications * State, input and mode paths for the last replication (unconstrained simulation - *N* = 3) - ![path3a](images/image_1_no_constraints_N_3_nrep_100.png) * Control Cost over all replications (unconstrained simulation - *N* = 3) - ![control3a](images/image_2_no_constraints_N_3_nrep_100.png) * Average Control effort over all replications (unconstrained simulation - *N* = 3) - ![average3a](images/image_5_no_constraints_N_3_nrep_100.png) ## Constrained Problem ### For *N*=1 (Constrained Problem) - 100 replications * State, input and mode paths for the last replication (constrained simulation - *N* = 1) - ![path1b](images/image_1_u_constraint_N_1_nrep_100.png) * Control Cost over all replications (constrained simulation - *N* = 1) - ![control1b](images/image_2_u_constraint_N_1_nrep_100.png) * Average Control effort over all replications (constrained simulation - *N* = 1) - ![average1b](images/image_5_u_constraint_N_1_nrep_100.png) ### For *N*=3 (Constrained Problem) - 100 replications * State, input and mode paths for the last replication (constrained simulation - *N* = 3) - ![path3b](images/image_1_u_constraint_N_3_nrep_100.png) * Control Cost over all replications (constrained simulation - *N* = 3) - ![control3b](images/image_2_u_constraint_N_3_nrep_100.png) * Average Control effort over all replications (constrained simulation - *N* = 3) - ![average3b](images/image_5_u_constraint_N_3_nrep_100.png) ## Constrained Problem - Random Initial Conditions of State Variables ### For *N*=1 (Input Constrained Problem) * State, input and mode paths for the last replication (unconstrained simulation - *N* = 1) - ![path1b](images/image_1_u_constraint_N_1_random.png) * Control Cost over all replications (Input Constrained Simulation - *N* = 1) - ![control1b](images/image_2_u_constraint_N_1_random.png) * Average Control effort over all replications (Input Constrained simulation - *N* = 1) - ![average1b](images/image_5_u_constraint_N_1_random.png) * Monte Carlo simulation (Input Constrained Problem) of Figure 4 - Comparision of the maximal feasible regions. Only for Controller IV - ![Fig4a](images/image_6_u_constraint_N_1_random.png) ### For *N*=3 (Input Constrained Problem) * State, input and mode paths for the last replication (unconstrained simulation - *N* = 3) - ![path1c](images/image_1_u_constraint_N_3_random.png) * Control Cost over all replications (Input Constrained Simulation - *N* = 3) - ![control1c](images/image_2_u_constraint_N_3_random.png) * Average Control effort over all replications (Input Constrained simulation - *N* = 3) - ![average1b](images/image_5_u_constraint_N_3_random.png) * Monte Carlo simulation (Input Constrained Problem) of Figure 4 - Comparision of
评论
    相关推荐
    • Matlab合集
      冈萨雷斯数字图像处理MATLAB版.中文版+数字图像处理第二版中文版(冈萨雷斯)+MATLAB-R2014a完全自学一本通+MATLAB R2016a完全自学一本通 素材文件+[模式识别与智能计算:MATLAB技术实现(第2版)].杨淑莹.扫描版
    • MATLAB教程
      MATLAB教程MATLAB教程MATLAB教程MATLAB教程MATLAB教程MATLAB教程
    • MATLAB
      MATLAB 该项目是在matlab上完成的,涉及创建和移动宇宙飞船和机器人。 太空飞船和机器人是使用Matlab中的简单几何形状创建的,并通过连续变换矩阵进行移动。 这个项目教我如何使用变换矩阵(旋转,平移等)的概念...
    • MATLAB基础
      一本学习matlab的一本好书
    • MATLAB编译器
      基于MATLAB 2018b版本介绍MATLAB编译器。介绍如何利用编译器将MATLAB代码编译为独立应用程序或组件,并在没有安装MATLAB的计算机上进行部署。
    • matlabruntime
      通过奇点容器运行您的matlab项目 可以在没有MATLAB的容器中运行matlab代码。 为此,我们首先需要通过Matlab编译器在本地构建相应的Matlab代码的独立应用程序,然后使用具有Matlab运行时( 的容器)运行该应用程序 )...
    • matlab实现
      matlab实现 matlab实现matlab实现matlab实现matlab实现
    • matlab 教程
      matlab 信号处理资料,里面包含信号处理pdf文档,一些杂乱的程序和命令等
    • matlab教程
      matlab教程,PPT格式,包含 matlab基本知识、matlab入门、matlab作图、线性规划、无约束优化、非线性规划、统计工具箱、差值、微分方程等多项知识点,并且每个知识点独立成为PPT,内还含有matlab信号处理详解等文档...
    • matlab简介
      1.MATLAB 开发环境 1.1 MATLAB 的视窗环境 进入MATLAB之后,会看到一个视窗MATLAB Command Window称为指令视窗,它是你键入指令的地方同时 MATLAB也将计算结果显示在此。 1.2 简易计算 我们先从MATLAB的...