Python Inverse of a Matrix

后端 未结 7 1124
遥遥无期
遥遥无期 2020-12-04 06:48

How do I get the inverse of a matrix in python? I\'ve implemented it myself, but it\'s pure python, and I suspect there are faster modules out there to do it.

7条回答
  •  天涯浪人
    2020-12-04 07:34

    You could calculate the determinant of the matrix which is recursive and then form the adjoined matrix

    Here is a short tutorial

    I think this only works for square matrices

    Another way of computing these involves gram-schmidt orthogonalization and then transposing the matrix, the transpose of an orthogonalized matrix is its inverse!

提交回复
热议问题