Mercurial > hg > mauch-mirex-2010
annotate _FullBNT/KPMtools/isposdef.m @ 9:4ea6619cb3f5 tip
removed log files
author | matthiasm |
---|---|
date | Fri, 11 Apr 2014 15:55:11 +0100 |
parents | b5b38998ef3b |
children |
rev | line source |
---|---|
matthiasm@8 | 1 function b = isposdef(a) |
matthiasm@8 | 2 % ISPOSDEF Test for positive definite matrix. |
matthiasm@8 | 3 % ISPOSDEF(A) returns 1 if A is positive definite, 0 otherwise. |
matthiasm@8 | 4 % Using chol is much more efficient than computing eigenvectors. |
matthiasm@8 | 5 |
matthiasm@8 | 6 % From Tom Minka's lightspeed toolbox |
matthiasm@8 | 7 |
matthiasm@8 | 8 [R,p] = chol(a); |
matthiasm@8 | 9 b = (p == 0); |