LQR for tracking error minimization
7 views (last 30 days)
Show older comments
I have a discrete time state-space SISO system M and I want to set up an LQR in order to minimize the tracking error between the output of the system M, y, and a reference trajectory, r. LQR formulation is .
I suppose I have to use u =reference trajectory and x =the state vector of the difference between reference r minus output y (=error I want to minimize). But, to do so, I will need coefficient of matrices A and B of the system that describes my situation in order to use dlqr. How do I get them? And how do I interpret the results obtained?
Hoping my question is clear enough. Thanks for the help!
0 Comments
Answers (1)
Raj
on 10 Jul 2019
1) Standard discrete cost function is J = Sum {x'Qx + u'Ru + 2*x'Nu}. In your case N=0.
2) "I suppose I have to use u =reference trajectory " - NO. u is the input to the system. If you are not giving any input and working on a pure tracking problem, you have to use u=0.
3) "x =the state vector of the difference between reference r minus output y (=error I want to minimize)" - This is right.
4) "I will need coefficient of matrices A and B of the system that describes my situation in order to use dlqr" - You can use this:
ts=-1 % Put your sample time here
z = tf('z',ts)
system=0.1/(z-0.9)
system_statespace=ss(system)
A = system_statespace.A
B = system_statespace.B
Select proper weight matrices for LQR (Q and R) and then design your controller.
0 Comments
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!