Fix LDLT with semi-definite complex matrices: owing to round-off errors, the diagonal was not real. Also exploit the fact that the diagonal is real in the rest of LDLT

This commit is contained in:
Gael Guennebaud
2014-07-08 10:04:27 +02:00
parent 7fa83e7374
commit 0dfb73d46a
2 changed files with 7 additions and 7 deletions

View File

@@ -209,7 +209,7 @@ template<typename MatrixType> void cholesky(const MatrixType& m)
VERIFY_IS_APPROX(A * vecX, vecB);
}
// check matrices with wide spectrum
// check matrices with a wide spectrum
if(rows>=3)
{
RealScalar s = (std::min)(16,std::numeric_limits<RealScalar>::max_exponent10/8);