[SciPy-User] Permutation convention for LU decomposition

Pauli Virtanen pav@iki...
Sun Oct 31 06:46:22 CDT 2010

Sat, 30 Oct 2010 20:42:49 -0500, Jason Grout wrote:

> I notice that in Lapack, Matlab, and Mathematica, the LU decomposition
> routine for a matrix A returns a P, L, and U matrices so that:

LAPACK returns the P L U decomposition. Quote from the relevant manual 

DGETRF computes an LU factorization of a general M-by-N matrix A using 
partial pivoting with row interchanges.  The factorization has the form

          A = P * L * U

where  P  is  a  permutation matrix, L is lower triangular with unit 
diagonal elements (lower trapezoidal if m > n), and U is upper triangular 
(upper trapezoidal if m < n). This is the right-looking Level 3 BLAS 
version of the algorithm.

Pauli Virtanen

More information about the SciPy-User mailing list