Mercurial > hg > octave-lyh
changeset 13036:8afb81b32748
Initialise vecout variable and return permutation matrices instead of sparse matrices (bug #34185)
author | Jordi Gutiérrez Hermoso <jordigh@gmail.com> |
---|---|
date | Thu, 01 Sep 2011 20:27:21 -0500 |
parents | 7d4429c82212 |
children | 12ba32dd3458 |
files | src/DLD-FUNCTIONS/luinc.cc |
diffstat | 1 files changed, 7 insertions(+), 7 deletions(-) [+] |
line wrap: on
line diff
--- a/src/DLD-FUNCTIONS/luinc.cc +++ b/src/DLD-FUNCTIONS/luinc.cc @@ -110,7 +110,7 @@ bool udiag = false; Matrix thresh; double droptol = -1.; - bool vecout; + bool vecout = false; if (args(1).is_string ()) { @@ -236,7 +236,7 @@ if (vecout) retval(2) = fact.Pr_vec (); else - retval(2) = fact.Pr (); + retval(2) = fact.Pr_mat (); retval(1) = octave_value (fact.U (), MatrixType (MatrixType::Upper)); retval(0) = octave_value (fact.L (), @@ -260,8 +260,8 @@ } else { - retval(3) = fact.Pc (); - retval(2) = fact.Pr (); + retval(3) = fact.Pc_mat (); + retval(2) = fact.Pr_mat (); } retval(1) = octave_value (fact.U (), MatrixType (MatrixType::Upper)); @@ -319,7 +319,7 @@ if (vecout) retval(2) = fact.Pr_vec (); else - retval(2) = fact.Pr (); + retval(2) = fact.Pr_mat (); retval(1) = octave_value (fact.U (), MatrixType (MatrixType::Upper)); retval(0) = octave_value (fact.L (), @@ -343,8 +343,8 @@ } else { - retval(3) = fact.Pc (); - retval(2) = fact.Pr (); + retval(3) = fact.Pc_mat (); + retval(2) = fact.Pr_mat (); } retval(1) = octave_value (fact.U (), MatrixType (MatrixType::Upper));