numpy中matrix的特殊属性

一、matrix特殊属性解释

numpy中matrix有下列的特殊属性,使得矩阵计算更加容易

摘自 NumPy Reference Release 1.8.1

 

1.1 The N-dimensional array (ndarray)

An ndarray is a (usually fixed-size) multidimensional container of items of the same type and size.

摘自 NumPy Reference Release 1.9.1

 

这些特殊属性中文含义如下:

matrix.T    转置矩阵

matrix.H    共轭转置矩阵

matrix.I   可逆矩阵的逆矩阵

matrix.A  矩阵转为基本数组

 

二、程序测试

1、初始矩阵m为matrix([[1,2],[3,4]])

 

2、初始矩阵m为matrix([[ 0.+0.j,  1.+1.j],[ 2.-2.j,  3.-3.j]])

 

参考资料:

1、 NumPy Reference Release 1.8.1 

  http://docs.scipy.org/doc/

2、 NumPy Reference Release 1.9.1

  http://docs.scipy.org/doc/

 

posted @ 2015-05-20 00:40  klchang  阅读(910)  评论(0编辑  收藏  举报