Low Complexity Polyhedral Calculation using Yalmip (LMI)

114 views
Skip to first unread message

Himanshu Nagpal

unread,
Apr 21, 2017, 8:43:21 AM4/21/17
to YALMIP
Hi there,

I have been using Algorithm 1 in pic1 to compute low-complexity polyhedral invariant sets in Example 2 given in pic2. I am getting different answers when I use mosek and SeDuMi solvers and both of them are not matching with the correct answer. 
clc
clear all

A = [0.858, -0.053, 0.021, 0.193, -0.029, 0.027;
    -0.053, 0.716, 0.039, 0.051, 0.179, 0.162;
     0.021, 0.039, 0.698, 0.031, 0.135, -0.206;
     0.193, 0.051, 0.031, 0.567, 0.053, -0.014;
     -0.029, 0.179, 0.135, 0.053, 0.658, -0.031;
     0.027, 0.162, -0.206, -0.014, -0.031, 0.504];
 
B = [-0.438, -1.607, -0.474;
    -0.074, -1.479, 1.389;
    -1.647, 1.011, 0.204;
    0.866, 1.869, 0.821;
    0.633, 0.004, -1.364;
    -0.997, 1.185, -0.554];
u = [1,1,1]';

nx = size(A,2);
nu = size(B,2);

Q = sdpvar(nx,nx);
Y = sdpvar(nu,nx);
alpha = 1/sqrt(nx);
X = sdpvar(nu,nu);

obj = -log(det(Q));
umax = norm(u,inf);
LMI1 = Q;
LMI2 = [X, Y;
        Y', Q];
LMI3 = [alpha^2*Q, (A*Q+B*Y)';
        A*Q+B*Y,    Q];
% const = [LMI1 >= 0; LMI2 >= 0; LMI3 >= 0, X(1,1) <= u(1)^2, X(2,2) <= u(2)^2, X(3,3) <= u(3)^2];
const = [LMI1 >= 0; LMI2 >= 0; LMI3 >= 0, X(1,1) <= umax^2, X(2,2) <= umax^2, X(3,3) <= umax^2];
% ops = sdpsettings('solver','SeDuMi');
ops = sdpsettings('solver','mosek');
diagnostics = optimize(const, obj, ops);
P = (1/(alpha^2))*inv(value(Q));
M = det(P);..

Any suggestions please.

Thanks.
blanco2010.pdf
pic1.PNG
pic2.PNG

Johan Löfberg

unread,
Apr 21, 2017, 9:03:38 AM4/21/17
to YALMIP
Your problem is not well-posed as the objective can get arbitrary large (neither mosek nor sedumi terminates with a solution, so you are looking at crap)

You can easily see this if you solve
diagnostics = optimize([const,trace(Q)<=100], obj, sdpsettings('solver','mosek'))

when you change the constant 100 to 1000 or 10000, the objective simply gets larger with the trace constraint being active, and there is no upper limit

Johan Löfberg

unread,
Apr 21, 2017, 9:06:05 AM4/21/17
to YALMIP
You are missing (14) in your model.

Johan Löfberg

unread,
Apr 21, 2017, 9:10:10 AM4/21/17
to YALMIP
and I hope you understand that LMI1 is completely redundant as it is a consequence of LMI2 and LMI3 

Himanshu Nagpal

unread,
Apr 21, 2017, 9:12:50 AM4/21/17
to YALMIP
Thank you Johan for your quick response. 

Yes, (14) represents the state constraint which is not mentioned in the problem. 

Himanshu Nagpal

unread,
Apr 21, 2017, 9:20:50 AM4/21/17
to YALMIP
and sorry I didn't understand that problem is ill-posed. Is it my program or the problem itself?

Johan Löfberg

unread,
Apr 21, 2017, 9:21:52 AM4/21/17
to YALMIP
Without (14) the problem is simply not well-defined.

Since the discrete-time system is asymptotically stable (all eigenvalues of A in unit-cricle), I can use the control law u = 0*x, and thus R^n is invariant, i.e., any invariant region without state constraints is arbitrrily large.

Johan Löfberg

unread,
Apr 21, 2017, 9:22:45 AM4/21/17
to yal...@googlegroups.com
Ill-posed because there is no optimal solution to the problem. The largest possible log(det(Q)) is infinity
Reply all
Reply to author
Forward
0 new messages