1 #ifndef PANZER_INTEGRATION_VALUES_2_IMPL_HPP
2 #define PANZER_INTEGRATION_VALUES_2_IMPL_HPP
14 template<
typename Scalar,
15 typename T0,
typename T1,
typename T2,
typename T3,
16 typename T4,
typename T5,
typename T6,
typename T7>
21 T0& ref_ip_coordinates,
28 T7& surface_rotation_matrices)
30 const int new_cell_point = a;
31 const int old_cell_point = b;
33 const int cell_dim = ref_ip_coordinates.extent(2);
36 KOKKOS_ASSERT(cell < ip_coordinates.extent_int(0));
37 KOKKOS_ASSERT(a < ip_coordinates.extent_int(1));
38 KOKKOS_ASSERT(b < ip_coordinates.extent_int(1));
39 KOKKOS_ASSERT(cell >= 0);
40 KOKKOS_ASSERT(a >= 0);
41 KOKKOS_ASSERT(b >= 0);
47 hold = weighted_measure(cell,new_cell_point);
48 weighted_measure(cell,new_cell_point) = weighted_measure(cell,old_cell_point);
49 weighted_measure(cell,old_cell_point) = hold;
51 hold = jac_det(cell,new_cell_point);
52 jac_det(cell,new_cell_point) = jac_det(cell,old_cell_point);
53 jac_det(cell,old_cell_point) = hold;
55 for(
int dim=0;dim<cell_dim;++dim){
57 hold = ref_ip_coordinates(cell,new_cell_point,dim);
58 ref_ip_coordinates(cell,new_cell_point,dim) = ref_ip_coordinates(cell,old_cell_point,dim);
59 ref_ip_coordinates(cell,old_cell_point,dim) = hold;
61 hold = ip_coordinates(cell,new_cell_point,dim);
62 ip_coordinates(cell,new_cell_point,dim) = ip_coordinates(cell,old_cell_point,dim);
63 ip_coordinates(cell,old_cell_point,dim) = hold;
65 hold = surface_normals(cell,new_cell_point,dim);
66 surface_normals(cell,new_cell_point,dim) = surface_normals(cell,old_cell_point,dim);
67 surface_normals(cell,old_cell_point,dim) = hold;
69 for(
int dim2=0;dim2<cell_dim;++dim2){
71 hold =
jac(cell,new_cell_point,dim,dim2);
72 jac(cell,new_cell_point,dim,dim2) =
jac(cell,old_cell_point,dim,dim2);
73 jac(cell,old_cell_point,dim,dim2) = hold;
75 hold = jac_inv(cell,new_cell_point,dim,dim2);
76 jac_inv(cell,new_cell_point,dim,dim2) = jac_inv(cell,old_cell_point,dim,dim2);
77 jac_inv(cell,old_cell_point,dim,dim2) = hold;
82 for(
int dim=0; dim<3; ++dim){
83 for(
int dim2=0; dim2<3; ++dim2){
84 hold = surface_rotation_matrices(cell,new_cell_point,dim,dim2);
85 surface_rotation_matrices(cell,new_cell_point,dim,dim2) = surface_rotation_matrices(cell,old_cell_point,dim,dim2);
86 surface_rotation_matrices(cell,old_cell_point,dim,dim2) = hold;
KOKKOS_INLINE_FUNCTION void swapQuadraturePoints(int cell, int a, int b, T0 &ref_ip_coordinates, T1 &ip_coordinates, T2 &weighted_measure, T3 &jac, T4 &jac_det, T5 &jac_inv, T6 &surface_normals, T7 &surface_rotation_matrices)
Swap the ordering of quadrature points in a specified cell.