Return alphas() and betas() by const reference

This commit is contained in:
Matt Keeter 2022-02-08 23:16:10 +00:00 committed by Rasmus Munk Larsen
parent 92d0026b7b
commit cec0005c74

View File

@ -212,7 +212,7 @@ template<typename MatrixType_> class GeneralizedEigenSolver
* This vector permits to reconstruct the j-th eigenvalues as alphas(i)/betas(j).
*
* \sa betas(), eigenvalues() */
ComplexVectorType alphas() const
const ComplexVectorType& alphas() const
{
eigen_assert(m_valuesOkay && "GeneralizedEigenSolver is not initialized.");
return m_alphas;
@ -223,7 +223,7 @@ template<typename MatrixType_> class GeneralizedEigenSolver
* This vector permits to reconstruct the j-th eigenvalues as alphas(i)/betas(j).
*
* \sa alphas(), eigenvalues() */
VectorType betas() const
const VectorType& betas() const
{
eigen_assert(m_valuesOkay && "GeneralizedEigenSolver is not initialized.");
return m_betas;