NAN+inf
이전 댓글 표시
in my paper i need to calculate exp()...here in my code i got exp(4096) but due to this i am getting NAN+inf in all larger value areas..what to do for this?whether tis indicates any error or this NAN+inf for some values are acceptable?
채택된 답변
추가 답변 (1개)
Paulo Silva
2011년 9월 8일
0 개 추천
Can you please tell my why are you trying to get a result from exp(4096)? you do know that the result would be a very huge number, MATLAB can't find it.
댓글 수: 4
x
2011년 9월 8일
Walter Roberson
2011년 9월 8일
If the det() of the covariance matrix is negative, then the sqrt() of it will be complex, which you then multiply by infinity. In particular if the real part of the sqrt() came out as 0 but the complex part came out positive, you would have 0*infinity + positive_number*infinity*sqrt(-1) . 0*infinity is NaN, but the second part would come out as +infinity*sqrt(-1), for a net result represented as NaN +infinity*i
x
2011년 9월 8일
Walter Roberson
2011년 9월 8일
What would you _like_ the result to come out as if the determinant turns out to be negative ?
카테고리
도움말 센터 및 File Exchange에서 Number Theory에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!