aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h
diff options
context:
space:
mode:
authorGravatar Gael Guennebaud <g.gael@free.fr>2014-02-18 15:45:39 +0100
committerGravatar Gael Guennebaud <g.gael@free.fr>2014-02-18 15:45:39 +0100
commit463554c25456613e55dbac3e5f734b59f1708dca (patch)
tree47395219cf1d2301d1b3aac8f0bc1a01857919a8 /Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h
parent82c066b3c4a0d64962ad0bf268bf7a4a28b2704b (diff)
parent37a1d736bfd6fdaa0e1a93aee585d1861ab4004a (diff)
Merge with default branch
Diffstat (limited to 'Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h')
-rw-r--r--Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h b/Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h
index 0c3425069..b8146d04d 100644
--- a/Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h
+++ b/Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h
@@ -756,7 +756,9 @@ struct direct_selfadjoint_eigenvalues<SolverType,2,false>
EIGEN_DEVICE_FUNC
static inline void run(SolverType& solver, const MatrixType& mat, int options)
{
- using std::sqrt;
+ EIGEN_USING_STD_MATH(max)
+ EIGEN_USING_STD_MATH(sqrt);
+
eigen_assert(mat.cols() == 2 && mat.cols() == mat.rows());
eigen_assert((options&~(EigVecMask|GenEigMask))==0
&& (options&EigVecMask)!=EigVecMask
@@ -768,7 +770,7 @@ struct direct_selfadjoint_eigenvalues<SolverType,2,false>
// map the matrix coefficients to [-1:1] to avoid over- and underflow.
Scalar scale = mat.cwiseAbs().maxCoeff();
- scale = (std::max)(scale,Scalar(1));
+ scale = (max)(scale,Scalar(1));
MatrixType scaledMat = mat / scale;
// Compute the eigenvalues