]> https://gitweb.dealii.org/ - dealii.git/commitdiff
QProjector: minor orientation fixes. 14762/head
authorDavid Wells <drwells@email.unc.edu>
Tue, 7 Feb 2023 02:04:05 +0000 (21:04 -0500)
committerDavid Wells <drwells@email.unc.edu>
Tue, 7 Feb 2023 02:04:05 +0000 (21:04 -0500)
source/base/qprojector.cc

index cafd48cf3d7da21014126e75764fe6f05d24618f..60cf0a7442ba700286a37a906ca0b23d5a77a666 100644 (file)
@@ -644,7 +644,8 @@ QProjector<3>::project_to_all_faces(const ReferenceCell &     reference_cell,
                                     const hp::QCollection<2> &quadrature)
 {
   const auto support_points_tri =
-    [](const auto &face, const auto &orientation) -> std::vector<Point<3>> {
+    [](const auto &        face,
+       const unsigned char orientation) -> std::vector<Point<3>> {
     std::array<Point<3>, 3> vertices;
     std::copy_n(face.first.begin(), face.first.size(), vertices.begin());
     const auto temp =
@@ -655,7 +656,8 @@ QProjector<3>::project_to_all_faces(const ReferenceCell &     reference_cell,
   };
 
   const auto support_points_quad =
-    [](const auto &face, const auto &orientation) -> std::vector<Point<3>> {
+    [](const auto &        face,
+       const unsigned char orientation) -> std::vector<Point<3>> {
     std::array<Point<3>, 4> vertices;
     std::copy_n(face.first.begin(), face.first.size(), vertices.begin());
     const auto temp =
@@ -688,8 +690,8 @@ QProjector<3>::project_to_all_faces(const ReferenceCell &     reference_cell,
             static_cast<const ScalarPolynomialsBase<2> &>(poly_quad);
 
         // ... and over all possible orientations
-        for (unsigned int orientation = 0;
-             orientation < (n_shape_functions * 2);
+        for (unsigned char orientation = 0;
+             orientation < reference_cell.n_face_orientations(face_no);
              ++orientation)
           {
             const auto &face = faces[face_no];

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.