From: Jean-Paul Pelteret Date: Thu, 16 Nov 2017 08:08:47 +0000 (+0100) Subject: Remove unnecessary ProductTypes and std::decay in FEValues functions X-Git-Tag: v9.0.0-rc1~765^2~1 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fd6c9856a849bf2ab51e576ad8d235720ea2a199;p=dealii.git Remove unnecessary ProductTypes and std::decay in FEValues functions With the current functionality my application of these two features in the FEValues function is now overly defensive. So this effectively reverts some of the changes made in #4951, as #4893 makes some use of ProductType unnecessary and #5251 ensures compatible conversions between numbers of all CV qualifications. --- diff --git a/source/fe/fe_values.cc b/source/fe/fe_values.cc index f141538cf5..686d6c35c9 100644 --- a/source/fe/fe_values.cc +++ b/source/fe/fe_values.cc @@ -473,7 +473,7 @@ namespace FEValuesViews AssertDimension (values.size(), n_quadrature_points); std::fill (values.begin(), values.end(), - dealii::internal::NumberType::type>::value(0.0)); + dealii::internal::NumberType::value(0.0)); for (unsigned int shape_function=0; shape_function >::type(*shape_derivative_ptr++); + dealii::Tensor(*shape_derivative_ptr++); } } @@ -666,7 +666,7 @@ namespace FEValuesViews &shape_derivatives[snc][0]; for (unsigned int q_point=0; q_point >::type(*shape_derivative_ptr++); + dealii::Tensor(*shape_derivative_ptr++); } else for (unsigned int d=0; d >::type(*shape_derivative_ptr++); + dealii::Tensor(*shape_derivative_ptr++); } } } @@ -724,7 +724,7 @@ namespace FEValuesViews &shape_gradients[snc][0]; for (unsigned int q_point=0; q_point >::type (symmetrize_single_row(comp, *shape_gradient_ptr++)); + dealii::SymmetricTensor<2,spacedim> (symmetrize_single_row(comp, *shape_gradient_ptr++)); } else for (unsigned int q_point=0; q_point::type>::value(0.0)); + dealii::internal::NumberType::value(0.0)); // add up contributions of trial functions. note that here we deal with // scalar finite elements, so no need to check for non-primitivity of @@ -3011,7 +3009,7 @@ namespace internal // initialize with zero std::fill_n (laplacians.begin(), n_quadrature_points, - dealii::internal::NumberType::type>::value(0.0)); + dealii::internal::NumberType::value(0.0)); // add up contributions of trial functions. note that here we deal with // scalar finite elements and also note that the Laplacian is