numpy筆記三(矩陣)

import numpy as np import matplotlib.pyplot as plt #字符串建立矩陣 mat = np.mat("1 2 3; 4 5 6; 7 8 9") print(mat) #T屬性轉置矩陣 print(mat.T) #I屬性得到逆矩陣 print(mat.I) #使用數組建立矩陣 a = np.array([[-2,1],[4,-3]]) mat = n
相關文章
相關標籤/搜索