Help Error using eig Input to EIG must not contain NaN or Inf

8 Ansichten (letzte 30 Tage)
Cheng Xu Feng
Cheng Xu Feng am 9 Jul. 2017
Kommentiert: laiche zeghdi am 18 Okt. 2023
Error using eig
Input to EIG must not contain NaN or Inf.
Error in composite_twoshaft_spurgear (line 450)
w=sort(abs(imag(eig(EF))));
E=[o,-(MM1+MM2+MMd);(MM1+MM2+MMd),(CC1+CC2+CCB1+CCB2)+(Oma1*(GG1+GGd1)+Oma2*(GG2+GGd2))];
F=[(MM1+MM2+MMd),o;o,(KK1+KK2+KKB1+KKB2)];
EF=-inv(E)*F;
w=sort(abs(imag(eig(EF))));
ww(:,n)=w;
[C,D]=eig(EF);
  7 Kommentare
KSSV
KSSV am 9 Jul. 2017
So problem is with MM1 etc values. You have to show us the complete code to solve the problem.
Walter Roberson
Walter Roberson am 9 Jul. 2017
Please show the output of
rcond(E)
rank(E)
rank(F)
nnz(~isfinite(E))
nnz(~isfinite(F))

Melden Sie sich an, um zu kommentieren.

Antworten (1)

Cheng Xu Feng
Cheng Xu Feng am 10 Jul. 2017
I already solve this problem. but ans are wrong.
  2 Kommentare
Walter Roberson
Walter Roberson am 10 Jul. 2017
How do you know they are wrong?
What is your current code? What are
rcond(E)
rank(E)
rank(F)
nnz(~isfinite(E))
nnz(~isfinite(F))
laiche zeghdi
laiche zeghdi am 18 Okt. 2023
i have same problem . can you help me
1) An error occurred while running the simulation and the simulation was terminated
Caused by: Input to EIG must not contain NaN or Inf.
2) Cannot create variable 'if' in workspace Caused by:
ASSIGNIN cannot assign to variables with the same name as a MATLAB keyword

Melden Sie sich an, um zu kommentieren.

Kategorien

Mehr zu Linear Algebra finden Sie in Help Center und File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by