Error in Chapter4_Example1/Ch4Ex1_main.m
abdul-mannan-khan opened this issue · comments
Abdul-Mannan Khan commented
Dear Dr. Yu-Jiang,
I am very thankful to you for sharing your day and night hard work. No matter how much it is praised it can never be enough.
If you don't mind, I would like to point out some problem. It may be problem in my understanding but here it is what I am getting. Running "Chapter4_Example1/Ch4Ex1_main.m" I am getting
Assignment has more non-singleton rhs dimensions than non-singleton subscripts
Error in sym/privsubsasgn (line 1002)
L_tilde2 = builtin('subsasgn',L_tilde,struct('type','()','subs',{varargin}),R_tilde);
Error in sym/subsasgn (line 839)
C = privsubsasgn(L,R,inds{:});
Error in getequation (line 181)
coeffnts_decvar((ind_k-1)*dimp+i,j) = s_ijk_decvar;
Error in sosconstr (line 79)
getequation(char(symexpr),sos.vartable,sos.decvartable,sos.varmat.vartable);
Error in sosineq (line 104)
sos = sosconstr(sos,'ineq',symexpr);
Error in Ch4Ex1_main (line 51)
prog = sosineq(prog,V-0.0001*(x1^2+x2^2+x3^2+x4^2));
Checking deeply the error, I believe it is the issue with some symbolic math thing. Your kind thoughts on the will be highly appreciated.
PS: I am running it on MATLAB2015b under Linux 18.04.