diff liboctave/dbleCHOL.h @ 6486:e978a9233cf6

[project @ 2007-04-04 15:16:46 by jwe]
author jwe
date Wed, 04 Apr 2007 15:17:51 +0000
parents 143b556ce725
children 93c65f2a5668
line wrap: on
line diff
--- a/liboctave/dbleCHOL.h
+++ b/liboctave/dbleCHOL.h
@@ -36,22 +36,27 @@
 
   CHOL (void) : chol_mat () { }
 
-  CHOL (const Matrix& a) { init (a); }
+  CHOL (const Matrix& a, bool calc_cond = false) { init (a, calc_cond); }
 
-  CHOL (const Matrix& a, octave_idx_type& info) { info = init (a); }
+  CHOL (const Matrix& a, octave_idx_type& info, bool calc_cond = false) 
+    { info = init (a, calc_cond); }
 
-  CHOL (const CHOL& a) : chol_mat (a.chol_mat) { }
+  CHOL (const CHOL& a) : chol_mat (a.chol_mat), xrcond (a.xrcond) { }
 
   CHOL& operator = (const CHOL& a)
     {
       if (this != &a)
-	chol_mat = a.chol_mat;
-
+	{
+	  chol_mat = a.chol_mat;
+	  xrcond = a.xrcond;
+	}
       return *this;
     }
 
   Matrix chol_matrix (void) const { return chol_mat; }
 
+  double rcond (void) const { return xrcond; }
+
   // Compute the inverse of a matrix using the Cholesky factorization.
   Matrix inverse (void) const;
 
@@ -61,7 +66,9 @@
 
   Matrix chol_mat;
 
-  octave_idx_type init (const Matrix& a);
+  double xrcond;
+
+  octave_idx_type init (const Matrix& a, bool calc_cond);
 };
 
 Matrix OCTAVE_API chol2inv (const Matrix& r);