Replace all M_PI by EIGEN_PI and add a check to the testsuite.

This commit is contained in:
Christoph Hertzberg
2016-03-23 15:37:45 +01:00
parent 28e02996df
commit 9642fd7a93
6 changed files with 13 additions and 13 deletions

View File

@@ -113,8 +113,8 @@ void testMatrixLogarithm(const MatrixType& A)
MatrixType scaledA;
RealScalar maxImagPartOfSpectrum = A.eigenvalues().imag().cwiseAbs().maxCoeff();
if (maxImagPartOfSpectrum >= 0.9 * M_PI)
scaledA = A * 0.9 * M_PI / maxImagPartOfSpectrum;
if (maxImagPartOfSpectrum >= 0.9 * EIGEN_PI)
scaledA = A * 0.9 * EIGEN_PI / maxImagPartOfSpectrum;
else
scaledA = A;