From 99953e4c25655920b80fe9a61434be88028e2725 Mon Sep 17 00:00:00 2001 From: Daniel Arndt Date: Wed, 15 Sep 2021 13:27:50 -0400 Subject: [PATCH] Avoid using std::fabs --- source/numerics/matrix_tools.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/numerics/matrix_tools.cc b/source/numerics/matrix_tools.cc index 4aded6ad24..47c719f160 100644 --- a/source/numerics/matrix_tools.cc +++ b/source/numerics/matrix_tools.cc @@ -573,7 +573,7 @@ namespace MatrixTools for (unsigned int k = 0; k < n_local_dofs; ++k) if (local_matrix(k, k) != number{}) { - average_diagonal += std::fabs(local_matrix(k, k)); + average_diagonal += std::abs(local_matrix(k, k)); ++nonzero_diagonals; } if (nonzero_diagonals != 0) @@ -591,7 +591,7 @@ namespace MatrixTools local_matrix(i, i) = average_diagonal; } else - local_matrix(i, i) = std::fabs(local_matrix(i, i)); + local_matrix(i, i) = std::abs(local_matrix(i, i)); // and replace rhs entry by correct // value -- 2.39.5