16 #include <deal.II/base/array_view.h> 17 #include <deal.II/base/memory_consumption.h> 18 #include <deal.II/base/multithread_info.h> 19 #include <deal.II/base/numbers.h> 20 #include <deal.II/base/quadrature.h> 21 #include <deal.II/base/signaling_nan.h> 22 #include <deal.II/base/std_cxx14/memory.h> 24 #include <deal.II/differentiation/ad.h> 26 #include <deal.II/dofs/dof_accessor.h> 28 #include <deal.II/fe/fe.h> 29 #include <deal.II/fe/fe_values.h> 30 #include <deal.II/fe/mapping_q1.h> 32 #include <deal.II/grid/tria_accessor.h> 33 #include <deal.II/grid/tria_iterator.h> 35 #include <deal.II/lac/block_vector.h> 36 #include <deal.II/lac/la_parallel_block_vector.h> 37 #include <deal.II/lac/la_parallel_vector.h> 38 #include <deal.II/lac/la_vector.h> 39 #include <deal.II/lac/petsc_block_vector.h> 40 #include <deal.II/lac/petsc_vector.h> 41 #include <deal.II/lac/trilinos_parallel_block_vector.h> 42 #include <deal.II/lac/trilinos_vector.h> 43 #include <deal.II/lac/vector.h> 44 #include <deal.II/lac/vector_element_access.h> 46 #include <boost/container/small_vector.hpp> 49 #include <type_traits> 51 DEAL_II_NAMESPACE_OPEN
56 template <
class VectorType>
57 typename VectorType::value_type
inline get_vector_element(
58 const VectorType & vector,
61 return internal::ElementAccess<VectorType>::get(vector, cell_number);
75 template <
int dim,
int spacedim>
76 inline std::vector<unsigned int>
79 std::vector<unsigned int> shape_function_to_row_table(
88 unsigned int nth_nonzero_component = 0;
93 row + nth_nonzero_component;
94 ++nth_nonzero_component;
99 return shape_function_to_row_table;
106 template <
typename Number,
typename T =
void>
110 value(
const Number &value)
121 template <
typename Number>
124 typename
std::enable_if<
125 Differentiation::AD::is_ad_number<Number>::value>::type>
128 value(
const Number & )
140 template <
int dim,
int spacedim>
142 const unsigned int component)
143 : fe_values(&fe_values)
144 , component(component)
145 , shape_function_data(this->fe_values->fe->dofs_per_cell)
154 const std::vector<unsigned int> shape_function_to_row_table =
155 ::internal::make_shape_function_to_row_table(fe);
161 if (is_primitive ==
true)
178 template <
int dim,
int spacedim>
186 template <
int dim,
int spacedim>
197 template <
int dim,
int spacedim>
199 const unsigned int first_vector_component)
200 : fe_values(&fe_values)
201 , first_vector_component(first_vector_component)
213 const std::vector<unsigned int> shape_function_to_row_table =
214 ::internal::make_shape_function_to_row_table(fe);
216 for (
unsigned int d = 0; d < spacedim; ++d)
218 const unsigned int component = first_vector_component + d;
224 if (is_primitive ==
true)
234 shape_function_to_row_table[i * fe.
n_components() + component];
243 unsigned int n_nonzero_components = 0;
244 for (
unsigned int d = 0; d < spacedim; ++d)
247 ++n_nonzero_components;
249 if (n_nonzero_components == 0)
251 else if (n_nonzero_components > 1)
255 for (
unsigned int d = 0; d < spacedim; ++d)
257 .is_nonzero_shape_function_component[d] ==
true)
270 template <
int dim,
int spacedim>
278 template <
int dim,
int spacedim>
289 template <
int dim,
int spacedim>
292 const unsigned int first_tensor_component)
293 : fe_values(&fe_values)
294 , first_tensor_component(first_tensor_component)
298 Assert(first_tensor_component + (dim * dim + dim) / 2 - 1 <
301 first_tensor_component +
308 const std::vector<unsigned int> shape_function_to_row_table =
309 ::internal::make_shape_function_to_row_table(fe);
311 for (
unsigned int d = 0;
312 d < ::SymmetricTensor<2, dim>::n_independent_components;
315 const unsigned int component = first_tensor_component + d;
321 if (is_primitive ==
true)
322 shape_function_data[i].is_nonzero_shape_function_component[d] =
325 shape_function_data[i].is_nonzero_shape_function_component[d] =
328 if (shape_function_data[i].is_nonzero_shape_function_component[d] ==
330 shape_function_data[i].row_index[d] =
331 shape_function_to_row_table[i * fe.
n_components() + component];
333 shape_function_data[i].row_index[d] =
340 unsigned int n_nonzero_components = 0;
341 for (
unsigned int d = 0;
342 d < ::SymmetricTensor<2, dim>::n_independent_components;
344 if (shape_function_data[i].is_nonzero_shape_function_component[d] ==
346 ++n_nonzero_components;
348 if (n_nonzero_components == 0)
349 shape_function_data[i].single_nonzero_component = -2;
350 else if (n_nonzero_components > 1)
351 shape_function_data[i].single_nonzero_component = -1;
354 for (
unsigned int d = 0;
355 d < ::SymmetricTensor<2, dim>::n_independent_components;
357 if (shape_function_data[i]
358 .is_nonzero_shape_function_component[d] ==
true)
360 shape_function_data[i].single_nonzero_component =
361 shape_function_data[i].row_index[d];
362 shape_function_data[i].single_nonzero_component_index = d;
371 template <
int dim,
int spacedim>
374 , first_tensor_component(
numbers::invalid_unsigned_int)
379 template <
int dim,
int spacedim>
391 template <
int dim,
int spacedim>
393 const unsigned int first_tensor_component)
394 : fe_values(&fe_values)
395 , first_tensor_component(first_tensor_component)
396 , shape_function_data(this->fe_values->fe->dofs_per_cell)
406 const std::vector<unsigned int> shape_function_to_row_table =
407 ::internal::make_shape_function_to_row_table(fe);
409 for (
unsigned int d = 0; d < dim * dim; ++d)
411 const unsigned int component = first_tensor_component + d;
417 if (is_primitive ==
true)
418 shape_function_data[i].is_nonzero_shape_function_component[d] =
421 shape_function_data[i].is_nonzero_shape_function_component[d] =
424 if (shape_function_data[i].is_nonzero_shape_function_component[d] ==
426 shape_function_data[i].row_index[d] =
427 shape_function_to_row_table[i * fe.
n_components() + component];
429 shape_function_data[i].row_index[d] =
436 unsigned int n_nonzero_components = 0;
437 for (
unsigned int d = 0; d < dim * dim; ++d)
438 if (shape_function_data[i].is_nonzero_shape_function_component[d] ==
440 ++n_nonzero_components;
442 if (n_nonzero_components == 0)
443 shape_function_data[i].single_nonzero_component = -2;
444 else if (n_nonzero_components > 1)
445 shape_function_data[i].single_nonzero_component = -1;
448 for (
unsigned int d = 0; d < dim * dim; ++d)
449 if (shape_function_data[i]
450 .is_nonzero_shape_function_component[d] ==
true)
452 shape_function_data[i].single_nonzero_component =
453 shape_function_data[i].row_index[d];
454 shape_function_data[i].single_nonzero_component_index = d;
463 template <
int dim,
int spacedim>
466 , first_tensor_component(
numbers::invalid_unsigned_int)
471 template <
int dim,
int spacedim>
488 template <
int dim,
int spacedim,
typename Number>
494 &shape_function_data,
495 std::vector<
typename ProductType<Number, double>::type> &values)
497 const unsigned int dofs_per_cell = dof_values.
size();
498 const unsigned int n_quadrature_points =
499 dofs_per_cell > 0 ? shape_values.n_cols() : values.
size();
502 std::fill(values.begin(),
506 for (
unsigned int shape_function = 0; shape_function < dofs_per_cell;
508 if (shape_function_data[shape_function]
509 .is_nonzero_shape_function_component)
511 const Number &value = dof_values[shape_function];
515 if (::internal::CheckForZero<Number>::value(value) ==
true)
518 const double *shape_value_ptr =
519 &shape_values(shape_function_data[shape_function].row_index, 0);
520 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
522 values[q_point] += value * (*shape_value_ptr++);
530 template <
int order,
int dim,
int spacedim,
typename Number>
532 do_function_derivatives(
534 const Table<2, ::Tensor<order, spacedim>> &shape_derivatives,
536 &shape_function_data,
538 typename ProductType<Number, ::Tensor<order, spacedim>>::type>
541 const unsigned int dofs_per_cell = dof_values.
size();
542 const unsigned int n_quadrature_points =
543 dofs_per_cell > 0 ? shape_derivatives[0].size() : derivatives.size();
551 for (
unsigned int shape_function = 0; shape_function < dofs_per_cell;
553 if (shape_function_data[shape_function]
554 .is_nonzero_shape_function_component)
556 const Number &value = dof_values[shape_function];
560 if (::internal::CheckForZero<Number>::value(value) ==
true)
563 const ::Tensor<order, spacedim> *shape_derivative_ptr =
564 &shape_derivatives[shape_function_data[shape_function].row_index]
566 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
568 derivatives[q_point] += value * (*shape_derivative_ptr++);
574 template <
int dim,
int spacedim,
typename Number>
576 do_function_laplacians(
580 & shape_function_data,
582 Number>::laplacian_type> &laplacians)
584 const unsigned int dofs_per_cell = dof_values.
size();
585 const unsigned int n_quadrature_points =
586 dofs_per_cell > 0 ? shape_hessians[0].size() : laplacians.size();
589 std::fill(laplacians.begin(),
592 Number>::laplacian_type());
594 for (
unsigned int shape_function = 0; shape_function < dofs_per_cell;
596 if (shape_function_data[shape_function]
597 .is_nonzero_shape_function_component)
599 const Number &value = dof_values[shape_function];
603 if (::internal::CheckForZero<Number>::value(value) ==
true)
606 const ::Tensor<2, spacedim> *shape_hessian_ptr =
607 &shape_hessians[shape_function_data[shape_function].row_index][0];
608 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
610 laplacians[q_point] += value *
trace(*shape_hessian_ptr++);
618 template <
int dim,
int spacedim,
typename Number>
624 &shape_function_data,
629 const unsigned int dofs_per_cell = dof_values.
size();
630 const unsigned int n_quadrature_points =
631 dofs_per_cell > 0 ? shape_values.n_cols() : values.
size();
639 for (
unsigned int shape_function = 0; shape_function < dofs_per_cell;
643 shape_function_data[shape_function].single_nonzero_component;
649 const Number &value = dof_values[shape_function];
653 if (::internal::CheckForZero<Number>::value(value) ==
true)
658 const unsigned int comp = shape_function_data[shape_function]
659 .single_nonzero_component_index;
660 const double *shape_value_ptr = &shape_values(snc, 0);
661 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
663 values[q_point][comp] += value * (*shape_value_ptr++);
666 for (
unsigned int d = 0; d < spacedim; ++d)
667 if (shape_function_data[shape_function]
668 .is_nonzero_shape_function_component[d])
670 const double *shape_value_ptr = &shape_values(
671 shape_function_data[shape_function].row_index[d], 0);
672 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
674 values[q_point][d] += value * (*shape_value_ptr++);
681 template <
int order,
int dim,
int spacedim,
typename Number>
683 do_function_derivatives(
685 const Table<2, ::Tensor<order, spacedim>> &shape_derivatives,
687 &shape_function_data,
689 typename ProductType<Number, ::Tensor<order + 1, spacedim>>::type>
692 const unsigned int dofs_per_cell = dof_values.
size();
693 const unsigned int n_quadrature_points =
694 dofs_per_cell > 0 ? shape_derivatives[0].size() : derivatives.size();
701 ::Tensor<order + 1, spacedim>>::type());
703 for (
unsigned int shape_function = 0; shape_function < dofs_per_cell;
707 shape_function_data[shape_function].single_nonzero_component;
713 const Number &value = dof_values[shape_function];
717 if (::internal::CheckForZero<Number>::value(value) ==
true)
722 const unsigned int comp = shape_function_data[shape_function]
723 .single_nonzero_component_index;
724 const ::Tensor<order, spacedim> *shape_derivative_ptr =
725 &shape_derivatives[snc][0];
726 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
728 derivatives[q_point][comp] += value * (*shape_derivative_ptr++);
731 for (
unsigned int d = 0; d < spacedim; ++d)
732 if (shape_function_data[shape_function]
733 .is_nonzero_shape_function_component[d])
735 const ::Tensor<order, spacedim> *shape_derivative_ptr =
736 &shape_derivatives[shape_function_data[shape_function]
738 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
740 derivatives[q_point][d] +=
741 value * (*shape_derivative_ptr++);
748 template <
int dim,
int spacedim,
typename Number>
750 do_function_symmetric_gradients(
754 &shape_function_data,
758 &symmetric_gradients)
760 const unsigned int dofs_per_cell = dof_values.
size();
761 const unsigned int n_quadrature_points = dofs_per_cell > 0 ?
762 shape_gradients[0].size() :
763 symmetric_gradients.size();
767 symmetric_gradients.begin(),
768 symmetric_gradients.end(),
772 for (
unsigned int shape_function = 0; shape_function < dofs_per_cell;
776 shape_function_data[shape_function].single_nonzero_component;
782 const Number &value = dof_values[shape_function];
786 if (::internal::CheckForZero<Number>::value(value) ==
true)
791 const unsigned int comp = shape_function_data[shape_function]
792 .single_nonzero_component_index;
793 const ::Tensor<1, spacedim> *shape_gradient_ptr =
794 &shape_gradients[snc][0];
795 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
797 symmetric_gradients[q_point] +=
799 symmetrize_single_row(comp, *shape_gradient_ptr++));
802 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
807 for (
unsigned int d = 0; d < spacedim; ++d)
808 if (shape_function_data[shape_function]
809 .is_nonzero_shape_function_component[d])
812 shape_gradients[shape_function_data[shape_function]
813 .row_index[d]][q_point];
814 symmetric_gradients[q_point] +=
symmetrize(grad);
821 template <
int dim,
int spacedim,
typename Number>
823 do_function_divergences(
827 & shape_function_data,
831 const unsigned int dofs_per_cell = dof_values.
size();
832 const unsigned int n_quadrature_points =
833 dofs_per_cell > 0 ? shape_gradients[0].size() : divergences.size();
836 std::fill(divergences.begin(),
841 for (
unsigned int shape_function = 0; shape_function < dofs_per_cell;
845 shape_function_data[shape_function].single_nonzero_component;
851 const Number &value = dof_values[shape_function];
855 if (::internal::CheckForZero<Number>::value(value) ==
true)
860 const unsigned int comp = shape_function_data[shape_function]
861 .single_nonzero_component_index;
862 const ::Tensor<1, spacedim> *shape_gradient_ptr =
863 &shape_gradients[snc][0];
864 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
866 divergences[q_point] += value * (*shape_gradient_ptr++)[comp];
869 for (
unsigned int d = 0; d < spacedim; ++d)
870 if (shape_function_data[shape_function]
871 .is_nonzero_shape_function_component[d])
873 const ::Tensor<1, spacedim> *shape_gradient_ptr =
874 &shape_gradients[shape_function_data[shape_function]
876 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
878 divergences[q_point] += value * (*shape_gradient_ptr++)[d];
885 template <
int dim,
int spacedim,
typename Number>
891 &shape_function_data,
894 typename ::internal::CurlType<spacedim>::type>::type> &curls)
896 const unsigned int dofs_per_cell = dof_values.
size();
897 const unsigned int n_quadrature_points =
898 dofs_per_cell > 0 ? shape_gradients[0].size() : curls.size();
901 std::fill(curls.begin(),
905 typename ::internal::CurlType<spacedim>::type>::type());
913 "Computing the curl in 1d is not a useful operation"));
919 for (
unsigned int shape_function = 0;
920 shape_function < dofs_per_cell;
923 const int snc = shape_function_data[shape_function]
924 .single_nonzero_component;
930 const Number &value = dof_values[shape_function];
934 if (::internal::CheckForZero<Number>::value(value) ==
940 const ::Tensor<1, spacedim> *shape_gradient_ptr =
941 &shape_gradients[snc][0];
943 Assert(shape_function_data[shape_function]
944 .single_nonzero_component >= 0,
947 if (shape_function_data[shape_function]
948 .single_nonzero_component_index == 0)
949 for (
unsigned int q_point = 0;
950 q_point < n_quadrature_points;
953 value * (*shape_gradient_ptr++)[1];
955 for (
unsigned int q_point = 0;
956 q_point < n_quadrature_points;
959 value * (*shape_gradient_ptr++)[0];
967 if (shape_function_data[shape_function]
968 .is_nonzero_shape_function_component[0])
971 spacedim> *shape_gradient_ptr =
972 &shape_gradients[shape_function_data[shape_function]
975 for (
unsigned int q_point = 0;
976 q_point < n_quadrature_points;
979 value * (*shape_gradient_ptr++)[1];
982 if (shape_function_data[shape_function]
983 .is_nonzero_shape_function_component[1])
986 spacedim> *shape_gradient_ptr =
987 &shape_gradients[shape_function_data[shape_function]
990 for (
unsigned int q_point = 0;
991 q_point < n_quadrature_points;
994 value * (*shape_gradient_ptr++)[0];
1003 for (
unsigned int shape_function = 0;
1004 shape_function < dofs_per_cell;
1007 const int snc = shape_function_data[shape_function]
1008 .single_nonzero_component;
1014 const Number &value = dof_values[shape_function];
1018 if (::internal::CheckForZero<Number>::value(value) ==
1024 const ::Tensor<1, spacedim> *shape_gradient_ptr =
1025 &shape_gradients[snc][0];
1027 switch (shape_function_data[shape_function]
1028 .single_nonzero_component_index)
1032 for (
unsigned int q_point = 0;
1033 q_point < n_quadrature_points;
1036 curls[q_point][1] +=
1037 value * (*shape_gradient_ptr)[2];
1038 curls[q_point][2] -=
1039 value * (*shape_gradient_ptr++)[1];
1047 for (
unsigned int q_point = 0;
1048 q_point < n_quadrature_points;
1051 curls[q_point][0] -=
1052 value * (*shape_gradient_ptr)[2];
1053 curls[q_point][2] +=
1054 value * (*shape_gradient_ptr++)[0];
1062 for (
unsigned int q_point = 0;
1063 q_point < n_quadrature_points;
1066 curls[q_point][0] +=
1067 value * (*shape_gradient_ptr)[1];
1068 curls[q_point][1] -=
1069 value * (*shape_gradient_ptr++)[0];
1085 if (shape_function_data[shape_function]
1086 .is_nonzero_shape_function_component[0])
1089 spacedim> *shape_gradient_ptr =
1090 &shape_gradients[shape_function_data[shape_function]
1093 for (
unsigned int q_point = 0;
1094 q_point < n_quadrature_points;
1097 curls[q_point][1] +=
1098 value * (*shape_gradient_ptr)[2];
1099 curls[q_point][2] -=
1100 value * (*shape_gradient_ptr++)[1];
1104 if (shape_function_data[shape_function]
1105 .is_nonzero_shape_function_component[1])
1108 spacedim> *shape_gradient_ptr =
1109 &shape_gradients[shape_function_data[shape_function]
1112 for (
unsigned int q_point = 0;
1113 q_point < n_quadrature_points;
1116 curls[q_point][0] -=
1117 value * (*shape_gradient_ptr)[2];
1118 curls[q_point][2] +=
1119 value * (*shape_gradient_ptr++)[0];
1123 if (shape_function_data[shape_function]
1124 .is_nonzero_shape_function_component[2])
1127 spacedim> *shape_gradient_ptr =
1128 &shape_gradients[shape_function_data[shape_function]
1131 for (
unsigned int q_point = 0;
1132 q_point < n_quadrature_points;
1135 curls[q_point][0] +=
1136 value * (*shape_gradient_ptr)[1];
1137 curls[q_point][1] -=
1138 value * (*shape_gradient_ptr++)[0];
1149 template <
int dim,
int spacedim,
typename Number>
1151 do_function_laplacians(
1155 & shape_function_data,
1157 Number>::laplacian_type> &laplacians)
1159 const unsigned int dofs_per_cell = dof_values.
size();
1160 const unsigned int n_quadrature_points =
1161 dofs_per_cell > 0 ? shape_hessians[0].size() : laplacians.size();
1164 std::fill(laplacians.begin(),
1167 Number>::laplacian_type());
1169 for (
unsigned int shape_function = 0; shape_function < dofs_per_cell;
1173 shape_function_data[shape_function].single_nonzero_component;
1179 const Number &value = dof_values[shape_function];
1183 if (::internal::CheckForZero<Number>::value(value) ==
true)
1188 const unsigned int comp = shape_function_data[shape_function]
1189 .single_nonzero_component_index;
1190 const ::Tensor<2, spacedim> *shape_hessian_ptr =
1191 &shape_hessians[snc][0];
1192 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
1194 laplacians[q_point][comp] +=
1195 value *
trace(*shape_hessian_ptr++);
1198 for (
unsigned int d = 0; d < spacedim; ++d)
1199 if (shape_function_data[shape_function]
1200 .is_nonzero_shape_function_component[d])
1202 const ::Tensor<2, spacedim> *shape_hessian_ptr =
1203 &shape_hessians[shape_function_data[shape_function]
1205 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
1207 laplacians[q_point][d] +=
1208 value *
trace(*shape_hessian_ptr++);
1217 template <
int dim,
int spacedim,
typename Number>
1221 const ::Table<2, double> &shape_values,
1223 typename SymmetricTensor<2, dim, spacedim>::ShapeFunctionData>
1224 &shape_function_data,
1230 const unsigned int dofs_per_cell = dof_values.
size();
1231 const unsigned int n_quadrature_points =
1232 dofs_per_cell > 0 ? shape_values.n_cols() : values.size();
1241 for (
unsigned int shape_function = 0; shape_function < dofs_per_cell;
1245 shape_function_data[shape_function].single_nonzero_component;
1251 const Number &value = dof_values[shape_function];
1255 if (::internal::CheckForZero<Number>::value(value) ==
true)
1262 shape_function_data[shape_function]
1263 .single_nonzero_component_index);
1264 const double *shape_value_ptr = &shape_values(snc, 0);
1265 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
1267 values[q_point][comp] += value * (*shape_value_ptr++);
1270 for (
unsigned int d = 0;
1274 if (shape_function_data[shape_function]
1275 .is_nonzero_shape_function_component[d])
1280 const double *shape_value_ptr = &shape_values(
1281 shape_function_data[shape_function].row_index[d], 0);
1282 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
1284 values[q_point][comp] += value * (*shape_value_ptr++);
1291 template <
int dim,
int spacedim,
typename Number>
1293 do_function_divergences(
1297 typename SymmetricTensor<2, dim, spacedim>::ShapeFunctionData>
1298 &shape_function_data,
1302 const unsigned int dofs_per_cell = dof_values.
size();
1303 const unsigned int n_quadrature_points =
1304 dofs_per_cell > 0 ? shape_gradients[0].size() : divergences.size();
1307 std::fill(divergences.begin(),
1309 typename SymmetricTensor<2, dim, spacedim>::template OutputType<
1312 for (
unsigned int shape_function = 0; shape_function < dofs_per_cell;
1316 shape_function_data[shape_function].single_nonzero_component;
1322 const Number &value = dof_values[shape_function];
1326 if (::internal::CheckForZero<Number>::value(value) ==
true)
1331 const unsigned int comp = shape_function_data[shape_function]
1332 .single_nonzero_component_index;
1334 const ::Tensor<1, spacedim> *shape_gradient_ptr =
1335 &shape_gradients[snc][0];
1342 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
1343 ++q_point, ++shape_gradient_ptr)
1345 divergences[q_point][ii] += value * (*shape_gradient_ptr)[jj];
1348 divergences[q_point][jj] +=
1349 value * (*shape_gradient_ptr)[ii];
1354 for (
unsigned int d = 0;
1356 ::SymmetricTensor<2,
1357 spacedim>::n_independent_components;
1359 if (shape_function_data[shape_function]
1360 .is_nonzero_shape_function_component[d])
1372 const unsigned int comp =
1373 shape_function_data[shape_function]
1374 .single_nonzero_component_index;
1376 const ::Tensor<1, spacedim> *shape_gradient_ptr =
1377 &shape_gradients[shape_function_data[shape_function]
1379 for (
unsigned int q_point = 0;
1380 q_point < n_quadrature_points;
1381 ++q_point, ++shape_gradient_ptr)
1383 for (
unsigned int j = 0; j < spacedim; ++j)
1385 const unsigned int vector_component =
1389 divergences[q_point][vector_component] +=
1390 value * (*shape_gradient_ptr++)[j];
1400 template <
int dim,
int spacedim,
typename Number>
1404 const ::Table<2, double> &shape_values,
1405 const std::vector<
typename Tensor<2, dim, spacedim>::ShapeFunctionData>
1406 &shape_function_data,
1411 const unsigned int dofs_per_cell = dof_values.
size();
1412 const unsigned int n_quadrature_points =
1413 dofs_per_cell > 0 ? shape_values.n_cols() : values.size();
1421 for (
unsigned int shape_function = 0; shape_function < dofs_per_cell;
1425 shape_function_data[shape_function].single_nonzero_component;
1431 const Number &value = dof_values[shape_function];
1435 if (::internal::CheckForZero<Number>::value(value) ==
true)
1440 const unsigned int comp = shape_function_data[shape_function]
1441 .single_nonzero_component_index;
1447 const double *shape_value_ptr = &shape_values(snc, 0);
1448 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
1450 values[q_point][indices] += value * (*shape_value_ptr++);
1453 for (
unsigned int d = 0; d < dim * dim; ++d)
1454 if (shape_function_data[shape_function]
1455 .is_nonzero_shape_function_component[d])
1461 const double *shape_value_ptr = &shape_values(
1462 shape_function_data[shape_function].row_index[d], 0);
1463 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
1465 values[q_point][indices] += value * (*shape_value_ptr++);
1472 template <
int dim,
int spacedim,
typename Number>
1474 do_function_divergences(
1477 const std::vector<
typename Tensor<2, dim, spacedim>::ShapeFunctionData>
1478 & shape_function_data,
1479 std::vector<
typename Tensor<2, dim, spacedim>::template OutputType<
1482 const unsigned int dofs_per_cell = dof_values.
size();
1483 const unsigned int n_quadrature_points =
1484 dofs_per_cell > 0 ? shape_gradients[0].size() : divergences.size();
1487 std::fill(divergences.begin(),
1489 typename Tensor<2, dim, spacedim>::template OutputType<
1492 for (
unsigned int shape_function = 0; shape_function < dofs_per_cell;
1496 shape_function_data[shape_function].single_nonzero_component;
1502 const Number &value = dof_values[shape_function];
1506 if (::internal::CheckForZero<Number>::value(value) ==
true)
1511 const unsigned int comp = shape_function_data[shape_function]
1512 .single_nonzero_component_index;
1514 const ::Tensor<1, spacedim> *shape_gradient_ptr =
1515 &shape_gradients[snc][0];
1520 const unsigned int ii = indices[0];
1521 const unsigned int jj = indices[1];
1523 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
1524 ++q_point, ++shape_gradient_ptr)
1526 divergences[q_point][ii] += value * (*shape_gradient_ptr)[jj];
1531 for (
unsigned int d = 0; d < dim * dim; ++d)
1532 if (shape_function_data[shape_function]
1533 .is_nonzero_shape_function_component[d])
1543 template <
int dim,
int spacedim,
typename Number>
1545 do_function_gradients(
1548 const std::vector<
typename Tensor<2, dim, spacedim>::ShapeFunctionData>
1549 & shape_function_data,
1550 std::vector<
typename Tensor<2, dim, spacedim>::template OutputType<
1553 const unsigned int dofs_per_cell = dof_values.
size();
1554 const unsigned int n_quadrature_points =
1555 dofs_per_cell > 0 ? shape_gradients[0].size() : gradients.size();
1558 std::fill(gradients.begin(),
1560 typename Tensor<2, dim, spacedim>::template OutputType<
1563 for (
unsigned int shape_function = 0; shape_function < dofs_per_cell;
1567 shape_function_data[shape_function].single_nonzero_component;
1573 const Number &value = dof_values[shape_function];
1577 if (::internal::CheckForZero<Number>::value(value) ==
true)
1582 const unsigned int comp = shape_function_data[shape_function]
1583 .single_nonzero_component_index;
1585 const ::Tensor<1, spacedim> *shape_gradient_ptr =
1586 &shape_gradients[snc][0];
1591 const unsigned int ii = indices[0];
1592 const unsigned int jj = indices[1];
1594 for (
unsigned int q_point = 0; q_point < n_quadrature_points;
1595 ++q_point, ++shape_gradient_ptr)
1597 gradients[q_point][ii][jj] += value * (*shape_gradient_ptr);
1602 for (
unsigned int d = 0; d < dim * dim; ++d)
1603 if (shape_function_data[shape_function]
1604 .is_nonzero_shape_function_component[d])
1616 template <
int dim,
int spacedim>
1617 template <
class InputVector>
1620 const InputVector &fe_function,
1622 typename ProductType<value_type, typename InputVector::value_type>::type>
1628 Assert(fe_values->present_cell.get() !=
nullptr,
1629 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
1631 fe_values->present_cell->n_dofs_for_dof_handler());
1636 fe_values->dofs_per_cell);
1637 fe_values->present_cell->get_interpolated_dof_values(fe_function,
1639 internal::do_function_values<dim, spacedim>(
1640 make_array_view(dof_values.begin(), dof_values.end()),
1641 fe_values->finite_element_output.shape_values,
1642 shape_function_data,
1648 template <
int dim,
int spacedim>
1649 template <
class InputVector>
1652 const InputVector &dof_values,
1660 Assert(fe_values->present_cell.get() !=
nullptr,
1661 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
1664 internal::do_function_values<dim, spacedim>(
1665 make_array_view(dof_values.begin(), dof_values.end()),
1666 fe_values->finite_element_output.shape_values,
1667 shape_function_data,
1673 template <
int dim,
int spacedim>
1674 template <
class InputVector>
1677 const InputVector &fe_function,
1679 typename InputVector::value_type>::type>
1684 "update_gradients")));
1685 Assert(fe_values->present_cell.get() !=
nullptr,
1686 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
1688 fe_values->present_cell->n_dofs_for_dof_handler());
1692 fe_values->dofs_per_cell);
1693 fe_values->present_cell->get_interpolated_dof_values(fe_function,
1695 internal::do_function_derivatives<1, dim, spacedim>(
1696 make_array_view(dof_values.begin(), dof_values.end()),
1697 fe_values->finite_element_output.shape_gradients,
1698 shape_function_data,
1704 template <
int dim,
int spacedim>
1705 template <
class InputVector>
1708 const InputVector &dof_values,
1715 "update_gradients")));
1716 Assert(fe_values->present_cell.get() !=
nullptr,
1717 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
1720 internal::do_function_derivatives<1, dim, spacedim>(
1721 make_array_view(dof_values.begin(), dof_values.end()),
1722 fe_values->finite_element_output.shape_gradients,
1723 shape_function_data,
1729 template <
int dim,
int spacedim>
1730 template <
class InputVector>
1733 const InputVector &fe_function,
1735 typename InputVector::value_type>::type>
1740 "update_hessians")));
1741 Assert(fe_values->present_cell.get() !=
nullptr,
1742 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
1744 fe_values->present_cell->n_dofs_for_dof_handler());
1748 fe_values->dofs_per_cell);
1749 fe_values->present_cell->get_interpolated_dof_values(fe_function,
1751 internal::do_function_derivatives<2, dim, spacedim>(
1752 make_array_view(dof_values.begin(), dof_values.end()),
1753 fe_values->finite_element_output.shape_hessians,
1754 shape_function_data,
1760 template <
int dim,
int spacedim>
1761 template <
class InputVector>
1764 const InputVector &dof_values,
1771 "update_hessians")));
1772 Assert(fe_values->present_cell.get() !=
nullptr,
1773 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
1776 internal::do_function_derivatives<2, dim, spacedim>(
1777 make_array_view(dof_values.begin(), dof_values.end()),
1778 fe_values->finite_element_output.shape_hessians,
1779 shape_function_data,
1785 template <
int dim,
int spacedim>
1786 template <
class InputVector>
1789 const InputVector &fe_function,
1791 typename ProductType<value_type, typename InputVector::value_type>::type>
1796 "update_hessians")));
1797 Assert(fe_values->present_cell.get() !=
nullptr,
1798 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
1800 fe_values->present_cell->n_dofs_for_dof_handler());
1804 fe_values->dofs_per_cell);
1805 fe_values->present_cell->get_interpolated_dof_values(fe_function,
1807 internal::do_function_laplacians<dim, spacedim>(
1808 make_array_view(dof_values.begin(), dof_values.end()),
1809 fe_values->finite_element_output.shape_hessians,
1810 shape_function_data,
1816 template <
int dim,
int spacedim>
1817 template <
class InputVector>
1820 const InputVector &dof_values,
1827 "update_hessians")));
1828 Assert(fe_values->present_cell.get() !=
nullptr,
1829 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
1832 internal::do_function_laplacians<dim, spacedim>(
1833 make_array_view(dof_values.begin(), dof_values.end()),
1834 fe_values->finite_element_output.shape_hessians,
1835 shape_function_data,
1841 template <
int dim,
int spacedim>
1842 template <
class InputVector>
1845 const InputVector &fe_function,
1847 typename InputVector::value_type>::type>
1848 &third_derivatives)
const 1852 "update_3rd_derivatives")));
1853 Assert(fe_values->present_cell.get() !=
nullptr,
1854 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
1856 fe_values->present_cell->n_dofs_for_dof_handler());
1860 fe_values->dofs_per_cell);
1861 fe_values->present_cell->get_interpolated_dof_values(fe_function,
1863 internal::do_function_derivatives<3, dim, spacedim>(
1864 make_array_view(dof_values.begin(), dof_values.end()),
1865 fe_values->finite_element_output.shape_3rd_derivatives,
1866 shape_function_data,
1872 template <
int dim,
int spacedim>
1873 template <
class InputVector>
1876 const InputVector & dof_values,
1882 "update_3rd_derivatives")));
1883 Assert(fe_values->present_cell.get() !=
nullptr,
1884 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
1887 internal::do_function_derivatives<3, dim, spacedim>(
1888 make_array_view(dof_values.begin(), dof_values.end()),
1889 fe_values->finite_element_output.shape_3rd_derivatives,
1890 shape_function_data,
1896 template <
int dim,
int spacedim>
1897 template <
class InputVector>
1900 const InputVector &fe_function,
1902 typename ProductType<value_type, typename InputVector::value_type>::type>
1908 Assert(fe_values->present_cell.get() !=
nullptr,
1909 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
1911 fe_values->present_cell->n_dofs_for_dof_handler());
1915 fe_values->dofs_per_cell);
1916 fe_values->present_cell->get_interpolated_dof_values(fe_function,
1918 internal::do_function_values<dim, spacedim>(
1919 make_array_view(dof_values.begin(), dof_values.end()),
1920 fe_values->finite_element_output.shape_values,
1921 shape_function_data,
1927 template <
int dim,
int spacedim>
1928 template <
class InputVector>
1931 const InputVector &dof_values,
1939 Assert(fe_values->present_cell.get() !=
nullptr,
1940 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
1943 internal::do_function_values<dim, spacedim>(
1944 make_array_view(dof_values.begin(), dof_values.end()),
1945 fe_values->finite_element_output.shape_values,
1946 shape_function_data,
1952 template <
int dim,
int spacedim>
1953 template <
class InputVector>
1956 const InputVector &fe_function,
1958 typename InputVector::value_type>::type>
1963 "update_gradients")));
1964 Assert(fe_values->present_cell.get() !=
nullptr,
1965 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
1967 fe_values->present_cell->n_dofs_for_dof_handler());
1971 fe_values->dofs_per_cell);
1972 fe_values->present_cell->get_interpolated_dof_values(fe_function,
1974 internal::do_function_derivatives<1, dim, spacedim>(
1975 make_array_view(dof_values.begin(), dof_values.end()),
1976 fe_values->finite_element_output.shape_gradients,
1977 shape_function_data,
1983 template <
int dim,
int spacedim>
1984 template <
class InputVector>
1987 const InputVector &dof_values,
1994 "update_gradients")));
1995 Assert(fe_values->present_cell.get() !=
nullptr,
1996 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
1999 internal::do_function_derivatives<1, dim, spacedim>(
2000 make_array_view(dof_values.begin(), dof_values.end()),
2001 fe_values->finite_element_output.shape_gradients,
2002 shape_function_data,
2008 template <
int dim,
int spacedim>
2009 template <
class InputVector>
2012 const InputVector &fe_function,
2014 typename InputVector::value_type>::type>
2015 &symmetric_gradients)
const 2019 "update_gradients")));
2020 Assert(fe_values->present_cell.get() !=
nullptr,
2021 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2023 fe_values->present_cell->n_dofs_for_dof_handler());
2027 fe_values->dofs_per_cell);
2028 fe_values->present_cell->get_interpolated_dof_values(fe_function,
2030 internal::do_function_symmetric_gradients<dim, spacedim>(
2031 make_array_view(dof_values.begin(), dof_values.end()),
2032 fe_values->finite_element_output.shape_gradients,
2033 shape_function_data,
2034 symmetric_gradients);
2039 template <
int dim,
int spacedim>
2040 template <
class InputVector>
2043 const InputVector & dof_values,
2049 "update_gradients")));
2050 Assert(fe_values->present_cell.get() !=
nullptr,
2051 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2054 internal::do_function_symmetric_gradients<dim, spacedim>(
2055 make_array_view(dof_values.begin(), dof_values.end()),
2056 fe_values->finite_element_output.shape_gradients,
2057 shape_function_data,
2058 symmetric_gradients);
2063 template <
int dim,
int spacedim>
2064 template <
class InputVector>
2067 const InputVector &fe_function,
2069 typename InputVector::value_type>::type>
2074 "update_gradients")));
2075 Assert(fe_values->present_cell.get() !=
nullptr,
2076 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2078 fe_values->present_cell->n_dofs_for_dof_handler());
2083 fe_values->dofs_per_cell);
2084 fe_values->present_cell->get_interpolated_dof_values(fe_function,
2086 internal::do_function_divergences<dim, spacedim>(
2087 make_array_view(dof_values.begin(), dof_values.end()),
2088 fe_values->finite_element_output.shape_gradients,
2089 shape_function_data,
2095 template <
int dim,
int spacedim>
2096 template <
class InputVector>
2099 const InputVector &dof_values,
2106 "update_gradients")));
2107 Assert(fe_values->present_cell.get() !=
nullptr,
2108 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2111 internal::do_function_divergences<dim, spacedim>(
2112 make_array_view(dof_values.begin(), dof_values.end()),
2113 fe_values->finite_element_output.shape_gradients,
2114 shape_function_data,
2120 template <
int dim,
int spacedim>
2121 template <
class InputVector>
2124 const InputVector &fe_function,
2126 typename ProductType<curl_type, typename InputVector::value_type>::type>
2131 "update_gradients")));
2132 Assert(fe_values->present_cell.get() !=
nullptr,
2133 ExcMessage(
"FEValues object is not reinited to any cell"));
2135 fe_values->present_cell->n_dofs_for_dof_handler());
2139 fe_values->dofs_per_cell);
2140 fe_values->present_cell->get_interpolated_dof_values(fe_function,
2142 internal::do_function_curls<dim, spacedim>(
2143 make_array_view(dof_values.begin(), dof_values.end()),
2144 fe_values->finite_element_output.shape_gradients,
2145 shape_function_data,
2151 template <
int dim,
int spacedim>
2152 template <
class InputVector>
2155 const InputVector &dof_values,
2162 "update_gradients")));
2163 Assert(fe_values->present_cell.get() !=
nullptr,
2164 ExcMessage(
"FEValues object is not reinited to any cell"));
2167 internal::do_function_curls<dim, spacedim>(
2168 make_array_view(dof_values.begin(), dof_values.end()),
2169 fe_values->finite_element_output.shape_gradients,
2170 shape_function_data,
2176 template <
int dim,
int spacedim>
2177 template <
class InputVector>
2180 const InputVector &fe_function,
2182 typename InputVector::value_type>::type>
2187 "update_hessians")));
2188 Assert(fe_values->present_cell.get() !=
nullptr,
2189 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2191 fe_values->present_cell->n_dofs_for_dof_handler());
2195 fe_values->dofs_per_cell);
2196 fe_values->present_cell->get_interpolated_dof_values(fe_function,
2198 internal::do_function_derivatives<2, dim, spacedim>(
2199 make_array_view(dof_values.begin(), dof_values.end()),
2200 fe_values->finite_element_output.shape_hessians,
2201 shape_function_data,
2207 template <
int dim,
int spacedim>
2208 template <
class InputVector>
2211 const InputVector &dof_values,
2218 "update_hessians")));
2219 Assert(fe_values->present_cell.get() !=
nullptr,
2220 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2223 internal::do_function_derivatives<2, dim, spacedim>(
2224 make_array_view(dof_values.begin(), dof_values.end()),
2225 fe_values->finite_element_output.shape_hessians,
2226 shape_function_data,
2232 template <
int dim,
int spacedim>
2233 template <
class InputVector>
2236 const InputVector &fe_function,
2238 typename ProductType<value_type, typename InputVector::value_type>::type>
2243 "update_hessians")));
2244 Assert(laplacians.size() == fe_values->n_quadrature_points,
2246 fe_values->n_quadrature_points));
2247 Assert(fe_values->present_cell.get() !=
nullptr,
2248 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2250 fe_function.size() == fe_values->present_cell->n_dofs_for_dof_handler(),
2252 fe_values->present_cell->n_dofs_for_dof_handler()));
2256 fe_values->dofs_per_cell);
2257 fe_values->present_cell->get_interpolated_dof_values(fe_function,
2259 internal::do_function_laplacians<dim, spacedim>(
2260 make_array_view(dof_values.begin(), dof_values.end()),
2261 fe_values->finite_element_output.shape_hessians,
2262 shape_function_data,
2268 template <
int dim,
int spacedim>
2269 template <
class InputVector>
2272 const InputVector &dof_values,
2279 "update_hessians")));
2280 Assert(laplacians.size() == fe_values->n_quadrature_points,
2282 fe_values->n_quadrature_points));
2283 Assert(fe_values->present_cell.get() !=
nullptr,
2284 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2287 internal::do_function_laplacians<dim, spacedim>(
2288 make_array_view(dof_values.begin(), dof_values.end()),
2289 fe_values->finite_element_output.shape_hessians,
2290 shape_function_data,
2296 template <
int dim,
int spacedim>
2297 template <
class InputVector>
2300 const InputVector &fe_function,
2302 typename InputVector::value_type>::type>
2303 &third_derivatives)
const 2307 "update_3rd_derivatives")));
2308 Assert(fe_values->present_cell.get() !=
nullptr,
2309 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2311 fe_values->present_cell->n_dofs_for_dof_handler());
2315 fe_values->dofs_per_cell);
2316 fe_values->present_cell->get_interpolated_dof_values(fe_function,
2318 internal::do_function_derivatives<3, dim, spacedim>(
2319 make_array_view(dof_values.begin(), dof_values.end()),
2320 fe_values->finite_element_output.shape_3rd_derivatives,
2321 shape_function_data,
2327 template <
int dim,
int spacedim>
2328 template <
class InputVector>
2331 const InputVector & dof_values,
2337 "update_3rd_derivatives")));
2338 Assert(fe_values->present_cell.get() !=
nullptr,
2339 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2342 internal::do_function_derivatives<3, dim, spacedim>(
2343 make_array_view(dof_values.begin(), dof_values.end()),
2344 fe_values->finite_element_output.shape_3rd_derivatives,
2345 shape_function_data,
2351 template <
int dim,
int spacedim>
2352 template <
class InputVector>
2355 const InputVector &fe_function,
2357 typename ProductType<value_type, typename InputVector::value_type>::type>
2363 Assert(fe_values->present_cell.get() !=
nullptr,
2364 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2366 fe_values->present_cell->n_dofs_for_dof_handler());
2370 fe_values->dofs_per_cell);
2371 fe_values->present_cell->get_interpolated_dof_values(fe_function,
2373 internal::do_function_values<dim, spacedim>(
2374 make_array_view(dof_values.begin(), dof_values.end()),
2375 fe_values->finite_element_output.shape_values,
2376 shape_function_data,
2382 template <
int dim,
int spacedim>
2383 template <
class InputVector>
2386 const InputVector &dof_values,
2394 Assert(fe_values->present_cell.get() !=
nullptr,
2395 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2398 internal::do_function_values<dim, spacedim>(
2399 make_array_view(dof_values.begin(), dof_values.end()),
2400 fe_values->finite_element_output.shape_values,
2401 shape_function_data,
2407 template <
int dim,
int spacedim>
2408 template <
class InputVector>
2411 const InputVector &fe_function,
2413 typename InputVector::value_type>::type>
2418 "update_gradients")));
2419 Assert(fe_values->present_cell.get() !=
nullptr,
2420 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2422 fe_values->present_cell->n_dofs_for_dof_handler());
2427 fe_values->dofs_per_cell);
2428 fe_values->present_cell->get_interpolated_dof_values(fe_function,
2430 internal::do_function_divergences<dim, spacedim>(
2431 make_array_view(dof_values.begin(), dof_values.end()),
2432 fe_values->finite_element_output.shape_gradients,
2433 shape_function_data,
2439 template <
int dim,
int spacedim>
2440 template <
class InputVector>
2444 const InputVector &dof_values,
2451 "update_gradients")));
2452 Assert(fe_values->present_cell.get() !=
nullptr,
2453 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2456 internal::do_function_divergences<dim, spacedim>(
2457 make_array_view(dof_values.begin(), dof_values.end()),
2458 fe_values->finite_element_output.shape_gradients,
2459 shape_function_data,
2465 template <
int dim,
int spacedim>
2466 template <
class InputVector>
2469 const InputVector &fe_function,
2471 typename ProductType<value_type, typename InputVector::value_type>::type>
2477 Assert(fe_values->present_cell.get() !=
nullptr,
2478 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2480 fe_values->present_cell->n_dofs_for_dof_handler());
2484 fe_values->dofs_per_cell);
2485 fe_values->present_cell->get_interpolated_dof_values(fe_function,
2487 internal::do_function_values<dim, spacedim>(
2488 make_array_view(dof_values.begin(), dof_values.end()),
2489 fe_values->finite_element_output.shape_values,
2490 shape_function_data,
2496 template <
int dim,
int spacedim>
2497 template <
class InputVector>
2500 const InputVector &dof_values,
2508 Assert(fe_values->present_cell.get() !=
nullptr,
2509 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2512 internal::do_function_values<dim, spacedim>(
2513 make_array_view(dof_values.begin(), dof_values.end()),
2514 fe_values->finite_element_output.shape_values,
2515 shape_function_data,
2521 template <
int dim,
int spacedim>
2522 template <
class InputVector>
2525 const InputVector &fe_function,
2527 typename InputVector::value_type>::type>
2532 "update_gradients")));
2533 Assert(fe_values->present_cell.get() !=
nullptr,
2534 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2536 fe_values->present_cell->n_dofs_for_dof_handler());
2541 fe_values->dofs_per_cell);
2542 fe_values->present_cell->get_interpolated_dof_values(fe_function,
2544 internal::do_function_divergences<dim, spacedim>(
2545 make_array_view(dof_values.begin(), dof_values.end()),
2546 fe_values->finite_element_output.shape_gradients,
2547 shape_function_data,
2553 template <
int dim,
int spacedim>
2554 template <
class InputVector>
2557 const InputVector &dof_values,
2564 "update_gradients")));
2565 Assert(fe_values->present_cell.get() !=
nullptr,
2566 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2569 internal::do_function_divergences<dim, spacedim>(
2570 make_array_view(dof_values.begin(), dof_values.end()),
2571 fe_values->finite_element_output.shape_gradients,
2572 shape_function_data,
2578 template <
int dim,
int spacedim>
2579 template <
class InputVector>
2582 const InputVector &fe_function,
2584 typename InputVector::value_type>::type>
2589 "update_gradients")));
2590 Assert(fe_values->present_cell.get() !=
nullptr,
2591 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2593 fe_values->present_cell->n_dofs_for_dof_handler());
2598 fe_values->dofs_per_cell);
2599 fe_values->present_cell->get_interpolated_dof_values(fe_function,
2601 internal::do_function_gradients<dim, spacedim>(
2602 make_array_view(dof_values.begin(), dof_values.end()),
2603 fe_values->finite_element_output.shape_gradients,
2604 shape_function_data,
2610 template <
int dim,
int spacedim>
2611 template <
class InputVector>
2614 const InputVector &dof_values,
2621 "update_gradients")));
2622 Assert(fe_values->present_cell.get() !=
nullptr,
2623 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
2626 internal::do_function_gradients<dim, spacedim>(
2627 make_array_view(dof_values.begin(), dof_values.end()),
2628 fe_values->finite_element_output.shape_gradients,
2629 shape_function_data,
2640 template <
int dim,
int spacedim>
2649 scalars.resize(n_scalars);
2650 for (
unsigned int component = 0; component < n_scalars; ++component)
2654 scalars[component].ScalarView::~ScalarView();
2656 new (&scalars[component])
2663 const unsigned int n_vectors =
2665 vectors.resize(n_vectors);
2666 for (
unsigned int component = 0; component < n_vectors; ++component)
2670 vectors[component].VectorView::~VectorView();
2672 new (&vectors[component])
2677 const unsigned int n_symmetric_second_order_tensors =
2681 symmetric_second_order_tensors.resize(n_symmetric_second_order_tensors);
2682 for (
unsigned int component = 0;
2683 component < n_symmetric_second_order_tensors;
2687 using SymmetricTensorView =
2689 symmetric_second_order_tensors[component]
2690 .SymmetricTensorView::~SymmetricTensorView();
2692 new (&symmetric_second_order_tensors[component])
2699 const unsigned int n_second_order_tensors =
2702 second_order_tensors.resize(n_second_order_tensors);
2703 for (
unsigned int component = 0; component < n_second_order_tensors;
2708 second_order_tensors[component].TensorView::~TensorView();
2710 new (&second_order_tensors[component])
2721 template <
int dim,
int spacedim>
2729 virtual ~CellIteratorBase() =
default;
2745 n_dofs_for_dof_handler()
const = 0;
2747 #include "fe_values.decl.1.inst" 2754 get_interpolated_dof_values(
const IndexSet & in,
2755 Vector<IndexSet::value_type> &out)
const = 0;
2767 template <
int dim,
int spacedim>
2768 template <
typename CI>
2776 CellIterator(
const CI &cell);
2792 n_dofs_for_dof_handler()
const override;
2794 #include "fe_values.decl.2.inst" 2801 get_interpolated_dof_values(
const IndexSet & in,
2802 Vector<IndexSet::value_type> &out)
const override;
2832 template <
int dim,
int spacedim>
2858 n_dofs_for_dof_handler()
const override;
2860 #include "fe_values.decl.2.inst" 2867 get_interpolated_dof_values(
const IndexSet & in,
2868 Vector<IndexSet::value_type> &out)
const override;
2889 template <
int dim,
int spacedim>
2890 template <
typename CI>
2897 template <
int dim,
int spacedim>
2898 template <
typename CI>
2907 template <
int dim,
int spacedim>
2908 template <
typename CI>
2912 return cell->get_dof_handler().n_dofs();
2917 #include "fe_values.impl.1.inst" 2921 template <
int dim,
int spacedim>
2922 template <
typename CI>
2926 Vector<IndexSet::value_type> &out)
const 2930 std::vector<types::global_dof_index> dof_indices(
2931 cell->get_fe().dofs_per_cell);
2932 cell->get_dof_indices(dof_indices);
2934 for (
unsigned int i = 0; i <
cell->get_fe().dofs_per_cell; ++i)
2935 out[i] = (in.
is_element(dof_indices[i]) ? 1 : 0);
2941 template <
int dim,
int spacedim>
2943 spacedim>::TriaCellIterator::message_string =
2944 (
"You have previously called the FEValues::reinit function with a\n" 2945 "cell iterator of type Triangulation<dim,spacedim>::cell_iterator. However,\n" 2946 "when you do this, you cannot call some functions in the FEValues\n" 2947 "class, such as the get_function_values/gradients/hessians/third_derivatives\n" 2948 "functions. If you need these functions, then you need to call\n" 2949 "FEValues::reinit with an iterator type that allows to extract\n" 2950 "degrees of freedom, such as DoFHandler<dim,spacedim>::cell_iterator.");
2954 template <
int dim,
int spacedim>
2962 template <
int dim,
int spacedim>
2971 template <
int dim,
int spacedim>
2981 #include "fe_values.impl.2.inst" 2985 template <
int dim,
int spacedim>
2989 Vector<IndexSet::value_type> &)
const 2998 namespace FEValuesImplementation
3000 template <
int dim,
int spacedim>
3007 this->quadrature_points.resize(
3008 n_quadrature_points,
3012 this->JxW_values.resize(n_quadrature_points,
3013 numbers::signaling_nan<double>());
3016 this->jacobians.resize(
3017 n_quadrature_points,
3021 this->jacobian_grads.resize(
3022 n_quadrature_points,
3026 this->jacobian_pushed_forward_grads.resize(
3030 this->jacobian_2nd_derivatives.resize(
3031 n_quadrature_points,
3035 this->jacobian_pushed_forward_2nd_derivatives.resize(
3039 this->jacobian_3rd_derivatives.resize(n_quadrature_points);
3042 this->jacobian_pushed_forward_3rd_derivatives.resize(
3046 this->inverse_jacobians.resize(
3047 n_quadrature_points,
3051 this->boundary_forms.resize(
3055 this->normal_vectors.resize(
3061 template <
int dim,
int spacedim>
3072 jacobian_pushed_forward_2nd_derivatives) +
3075 jacobian_pushed_forward_3rd_derivatives) +
3084 template <
int dim,
int spacedim>
3094 this->shape_function_to_row_table =
3095 ::internal::make_shape_function_to_row_table(fe);
3099 unsigned int n_nonzero_shape_components = 0;
3109 this->shape_values.reinit(n_nonzero_shape_components,
3110 n_quadrature_points);
3111 this->shape_values.fill(numbers::signaling_nan<double>());
3116 this->shape_gradients.reinit(n_nonzero_shape_components,
3117 n_quadrature_points);
3118 this->shape_gradients.fill(
3124 this->shape_hessians.reinit(n_nonzero_shape_components,
3125 n_quadrature_points);
3126 this->shape_hessians.fill(
3132 this->shape_3rd_derivatives.reinit(n_nonzero_shape_components,
3133 n_quadrature_points);
3134 this->shape_3rd_derivatives.fill(
3141 template <
int dim,
int spacedim>
3160 template <
int dim,
int spacedim>
3162 const unsigned int n_q_points,
3168 , dofs_per_cell(dofs_per_cell)
3169 , mapping(&mapping, typeid(*this).name())
3170 , fe(&fe, typeid(*this).name())
3175 ExcMessage(
"There is nothing useful you can do with an FEValues " 3176 "object when using a quadrature formula with zero " 3177 "quadrature points!"));
3183 template <
int dim,
int spacedim>
3201 template <
typename Number,
typename Number2>
3203 do_function_values(
const Number2 * dof_values_ptr,
3204 const ::Table<2, double> &shape_values,
3205 std::vector<Number> & values)
3210 dofs_per_cell > 0 ? shape_values.n_cols() : values.size();
3214 std::fill_n(values.begin(),
3225 for (
unsigned int shape_func = 0; shape_func <
dofs_per_cell; ++shape_func)
3227 const Number2 value = dof_values_ptr[shape_func];
3235 const double *shape_value_ptr = &shape_values(shape_func, 0);
3237 values[point] += value * (*shape_value_ptr++);
3243 template <
int dim,
int spacedim,
typename VectorType>
3246 const typename VectorType::value_type *dof_values_ptr,
3247 const ::Table<2, double> & shape_values,
3249 const std::vector<unsigned int> & shape_function_to_row_table,
3251 const bool quadrature_points_fastest =
false,
3252 const unsigned int component_multiple = 1)
3254 using Number =
typename VectorType::value_type;
3256 for (
unsigned int i = 0; i < values.
size(); ++i)
3257 std::fill_n(values[i].begin(),
3259 typename VectorType::value_type());
3264 if (dofs_per_cell == 0)
3271 const unsigned result_components = n_components * component_multiple;
3272 (void)result_components;
3273 if (quadrature_points_fastest)
3276 for (
unsigned int i = 0; i < values.
size(); ++i)
3282 for (
unsigned int i = 0; i < values.
size(); ++i)
3289 for (
unsigned int mc = 0; mc < component_multiple; ++mc)
3290 for (
unsigned int shape_func = 0; shape_func <
dofs_per_cell;
3293 const Number &value = dof_values_ptr[shape_func + mc *
dofs_per_cell];
3297 if (::internal::CheckForZero<Number>::value(value) ==
true)
3302 const unsigned int comp =
3305 const unsigned int row =
3306 shape_function_to_row_table[shape_func * n_components + comp];
3308 const double *shape_value_ptr = &shape_values(row, 0);
3310 if (quadrature_points_fastest)
3312 VectorType &values_comp = values[comp];
3315 values_comp[point] += value * (*shape_value_ptr++);
3320 values[point][comp] += value * (*shape_value_ptr++);
3323 for (
unsigned int c = 0; c < n_components; ++c)
3328 const unsigned int row =
3329 shape_function_to_row_table[shape_func * n_components + c];
3331 const double * shape_value_ptr = &shape_values(row, 0);
3332 const unsigned int comp = c + mc * n_components;
3334 if (quadrature_points_fastest)
3336 VectorType &values_comp = values[comp];
3339 values_comp[point] += value * (*shape_value_ptr++);
3344 values[point][comp] += value * (*shape_value_ptr++);
3353 template <
int order,
int spacedim,
typename Number>
3355 do_function_derivatives(
3356 const Number * dof_values_ptr,
3360 const unsigned int dofs_per_cell = shape_derivatives.size()[0];
3362 dofs_per_cell > 0 ? shape_derivatives[0].size() : derivatives.size();
3366 std::fill_n(derivatives.begin(),
3377 for (
unsigned int shape_func = 0; shape_func <
dofs_per_cell; ++shape_func)
3379 const Number &value = dof_values_ptr[shape_func];
3383 if (::internal::CheckForZero<Number>::value(value) ==
true)
3387 &shape_derivatives[shape_func][0];
3389 derivatives[point] += value * (*shape_derivative_ptr++);
3395 template <
int order,
int dim,
int spacedim,
typename Number>
3397 do_function_derivatives(
3398 const Number * dof_values_ptr,
3401 const std::vector<unsigned int> &shape_function_to_row_table,
3403 const bool quadrature_points_fastest =
false,
3404 const unsigned int component_multiple = 1)
3407 for (
unsigned int i = 0; i < derivatives.size(); ++i)
3408 std::fill_n(derivatives[i].begin(),
3409 derivatives[i].size(),
3415 if (dofs_per_cell == 0)
3423 const unsigned result_components = n_components * component_multiple;
3424 (void)result_components;
3425 if (quadrature_points_fastest)
3428 for (
unsigned int i = 0; i < derivatives.size(); ++i)
3434 for (
unsigned int i = 0; i < derivatives.size(); ++i)
3441 for (
unsigned int mc = 0; mc < component_multiple; ++mc)
3442 for (
unsigned int shape_func = 0; shape_func <
dofs_per_cell;
3445 const Number &value = dof_values_ptr[shape_func + mc *
dofs_per_cell];
3449 if (::internal::CheckForZero<Number>::value(value) ==
true)
3454 const unsigned int comp =
3457 const unsigned int row =
3458 shape_function_to_row_table[shape_func * n_components + comp];
3461 &shape_derivatives[row][0];
3463 if (quadrature_points_fastest)
3466 derivatives[comp][point] += value * (*shape_derivative_ptr++);
3470 derivatives[point][comp] += value * (*shape_derivative_ptr++);
3473 for (
unsigned int c = 0; c < n_components; ++c)
3478 const unsigned int row =
3479 shape_function_to_row_table[shape_func * n_components + c];
3482 &shape_derivatives[row][0];
3483 const unsigned int comp = c + mc * n_components;
3485 if (quadrature_points_fastest)
3488 derivatives[comp][point] +=
3489 value * (*shape_derivative_ptr++);
3493 derivatives[point][comp] +=
3494 value * (*shape_derivative_ptr++);
3501 template <
int spacedim,
typename Number,
typename Number2>
3503 do_function_laplacians(
3504 const Number2 * dof_values_ptr,
3506 std::vector<Number> & laplacians)
3508 const unsigned int dofs_per_cell = shape_hessians.size()[0];
3510 dofs_per_cell > 0 ? shape_hessians[0].size() : laplacians.size();
3514 std::fill_n(laplacians.begin(),
3521 for (
unsigned int shape_func = 0; shape_func <
dofs_per_cell; ++shape_func)
3523 const Number2 value = dof_values_ptr[shape_func];
3532 &shape_hessians[shape_func][0];
3534 laplacians[point] += value *
trace(*shape_hessian_ptr++);
3540 template <
int dim,
int spacedim,
typename VectorType,
typename Number>
3542 do_function_laplacians(
3543 const Number * dof_values_ptr,
3546 const std::vector<unsigned int> & shape_function_to_row_table,
3547 std::vector<VectorType> & laplacians,
3548 const bool quadrature_points_fastest =
false,
3549 const unsigned int component_multiple = 1)
3552 for (
unsigned int i = 0; i < laplacians.size(); ++i)
3553 std::fill_n(laplacians[i].begin(),
3554 laplacians[i].size(),
3555 typename VectorType::value_type());
3560 if (dofs_per_cell == 0)
3568 const unsigned result_components = n_components * component_multiple;
3569 (void)result_components;
3570 if (quadrature_points_fastest)
3573 for (
unsigned int i = 0; i < laplacians.size(); ++i)
3579 for (
unsigned int i = 0; i < laplacians.size(); ++i)
3586 for (
unsigned int mc = 0; mc < component_multiple; ++mc)
3587 for (
unsigned int shape_func = 0; shape_func <
dofs_per_cell;
3590 const Number &value = dof_values_ptr[shape_func + mc *
dofs_per_cell];
3594 if (::internal::CheckForZero<Number>::value(value) ==
true)
3599 const unsigned int comp =
3602 const unsigned int row =
3603 shape_function_to_row_table[shape_func * n_components + comp];
3606 &shape_hessians[row][0];
3607 if (quadrature_points_fastest)
3609 VectorType &laplacians_comp = laplacians[comp];
3612 laplacians_comp[point] +=
3613 value *
trace(*shape_hessian_ptr++);
3618 laplacians[point][comp] +=
3619 value *
trace(*shape_hessian_ptr++);
3622 for (
unsigned int c = 0; c < n_components; ++c)
3627 const unsigned int row =
3628 shape_function_to_row_table[shape_func * n_components + c];
3631 &shape_hessians[row][0];
3632 const unsigned int comp = c + mc * n_components;
3634 if (quadrature_points_fastest)
3636 VectorType &laplacians_comp = laplacians[comp];
3639 laplacians_comp[point] +=
3640 value *
trace(*shape_hessian_ptr++);
3645 laplacians[point][comp] +=
3646 value *
trace(*shape_hessian_ptr++);
3654 template <
int dim,
int spacedim>
3655 template <
class InputVector>
3658 const InputVector & fe_function,
3659 std::vector<typename InputVector::value_type> &values)
const 3661 using Number =
typename InputVector::value_type;
3666 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
3671 present_cell->get_interpolated_dof_values(fe_function, dof_values);
3672 internal::do_function_values(dof_values.begin(),
3679 template <
int dim,
int spacedim>
3680 template <
class InputVector>
3683 const InputVector & fe_function,
3684 const VectorSlice<
const std::vector<types::global_dof_index>> &indices,
3685 std::vector<typename InputVector::value_type> & values)
const 3687 using Number =
typename InputVector::value_type;
3693 boost::container::small_vector<Number, 200> dof_values(
dofs_per_cell);
3695 dof_values[i] = internal::get_vector_element(fe_function, indices[i]);
3696 internal::do_function_values(dof_values.data(),
3703 template <
int dim,
int spacedim>
3704 template <
class InputVector>
3707 const InputVector & fe_function,
3708 std::vector<Vector<typename InputVector::value_type>> &values)
const 3710 using Number =
typename InputVector::value_type;
3712 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
3720 present_cell->get_interpolated_dof_values(fe_function, dof_values);
3721 internal::do_function_values(
3726 make_array_view(values.begin(), values.end()));
3731 template <
int dim,
int spacedim>
3732 template <
class InputVector>
3735 const InputVector & fe_function,
3736 const VectorSlice<
const std::vector<types::global_dof_index>> &indices,
3737 std::vector<Vector<typename InputVector::value_type>> & values)
const 3739 using Number =
typename InputVector::value_type;
3747 boost::container::small_vector<Number, 200> dof_values(
dofs_per_cell);
3749 dof_values[i] = internal::get_vector_element(fe_function, indices[i]);
3750 internal::do_function_values(
3755 make_array_view(values.begin(), values.end()),
3762 template <
int dim,
int spacedim>
3763 template <
class InputVector>
3766 const InputVector & fe_function,
3767 const VectorSlice<
const std::vector<types::global_dof_index>> &indices,
3768 VectorSlice<std::vector<std::vector<typename InputVector::value_type>>>
3770 bool quadrature_points_fastest)
const 3772 using Number =
typename InputVector::value_type;
3781 boost::container::small_vector<Number, 200> dof_values(indices.size());
3782 for (
unsigned int i = 0; i < indices.size(); ++i)
3783 dof_values[i] = internal::get_vector_element(fe_function, indices[i]);
3784 internal::do_function_values(
3789 make_array_view(values.begin(), values.end()),
3790 quadrature_points_fastest,
3796 template <
int dim,
int spacedim>
3797 template <
class InputVector>
3800 const InputVector &fe_function,
3804 using Number =
typename InputVector::value_type;
3809 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
3814 present_cell->get_interpolated_dof_values(fe_function, dof_values);
3815 internal::do_function_derivatives(dof_values.begin(),
3822 template <
int dim,
int spacedim>
3823 template <
class InputVector>
3826 const InputVector & fe_function,
3827 const VectorSlice<
const std::vector<types::global_dof_index>> &indices,
3831 using Number =
typename InputVector::value_type;
3837 boost::container::small_vector<Number, 200> dof_values(
dofs_per_cell);
3839 dof_values[i] = internal::get_vector_element(fe_function, indices[i]);
3840 internal::do_function_derivatives(dof_values.data(),
3847 template <
int dim,
int spacedim>
3848 template <
class InputVector>
3851 const InputVector &fe_function,
3856 using Number =
typename InputVector::value_type;
3860 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
3865 present_cell->get_interpolated_dof_values(fe_function, dof_values);
3866 internal::do_function_derivatives(
3871 make_array_view(gradients.begin(), gradients.end()));
3876 template <
int dim,
int spacedim>
3877 template <
class InputVector>
3880 const InputVector & fe_function,
3881 const VectorSlice<
const std::vector<types::global_dof_index>> &indices,
3885 bool quadrature_points_fastest)
const 3887 using Number =
typename InputVector::value_type;
3895 boost::container::small_vector<Number, 200> dof_values(indices.size());
3896 for (
unsigned int i = 0; i < indices.size(); ++i)
3897 dof_values[i] = internal::get_vector_element(fe_function, indices[i]);
3898 internal::do_function_derivatives(
3903 make_array_view(gradients.begin(), gradients.end()),
3904 quadrature_points_fastest,
3910 template <
int dim,
int spacedim>
3911 template <
class InputVector>
3914 const InputVector &fe_function,
3918 using Number =
typename InputVector::value_type;
3923 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
3928 present_cell->get_interpolated_dof_values(fe_function, dof_values);
3929 internal::do_function_derivatives(dof_values.begin(),
3936 template <
int dim,
int spacedim>
3937 template <
class InputVector>
3940 const InputVector & fe_function,
3941 const VectorSlice<
const std::vector<types::global_dof_index>> &indices,
3945 using Number =
typename InputVector::value_type;
3951 boost::container::small_vector<Number, 200> dof_values(
dofs_per_cell);
3953 dof_values[i] = internal::get_vector_element(fe_function, indices[i]);
3954 internal::do_function_derivatives(dof_values.data(),
3961 template <
int dim,
int spacedim>
3962 template <
class InputVector>
3965 const InputVector &fe_function,
3969 bool quadrature_points_fastest)
const 3971 using Number =
typename InputVector::value_type;
3975 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
3980 present_cell->get_interpolated_dof_values(fe_function, dof_values);
3981 internal::do_function_derivatives(
3986 make_array_view(hessians.begin(), hessians.end()),
3987 quadrature_points_fastest);
3992 template <
int dim,
int spacedim>
3993 template <
class InputVector>
3996 const InputVector & fe_function,
3997 const VectorSlice<
const std::vector<types::global_dof_index>> &indices,
4001 bool quadrature_points_fastest)
const 4003 using Number =
typename InputVector::value_type;
4009 boost::container::small_vector<Number, 200> dof_values(indices.size());
4010 for (
unsigned int i = 0; i < indices.size(); ++i)
4011 dof_values[i] = internal::get_vector_element(fe_function, indices[i]);
4012 internal::do_function_derivatives(
4017 make_array_view(hessians.begin(), hessians.end()),
4018 quadrature_points_fastest,
4024 template <
int dim,
int spacedim>
4025 template <
class InputVector>
4028 const InputVector & fe_function,
4029 std::vector<typename InputVector::value_type> &laplacians)
const 4031 using Number =
typename InputVector::value_type;
4036 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
4041 present_cell->get_interpolated_dof_values(fe_function, dof_values);
4042 internal::do_function_laplacians(dof_values.begin(),
4049 template <
int dim,
int spacedim>
4050 template <
class InputVector>
4053 const InputVector & fe_function,
4054 const VectorSlice<
const std::vector<types::global_dof_index>> &indices,
4055 std::vector<typename InputVector::value_type> &laplacians)
const 4057 using Number =
typename InputVector::value_type;
4063 boost::container::small_vector<Number, 200> dof_values(
dofs_per_cell);
4065 dof_values[i] = internal::get_vector_element(fe_function, indices[i]);
4066 internal::do_function_laplacians(dof_values.data(),
4073 template <
int dim,
int spacedim>
4074 template <
class InputVector>
4077 const InputVector & fe_function,
4078 std::vector<Vector<typename InputVector::value_type>> &laplacians)
const 4080 using Number =
typename InputVector::value_type;
4082 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
4089 present_cell->get_interpolated_dof_values(fe_function, dof_values);
4090 internal::do_function_laplacians(
4100 template <
int dim,
int spacedim>
4101 template <
class InputVector>
4104 const InputVector & fe_function,
4105 const VectorSlice<
const std::vector<types::global_dof_index>> &indices,
4106 std::vector<Vector<typename InputVector::value_type>> &laplacians)
const 4108 using Number =
typename InputVector::value_type;
4116 boost::container::small_vector<Number, 200> dof_values(indices.size());
4117 for (
unsigned int i = 0; i < indices.size(); ++i)
4118 dof_values[i] = internal::get_vector_element(fe_function, indices[i]);
4119 internal::do_function_laplacians(
4131 template <
int dim,
int spacedim>
4132 template <
class InputVector>
4135 const InputVector & fe_function,
4136 const VectorSlice<
const std::vector<types::global_dof_index>> &indices,
4137 std::vector<std::vector<typename InputVector::value_type>> & laplacians,
4138 bool quadrature_points_fastest)
const 4140 using Number =
typename InputVector::value_type;
4146 boost::container::small_vector<Number, 200> dof_values(indices.size());
4147 for (
unsigned int i = 0; i < indices.size(); ++i)
4148 dof_values[i] = internal::get_vector_element(fe_function, indices[i]);
4149 internal::do_function_laplacians(
4155 quadrature_points_fastest,
4161 template <
int dim,
int spacedim>
4162 template <
class InputVector>
4165 const InputVector &fe_function,
4167 &third_derivatives)
const 4169 using Number =
typename InputVector::value_type;
4174 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
4179 present_cell->get_interpolated_dof_values(fe_function, dof_values);
4180 internal::do_function_derivatives(
4188 template <
int dim,
int spacedim>
4189 template <
class InputVector>
4192 const InputVector & fe_function,
4193 const VectorSlice<
const std::vector<types::global_dof_index>> &indices,
4195 &third_derivatives)
const 4197 using Number =
typename InputVector::value_type;
4203 boost::container::small_vector<Number, 200> dof_values(
dofs_per_cell);
4205 dof_values[i] = internal::get_vector_element(fe_function, indices[i]);
4206 internal::do_function_derivatives(
4214 template <
int dim,
int spacedim>
4215 template <
class InputVector>
4218 const InputVector &fe_function,
4221 & third_derivatives,
4222 bool quadrature_points_fastest)
const 4224 using Number =
typename InputVector::value_type;
4228 ExcMessage(
"FEValues object is not reinit'ed to any cell"));
4233 present_cell->get_interpolated_dof_values(fe_function, dof_values);
4234 internal::do_function_derivatives(
4239 make_array_view(third_derivatives.begin(), third_derivatives.end()),
4240 quadrature_points_fastest);
4245 template <
int dim,
int spacedim>
4246 template <
class InputVector>
4249 const InputVector & fe_function,
4250 const VectorSlice<
const std::vector<types::global_dof_index>> &indices,
4254 bool quadrature_points_fastest)
const 4256 using Number =
typename InputVector::value_type;
4262 boost::container::small_vector<Number, 200> dof_values(indices.size());
4263 for (
unsigned int i = 0; i < indices.size(); ++i)
4264 dof_values[i] = internal::get_vector_element(fe_function, indices[i]);
4265 internal::do_function_derivatives(
4270 make_array_view(third_derivatives.begin(), third_derivatives.end()),
4271 quadrature_points_fastest,
4277 template <
int dim,
int spacedim>
4286 template <
int dim,
int spacedim>
4287 const std::vector<Tensor<1, spacedim>> &
4292 "update_normal_vectors")));
4298 template <
int dim,
int spacedim>
4299 const std::vector<Tensor<1, spacedim>> &
4304 "update_normal_vectors")));
4311 template <
int dim,
int spacedim>
4331 template <
int dim,
int spacedim>
4343 flags |=
mapping->requires_update_flags(flags);
4350 template <
int dim,
int spacedim>
4368 template <
int dim,
int spacedim>
4375 if (&cell->get_triangulation() !=
4379 ->get_triangulation())
4388 cell->get_triangulation().signals.any_change.connect(std::bind(
4392 cell->get_triangulation().signals.mesh_movement.connect(std::bind(
4403 cell->get_triangulation().signals.post_refinement.connect(std::bind(
4407 cell->get_triangulation().signals.mesh_movement.connect(std::bind(
4415 template <
int dim,
int spacedim>
4451 (cell->is_translation_of(
4461 ->direction_flag() != cell->direction_flag())
4470 template <
int dim,
int spacedim>
4479 template <
int dim,
int spacedim>
4484 template <
int dim,
int spacedim>
4489 template <
int dim,
int spacedim>
4494 template <
int dim,
int spacedim>
4511 template <
int dim,
int spacedim>
4527 template <
int dim,
int spacedim>
4533 if (dim != spacedim - 1)
4535 ExcMessage(
"You can only pass the 'update_normal_vectors' " 4536 "flag to FEFaceValues or FESubfaceValues objects, " 4537 "but not to an FEValues object unless the " 4538 "triangulation it refers to is embedded in a higher " 4539 "dimensional space."));
4553 std::unique_ptr<typename FiniteElement<dim, spacedim>::InternalDataBase>>
4561 std::unique_ptr<typename Mapping<dim, spacedim>::InternalDataBase>>
4563 if (flags & update_mapping)
4569 this->update_flags = flags;
4572 this->
fe_data = std::move(fe_get_data.return_value());
4573 if (flags & update_mapping)
4574 this->
mapping_data = std::move(mapping_get_data.return_value());
4588 template <
typename Type,
typename Po
inter,
typename Iterator>
4590 reset_pointer_in_place_if_possible(std::unique_ptr<Pointer> &
present_cell,
4591 const Iterator & new_cell)
4596 if (present_cell.get() && (
typeid(*present_cell.get()) ==
typeid(Type)))
4599 static_cast<const Type *
>(present_cell.get())->~Type();
4602 new (
const_cast<void *
>(
static_cast<const void *
>(present_cell.get())))
4607 present_cell = std_cxx14::make_unique<Type>(new_cell);
4613 template <
int dim,
int spacedim>
4623 reset_pointer_in_place_if_possible<
4635 template <
int dim,
int spacedim>
4636 template <
template <
int,
int>
class DoFHandlerType,
bool lda>
4650 reset_pointer_in_place_if_possible<
4663 template <
int dim,
int spacedim>
4697 template <
int dim,
int spacedim>
4709 template <
int dim,
int spacedim>
4711 const unsigned int n_q_points,
4722 , present_face_index(
numbers::invalid_unsigned_int)
4723 , quadrature(quadrature)
4728 template <
int dim,
int spacedim>
4729 const std::vector<Tensor<1, spacedim>> &
4734 "update_boundary_forms")));
4740 template <
int dim,
int spacedim>
4751 template <
int dim,
int spacedim>
4756 template <
int dim,
int spacedim>
4761 template <
int dim,
int spacedim>
4779 template <
int dim,
int spacedim>
4796 template <
int dim,
int spacedim>
4812 std::unique_ptr<typename FiniteElement<dim, spacedim>::InternalDataBase>>
4821 std::unique_ptr<typename Mapping<dim, spacedim>::InternalDataBase>>
4823 if (flags & update_mapping)
4829 this->update_flags = flags;
4832 this->
fe_data = std::move(fe_get_data.return_value());
4833 if (flags & update_mapping)
4834 this->
mapping_data = std::move(mapping_get_data.return_value());
4842 template <
int dim,
int spacedim>
4843 template <
template <
int,
int>
class DoFHandlerType,
bool lda>
4847 const unsigned int face_no)
4853 cell->get_dof_handler().get_fe(cell->active_fe_index())),
4860 reset_pointer_in_place_if_possible<
4873 template <
int dim,
int spacedim>
4877 const unsigned int face_no)
4883 reset_pointer_in_place_if_possible<
4895 template <
int dim,
int spacedim>
4927 template <
int dim,
int spacedim>
4932 template <
int dim,
int spacedim>
4937 template <
int dim,
int spacedim>
4955 template <
int dim,
int spacedim>
4972 template <
int dim,
int spacedim>
4989 std::unique_ptr<typename FiniteElement<dim, spacedim>::InternalDataBase>>
4998 std::unique_ptr<typename Mapping<dim, spacedim>::InternalDataBase>>
5000 if (flags & update_mapping)
5007 this->update_flags = flags;
5010 this->
fe_data = std::move(fe_get_data.return_value());
5011 if (flags & update_mapping)
5012 this->
mapping_data = std::move(mapping_get_data.return_value());
5020 template <
int dim,
int spacedim>
5021 template <
template <
int,
int>
class DoFHandlerType,
bool lda>
5025 const unsigned int face_no,
5026 const unsigned int subface_no)
5032 cell->get_dof_handler().get_fe(cell->active_fe_index())),
5040 Assert(cell->face(face_no)->has_children() ||
5041 subface_no < GeometryInfo<dim>::max_children_per_face,
5045 Assert(!cell->face(face_no)->has_children() ||
5046 subface_no < cell->face(face_no)->number_of_children(),
5049 cell->face(face_no)->number_of_children()));
5050 Assert(cell->has_children() ==
false,
5051 ExcMessage(
"You can't use subface data for cells that are " 5052 "already refined. Iterate over their children " 5053 "instead in these cases."));
5056 reset_pointer_in_place_if_possible<
5069 template <
int dim,
int spacedim>
5073 const unsigned int face_no,
5074 const unsigned int subface_no)
5078 Assert(subface_no < cell->face(face_no)->n_children(),
5079 ExcIndexRange(subface_no, 0, cell->face(face_no)->n_children()));
5082 reset_pointer_in_place_if_possible<
5094 template <
int dim,
int spacedim>
5097 const unsigned int subface_no)
5103 if (!cell->face(face_no)->has_children())
5114 switch (cell->subface_case(face_no))
5119 subface_index = cell->face(face_no)->child_index(subface_no);
5123 subface_index = cell->face(face_no)
5124 ->child(subface_no / 2)
5125 ->child_index(subface_no % 2);
5134 cell->face(face_no)->child(0)->child_index(subface_no);
5137 subface_index = cell->face(face_no)->child_index(1);
5148 subface_index = cell->face(face_no)->child_index(0);
5153 cell->face(face_no)->child(1)->child_index(subface_no - 1);
5192 #define SPLIT_INSTANTIATIONS_COUNT 6 5193 #ifndef SPLIT_INSTANTIATIONS_INDEX 5194 # define SPLIT_INSTANTIATIONS_INDEX 0 5196 #include "fe_values.inst" 5198 DEAL_II_NAMESPACE_CLOSE
Transformed quadrature weights.
void get_function_hessians_from_local_dof_values(const InputVector &dof_values, std::vector< typename OutputType< typename InputVector::value_type >::hessian_type > &hessians) const
virtual ~FEValuesBase() override
void get_function_values(const InputVector &fe_function, std::vector< typename InputVector::value_type > &values) const
void get_function_curls(const InputVector &fe_function, std::vector< typename ProductType< curl_type, typename InputVector::value_type >::type > &curls) const
void get_function_divergences(const InputVector &fe_function, std::vector< typename ProductType< divergence_type, typename InputVector::value_type >::type > &divergences) const
typename ProductType< Number, typename Vector< dim, spacedim >::curl_type >::type curl_type
virtual UpdateFlags requires_update_flags(const UpdateFlags update_flags) const =0
void get_function_laplacians(const InputVector &fe_function, std::vector< typename ProductType< value_type, typename InputVector::value_type >::type > &laplacians) const
void reinit(const TriaIterator< DoFCellAccessor< DoFHandlerType< dim, spacedim >, level_dof_access >> &cell, const unsigned int face_no, const unsigned int subface_no)
void get_function_values(const InputVector &fe_function, std::vector< typename ProductType< value_type, typename InputVector::value_type >::type > &values) const
static const unsigned int invalid_unsigned_int
std::unique_ptr< typename FiniteElement< dim, spacedim >::InternalDataBase > fe_data
CellSimilarity::Similarity cell_similarity
void get_function_values(const InputVector &fe_function, std::vector< typename ProductType< value_type, typename InputVector::value_type >::type > &values) const
typename ProductType< Number, typename Tensor< 2, dim, spacedim >::gradient_type >::type gradient_type
void get_function_values_from_local_dof_values(const InputVector &dof_values, std::vector< typename OutputType< typename InputVector::value_type >::value_type > &values) const
typename ProductType< Number, typename SymmetricTensor< 2, dim, spacedim >::value_type >::type value_type
void get_function_gradients_from_local_dof_values(const InputVector &dof_values, std::vector< typename OutputType< typename InputVector::value_type >::gradient_type > &gradients) const
#define AssertDimension(dim1, dim2)
void get_function_divergences(const InputVector &fe_function, std::vector< typename ProductType< divergence_type, typename InputVector::value_type >::type > &divergences) const
std::size_t memory_consumption() const
static constexpr unsigned int n_independent_components
static unsigned int component_to_unrolled_index(const TableIndices< rank_ > &indices)
unsigned int present_face_index
void get_function_hessians(const InputVector &fe_function, std::vector< typename ProductType< hessian_type, typename InputVector::value_type >::type > &hessians) const
void get_function_third_derivatives(const InputVector &fe_function, std::vector< Tensor< 3, spacedim, typename InputVector::value_type >> &third_derivatives) const
void get_function_third_derivatives_from_local_dof_values(const InputVector &dof_values, std::vector< typename OutputType< typename InputVector::value_type >::third_derivative_type > &third_derivatives) const
const SmartPointer< const FEValuesBase< dim, spacedim > > fe_values
void get_function_symmetric_gradients_from_local_dof_values(const InputVector &dof_values, std::vector< typename OutputType< typename InputVector::value_type >::symmetric_gradient_type > &symmetric_gradients) const
Task< RT > new_task(const std::function< RT()> &function)
const unsigned int dofs_per_cell
const unsigned int component
const Quadrature< dim-1 > quadrature
Number trace(const SymmetricTensor< 2, dim, Number > &d)
FEValuesBase(const unsigned int n_q_points, const unsigned int dofs_per_cell, const UpdateFlags update_flags, const Mapping< dim, spacedim > &mapping, const FiniteElement< dim, spacedim > &fe)
void get_function_gradients(const InputVector &fe_function, std::vector< Tensor< 1, spacedim, typename InputVector::value_type >> &gradients) const
void get_function_divergences_from_local_dof_values(const InputVector &dof_values, std::vector< typename OutputType< typename InputVector::value_type >::divergence_type > &divergences) const
static::ExceptionBase & ExcAccessToUninitializedField(std::string arg1)
Outer normal vector, not normalized.
typename ProductType< Number, typename Scalar< dim, spacedim >::hessian_type >::type hessian_type
std::unique_ptr< const CellIteratorBase > present_cell
static::ExceptionBase & ExcFEDontMatch()
Scalar & operator=(const Scalar< dim, spacedim > &)
TriaCellIterator(const typename Triangulation< dim, spacedim >::cell_iterator &cell)
Transformed quadrature points.
SymmetricTensor & operator=(const SymmetricTensor< rank_, dim, OtherNumber > &rhs)
void get_function_curls_from_local_dof_values(const InputVector &dof_values, std::vector< typename OutputType< typename InputVector::value_type >::curl_type > &curls) const
void do_reinit(const unsigned int face_no)
const Triangulation< dim, spacedim >::cell_iterator get_cell() const
typename ProductType< Number, typename Scalar< dim, spacedim >::value_type >::type value_type
void get_function_values_from_local_dof_values(const InputVector &dof_values, std::vector< typename OutputType< typename InputVector::value_type >::value_type > &values) const
bool is_primitive() const
void check_cell_similarity(const typename Triangulation< dim, spacedim >::cell_iterator &cell)
const SmartPointer< const Mapping< dim, spacedim >, FEValuesBase< dim, spacedim > > mapping
static::ExceptionBase & ExcIndexRange(int arg1, int arg2, int arg3)
void get_function_laplacians_from_local_dof_values(const InputVector &dof_values, std::vector< typename OutputType< typename InputVector::value_type >::laplacian_type > &laplacians) const
void get_function_third_derivatives(const InputVector &fe_function, std::vector< typename ProductType< third_derivative_type, typename InputVector::value_type >::type > &third_derivatives) const
Tensor & operator=(const Tensor< rank_, dim, OtherNumber > &rhs)
void get_function_symmetric_gradients(const InputVector &fe_function, std::vector< typename ProductType< symmetric_gradient_type, typename InputVector::value_type >::type > &symmetric_gradients) const
void get_function_gradients(const InputVector &fe_function, std::vector< typename ProductType< gradient_type, typename InputVector::value_type >::type > &gradients) const
::internal::FEValuesViews::Cache< dim, spacedim > fe_values_views_cache
void do_reinit(const unsigned int face_no, const unsigned int subface_no)
static TableIndices< rank_ > unrolled_to_component_indices(const unsigned int i)
unsigned long long int global_dof_index
void get_function_laplacians_from_local_dof_values(const InputVector &dof_values, std::vector< typename OutputType< typename InputVector::value_type >::laplacian_type > &laplacians) const
UpdateFlags compute_update_flags(const UpdateFlags update_flags) const
typename ProductType< Number, typename Vector< dim, spacedim >::gradient_type >::type gradient_type
void get_function_gradients_from_local_dof_values(const InputVector &dof_values, std::vector< typename OutputType< typename InputVector::value_type >::gradient_type > &gradients) const
void get_function_laplacians(const InputVector &fe_function, std::vector< typename InputVector::value_type > &laplacians) const
const Triangulation< dim, spacedim >::cell_iterator cell
typename ProductType< Number, typename Scalar< dim, spacedim >::gradient_type >::type gradient_type
typename ProductType< Number, typename Tensor< 2, dim, spacedim >::value_type >::type value_type
static::ExceptionBase & ExcMessage(std::string arg1)
void get_function_hessians(const InputVector &fe_function, std::vector< typename ProductType< hessian_type, typename InputVector::value_type >::type > &hessians) const
const std::vector< Tensor< 1, spacedim > > & get_boundary_forms() const
void get_function_divergences_from_local_dof_values(const InputVector &dof_values, std::vector< typename OutputType< typename InputVector::value_type >::divergence_type > &divergences) const
Third derivatives of shape functions.
void get_function_gradients(const InputVector &fe_function, std::vector< typename ProductType< gradient_type, typename InputVector::value_type >::type > &gradients) const
void get_function_hessians_from_local_dof_values(const InputVector &dof_values, std::vector< typename OutputType< typename InputVector::value_type >::hessian_type > &hessians) const
size_type size(const unsigned int i) const
#define Assert(cond, exc)
void get_function_third_derivatives(const InputVector &fe_function, std::vector< typename ProductType< third_derivative_type, typename InputVector::value_type >::type > &third_derivatives) const
unsigned int n_nonzero_components(const unsigned int i) const
static::ExceptionBase & ExcDimensionMismatch(std::size_t arg1, std::size_t arg2)
Abstract base class for mapping classes.
std::vector< ShapeFunctionData > shape_function_data
const Quadrature< dim > quadrature
const unsigned int first_vector_component
std::size_t memory_consumption() const
const FiniteElement< dim, spacedim > & get_fe() const
virtual types::global_dof_index n_dofs_for_dof_handler() const override
void get_function_gradients_from_local_dof_values(const InputVector &dof_values, std::vector< typename OutputType< typename InputVector::value_type >::gradient_type > &gradients) const
void get_function_values(const InputVector &fe_function, std::vector< typename ProductType< value_type, typename InputVector::value_type >::type > &values) const
void invalidate_present_cell()
const ComponentMask & get_nonzero_components(const unsigned int i) const
std::unique_ptr< typename Mapping< dim, spacedim >::InternalDataBase > mapping_data
Vector & operator=(const Vector< dim, spacedim > &)
SymmetricTensor< 2, dim, Number > symmetrize(const Tensor< 2, dim, Number > &t)
const std::vector< Tensor< 1, spacedim > > & get_normal_vectors() const
void get_function_divergences_from_local_dof_values(const InputVector &dof_values, std::vector< typename OutputType< typename InputVector::value_type >::divergence_type > &divergences) const
static const char *const message_string
unsigned int n_components() const
Second derivatives of shape functions.
void get_function_gradients(const InputVector &fe_function, std::vector< typename ProductType< gradient_type, typename InputVector::value_type >::type > &gradients) const
Gradient of volume element.
typename ProductType< Number, typename SymmetricTensor< 2, dim, spacedim >::divergence_type >::type divergence_type
static TableIndices< rank_ > unrolled_to_component_indices(const unsigned int i)
void reinit(const TriaIterator< DoFCellAccessor< DoFHandlerType< dim, spacedim >, level_dof_access >> &cell)
void get_function_values(const InputVector &fe_function, std::vector< typename ProductType< value_type, typename InputVector::value_type >::type > &values) const
const unsigned int dofs_per_cell
void get_function_values_from_local_dof_values(const InputVector &dof_values, std::vector< typename OutputType< typename InputVector::value_type >::value_type > &values) const
const unsigned int n_quadrature_points
boost::signals2::connection tria_listener_mesh_transform
typename ProductType< Number, typename Vector< dim, spacedim >::value_type >::type value_type
FEFaceValuesBase(const unsigned int n_q_points, const unsigned int dofs_per_cell, const UpdateFlags update_flags, const Mapping< dim, spacedim > &mapping, const FiniteElement< dim, spacedim > &fe, const Quadrature< dim-1 > &quadrature)
std::pair< unsigned int, unsigned int > system_to_component_index(const unsigned int index) const
typename ProductType< Number, typename Vector< dim, spacedim >::divergence_type >::type divergence_type
void initialize(const UpdateFlags update_flags)
typename ProductType< Number, typename Vector< dim, spacedim >::hessian_type >::type hessian_type
Shape function gradients.
void maybe_invalidate_previous_present_cell(const typename Triangulation< dim, spacedim >::cell_iterator &cell)
typename ProductType< Number, typename Tensor< 2, dim, spacedim >::divergence_type >::type divergence_type
void get_function_divergences(const InputVector &fe_function, std::vector< typename ProductType< divergence_type, typename InputVector::value_type >::type > &divergences) const
void initialize(const UpdateFlags update_flags)
const std::vector< Tensor< 1, spacedim > > & get_all_normal_vectors() const
static::ExceptionBase & ExcNotMultiple(int arg1, int arg2)
void get_function_laplacians(const InputVector &fe_function, std::vector< typename ProductType< value_type, typename InputVector::value_type >::type > &laplacians) const
static::ExceptionBase & ExcNotImplemented()
bool is_element(const size_type index) const
static unsigned int n_threads()
void reinit(const TriaIterator< DoFCellAccessor< DoFHandlerType< dim, spacedim >, level_dof_access >> &cell, const unsigned int face_no)
const SmartPointer< const FEValuesBase< dim, spacedim > > fe_values
boost::signals2::connection tria_listener_refinement
::internal::FEValuesImplementation::FiniteElementRelatedData< dim, spacedim > finite_element_output
typename ProductType< Number, typename Vector< dim, spacedim >::value_type >::type laplacian_type
void initialize(const UpdateFlags update_flags)
::internal::FEValuesImplementation::MappingRelatedData< dim, spacedim > mapping_output
FEValues(const Mapping< dim, spacedim > &mapping, const FiniteElement< dim, spacedim > &fe, const Quadrature< dim > &quadrature, const UpdateFlags update_flags)
const Mapping< dim, spacedim > & get_mapping() const
FESubfaceValues(const Mapping< dim, spacedim > &mapping, const FiniteElement< dim, spacedim > &fe, const Quadrature< dim-1 > &face_quadrature, const UpdateFlags update_flags)
typename ProductType< Number, typename Scalar< dim, spacedim >::value_type >::type laplacian_type
void get_function_values_from_local_dof_values(const InputVector &dof_values, std::vector< typename OutputType< typename InputVector::value_type >::value_type > &values) const
FEFaceValues(const Mapping< dim, spacedim > &mapping, const FiniteElement< dim, spacedim > &fe, const Quadrature< dim-1 > &quadrature, const UpdateFlags update_flags)
TriaIterator< CellAccessor< dim, spacedim >> cell_iterator
CellSimilarity::Similarity get_cell_similarity() const
void get_function_third_derivatives_from_local_dof_values(const InputVector &dof_values, std::vector< typename OutputType< typename InputVector::value_type >::third_derivative_type > &third_derivatives) const
std::vector< ShapeFunctionData > shape_function_data
std::enable_if< std::is_fundamental< T >::value, std::size_t >::type memory_consumption(const T &t)
std::size_t memory_consumption() const
static::ExceptionBase & ExcInternalError()
const SmartPointer< const FiniteElement< dim, spacedim >, FEValuesBase< dim, spacedim > > fe
void get_function_hessians(const InputVector &fe_function, std::vector< Tensor< 2, spacedim, typename InputVector::value_type >> &hessians) const