MATLAB: How to plot only second pole of state space matrix with 20 eigenvalues

state space matrix pole location

I have a state space matrix with 20 Eigenvalues. I want to plot the location of second pole on pzmap at a different value of the matrix parameter. How to plot only second pole?

Best Answer

Any specific reason you want to plot it on a 'pzmap'? I mean, If you just want to see the trend/evolution of the second Eigen value w.r.t change in A matrix, why dont you just extract that particular Eigen value and plot it separately like this:
temp=1;
while temp<=10 %loop 10 times and change the A matrix each time
A=rand(20,20);
B=ones(20,2);% Assuming you have 2 inputs
C=ones(size(A));
D=zeros(size(B));
system=ss(A,B,C,D);
EigenValues=eig(A);
m=real(EigenValues(2,1));% Real part of second Eigen value
n=imag(EigenValues(2,1)); % Imaginary part of second Eigen value
plot(m,n,'r*:')% plot only second Eigen value
hold on
temp=temp+1;
end
Related Question