Merge with upstream.

This commit is contained in:
Mehdi Goli 2018-08-10 12:28:38 +01:00
commit 3a2e1b1fc6

View File

@ -53,7 +53,7 @@ template<typename _MatrixType> struct traits<FullPivLU<_MatrixType> >
* Output: \verbinclude class_FullPivLU.out * Output: \verbinclude class_FullPivLU.out
* *
* This class supports the \link InplaceDecomposition inplace decomposition \endlink mechanism. * This class supports the \link InplaceDecomposition inplace decomposition \endlink mechanism.
* *
* \sa MatrixBase::fullPivLu(), MatrixBase::determinant(), MatrixBase::inverse() * \sa MatrixBase::fullPivLu(), MatrixBase::determinant(), MatrixBase::inverse()
*/ */
template<typename _MatrixType> class FullPivLU template<typename _MatrixType> class FullPivLU
@ -320,7 +320,7 @@ template<typename _MatrixType> class FullPivLU
return m_usePrescribedThreshold ? m_prescribedThreshold return m_usePrescribedThreshold ? m_prescribedThreshold
// this formula comes from experimenting (see "LU precision tuning" thread on the list) // this formula comes from experimenting (see "LU precision tuning" thread on the list)
// and turns out to be identical to Higham's formula used already in LDLt. // and turns out to be identical to Higham's formula used already in LDLt.
: NumTraits<Scalar>::epsilon() * m_lu.diagonalSize(); : NumTraits<Scalar>::epsilon() * RealScalar(m_lu.diagonalSize());
} }
/** \returns the rank of the matrix of which *this is the LU decomposition. /** \returns the rank of the matrix of which *this is the LU decomposition.