R:为什么不通过逆矩阵乘法提供精确的单位矩阵?

时间:2015-01-31 16:05:34

标签: r matrix

我的矩阵:

>mat
     [,1] [,2] [,3] [,4]
[1,]  886  108  324  468
[2,]  280  820  783  475
[3,]  219  235  385  578
[4,]  843  672  594   74

> solve(mat) %*% mat
              [,1]          [,2]          [,3]          [,4]
[1,]  1.000000e+00  7.105427e-15  1.243450e-14  1.509903e-14
[2,]  0.000000e+00  1.000000e+00 -2.842171e-14  1.953993e-14
[3,] -2.842171e-14  2.842171e-14  1.000000e+00 -3.552714e-14
[4,]  0.000000e+00 -1.421085e-14 -7.105427e-15  1.000000e+00

0 个答案:

没有答案