from
QCAT
by Ola Harkegard Quadratic Programming Control Allocation Toolbox
Description of lq2ca
lq2ca
PURPOSE
LQ2CA - Extract control allocator from a given LQ controller.
SYNOPSIS
function [R2,Wu] = lq2ca(B,R1)
DESCRIPTION
LQ2CA - Extract control allocator from a given LQ controller.
[R2,Wu] = lq2ca(B,R1)
Given a dynamic system
. .
x = Ax + B1u, B1 = B2*B <=> x = Ax + B2v, v = Bu
this function calculates weighting matrices R2 and Wu such that the
design criterium
min Integral (x'Qx + v'R2v) dt (LQ control)
v
min ||Wu u|| subj. to Bu = v (control allocation)
u
gives the same linear optimal control law as
min Integral (x'Qx + u'R1u) dt (LQ control)
u
Controller structures:
x ------- u x ------- v ---- u
--->| Q, R1 |---> <=> --->| Q, R2 |--->| Wu |--->
------- ------- ----
LQ ctl LQ ctl Ctl alloc
See also CA2LQ, LQR, WPINV.
CROSS-REFERENCE INFORMATION
This function calls:
This function is called by:
SOURCE CODE
0001 function [R2,Wu] = lq2ca(B,R1)
0002
0003 % LQ2CA - Extract control allocator from a given LQ controller.
0004 %
0005 % [R2,Wu] = lq2ca(B,R1)
0006 %
0007 % Given a dynamic system
0008 % . .
0009 % x = Ax + B1u, B1 = B2*B <=> x = Ax + B2v, v = Bu
0010 %
0011 % this function calculates weighting matrices R2 and Wu such that the
0012 % design criterium
0013 %
0014 % min Integral (x'Qx + v'R2v) dt (LQ control)
0015 % v
0016 %
0017 % min ||Wu u|| subj. to Bu = v (control allocation)
0018 % u
0019 %
0020 % gives the same linear optimal control law as
0021 %
0022 % min Integral (x'Qx + u'R1u) dt (LQ control)
0023 % u
0024 %
0025 % Controller structures:
0026 %
0027 % x ------- u x ------- v ---- u
0028 % --->| Q, R1 |---> <=> --->| Q, R2 |--->| Wu |--->
0029 % ------- ------- ----
0030 % LQ ctl LQ ctl Ctl alloc
0031 %
0032 % See also CA2LQ, LQR, WPINV.
0033
0034 % Thesis, Theorem 10.4:
0035 R2 = inv(B*inv(R1)*B');
0036 Wu = sqrtm(R1);
0037