Can I get the matrix determinant using Numpy?
Question: I read in the manual of Numpy that there is function `det(M)` that can
calculate the determinant. However, I can't find the `det()` method in Numpy.

By the way, I use Python 2.5. There should be no compatibility problems with
Numpy.


Answer: You can use
[`numpy.linalg.det`](http://docs.scipy.org/doc/numpy/reference/generated/numpy.linalg.det.html)
to compute the determinant of an array:

    
    
    In [1]: import numpy
    
    In [2]: M = [[1, 2], [3, 4]]
    
    In [3]: print numpy.linalg.det(M)
    Out[3]: -2.0000000000000004
    

