Problem with eigenvalues - Comparison between matlab and a fortran code values.
Show older comments
Hi,
I am using a Fortran code to solve Orr-Sommerfeld equation with Blasius flow and so I have to solve the general problem:
A*v = lambda*B*v
Where A and B are two complex matrix and lambda are the eigenvalues (complex too). I would like to get the same lamda values with my code and with matlab.
For a 4*4 matrix (A and B) it is ok. But for a 65*65 there is a problem. The code gives to me (I am interested only by lambda with positive imaginary part): lambda_1 = -0.00010 + 0.000086*i ; lambda_2 = 0.011 + 0.00021*i ; lambda_3 = 0.031 + 0.000023*i
And matlab: lambda_1 = - 89.64 + 505.36*i ; lambda_2 = 0.011 + 0.00025*i
I am using eig(A,B) in matlab to solve the problem.
I think that it is nearly good because lambda_2 code and lambda_2 matlab are (nearly) the same and it is the value that I found in the literature. But I don’t understand why I have Lambda_1 = - 89.64 + 505.36*I with matlab.
I tried to solve in matlab:
det(A-lambda*B)
To see if I get 0 with the different values of lambda (form matlab and fortran) but it doesn’t work (solutions around e+65 or e+226).
Do you have a idea to solve my problem?
Thank you for your time.
Answers (0)
Categories
Find more on Linear Algebra in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!