Computational Science, Numpy, Linear Algebra, Numerical Analysis, Python Programming.
to inverse given matrix below : from numpy.linalg import inv M = np.array([[0,2,1,3], [3,2,8,1], [1,0,0,3], [0,3,2,1]]) print('Inv M:\n', inv(M)) The result will be : Inv M: [[-1.57894737 -0.07894737 1.23684211 1.10526316] [-0.63157895 -0.13157895 0.39473684 0.84210526] [ 0.68421053 0.18421053