I have to implemet a state feedback design using SOS, but i got this Error, (its just a simple example) , what should i do ? (Matlab-R2010b)

>> syms x y
>> VEC = monomials([x; y],[1 2 3])
??? Error using ==> sprintf Function is not defined for sparse inputs.
Error in ==> int2str at 32 s = sprintf(['%', formatConversion], x);
Error in ==> mysympower at 44 charexpr = [charexpr,char(vartable(i)),'^',int2str(Z(j,i)),'*'];
Error in ==> monomials>oldconstructZ at 98 Z = mysympower(vartable,Z);
Error in ==> monomials at 71 Z = [Z; oldconstructZ(vartable,i)];

2 Comments

Which toolkit or File Exchange did you get monomials() from?
i think it's coming from sostools or sedumi , cuz i had to install both of them to implement the desired design

Sign in to comment.

 Accepted Answer

Okay, you will need to go into the mysympower.m file, and where it has
charexpr = [charexpr,char(vartable(i)),'^',int2str(Z(j,i)),'*'];
on line 44, change that to
charexpr = [charexpr,char(vartable(i)),'^',int2str(full(Z(j,i))),'*']

More Answers (0)

Categories

Asked:

on 29 Sep 2015

Commented:

on 1 Oct 2015

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!