Negative eigenvalues

Dear all,
I try to simulate the data using mvnrdn function but I had the the error saying that "SIGMA must be a symmetric positive semi-definite matrix". I checked the eigenvalues and the problem seems to be the negative eigenvalues of covariance matrix. Does anyone know how to fix this problem?
mean=[3.6,0.48,1.8,1.8,1.12]
var=[0.5365 0.0676 0.2527 0.2527 0.1581
0.0676 0.0092 0.0340 0.0340 0.0213
0.2527 0.0340 0.1321 0.1272 0.0796
0.2527 0.0340 0.1272 0.1321 0.0796
0.1581 0.0213 0.0796 0.0796 0.0511];
Thank you for your suggestions,
Wan

1 个评论

Hi Winn, I would not name your matrix, var, that is the name of a MATLAB function (variance) and that is going to cause you problems.
Is the matrix you have listed above your covariance matrix, or your variable matrix?

请先登录,再进行评论。

回答(0 个)

类别

帮助中心File Exchange 中查找有关 Linear Algebra 的更多信息

提问:

2012-2-23

编辑:

2013-10-22

Community Treasure Hunt

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

Start Hunting!

Translated by