eigen value of the transfer function 2x2 matrix

hello
I have 2x2 matrix
G=[1/(s+1) 1/(s+2);1/(s+3) 1/(s+4)] where G(1,1)=/(s+1) G(1,2)=1/(s+2) G(2,1)=1/(s+3) G(2,2)=1/(s+4)
Now because it is a 2x2 matrix it must have 2 eigen values .
so my questions are:
  1. How to calculate the determinant of G matrix?
  2. How to find the eigen values of the G matrix?
  3. How to get the eigen vectors of the G matrix?
  4. I want to perform the following operation ------- SQUAREROOT OF((G(1,1)+G(2,2))/2) but I am unable to do.

1 Comment

Paul
Paul on 25 Aug 2020
Edited: Paul on 25 Aug 2020
The discussion below indicates these questions are related to multivariable stability analysis. But it's not clear how any of your questions 3-4 actually relate to that type of analysis. Can you clarify what you're actually trying to do and explain why you need to complete the operations in questions 3-4?

Sign in to comment.

 Accepted Answer

If you want to use the symbolic appoach, why not just create a matlab function to evaluate lambda(2) and then create the plot using an frd model:
syms s
G=[1/(s+1) 1/(s+2);1/(s+3) 1/(s+4)];
lambda=eig(G);
f=matlabFunction(lambda(2));
w=logspace(-1,3,500);
nyquist(frd(f(1j*w),w));
Unclear how well this symbolic approach will work for systems of even moderate complexity ....

2 Comments

Walter,
I see that you edited my answer, I think to remove the >> from the code snippet. Can anyone edit anyone else's Answer?
You are correct, I removed the >> so that the code could be copied and pasted.
People with reputation 3000 or higher can edit answers. That is about 45 people (out of over 200000 users) . We mostly reformat text into code, or adjust html links to be usable, but sometimes we remove >> so that code can be run more easily. Sometimes we fix spelling mistakes that are interfering with understanding what has been posted (a lot of the users do not have English as a first language, so incorrect spelling can make it difficult for them to understand what was said.)
Less pleasantly, from time to time we remove inappropriate wording such as personal insults.

Sign in to comment.

More Answers (3)

If you use the symbolic toolbox,
syms s
G=[1/(s+1) 1/(s+2);1/(s+3) 1/(s+4)]
then you can do all of those operations directly.
If you use
s = tf('s');
G=[1/(s+1) 1/(s+2);1/(s+3) 1/(s+4)]
then you can do det(G) and eig(G) but eig(G) will not return the eigenvectors
An example of finding eigenvectors from eigenvalues is at https://www.scss.tcd.ie/Rozenn.Dahyot/CS1BA1/SolutionEigen.pdf
A youtube for 2 x 2 case is at https://www.youtube.com/watch?v=IdsV0RaC9jM
SQUAREROOT OF((G(1,1)+G(2,2))/2)
The sqrt() is the problem; sqrt() is not defined for transfer functions
Maple tells me that that particular expression might have an inverse laplace,
exp(-4*t)*int(3*((4*Dirac(_U1)*sqrt(t - _U1))/3 + sqrt(t)*exp((9*_U1)/4)*(BesselI(0, (3*_U1)/4) + BesselI(1, (3*_U1)/4)))/sqrt(t - _U1), _U1 = 0 .. t)/(4*sqrt(Pi)*sqrt(t))
Thanks walter for helping me to deal with how to use different tools to analyze a 2x2 transfer function maths in MATLAB.
But the matlab is returning an error when I am trying to plot the nyquist plot for the obtained eigen values from the procedure discussed above in this thread.
Here is the code:
syms s
G=[1/(s+1) 1/(s+2);1/(s+3) 1/(s+4)]
lambda=eig(G)
nyquist(lambda(2,1))
Error using nyquist (line 73)
Not enough input arguments.
The error is highlighted in the bold letter.

5 Comments

The eigenvalues involve square roots, and those make the transforms difficult. They cannot be stated in terms of standard tf form unless perhaps as approximation. The discussions I find argue about whether the transform for sqrt(s) even exists (difficulties at 0).
Note that I have not studied control systems theory so I do not have the background for this.
nyquist does not accept symbolic expressions. I have not been able to find the mathematics of nyquist as yet.
Ok
No issue Sir. But I would appeal/request you to pass this question to someone who knows control system
Thank You.
I traced the calls further, and found that the nyquist plot code converts the system to zpk form, and then iterates through a list of frequencies to calculate the zpk response at the frequency. Unfortunately that calculation routine is a mex file so I do not know how it calculates the response.
To calculate the zpk it finds the roots of the numerator and denominator and the ratio of the leading coefficients.
The zpk representation assumes polynomials. You can seek out the roots anyhow thinking you might get a hint about the behaviour. The roots of the numerator are -4. The roots of the denominator are -4 and -1. -4 is an overall zero in theory because of limits.
... but really you have to examine the poles of the sqrt in the numerator, which are -2 and -3, so the overall poles are -4 -3 -2 -1. And the function goes complex for part and I do not know what to do with that.
ya
This part I was pretty very much sure that the there might be some convesrsion error kind of thing or file mismatch sort of problem due to which the nyquist command is failing in symbololic math library. Well even I tried I couldn't got any result. Hope we get a solution meanwhile in a couple of days if we keep trying.
But thanks for the information about mex File. Well I look forward to mathworks to obtain a concrete solution.
(note that I edited my comment)

Sign in to comment.

Thanks Paul
Its working but as you have truely said I don,t know whats happening when I am using the command
.
.
.
.
w=logspace(-400,400,50000);
nyquist(frd(f(1j*w),w));
Its returning error as follows
Error using frd (line 214)
The "Frequency" property of FRD models must be set to a vector of real and finite frequencies.
Error in nyquist (line 40)
nyquist(frd(f(1j*w),w))

2 Comments

max(w)
ans =
Inf
The usable range for logspace is -324 to +308
Paul
Paul on 28 Aug 2020
Edited: Paul on 28 Aug 2020
Obviously I don't know what you're actually trying to accomplish, but I really doubt you need to use a 50000 pont vector spanning the entire space of usable frequencies. But maybe you do. Along those same lines, is computing the eigenvalues symbolically going to work for problems of even moderate complexity? I have basically no experience with the Symbolic Toolbox and don't really know what its limitations are in computing eigenvalues symbolically. And even if you can get expressions for the eigenvalues, they may very well be very high order polynomials that may not lend themselves well to numericaly evaluation.

Sign in to comment.

Categories

Find more on Programming in Help Center and File Exchange

Asked:

on 23 Aug 2020

Edited:

on 28 Aug 2020

Community Treasure Hunt

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

Start Hunting!