Matrix multiplication resulting in different values in MATLAB and NUMPY(?) [duplicate]

旧城冷巷雨未停 提交于 2019-12-01 21:55:57

Numpy documentation states that the operator you apply performs element-wise multiplication.

However, mtimes in MATLAB does matrix multiplication.

To verify, MATLAB syntax for element-wise multiplication produces the same result you see in numpy:

disp(x.'.*x)

     4    56    20    54     4
    56     9     7    42    80
    20     7     9   100     2
    54    42   100     1    40
     4    80     2    40    81
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!