Mercurial > hg > octave-nkf
diff liboctave/sparse-base-chol.h @ 11716:017e13f0d056 release-3-0-x
Fix fall back from sparse cholesky factorization to LU when matrix detected as not being positive definite
author | David Bateman <dbateman@free.fr> |
---|---|
date | Tue, 25 Mar 2008 16:18:42 -0400 |
parents | a1dbe9d80eee |
children | 72830070a17b |
line wrap: on
line diff
--- a/liboctave/sparse-base-chol.h +++ b/liboctave/sparse-base-chol.h @@ -51,8 +51,8 @@ const bool natural) : count (1) { info = init (a, natural); } - ~sparse_base_chol_rep (void) - { CHOLMOD_NAME(free_sparse) (&Lsparse, &Common); } + ~sparse_base_chol_rep (void) + { if (is_pd) CHOLMOD_NAME(free_sparse) (&Lsparse, &Common); } cholmod_sparse * L (void) const { return Lsparse; }