16 #ifndef dealii_mapping_q_internal_h
17 #define dealii_mapping_q_internal_h
60 template <
int spacedim>
74 template <
int spacedim>
86 const long double x = p(0);
87 const long double y = p(1);
89 const long double x0 =
vertices[0](0);
90 const long double x1 =
vertices[1](0);
91 const long double x2 =
vertices[2](0);
92 const long double x3 =
vertices[3](0);
94 const long double y0 =
vertices[0](1);
95 const long double y1 =
vertices[1](1);
96 const long double y2 =
vertices[2](1);
97 const long double y3 =
vertices[3](1);
99 const long double a = (x1 - x3) * (y0 - y2) - (x0 - x2) * (y1 - y3);
100 const long double b = -(x0 - x1 - x2 + x3) * y + (x - 2 * x1 + x3) * y0 -
101 (x - 2 * x0 + x2) * y1 - (x - x1) * y2 +
103 const long double c = (x0 - x1) * y - (x - x1) * y0 + (x - x0) * y1;
105 const long double discriminant =
b *
b - 4 * a * c;
114 const long double sqrt_discriminant = std::sqrt(discriminant);
117 if (
b != 0.0 && std::abs(
b) == sqrt_discriminant)
124 else if (std::abs(a) < 1
e-8 * std::abs(
b))
128 eta1 = 2 * c / (-
b - sqrt_discriminant);
129 eta2 = 2 * c / (-
b + sqrt_discriminant);
134 eta1 = (-
b - sqrt_discriminant) / (2 * a);
135 eta2 = (-
b + sqrt_discriminant) / (2 * a);
138 const long double eta =
139 (std::abs(eta1 - 0.5) < std::abs(eta2 - 0.5)) ? eta1 : eta2;
145 const long double subexpr0 = -eta * x2 + x0 * (eta - 1);
146 const long double xi_denominator0 = eta * x3 - x1 * (eta - 1) + subexpr0;
148 std::max(std::abs(x2), std::abs(x3)));
150 if (std::abs(xi_denominator0) > 1
e-10 * max_x)
152 const double xi = (x + subexpr0) / xi_denominator0;
153 return {xi,
static_cast<double>(eta)};
157 const long double max_y =
159 std::max(std::abs(y2), std::abs(y3)));
160 const long double subexpr1 = -eta * y2 + y0 * (eta - 1);
161 const long double xi_denominator1 =
162 eta * y3 - y1 * (eta - 1) + subexpr1;
163 if (std::abs(xi_denominator1) > 1
e-10 * max_y)
165 const double xi = (subexpr1 + y) / xi_denominator1;
166 return {xi,
static_cast<double>(eta)};
173 spacedim>::ExcTransformationFailed()));
179 return {std::numeric_limits<double>::quiet_NaN(),
180 std::numeric_limits<double>::quiet_NaN()};
185 template <
int spacedim>
194 return {std::numeric_limits<double>::quiet_NaN(),
195 std::numeric_limits<double>::quiet_NaN(),
196 std::numeric_limits<double>::quiet_NaN()};
207 namespace MappingQGenericImplementation
214 std::vector<Point<dim>>
216 const std::vector<unsigned int> &renumbering)
220 std::vector<Point<dim>> points(renumbering.size());
221 const unsigned int n1 = line_support_points.size();
222 for (
unsigned int q2 = 0, q = 0; q2 < (dim > 2 ? n1 : 1); ++q2)
223 for (
unsigned int q1 = 0; q1 < (dim > 1 ? n1 : 1); ++q1)
224 for (
unsigned int q0 = 0; q0 < n1; ++q0, ++q)
226 points[renumbering[q]][0] = line_support_points[q0][0];
228 points[renumbering[q]][1] = line_support_points[q1][0];
230 points[renumbering[q]][2] = line_support_points[q2][0];
244 inline ::Table<2, double>
251 if (polynomial_degree == 1)
254 const unsigned int M = polynomial_degree - 1;
255 const unsigned int n_inner_2d = M * M;
256 const unsigned int n_outer_2d = 4 + 4 * M;
259 loqvs.reinit(n_inner_2d, n_outer_2d);
261 for (
unsigned int i = 0; i < M; ++i)
262 for (
unsigned int j = 0; j < M; ++j)
265 gl.
point((i + 1) * (polynomial_degree + 1) + (j + 1));
266 const unsigned int index_table = i * M + j;
267 for (
unsigned int v = 0; v < 4; ++v)
268 loqvs(index_table, v) =
270 loqvs(index_table, 4 + i) = 1. - p[0];
271 loqvs(index_table, 4 + i + M) = p[0];
272 loqvs(index_table, 4 + j + 2 * M) = 1. - p[1];
273 loqvs(index_table, 4 + j + 3 * M) = p[1];
278 for (
unsigned int unit_point = 0; unit_point < n_inner_2d; ++unit_point)
280 loqvs[unit_point].
end(),
282 1) < 1
e-13 * polynomial_degree,
296 inline ::Table<2, double>
303 if (polynomial_degree == 1)
306 const unsigned int M = polynomial_degree - 1;
308 const unsigned int n_inner = Utilities::fixed_power<3>(M);
309 const unsigned int n_outer = 8 + 12 * M + 6 * M * M;
312 lohvs.reinit(n_inner, n_outer);
314 for (
unsigned int i = 0; i < M; ++i)
315 for (
unsigned int j = 0; j < M; ++j)
316 for (
unsigned int k = 0; k < M; ++k)
319 (j + 1) * (M + 2) + (k + 1));
320 const unsigned int index_table = i * M * M + j * M + k;
323 for (
unsigned int v = 0; v < 8; ++v)
324 lohvs(index_table, v) =
329 constexpr std::array<unsigned int, 4> line_coordinates_y(
332 for (
unsigned int l = 0;
l < 4; ++
l)
333 lohvs(index_table, 8 + line_coordinates_y[
l] * M + j) =
338 constexpr std::array<unsigned int, 4> line_coordinates_x(
341 for (
unsigned int l = 0;
l < 4; ++
l)
342 lohvs(index_table, 8 + line_coordinates_x[
l] * M + k) =
347 constexpr std::array<unsigned int, 4> line_coordinates_z(
350 for (
unsigned int l = 0;
l < 4; ++
l)
351 lohvs(index_table, 8 + line_coordinates_z[
l] * M + i) =
356 lohvs(index_table, 8 + 12 * M + 0 * M * M + i * M + j) =
358 lohvs(index_table, 8 + 12 * M + 1 * M * M + i * M + j) = p[0];
359 lohvs(index_table, 8 + 12 * M + 2 * M * M + k * M + i) =
361 lohvs(index_table, 8 + 12 * M + 3 * M * M + k * M + i) = p[1];
362 lohvs(index_table, 8 + 12 * M + 4 * M * M + j * M + k) =
364 lohvs(index_table, 8 + 12 * M + 5 * M * M + j * M + k) = p[2];
369 for (
unsigned int unit_point = 0; unit_point < n_inner; ++unit_point)
371 lohvs[unit_point].
end(),
373 1) < 1
e-13 * polynomial_degree,
385 inline std::vector<::Table<2, double>>
387 const unsigned int polynomial_degree,
388 const unsigned int dim)
391 std::vector<::Table<2, double>> output(dim);
392 if (polynomial_degree <= 1)
397 output[0].reinit(polynomial_degree - 1,
399 for (
unsigned int q = 0; q < polynomial_degree - 1; ++q)
420 inline ::Table<2, double>
424 if (polynomial_degree <= 1)
425 return ::Table<2, double>();
428 const std::vector<unsigned int> h2l =
429 FETools::hierarchic_to_lexicographic_numbering<dim>(polynomial_degree);
434 for (
unsigned int q = 0; q < output.size(0); ++q)
451 template <
int dim,
int spacedim>
454 const typename ::MappingQGeneric<dim, spacedim>::InternalData &data)
457 data.mapping_support_points.size());
461 for (
unsigned int i = 0; i < data.mapping_support_points.size(); ++i)
462 p_real += data.mapping_support_points[i] * data.shape(0, i);
473 template <
int dim,
int spacedim,
typename Number>
480 const std::vector<unsigned int> & renumber,
481 const bool print_iterations_to_deallog =
false)
498 polynomials_1d, points, p_unit, polynomials_1d.size() == 2, renumber);
507 f.
norm_square() - 1
e-24 * p_real.second[0].norm_square()) ==
545 const double eps = 1.e-11;
546 const unsigned int newton_iteration_limit = 20;
549 invalid_point[0] = std::numeric_limits<double>::infinity();
550 bool try_project_to_unit_cell =
false;
552 unsigned int newton_iteration = 0;
553 Number f_weighted_norm_square = 1.;
554 Number last_f_weighted_norm_square = 1.;
558 if (print_iterations_to_deallog)
559 deallog <<
"Newton iteration " << newton_iteration
560 <<
" for unit point guess " << p_unit << std::endl;
564 for (
unsigned int d = 0;
d < spacedim; ++
d)
565 for (
unsigned int e = 0;
e < dim; ++
e)
566 df[
d][
e] = p_real.second[
e][
d];
579 if (try_project_to_unit_cell ==
false)
586 polynomials_1d.size() == 2,
588 f = p_real.first - p;
589 f_weighted_norm_square = 1.;
590 last_f_weighted_norm_square = 1;
591 try_project_to_unit_cell =
true;
595 return invalid_point;
603 if (print_iterations_to_deallog)
604 deallog <<
" delta=" << delta << std::endl;
607 double step_length = 1;
615 for (
unsigned int i = 0; i < dim; ++i)
616 p_unit_trial[i] -= step_length * delta[i];
619 const auto p_real_trial =
624 polynomials_1d.size() == 2,
627 p_real_trial.first - p;
628 f_weighted_norm_square = (df_inverse * f_trial).norm_square();
630 if (print_iterations_to_deallog)
631 deallog <<
" step_length=" << step_length << std::endl
632 <<
" ||f || =" << f.norm() << std::endl
633 <<
" ||f*|| =" << f_trial.
norm() << std::endl
635 << std::sqrt(f_weighted_norm_square) << std::endl;
654 if (
std::max(f_weighted_norm_square - 1
e-6 * 1
e-6, Number(0.)) *
659 p_real = p_real_trial;
660 p_unit = p_unit_trial;
664 else if (step_length > 0.05)
675 if (step_length <= 0.05 && try_project_to_unit_cell ==
false)
682 polynomials_1d.size() == 2,
684 f = p_real.first - p;
685 f_weighted_norm_square = 1.;
686 last_f_weighted_norm_square = 1;
687 try_project_to_unit_cell =
true;
690 else if (step_length <= 0.05)
691 return invalid_point;
694 if (newton_iteration > newton_iteration_limit)
695 return invalid_point;
704 std::max(last_f_weighted_norm_square -
705 std::min(f_weighted_norm_square, Number(1
e-6 * 1
e-6)) *
710 if (print_iterations_to_deallog)
711 deallog <<
"Iteration converged for p_unit = [ " << p_unit
712 <<
" ] and iteration error "
713 << std::sqrt(f_weighted_norm_square) << std::endl;
726 const typename ::Triangulation<dim, dim + 1>::cell_iterator &cell,
729 typename ::MappingQGeneric<dim, dim + 1>::InternalData &mdata)
731 const unsigned int spacedim = dim + 1;
733 const unsigned int n_shapes = mdata.shape_values.size();
737 Assert(mdata.shape_second_derivatives.size() == n_shapes,
740 std::vector<Point<spacedim>> &points = mdata.mapping_support_points;
753 mdata.compute_shape_function_values(std::vector<
Point<dim>>(1, p_unit));
755 for (
unsigned int k = 0; k < mdata.n_shape_functions; ++k)
761 for (
unsigned int j = 0; j < dim; ++j)
763 DF[j] += grad_phi_k[j] * point_k;
764 for (
unsigned int l = 0;
l < dim; ++
l)
765 D2F[j][
l] += hessian_k[j][
l] * point_k;
770 p_minus_F -= compute_mapped_location_of_point<dim, spacedim>(mdata);
773 for (
unsigned int j = 0; j < dim; ++j)
774 f[j] = DF[j] * p_minus_F;
776 for (
unsigned int j = 0; j < dim; ++j)
778 f[j] = DF[j] * p_minus_F;
779 for (
unsigned int l = 0;
l < dim; ++
l)
780 df[j][
l] = -DF[j] * DF[
l] + D2F[j][
l] * p_minus_F;
784 const double eps = 1.e-12 * cell->diameter();
785 const unsigned int loop_limit = 10;
787 unsigned int loop = 0;
796 for (
unsigned int j = 0; j < dim; ++j)
799 for (
unsigned int l = 0;
l < dim; ++
l)
803 mdata.compute_shape_function_values(
806 for (
unsigned int k = 0; k < mdata.n_shape_functions; ++k)
812 for (
unsigned int j = 0; j < dim; ++j)
814 DF[j] += grad_phi_k[j] * point_k;
815 for (
unsigned int l = 0;
l < dim; ++
l)
816 D2F[j][
l] += hessian_k[j][
l] * point_k;
823 p_minus_F -= compute_mapped_location_of_point<dim, spacedim>(mdata);
825 for (
unsigned int j = 0; j < dim; ++j)
827 f[j] = DF[j] * p_minus_F;
828 for (
unsigned int l = 0;
l < dim; ++
l)
829 df[j][
l] = -DF[j] * DF[
l] + D2F[j][
l] * p_minus_F;
863 template <
int dim,
int spacedim>
871 (spacedim == 1 ? 3 : (spacedim == 2 ? 6 : 10));
889 1. / real_support_points[0].distance(real_support_points[1]))
899 if (real_support_points.size() ==
903 const auto affine = GridTools::affine_cell_approximation<dim>(
906 affine.first.covariant_form().transpose();
908 for (
unsigned int d = 0;
d < spacedim; ++
d)
909 for (
unsigned int e = 0;
e < dim; ++
e)
916 std::array<double, n_functions> shape_values;
922 shape_values[0] = 1.;
926 for (
unsigned int d = 0;
d < spacedim; ++
d)
927 shape_values[1 +
d] = p_scaled[
d];
928 for (
unsigned int d = 0, c = 0;
d < spacedim; ++
d)
929 for (
unsigned int e = 0;
e <=
d; ++
e, ++c)
930 shape_values[1 + spacedim + c] = p_scaled[
d] * p_scaled[
e];
939 matrix[i][j] += shape_values[i] * shape_values[j];
952 for (
unsigned int j = 0; j < i; ++j)
954 double Lik_Ljk_sum = 0;
955 for (
unsigned int k = 0; k < j; ++k)
973 for (
unsigned int j = 0; j < i; ++j)
991 for (
unsigned int i = dim + 1; i <
n_functions; ++i)
1008 template <
typename Number>
1013 for (
unsigned int d = 0;
d < dim; ++
d)
1021 for (
unsigned int d = 0;
d < spacedim; ++
d)
1024 for (
unsigned int d = 0;
d < spacedim; ++
d)
1029 for (
unsigned int d = 0, c = 0;
d < spacedim; ++
d)
1030 for (
unsigned int e = 0;
e <=
d; ++
e, ++c)
1072 template <
int dim,
int spacedim>
1076 const typename ::MappingQGeneric<dim, spacedim>::InternalData &data,
1080 const UpdateFlags update_flags = data.update_each;
1082 const unsigned int n_shape_values = data.n_shape_functions;
1083 const unsigned int n_q_points = data.shape_info.n_q_points;
1085 constexpr
unsigned int n_comp = 1 + (spacedim - 1) / n_lanes;
1086 constexpr
unsigned int n_hessians = (dim * (dim + 1)) / 2;
1106 data.n_shape_functions > 0,
1109 n_q_points == data.contravariant.size(),
1112 n_q_points == jacobian_grads.size(),
1118 data.shape_info.element_type ==
1121 for (
unsigned int q = 0; q < n_q_points; ++q)
1123 data.mapping_support_points[data.shape_info
1124 .lexicographic_numbering[q]];
1131 data.values_dofs.resize(n_comp * n_shape_values);
1132 data.values_quad.resize(n_comp * n_q_points);
1133 data.gradients_quad.resize(n_comp * n_q_points * dim);
1134 data.scratch.resize(2 *
std::max(n_q_points, n_shape_values));
1137 data.hessians_quad.resize(n_comp * n_q_points * n_hessians);
1139 const std::vector<unsigned int> &renumber_to_lexicographic =
1140 data.shape_info.lexicographic_numbering;
1141 for (
unsigned int i = 0; i < n_shape_values; ++i)
1142 for (
unsigned int d = 0;
d < spacedim; ++
d)
1144 const unsigned int in_comp =
d % n_lanes;
1145 const unsigned int out_comp =
d / n_lanes;
1146 data.values_dofs[out_comp * n_shape_values + i][in_comp] =
1147 data.mapping_support_points[renumber_to_lexicographic[i]][
d];
1155 data.values_dofs.begin(),
1156 data.values_quad.begin(),
1157 data.gradients_quad.begin(),
1158 data.hessians_quad.begin(),
1159 data.scratch.begin());
1165 for (
unsigned int out_comp = 0; out_comp < n_comp; ++out_comp)
1166 for (
unsigned int i = 0; i < n_q_points; ++i)
1167 for (
unsigned int in_comp = 0;
1168 in_comp < n_lanes && in_comp < spacedim - out_comp * n_lanes;
1171 data.values_quad[out_comp * n_q_points + i][in_comp];
1176 std::fill(data.contravariant.begin(),
1177 data.contravariant.end(),
1180 for (
unsigned int out_comp = 0; out_comp < n_comp; ++out_comp)
1182 for (
unsigned int j = 0; j < dim; ++j)
1183 for (
unsigned int in_comp = 0;
1184 in_comp < n_lanes &&
1185 in_comp < spacedim - out_comp * n_lanes;
1188 const unsigned int total_number =
point * dim + j;
1189 const unsigned int new_comp = total_number / n_q_points;
1190 const unsigned int new_point = total_number % n_q_points;
1191 data.contravariant[new_point][out_comp * n_lanes + in_comp]
1194 .gradients_quad[(out_comp * n_q_points +
point) * dim +
1201 data.covariant[
point] =
1202 (data.contravariant[
point]).covariant_form();
1207 data.volume_elements[
point] =
1212 constexpr
int desymmetrize_3d[6][2] = {
1213 {0, 0}, {1, 1}, {2, 2}, {0, 1}, {0, 2}, {1, 2}};
1214 constexpr
int desymmetrize_2d[3][2] = {{0, 0}, {1, 1}, {0, 1}};
1217 for (
unsigned int out_comp = 0; out_comp < n_comp; ++out_comp)
1219 for (
unsigned int j = 0; j < n_hessians; ++j)
1220 for (
unsigned int in_comp = 0;
1221 in_comp < n_lanes &&
1222 in_comp < spacedim - out_comp * n_lanes;
1225 const unsigned int total_number =
point * n_hessians + j;
1226 const unsigned int new_point = total_number % n_q_points;
1227 const unsigned int new_hessian_comp =
1228 total_number / n_q_points;
1229 const unsigned int new_hessian_comp_i =
1230 dim == 2 ? desymmetrize_2d[new_hessian_comp][0] :
1231 desymmetrize_3d[new_hessian_comp][0];
1232 const unsigned int new_hessian_comp_j =
1233 dim == 2 ? desymmetrize_2d[new_hessian_comp][1] :
1234 desymmetrize_3d[new_hessian_comp][1];
1235 const double value =
1236 data.hessians_quad[(out_comp * n_q_points +
point) *
1239 jacobian_grads[new_point][out_comp * n_lanes + in_comp]
1240 [new_hessian_comp_i][new_hessian_comp_j] =
1242 jacobian_grads[new_point][out_comp * n_lanes + in_comp]
1243 [new_hessian_comp_j][new_hessian_comp_i] =
1256 template <
int dim,
int spacedim>
1260 const typename ::MappingQGeneric<dim, spacedim>::InternalData &data,
1263 const UpdateFlags update_flags = data.update_each;
1268 const double * shape = &data.shape(
point + data_set, 0);
1270 (shape[0] * data.mapping_support_points[0]);
1271 for (
unsigned int k = 1; k < data.n_shape_functions; ++k)
1272 for (
unsigned int i = 0; i < spacedim; ++i)
1273 result[i] += shape[k] * data.mapping_support_points[k][i];
1288 template <
int dim,
int spacedim>
1292 const typename ::QProjector<dim>::DataSetDescriptor data_set,
1293 const typename ::MappingQGeneric<dim, spacedim>::InternalData &data)
1295 const UpdateFlags update_flags = data.update_each;
1303 const unsigned int n_q_points = data.contravariant.size();
1305 std::fill(data.contravariant.begin(),
1306 data.contravariant.end(),
1312 data.mapping_support_points.data();
1317 &data.derivative(
point + data_set, 0);
1319 double result[spacedim][dim];
1323 for (
unsigned int i = 0; i < spacedim; ++i)
1324 for (
unsigned int j = 0; j < dim; ++j)
1325 result[i][j] = data_derv[0][j] * supp_pts[0][i];
1326 for (
unsigned int k = 1; k < data.n_shape_functions; ++k)
1327 for (
unsigned int i = 0; i < spacedim; ++i)
1328 for (
unsigned int j = 0; j < dim; ++j)
1329 result[i][j] += data_derv[k][j] * supp_pts[k][i];
1336 for (
unsigned int i = 0; i < spacedim; ++i)
1337 for (
unsigned int j = 0; j < dim; ++j)
1338 data.contravariant[
point][i][j] = result[i][j];
1345 const unsigned int n_q_points = data.contravariant.size();
1348 data.covariant[
point] =
1349 (data.contravariant[
point]).covariant_form();
1356 const unsigned int n_q_points = data.contravariant.size();
1358 data.volume_elements[
point] =
1359 data.contravariant[
point].determinant();
1371 template <
int dim,
int spacedim>
1376 const typename ::MappingQGeneric<dim, spacedim>::InternalData &data,
1379 const UpdateFlags update_flags = data.update_each;
1382 const unsigned int n_q_points = jacobian_grads.size();
1388 &data.second_derivative(
point + data_set, 0);
1389 double result[spacedim][dim][dim];
1390 for (
unsigned int i = 0; i < spacedim; ++i)
1391 for (
unsigned int j = 0; j < dim; ++j)
1392 for (
unsigned int l = 0;
l < dim; ++
l)
1394 (
second[0][j][
l] * data.mapping_support_points[0][i]);
1395 for (
unsigned int k = 1; k < data.n_shape_functions; ++k)
1396 for (
unsigned int i = 0; i < spacedim; ++i)
1397 for (
unsigned int j = 0; j < dim; ++j)
1398 for (
unsigned int l = 0;
l < dim; ++
l)
1400 (
second[k][j][
l] * data.mapping_support_points[k][i]);
1402 for (
unsigned int i = 0; i < spacedim; ++i)
1403 for (
unsigned int j = 0; j < dim; ++j)
1404 for (
unsigned int l = 0;
l < dim; ++
l)
1405 jacobian_grads[
point][i][j][
l] = result[i][j][
l];
1418 template <
int dim,
int spacedim>
1423 const typename ::MappingQGeneric<dim, spacedim>::InternalData &data,
1426 const UpdateFlags update_flags = data.update_each;
1429 const unsigned int n_q_points = jacobian_pushed_forward_grads.size();
1433 double tmp[spacedim][spacedim][spacedim];
1437 &data.second_derivative(
point + data_set, 0);
1438 double result[spacedim][dim][dim];
1439 for (
unsigned int i = 0; i < spacedim; ++i)
1440 for (
unsigned int j = 0; j < dim; ++j)
1441 for (
unsigned int l = 0;
l < dim; ++
l)
1443 (
second[0][j][
l] * data.mapping_support_points[0][i]);
1444 for (
unsigned int k = 1; k < data.n_shape_functions; ++k)
1445 for (
unsigned int i = 0; i < spacedim; ++i)
1446 for (
unsigned int j = 0; j < dim; ++j)
1447 for (
unsigned int l = 0;
l < dim; ++
l)
1450 data.mapping_support_points[k][i]);
1453 for (
unsigned int i = 0; i < spacedim; ++i)
1454 for (
unsigned int j = 0; j < spacedim; ++j)
1455 for (
unsigned int l = 0;
l < dim; ++
l)
1458 result[i][0][
l] * data.covariant[
point][j][0];
1459 for (
unsigned int jr = 1; jr < dim; ++jr)
1462 result[i][jr][
l] * data.covariant[
point][j][jr];
1467 for (
unsigned int i = 0; i < spacedim; ++i)
1468 for (
unsigned int j = 0; j < spacedim; ++j)
1469 for (
unsigned int l = 0;
l < spacedim; ++
l)
1471 jacobian_pushed_forward_grads[
point][i][j][
l] =
1472 tmp[i][j][0] * data.covariant[
point][
l][0];
1473 for (
unsigned int lr = 1; lr < dim; ++lr)
1475 jacobian_pushed_forward_grads[
point][i][j][
l] +=
1476 tmp[i][j][lr] * data.covariant[
point][
l][lr];
1492 template <
int dim,
int spacedim>
1497 const typename ::MappingQGeneric<dim, spacedim>::InternalData &data,
1500 const UpdateFlags update_flags = data.update_each;
1503 const unsigned int n_q_points = jacobian_2nd_derivatives.size();
1510 &data.third_derivative(
point + data_set, 0);
1511 double result[spacedim][dim][dim][dim];
1512 for (
unsigned int i = 0; i < spacedim; ++i)
1513 for (
unsigned int j = 0; j < dim; ++j)
1514 for (
unsigned int l = 0;
l < dim; ++
l)
1515 for (
unsigned int m = 0; m < dim; ++m)
1516 result[i][j][
l][m] =
1517 (third[0][j][
l][m] *
1518 data.mapping_support_points[0][i]);
1519 for (
unsigned int k = 1; k < data.n_shape_functions; ++k)
1520 for (
unsigned int i = 0; i < spacedim; ++i)
1521 for (
unsigned int j = 0; j < dim; ++j)
1522 for (
unsigned int l = 0;
l < dim; ++
l)
1523 for (
unsigned int m = 0; m < dim; ++m)
1524 result[i][j][
l][m] +=
1525 (third[k][j][
l][m] *
1526 data.mapping_support_points[k][i]);
1528 for (
unsigned int i = 0; i < spacedim; ++i)
1529 for (
unsigned int j = 0; j < dim; ++j)
1530 for (
unsigned int l = 0;
l < dim; ++
l)
1531 for (
unsigned int m = 0; m < dim; ++m)
1532 jacobian_2nd_derivatives[
point][i][j][
l][m] =
1548 template <
int dim,
int spacedim>
1553 const typename ::MappingQGeneric<dim, spacedim>::InternalData &data,
1556 const UpdateFlags update_flags = data.update_each;
1559 const unsigned int n_q_points =
1560 jacobian_pushed_forward_2nd_derivatives.size();
1564 double tmp[spacedim][spacedim][spacedim][spacedim];
1568 &data.third_derivative(
point + data_set, 0);
1569 double result[spacedim][dim][dim][dim];
1570 for (
unsigned int i = 0; i < spacedim; ++i)
1571 for (
unsigned int j = 0; j < dim; ++j)
1572 for (
unsigned int l = 0;
l < dim; ++
l)
1573 for (
unsigned int m = 0; m < dim; ++m)
1574 result[i][j][
l][m] =
1575 (third[0][j][
l][m] *
1576 data.mapping_support_points[0][i]);
1577 for (
unsigned int k = 1; k < data.n_shape_functions; ++k)
1578 for (
unsigned int i = 0; i < spacedim; ++i)
1579 for (
unsigned int j = 0; j < dim; ++j)
1580 for (
unsigned int l = 0;
l < dim; ++
l)
1581 for (
unsigned int m = 0; m < dim; ++m)
1582 result[i][j][
l][m] +=
1583 (third[k][j][
l][m] *
1584 data.mapping_support_points[k][i]);
1587 for (
unsigned int i = 0; i < spacedim; ++i)
1588 for (
unsigned int j = 0; j < spacedim; ++j)
1589 for (
unsigned int l = 0;
l < dim; ++
l)
1590 for (
unsigned int m = 0; m < dim; ++m)
1592 jacobian_pushed_forward_2nd_derivatives
1593 [
point][i][j][
l][m] = result[i][0][
l][m] *
1594 data.covariant[
point][j][0];
1595 for (
unsigned int jr = 1; jr < dim; ++jr)
1596 jacobian_pushed_forward_2nd_derivatives[
point][i]
1599 result[i][jr][
l][m] *
1600 data.covariant[
point][j][jr];
1604 for (
unsigned int i = 0; i < spacedim; ++i)
1605 for (
unsigned int j = 0; j < spacedim; ++j)
1606 for (
unsigned int l = 0;
l < spacedim; ++
l)
1607 for (
unsigned int m = 0; m < dim; ++m)
1610 jacobian_pushed_forward_2nd_derivatives[
point][i]
1612 data.covariant[
point][
l][0];
1613 for (
unsigned int lr = 1; lr < dim; ++lr)
1615 jacobian_pushed_forward_2nd_derivatives[
point]
1618 data.covariant[
point][
l][lr];
1622 for (
unsigned int i = 0; i < spacedim; ++i)
1623 for (
unsigned int j = 0; j < spacedim; ++j)
1624 for (
unsigned int l = 0;
l < spacedim; ++
l)
1625 for (
unsigned int m = 0; m < spacedim; ++m)
1627 jacobian_pushed_forward_2nd_derivatives
1629 tmp[i][j][
l][0] * data.covariant[
point][m][0];
1630 for (
unsigned int mr = 1; mr < dim; ++mr)
1631 jacobian_pushed_forward_2nd_derivatives[
point][i]
1634 tmp[i][j][
l][mr] * data.covariant[
point][m][mr];
1649 template <
int dim,
int spacedim>
1654 const typename ::MappingQGeneric<dim, spacedim>::InternalData &data,
1657 const UpdateFlags update_flags = data.update_each;
1660 const unsigned int n_q_points = jacobian_3rd_derivatives.size();
1667 &data.fourth_derivative(
point + data_set, 0);
1668 double result[spacedim][dim][dim][dim][dim];
1669 for (
unsigned int i = 0; i < spacedim; ++i)
1670 for (
unsigned int j = 0; j < dim; ++j)
1671 for (
unsigned int l = 0;
l < dim; ++
l)
1672 for (
unsigned int m = 0; m < dim; ++m)
1673 for (
unsigned int n = 0; n < dim; ++n)
1674 result[i][j][
l][m][n] =
1675 (fourth[0][j][
l][m][n] *
1676 data.mapping_support_points[0][i]);
1677 for (
unsigned int k = 1; k < data.n_shape_functions; ++k)
1678 for (
unsigned int i = 0; i < spacedim; ++i)
1679 for (
unsigned int j = 0; j < dim; ++j)
1680 for (
unsigned int l = 0;
l < dim; ++
l)
1681 for (
unsigned int m = 0; m < dim; ++m)
1682 for (
unsigned int n = 0; n < dim; ++n)
1683 result[i][j][
l][m][n] +=
1684 (fourth[k][j][
l][m][n] *
1685 data.mapping_support_points[k][i]);
1687 for (
unsigned int i = 0; i < spacedim; ++i)
1688 for (
unsigned int j = 0; j < dim; ++j)
1689 for (
unsigned int l = 0;
l < dim; ++
l)
1690 for (
unsigned int m = 0; m < dim; ++m)
1691 for (
unsigned int n = 0; n < dim; ++n)
1692 jacobian_3rd_derivatives[
point][i][j][
l][m][n] =
1693 result[i][j][
l][m][n];
1708 template <
int dim,
int spacedim>
1713 const typename ::MappingQGeneric<dim, spacedim>::InternalData &data,
1716 const UpdateFlags update_flags = data.update_each;
1719 const unsigned int n_q_points =
1720 jacobian_pushed_forward_3rd_derivatives.size();
1724 double tmp[spacedim][spacedim][spacedim][spacedim][spacedim];
1728 &data.fourth_derivative(
point + data_set, 0);
1729 double result[spacedim][dim][dim][dim][dim];
1730 for (
unsigned int i = 0; i < spacedim; ++i)
1731 for (
unsigned int j = 0; j < dim; ++j)
1732 for (
unsigned int l = 0;
l < dim; ++
l)
1733 for (
unsigned int m = 0; m < dim; ++m)
1734 for (
unsigned int n = 0; n < dim; ++n)
1735 result[i][j][
l][m][n] =
1736 (fourth[0][j][
l][m][n] *
1737 data.mapping_support_points[0][i]);
1738 for (
unsigned int k = 1; k < data.n_shape_functions; ++k)
1739 for (
unsigned int i = 0; i < spacedim; ++i)
1740 for (
unsigned int j = 0; j < dim; ++j)
1741 for (
unsigned int l = 0;
l < dim; ++
l)
1742 for (
unsigned int m = 0; m < dim; ++m)
1743 for (
unsigned int n = 0; n < dim; ++n)
1744 result[i][j][
l][m][n] +=
1745 (fourth[k][j][
l][m][n] *
1746 data.mapping_support_points[k][i]);
1749 for (
unsigned int i = 0; i < spacedim; ++i)
1750 for (
unsigned int j = 0; j < spacedim; ++j)
1751 for (
unsigned int l = 0;
l < dim; ++
l)
1752 for (
unsigned int m = 0; m < dim; ++m)
1753 for (
unsigned int n = 0; n < dim; ++n)
1755 tmp[i][j][
l][m][n] = result[i][0][
l][m][n] *
1756 data.covariant[
point][j][0];
1757 for (
unsigned int jr = 1; jr < dim; ++jr)
1758 tmp[i][j][
l][m][n] +=
1759 result[i][jr][
l][m][n] *
1760 data.covariant[
point][j][jr];
1764 for (
unsigned int i = 0; i < spacedim; ++i)
1765 for (
unsigned int j = 0; j < spacedim; ++j)
1766 for (
unsigned int l = 0;
l < spacedim; ++
l)
1767 for (
unsigned int m = 0; m < dim; ++m)
1768 for (
unsigned int n = 0; n < dim; ++n)
1770 jacobian_pushed_forward_3rd_derivatives
1772 tmp[i][j][0][m][n] *
1773 data.covariant[
point][
l][0];
1774 for (
unsigned int lr = 1; lr < dim; ++lr)
1775 jacobian_pushed_forward_3rd_derivatives[
point]
1778 tmp[i][j][lr][m][n] *
1779 data.covariant[
point][
l][lr];
1783 for (
unsigned int i = 0; i < spacedim; ++i)
1784 for (
unsigned int j = 0; j < spacedim; ++j)
1785 for (
unsigned int l = 0;
l < spacedim; ++
l)
1786 for (
unsigned int m = 0; m < spacedim; ++m)
1787 for (
unsigned int n = 0; n < dim; ++n)
1789 tmp[i][j][
l][m][n] =
1790 jacobian_pushed_forward_3rd_derivatives[
point]
1793 data.covariant[
point][m][0];
1794 for (
unsigned int mr = 1; mr < dim; ++mr)
1795 tmp[i][j][
l][m][n] +=
1796 jacobian_pushed_forward_3rd_derivatives
1797 [
point][i][j][
l][mr][n] *
1798 data.covariant[
point][m][mr];
1802 for (
unsigned int i = 0; i < spacedim; ++i)
1803 for (
unsigned int j = 0; j < spacedim; ++j)
1804 for (
unsigned int l = 0;
l < spacedim; ++
l)
1805 for (
unsigned int m = 0; m < spacedim; ++m)
1806 for (
unsigned int n = 0; n < spacedim; ++n)
1808 jacobian_pushed_forward_3rd_derivatives
1810 tmp[i][j][
l][m][0] *
1811 data.covariant[
point][n][0];
1812 for (
unsigned int nr = 1; nr < dim; ++nr)
1813 jacobian_pushed_forward_3rd_derivatives[
point]
1816 tmp[i][j][
l][m][nr] *
1817 data.covariant[
point][n][nr];
1835 template <
int dim,
int spacedim>
1838 const ::MappingQGeneric<dim, spacedim> &mapping,
1839 const typename ::Triangulation<dim, spacedim>::cell_iterator &cell,
1840 const unsigned int face_no,
1841 const unsigned int subface_no,
1842 const unsigned int n_q_points,
1843 const std::vector<double> &weights,
1844 const typename ::MappingQGeneric<dim, spacedim>::InternalData &data,
1848 const UpdateFlags update_flags = data.update_each;
1869 for (
unsigned int d = 0;
d != dim - 1; ++
d)
1872 data.unit_tangentials.size(),
1875 data.aux[
d].size() <=
1877 .unit_tangentials[face_no +
1884 data.unit_tangentials[face_no +
1895 if (dim == spacedim)
1897 for (
unsigned int i = 0; i < n_q_points; ++i)
1907 (face_no == 0 ? -1 : +1);
1937 data.contravariant[
point].transpose()[0];
1939 (face_no == 0 ? -1. : +1.) *
1950 cell_normal /= cell_normal.
norm();
1962 for (
unsigned int i = 0; i < output_data.
boundary_forms.size(); ++i)
1970 cell->subface_case(face_no), subface_no);
1976 for (
unsigned int i = 0; i < output_data.
normal_vectors.size(); ++i)
1988 data.covariant[
point].transpose();
1999 template <
int dim,
int spacedim>
2002 const ::MappingQGeneric<dim, spacedim> &mapping,
2003 const typename ::Triangulation<dim, spacedim>::cell_iterator &cell,
2004 const unsigned int face_no,
2005 const unsigned int subface_no,
2008 const typename ::MappingQGeneric<dim, spacedim>::InternalData &data,
2012 if (dim > 1 && data.tensor_product_quadrature)
2014 maybe_update_q_points_Jacobians_and_grads_tensor<dim, spacedim>(
2022 maybe_compute_q_points<dim, spacedim>(data_set,
2028 maybe_update_jacobian_grads<dim, spacedim>(
2031 maybe_update_jacobian_pushed_forward_grads<dim, spacedim>(
2036 maybe_update_jacobian_2nd_derivatives<dim, spacedim>(
2041 maybe_update_jacobian_pushed_forward_2nd_derivatives<dim, spacedim>(
2046 maybe_update_jacobian_3rd_derivatives<dim, spacedim>(
2051 maybe_update_jacobian_pushed_forward_3rd_derivatives<dim, spacedim>(
2072 template <
int dim,
int spacedim,
int rank>
2081 Assert((
dynamic_cast<const typename ::
2082 MappingQGeneric<dim, spacedim>::InternalData *
>(
2083 &mapping_data) !=
nullptr),
2085 const typename ::MappingQGeneric<dim, spacedim>::InternalData
2087 static_cast<const typename ::MappingQGeneric<dim, spacedim>::
2088 InternalData &
>(mapping_data);
2090 switch (mapping_kind)
2096 "update_contravariant_transformation"));
2098 for (
unsigned int i = 0; i < output.size(); ++i)
2109 "update_contravariant_transformation"));
2112 "update_volume_elements"));
2117 for (
unsigned int i = 0; i < output.size(); ++i)
2121 output[i] /= data.volume_elements[i];
2132 "update_covariant_transformation"));
2134 for (
unsigned int i = 0; i < output.size(); ++i)
2150 template <
int dim,
int spacedim,
int rank>
2159 Assert((
dynamic_cast<const typename ::
2160 MappingQGeneric<dim, spacedim>::InternalData *
>(
2161 &mapping_data) !=
nullptr),
2163 const typename ::MappingQGeneric<dim, spacedim>::InternalData
2165 static_cast<const typename ::MappingQGeneric<dim, spacedim>::
2166 InternalData &
>(mapping_data);
2168 switch (mapping_kind)
2174 "update_covariant_transformation"));
2177 "update_contravariant_transformation"));
2180 for (
unsigned int i = 0; i < output.size(); ++i)
2196 "update_covariant_transformation"));
2199 for (
unsigned int i = 0; i < output.size(); ++i)
2215 "update_covariant_transformation"));
2218 "update_contravariant_transformation"));
2221 "update_volume_elements"));
2224 for (
unsigned int i = 0; i < output.size(); ++i)
2232 output[i] /= data.volume_elements[i];
2248 template <
int dim,
int spacedim>
2257 Assert((
dynamic_cast<const typename ::
2258 MappingQGeneric<dim, spacedim>::InternalData *
>(
2259 &mapping_data) !=
nullptr),
2261 const typename ::MappingQGeneric<dim, spacedim>::InternalData
2263 static_cast<const typename ::MappingQGeneric<dim, spacedim>::
2264 InternalData &
>(mapping_data);
2266 switch (mapping_kind)
2272 "update_covariant_transformation"));
2275 "update_contravariant_transformation"));
2277 for (
unsigned int q = 0; q < output.size(); ++q)
2278 for (
unsigned int i = 0; i < spacedim; ++i)
2280 double tmp1[dim][dim];
2281 for (
unsigned int J = 0; J < dim; ++J)
2282 for (
unsigned int K = 0; K < dim; ++K)
2285 data.contravariant[q][i][0] * input[q][0][J][K];
2286 for (
unsigned int I = 1; I < dim; ++I)
2288 data.contravariant[q][i][I] * input[q][I][J][K];
2290 for (
unsigned int j = 0; j < spacedim; ++j)
2293 for (
unsigned int K = 0; K < dim; ++K)
2295 tmp2[K] = data.covariant[q][j][0] * tmp1[0][K];
2296 for (
unsigned int J = 1; J < dim; ++J)
2297 tmp2[K] += data.covariant[q][j][J] * tmp1[J][K];
2299 for (
unsigned int k = 0; k < spacedim; ++k)
2301 output[q][i][j][k] =
2302 data.covariant[q][k][0] * tmp2[0];
2303 for (
unsigned int K = 1; K < dim; ++K)
2304 output[q][i][j][k] +=
2305 data.covariant[q][k][K] * tmp2[K];
2316 "update_covariant_transformation"));
2318 for (
unsigned int q = 0; q < output.size(); ++q)
2319 for (
unsigned int i = 0; i < spacedim; ++i)
2321 double tmp1[dim][dim];
2322 for (
unsigned int J = 0; J < dim; ++J)
2323 for (
unsigned int K = 0; K < dim; ++K)
2326 data.covariant[q][i][0] * input[q][0][J][K];
2327 for (
unsigned int I = 1; I < dim; ++I)
2329 data.covariant[q][i][I] * input[q][I][J][K];
2331 for (
unsigned int j = 0; j < spacedim; ++j)
2334 for (
unsigned int K = 0; K < dim; ++K)
2336 tmp2[K] = data.covariant[q][j][0] * tmp1[0][K];
2337 for (
unsigned int J = 1; J < dim; ++J)
2338 tmp2[K] += data.covariant[q][j][J] * tmp1[J][K];
2340 for (
unsigned int k = 0; k < spacedim; ++k)
2342 output[q][i][j][k] =
2343 data.covariant[q][k][0] * tmp2[0];
2344 for (
unsigned int K = 1; K < dim; ++K)
2345 output[q][i][j][k] +=
2346 data.covariant[q][k][K] * tmp2[K];
2358 "update_covariant_transformation"));
2361 "update_contravariant_transformation"));
2364 "update_volume_elements"));
2366 for (
unsigned int q = 0; q < output.size(); ++q)
2367 for (
unsigned int i = 0; i < spacedim; ++i)
2370 for (
unsigned int I = 0; I < dim; ++I)
2372 data.contravariant[q][i][I] / data.volume_elements[q];
2373 double tmp1[dim][dim];
2374 for (
unsigned int J = 0; J < dim; ++J)
2375 for (
unsigned int K = 0; K < dim; ++K)
2377 tmp1[J][K] = factor[0] * input[q][0][J][K];
2378 for (
unsigned int I = 1; I < dim; ++I)
2379 tmp1[J][K] += factor[I] * input[q][I][J][K];
2381 for (
unsigned int j = 0; j < spacedim; ++j)
2384 for (
unsigned int K = 0; K < dim; ++K)
2386 tmp2[K] = data.covariant[q][j][0] * tmp1[0][K];
2387 for (
unsigned int J = 1; J < dim; ++J)
2388 tmp2[K] += data.covariant[q][j][J] * tmp1[J][K];
2390 for (
unsigned int k = 0; k < spacedim; ++k)
2392 output[q][i][j][k] =
2393 data.covariant[q][k][0] * tmp2[0];
2394 for (
unsigned int K = 1; K < dim; ++K)
2395 output[q][i][j][k] +=
2396 data.covariant[q][k][K] * tmp2[K];
2415 template <
int dim,
int spacedim,
int rank>
2424 Assert((
dynamic_cast<const typename ::
2425 MappingQGeneric<dim, spacedim>::InternalData *
>(
2426 &mapping_data) !=
nullptr),
2428 const typename ::MappingQGeneric<dim, spacedim>::InternalData
2430 static_cast<const typename ::MappingQGeneric<dim, spacedim>::
2431 InternalData &
>(mapping_data);
2433 switch (mapping_kind)
2439 "update_covariant_transformation"));
2441 for (
unsigned int i = 0; i < output.size(); ++i)
ArrayView< typename std::remove_reference< typename std::iterator_traits< Iterator >::reference >::type, MemorySpaceType > make_array_view(const Iterator begin, const Iterator end)
Abstract base class for mapping classes.
const std::vector< double > & get_weights() const
const Point< dim > & point(const unsigned int i) const
unsigned int size() const
constexpr Number determinant(const Tensor< 2, dim, Number > &t)
constexpr numbers::NumberTraits< Number >::real_type norm_square() const
numbers::NumberTraits< Number >::real_type norm() const
static constexpr std::size_t size()
static constexpr unsigned int n_functions
std::array< Point< dim >, n_functions > coefficients
InverseQuadraticApproximation(const std::vector< Point< spacedim >> &real_support_points, const std::vector< Point< dim >> &unit_support_points)
const Point< spacedim > normalization_shift
const double normalization_length
Point< dim, Number > compute(const Point< spacedim, Number > &p) const
InverseQuadraticApproximation(const InverseQuadraticApproximation &)=default
#define DEAL_II_NAMESPACE_OPEN
#define DEAL_II_NAMESPACE_CLOSE
@ update_jacobian_pushed_forward_2nd_derivatives
@ update_volume_elements
Determinant of the Jacobian.
@ update_contravariant_transformation
Contravariant transformation.
@ update_jacobian_pushed_forward_grads
@ update_jacobian_3rd_derivatives
@ update_jacobian_grads
Gradient of volume element.
@ update_normal_vectors
Normal vectors.
@ update_JxW_values
Transformed quadrature weights.
@ update_covariant_transformation
Covariant transformation.
@ update_jacobians
Volume element.
@ update_inverse_jacobians
Volume element.
@ update_quadrature_points
Transformed quadrature points.
@ update_jacobian_pushed_forward_3rd_derivatives
@ update_boundary_forms
Outer normal vector, not normalized.
@ update_jacobian_2nd_derivatives
static ::ExceptionBase & ExcInternalError()
static ::ExceptionBase & ExcDimensionMismatch(std::size_t arg1, std::size_t arg2)
#define Assert(cond, exc)
static ::ExceptionBase & ExcNotImplemented()
static ::ExceptionBase & ExcImpossibleInDim(int arg1)
#define AssertDimension(dim1, dim2)
static ::ExceptionBase & ExcMessage(std::string arg1)
#define AssertThrow(cond, exc)
void loop(ITERATOR begin, typename identity< ITERATOR >::type end, DOFINFO &dinfo, INFOBOX &info, const std::function< void(DOFINFO &, typename INFOBOX::CellInfo &)> &cell_worker, const std::function< void(DOFINFO &, typename INFOBOX::CellInfo &)> &boundary_worker, const std::function< void(DOFINFO &, DOFINFO &, typename INFOBOX::CellInfo &, typename INFOBOX::CellInfo &)> &face_worker, ASSEMBLER &assembler, const LoopControl &lctrl=LoopControl())
@ mapping_covariant_gradient
@ mapping_contravariant_hessian
@ mapping_covariant_hessian
@ mapping_contravariant_gradient
@ tensor_symmetric_collocation
Expression fabs(const Expression &x)
EvaluationFlags
The EvaluationFlags enum.
@ matrix
Contents is actually a matrix.
Point< spacedim > point(const gp_Pnt &p, const double tolerance=1e-10)
void quadrature_points(const Triangulation< dim, spacedim > &triangulation, const Quadrature< dim > &quadrature, const std::vector< std::vector< BoundingBox< spacedim >>> &global_bounding_boxes, ParticleHandler< dim, spacedim > &particle_handler, const Mapping< dim, spacedim > &mapping=(ReferenceCells::get_hypercube< dim >() .template get_default_linear_mapping< dim, spacedim >()), const std::vector< std::vector< double >> &properties={})
SymmetricTensor< 2, dim, Number > d(const Tensor< 2, dim, Number > &F, const Tensor< 2, dim, Number > &dF_dt)
SymmetricTensor< 2, dim, Number > e(const Tensor< 2, dim, Number > &F)
Tensor< 2, dim, Number > l(const Tensor< 2, dim, Number > &F, const Tensor< 2, dim, Number > &dF_dt)
SymmetricTensor< 2, dim, Number > b(const Tensor< 2, dim, Number > &F)
VectorType::value_type * begin(VectorType &V)
VectorType::value_type * end(VectorType &V)
T sum(const T &t, const MPI_Comm &mpi_communicator)
constexpr T pow(const T base, const int iexp)
Point< 1 > transform_real_to_unit_cell(const std::array< Point< spacedim >, GeometryInfo< 1 >::vertices_per_cell > &vertices, const Point< spacedim > &p)
void maybe_update_jacobian_pushed_forward_3rd_derivatives(const CellSimilarity::Similarity cell_similarity, const typename QProjector< dim >::DataSetDescriptor data_set, const typename ::MappingQGeneric< dim, spacedim >::InternalData &data, std::vector< Tensor< 5, spacedim >> &jacobian_pushed_forward_3rd_derivatives)
inline ::Table< 2, double > compute_support_point_weights_on_hex(const unsigned int polynomial_degree)
void transform_fields(const ArrayView< const Tensor< rank, dim >> &input, const MappingKind mapping_kind, const typename Mapping< dim, spacedim >::InternalDataBase &mapping_data, const ArrayView< Tensor< rank, spacedim >> &output)
inline ::Table< 2, double > compute_support_point_weights_on_quad(const unsigned int polynomial_degree)
Point< dim > do_transform_real_to_unit_cell_internal_codim1(const typename ::Triangulation< dim, dim+1 >::cell_iterator &cell, const Point< dim+1 > &p, const Point< dim > &initial_p_unit, typename ::MappingQGeneric< dim, dim+1 >::InternalData &mdata)
Point< spacedim > compute_mapped_location_of_point(const typename ::MappingQGeneric< dim, spacedim >::InternalData &data)
std::vector<::Table< 2, double > > compute_support_point_weights_perimeter_to_interior(const unsigned int polynomial_degree, const unsigned int dim)
void maybe_update_q_points_Jacobians_and_grads_tensor(const CellSimilarity::Similarity cell_similarity, const typename ::MappingQGeneric< dim, spacedim >::InternalData &data, std::vector< Point< spacedim >> &quadrature_points, std::vector< DerivativeForm< 2, dim, spacedim >> &jacobian_grads)
std::vector< Point< dim > > unit_support_points(const std::vector< Point< 1 >> &line_support_points, const std::vector< unsigned int > &renumbering)
void maybe_update_Jacobians(const CellSimilarity::Similarity cell_similarity, const typename ::QProjector< dim >::DataSetDescriptor data_set, const typename ::MappingQGeneric< dim, spacedim >::InternalData &data)
inline ::Table< 2, double > compute_support_point_weights_cell(const unsigned int polynomial_degree)
void transform_gradients(const ArrayView< const Tensor< rank, dim >> &input, const MappingKind mapping_kind, const typename Mapping< dim, spacedim >::InternalDataBase &mapping_data, const ArrayView< Tensor< rank, spacedim >> &output)
void maybe_update_jacobian_2nd_derivatives(const CellSimilarity::Similarity cell_similarity, const typename QProjector< dim >::DataSetDescriptor data_set, const typename ::MappingQGeneric< dim, spacedim >::InternalData &data, std::vector< DerivativeForm< 3, dim, spacedim >> &jacobian_2nd_derivatives)
void maybe_update_jacobian_pushed_forward_2nd_derivatives(const CellSimilarity::Similarity cell_similarity, const typename QProjector< dim >::DataSetDescriptor data_set, const typename ::MappingQGeneric< dim, spacedim >::InternalData &data, std::vector< Tensor< 4, spacedim >> &jacobian_pushed_forward_2nd_derivatives)
void maybe_compute_q_points(const typename QProjector< dim >::DataSetDescriptor data_set, const typename ::MappingQGeneric< dim, spacedim >::InternalData &data, std::vector< Point< spacedim >> &quadrature_points)
void maybe_update_jacobian_pushed_forward_grads(const CellSimilarity::Similarity cell_similarity, const typename QProjector< dim >::DataSetDescriptor data_set, const typename ::MappingQGeneric< dim, spacedim >::InternalData &data, std::vector< Tensor< 3, spacedim >> &jacobian_pushed_forward_grads)
void maybe_update_jacobian_3rd_derivatives(const CellSimilarity::Similarity cell_similarity, const typename QProjector< dim >::DataSetDescriptor data_set, const typename ::MappingQGeneric< dim, spacedim >::InternalData &data, std::vector< DerivativeForm< 4, dim, spacedim >> &jacobian_3rd_derivatives)
void do_fill_fe_face_values(const ::MappingQGeneric< dim, spacedim > &mapping, const typename ::Triangulation< dim, spacedim >::cell_iterator &cell, const unsigned int face_no, const unsigned int subface_no, const typename QProjector< dim >::DataSetDescriptor data_set, const Quadrature< dim - 1 > &quadrature, const typename ::MappingQGeneric< dim, spacedim >::InternalData &data, internal::FEValuesImplementation::MappingRelatedData< dim, spacedim > &output_data)
void maybe_update_jacobian_grads(const CellSimilarity::Similarity cell_similarity, const typename QProjector< dim >::DataSetDescriptor data_set, const typename ::MappingQGeneric< dim, spacedim >::InternalData &data, std::vector< DerivativeForm< 2, dim, spacedim >> &jacobian_grads)
void maybe_compute_face_data(const ::MappingQGeneric< dim, spacedim > &mapping, const typename ::Triangulation< dim, spacedim >::cell_iterator &cell, const unsigned int face_no, const unsigned int subface_no, const unsigned int n_q_points, const std::vector< double > &weights, const typename ::MappingQGeneric< dim, spacedim >::InternalData &data, internal::FEValuesImplementation::MappingRelatedData< dim, spacedim > &output_data)
void transform_differential_forms(const ArrayView< const DerivativeForm< rank, dim, spacedim >> &input, const MappingKind mapping_kind, const typename Mapping< dim, spacedim >::InternalDataBase &mapping_data, const ArrayView< Tensor< rank+1, spacedim >> &output)
Point< dim, Number > do_transform_real_to_unit_cell_internal(const Point< spacedim, Number > &p, const Point< dim, Number > &initial_p_unit, const std::vector< Point< spacedim >> &points, const std::vector< Polynomials::Polynomial< double >> &polynomials_1d, const std::vector< unsigned int > &renumber, const bool print_iterations_to_deallog=false)
void transform_hessians(const ArrayView< const Tensor< 3, dim >> &input, const MappingKind mapping_kind, const typename Mapping< dim, spacedim >::InternalDataBase &mapping_data, const ArrayView< Tensor< 3, spacedim >> &output)
std::pair< typename ProductTypeNoPoint< Number, Number2 >::type, Tensor< 1, dim, typename ProductTypeNoPoint< Number, Number2 >::type > > evaluate_tensor_product_value_and_gradient(const std::vector< Polynomials::Polynomial< double >> &poly, const std::vector< Number > &values, const Point< dim, Number2 > &p, const bool d_linear=false, const std::vector< unsigned int > &renumber={})
static const unsigned int invalid_unsigned_int
static double subface_ratio(const internal::SubfaceCase< dim > &subface_case, const unsigned int subface_no)
static double d_linear_shape_function(const Point< dim > &xi, const unsigned int i)
static Point< dim, Number > project_to_unit_cell(const Point< dim, Number > &p)
constexpr Number determinant(const SymmetricTensor< 2, dim, Number > &)
constexpr SymmetricTensor< 2, dim, Number > invert(const SymmetricTensor< 2, dim, Number > &)
constexpr Tensor< 1, dim, Number > cross_product_2d(const Tensor< 1, dim, Number > &src)
constexpr Tensor< 1, dim, typename ProductType< Number1, Number2 >::type > cross_product_3d(const Tensor< 1, dim, Number1 > &src1, const Tensor< 1, dim, Number2 > &src2)