Help


from Wikipedia
« »  
# Its leading principal minors are all positive.
The kth leading principal minor of a matrix M is the determinant of its upper left k by k sub-matrix.
It turns out that matrix is positive definite if and only if all these determinants are positive.
This condition is known as Sylvester's criterion, and provides an efficient test of positive-definiteness of a symmetric real matrix.
Namely, the matrix is reduced to an upper triangular matrix by using elementary row operations, as in the first part of the Gaussian elimination method, taking care to preserve the sign of its determinant.
Since the kth leading principal minor of a triangular matrix is the product of its diagonal elements up to row k, Sylvester's criterion is equivalent to checking whether its diagonal elements are all positive.
This condition can be checked each time a new row k of the triangular matrix is obtained.

2.423 seconds.