From: Denis Davydov Date: Sat, 28 Feb 2015 17:48:54 +0000 (+0100) Subject: fixing do_function_xxx used in the FEValuesBase class X-Git-Tag: v8.3.0-rc1~184^2~28 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5648c30cd7954ed5cb9a5accc60a6866af33e16d;p=dealii.git fixing do_function_xxx used in the FEValuesBase class --- diff --git a/source/fe/fe_values.cc b/source/fe/fe_values.cc index 10a1e72fa2..d606db71a7 100644 --- a/source/fe/fe_values.cc +++ b/source/fe/fe_values.cc @@ -1208,7 +1208,7 @@ namespace FEValuesViews AssertDimension (divergences.size(), n_quadrature_points); std::fill (divergences.begin(), divergences.end(), - dealii::Tensor<1,spacedim>()); + typename ProductType >::type()); for (unsigned int shape_function=0; shape_function + template void - do_function_values (const double *dof_values_ptr, + do_function_values (const Number2 *dof_values_ptr, const dealii::Table<2,double> &shape_values, std::vector &values) { @@ -2222,8 +2222,8 @@ namespace internal // the shape_values data stored contiguously for (unsigned int shape_func=0; shape_func + template void - do_function_values (const double *dof_values_ptr, + do_function_values (const Number *dof_values_ptr, const dealii::Table<2,double> &shape_values, const FiniteElement &fe, const std::vector &shape_function_to_row_table, @@ -2278,8 +2278,8 @@ namespace internal for (unsigned int mc = 0; mc < component_multiple; ++mc) for (unsigned int shape_func=0; shape_func + template void - do_function_derivatives (const double *dof_values_ptr, + do_function_derivatives (const Number *dof_values_ptr, const std::vector > > &shape_derivatives, - std::vector > &derivatives) + std::vector > &derivatives) { const unsigned int dofs_per_cell = shape_derivatives.size(); const unsigned int n_quadrature_points = dofs_per_cell > 0 ? @@ -2342,7 +2342,7 @@ namespace internal AssertDimension(derivatives.size(), n_quadrature_points); // initialize with zero - std::fill_n (derivatives.begin(), n_quadrature_points, Tensor()); + std::fill_n (derivatives.begin(), n_quadrature_points, Tensor()); // add up contributions of trial functions. note that here we deal with // scalar finite elements, so no need to check for non-primitivity of @@ -2353,8 +2353,8 @@ namespace internal // access the shape_gradients/hessians data stored contiguously for (unsigned int shape_func=0; shape_func *shape_derivative_ptr @@ -2364,20 +2364,20 @@ namespace internal } } - template + template void - do_function_derivatives (const double *dof_values_ptr, + do_function_derivatives (const Number *dof_values_ptr, const std::vector > > &shape_derivatives, const FiniteElement &fe, const std::vector &shape_function_to_row_table, - VectorSlice > > > &derivatives, + VectorSlice > > > &derivatives, const bool quadrature_points_fastest = false, const unsigned int component_multiple = 1) { // initialize with zero for (unsigned int i=0; i()); + Tensor()); // see if there the current cell has DoFs at all, and if not // then there is nothing else to do. @@ -2411,8 +2411,8 @@ namespace internal for (unsigned int mc = 0; mc < component_multiple; ++mc) for (unsigned int shape_func=0; shape_func + template void - do_function_laplacians (const double *dof_values_ptr, + do_function_laplacians (const Number2 *dof_values_ptr, const std::vector > > &shape_hessians, std::vector &laplacians) { @@ -2475,8 +2475,8 @@ namespace internal // the trace of the Hessian. for (unsigned int shape_func=0; shape_func *shape_hessian_ptr @@ -2486,9 +2486,9 @@ namespace internal } } - template + template void - do_function_laplacians (const double *dof_values_ptr, + do_function_laplacians (const Number *dof_values_ptr, const std::vector > > &shape_hessians, const FiniteElement &fe, const std::vector &shape_function_to_row_table, @@ -2533,8 +2533,8 @@ namespace internal for (unsigned int mc = 0; mc < component_multiple; ++mc) for (unsigned int shape_func=0; shape_func