diff options
author | Jitse Niesen <jitse@maths.leeds.ac.uk> | 2010-06-01 17:40:51 +0100 |
---|---|---|
committer | Jitse Niesen <jitse@maths.leeds.ac.uk> | 2010-06-01 17:40:51 +0100 |
commit | e3e23805488d701b9f3a463ed226949c05d726c8 (patch) | |
tree | 50ef3ee96154e352e34a308bfa67045be6300d4c /Eigen/src/Eigenvalues/RealSchur.h | |
parent | 4c6d182c42492b94a2415b9f5c1e50d564b2c78e (diff) |
Make all compute() methods return a reference to *this.
Diffstat (limited to 'Eigen/src/Eigenvalues/RealSchur.h')
-rw-r--r-- | Eigen/src/Eigenvalues/RealSchur.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Eigen/src/Eigenvalues/RealSchur.h b/Eigen/src/Eigenvalues/RealSchur.h index c92b72a94..41f74e530 100644 --- a/Eigen/src/Eigenvalues/RealSchur.h +++ b/Eigen/src/Eigenvalues/RealSchur.h @@ -161,6 +161,7 @@ template<typename _MatrixType> class RealSchur * * \param[in] matrix Square matrix whose Schur decomposition is to be computed. * \param[in] computeU If true, both T and U are computed; if false, only T is computed. + * \returns Reference to \c *this * * The Schur decomposition is computed by first reducing the matrix to * Hessenberg form using the class HessenbergDecomposition. The Hessenberg @@ -173,7 +174,7 @@ template<typename _MatrixType> class RealSchur * Example: \include RealSchur_compute.cpp * Output: \verbinclude RealSchur_compute.out */ - void compute(const MatrixType& matrix, bool computeU = true); + RealSchur& compute(const MatrixType& matrix, bool computeU = true); private: @@ -196,7 +197,7 @@ template<typename _MatrixType> class RealSchur template<typename MatrixType> -void RealSchur<MatrixType>::compute(const MatrixType& matrix, bool computeU) +RealSchur<MatrixType>& RealSchur<MatrixType>::compute(const MatrixType& matrix, bool computeU) { assert(matrix.cols() == matrix.rows()); @@ -251,6 +252,7 @@ void RealSchur<MatrixType>::compute(const MatrixType& matrix, bool computeU) m_isInitialized = true; m_matUisUptodate = computeU; + return *this; } /** \internal Computes and returns vector L1 norm of T */ |