LQR regulator doesn't regulate the system
조회 수: 4(최근 30일)
표시 이전 댓글
DoctorCrow 2023년 3월 21일
I used the function lqr to get a regulator that helps me to regulate my system.
My function is:
r = lqr(A,B,Q,R)
With this function i get a regulator that gives me two conjugate complex poles. Thus the system is not regulated, but continues to oscillate. I don't get any errors or warnings.
How can I fix this problem? .
댓글 수: 2
Your selection of and results in the closed-loop eigenvalues having negative real parts very close to zero. Consequently, although the system states converge to steady-state, they also oscillate for a much longer period of time.
A = [0 1 0 0; 0 0 14.72 0; 0 0 0 1; 0 0 -3.066 0];
B = [0; 0.001; 0; -0.000125];
Q = [1 0 0 0; 0 1 0 0; 0 0 1 0; 0 0 0 1];
R = 1;
[K1, P, e] = lqr(A, B, Q, R)
sys1 = ss(A-B*K1, B, eye(4), 0);
Increasing Q should improve the system response, as shown in the following plot.
Q = 1e7*eye(4);
[K2, P, e] = lqr(A, B, Q, R)
sys2 = ss(A-B*K2, B, eye(4), 0);
댓글 수: 2
You are welcome, @DoctorCrow. If you find the solution helpful, please consider accepting ✔ and voting 👍 on the answer. Thanks a bunch! 🙏
Find more on Classical Control Design in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!