求助奇异矩阵问题
在进行模型参数率定时,需要进行矩阵求逆,发现在样本数较多时,计算正常,样本数较少时,会提示Matrix is close to singular or badly scaled.Results may be inaccurate. RCOND = 9.464582e-019.s = cov(z,1);
n = n1 + n2;
s22 = s(n1+1:n,n1+1:n);
s22inv = inv(s22);%提示出错
a = s12*s22inv;
有人说用pinv代替inv函数求逆,但是求a的时候继续会提示a近似于奇异函数
请问如何解决,谢谢。 Matrix is close to singular or badly scaled
http://www.mathworks.com/matlabc ... /view_thread/170919
http://groups.google.com/group/c ... ad/f640ae64aa62fbe6
http://dmpeli.mcmaster.ca/Matlab ... otes/Lecture2_4.htm
from http://forum.vibunion.com/home-spa ... -blog-id-18250.html
pinv是伪逆,得到的是最小二乘解,可是最小二乘解有时候不唯一。
页:
[1]