当前位置:网站首页>LQR control learning -lqr control matlab official tutorial -lqr controller_ Modeling and analysis of state space system with matlab/simulink
LQR control learning -lqr control matlab official tutorial -lqr controller_ Modeling and analysis of state space system with matlab/simulink
2022-07-23 17:37:00 【Full stack programmer webmaster】
Hello everyone , I meet you again , I'm your friend, Quan Jun .
LQR control
Ben blog Main records LQR Linear quadratic modulation system , Study There are two tutorials B Teaching video of the station .
The state space 4-LQR control MATLAB The official tutorial
Video link : [ Original translation ] The state space 4-LQR control MATLAB The official tutorial
https://player.bilibili.com/player.html?aid=98406477
[ Original translation ] The state space 4-LQR control MATLAB The official tutorial
The author uses straightforward examples to describe LQR Of cost function Q Penalty cost for state quantity 、R For thrusters ( Input ) The penalty cost , By building J Objective equation , So yes J The smallest purpose , solve K, Thus, the gain matrix at the lowest cost is obtained .
LQR-UFO experiment :
matlab Official code Original video website
test1
We adjust Q matrix ,penalize angular error ( Angle error cost ) by 1,penalize angular rate by 0.01 ( Angular velocity cost ), The cost of angular error is much greater than that of angular velocity .R = 1 ( Actuator input cost ).
The results are shown below , stay R penalize angular error At a high cost , Use lqr,Angular Error Finally, it can converge , And there is no significant overshoot .
test2
Adjust the Q matrix ,penalize angular error ( Angle error cost ) by 1,penalize angular rate by 100 ( Angular velocity cost )
The results are shown below , You can see , The acceleration converges faster , And stabilize , But correspondingly Angular Error There is no guarantee of convergence .
test3
Adjust the R matrix Penalize thruster effort The cost of the actuator is 3
The results are shown below , There is obviously less fuel to burn
【Advanced Control theory 】8_LQR controller _ State space system Matlab/Simulink Modeling analysis
Video link :【Advanced Control theory 】8_LQR controller _ State space system Matlab/Simulink Modeling analysis
【Advanced Control theory 】8
Let's start with the formula
Aim to solve the appropriate Acl Closed loop matrix
Let's start with the formula
test1 Open loop system
simulink Simulation model download
Set up K1 、K2 = 0, Use scope Check the open-loop system ,x1 Displacement ;x2 Speed ;u Negative feedback input
As follows , You can see , Under the open-loop system ,x1 x2 Tend to diverge
test2 Add negative feedback input , Build a closed-loop system ,lqr To solve the parameter K
It will be set by itself Q R, Solved K, Write in simlink Medium k1 k2
The results are shown below , It can be seen that after adding the closed-loop system ,x1 x2 All tend to converge
test3 modify R, Controlled experiment
The whole closed loop is encapsulated into a three output Subsysytem, Conduct a control experiment
take Q Set the matrix to unit matrix ,R( Actuator cost ) Set to the original 100 times ,R = 10, And will calculate K1、K2 Enter into , Observe scope Output
The comparison results are as follows , Yellow is the above test2 The experimental results of , Blue test3 The experimental results of , As shown in the figure below ,scope1 The convergence speed of the yellow line is obviously faster than that of the blue line , Such as scope3 Shown , When promoted R After the loss weight of , Input ( The blue line ) Be more stable . For both systems , The end result is the same , Finally, the state convergence is realized . For the yellow line , We pay more attention to the effect of convergence 、 Response speed , And for the blue line , We pay more attention to energy consumption .
Publisher : Full stack programmer stack length , Reprint please indicate the source :https://javaforall.cn/126480.html Link to the original text :https://javaforall.cn
边栏推荐
- Help from a student, if you can help in your spare time!
- How to refine the operation of small program mall?
- leetcode刷题:动态规划05(不同路径 II)
- 面试官:如何用 Redis 实现分布式锁?
- Food safety eating preserved eggs will lead poisoning? Don't worry about eating after knowing these points
- 单细胞论文记录(part19)--A comprehensive comparison on cell-type composition inference for ST data
- Kv260 single board PS control setting IIC switch chip
- Interviewer: how to use redis to realize distributed locks?
- 工业物联网中的时序数据
- Single cell literature learning (part6) -- forestfireclustering for SC sequencing combinations iterative label promotion with
猜你喜欢

封玩家IP和机器码以及解开被封的教程

When does MySQL use table locks and row locks?

Unity production QR code scanning

"Now, the number of codes has expanded to astronomical level"

Kubernetes kubelet manages pod core process

项目中遇到的问题及解决

leetcode刷题:动态规划05(不同路径 II)

Program environment and pretreatment

Description and usage of Axi interconnect IP core

SQL报错盲注详解
随机推荐
Investment and finance report this week: Web3 game bear market attracts gold
Detailed explanation of SQL error reporting and blind annotation
食品安全|火腿肠午餐肉,真有说的那么不堪?
C语言·结构体(线性表入门)
线程池,我是谁?我在哪儿?
【redis入门系列】redis的数据类型及相关命令
面试官:如何用 Redis 实现分布式锁?
js工具 cecp
深拷贝deepClone的实现
Virtual machine network connection mode
Software configuration | pychart download, installation, environment configuration and uninstall
使用 PreparedStatement 的 JDBC 程序示例
Typescript 清空数组
记录一下MySql update会锁定哪些范围的数据
数智化时代文旅遇新机?中国移动咪咕造 “元宇宙第一岛”
职场3道坎:年薪30万、50万、100万
别再问我MySQL为啥没走索引?就这几种原因,全都告诉你
Single cell literature learning (part6) -- forestfireclustering for SC sequencing combinations iterative label promotion with
食品安全|选购益生菌类产品,你必须知道的八件事
Encapsulate the general connection and query of the project with pymysql