aboutsummaryrefslogtreecommitdiffhomepage
path: root/Eigen
diff options
context:
space:
mode:
authorGravatar Christoph Hertzberg <chtz@informatik.uni-bremen.de>2018-12-05 15:01:04 +0100
committerGravatar Christoph Hertzberg <chtz@informatik.uni-bremen.de>2018-12-05 15:01:04 +0100
commitc1d356e8b4b84fa5c7172567d5529f52191ed85b (patch)
treeb88bae3a46c61661a4c5386c48bb6ead00712537 /Eigen
parentb57b31cce9e86eac78d2219c976797225ac1db38 (diff)
bug #1635: Use infinity from Numtraits instead of creating it manually.
Diffstat (limited to 'Eigen')
-rw-r--r--Eigen/src/Core/ConditionEstimator.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/Eigen/src/Core/ConditionEstimator.h b/Eigen/src/Core/ConditionEstimator.h
index 8c1a89129..51a2e5f1b 100644
--- a/Eigen/src/Core/ConditionEstimator.h
+++ b/Eigen/src/Core/ConditionEstimator.h
@@ -160,7 +160,7 @@ rcond_estimate_helper(typename Decomposition::RealScalar matrix_norm, const Deco
{
typedef typename Decomposition::RealScalar RealScalar;
eigen_assert(dec.rows() == dec.cols());
- if (dec.rows() == 0) return RealScalar(1)/RealScalar(0);
+ if (dec.rows() == 0) return NumTraits<RealScalar>::infinity();
if (matrix_norm == RealScalar(0)) return RealScalar(0);
if (dec.rows() == 1) return RealScalar(1);
const RealScalar inverse_matrix_norm = rcond_invmatrix_L1_norm_estimate(dec);