Please help me to overcome the error of the my code
2 views (last 30 days)
Show older comments
Hi , Is there anyone to help me o solve the error? please i become confused.
Bw=zeros(3,1);
Cg=[0 0 1]; Cz=[0 0 1];
Dzu=0; Dzw=1; Dw=1;
r1=-0.1; r2=0.5; r3=-1.2;r4=0.2;
Ag{1} =[0 0 -(r1+.2*r1);1 0 -(r2+0.2*r2);0 1 -(r3+0.2*r3)]
Bg{1}=[r4+0.2*r4;1;0]
P{1,1} = ss(Ag{1}, [Bg{1} Bw], [Cz;Cg], [Dzu Dzw;0 Dw],0.1)
Ts = 0.1
z = tf('z',Ts)
s = tf('s')
phi = conphi('laguerre',[Ts,0,2],'z',z/(z-1))
W{1}=0.4902*(z^2-1.0432*z+0.3263)/(z^2-1.282*z+0.282);
Ld = 0.2/s
per =conper('Hinf',W,Ld)
K = condes(P{i,k},phi,per)
[a,b,c,d]=ssdata(K);
the error is on " K = condes(P{i,k},phi,per)" and error is : Index exceeds matrix dimensions.
Error in condes (line 988) K1{k}(p,q) = minreal(transpose(x(nn+k:Ngs:nn+Ngs*n(p,q))) * phi{p,q});
Error in firstexx (line 43) K = condes(P{i,k},phi,per)
0 Comments
Answers (1)
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!