]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Implement gnuplot output for pyramids.
authorWolfgang Bangerth <bangerth@colostate.edu>
Tue, 2 Nov 2021 00:03:39 +0000 (18:03 -0600)
committerWolfgang Bangerth <bangerth@colostate.edu>
Fri, 5 Nov 2021 03:48:48 +0000 (21:48 -0600)
source/base/data_out_base.cc

index 92b530f1a23a8de37912eb6f08b3d7224bc36431..4c3ff24914a0fbfd3019c253992bff2047150724 100644 (file)
@@ -4014,6 +4014,53 @@ namespace DataOutBase
                     out << '\n';
                     out << '\n'; // end of second line
                   }
+                else if (patch.reference_cell == ReferenceCells::Pyramid)
+                  {
+                    Assert(n_subdivisions == 1, ExcNotImplemented());
+
+                    // Draw the pyramid as a two collections of lines.
+                    out << get_node_location(patch, 0) << ' ';
+                    output_point_data(0);
+                    out << '\n';
+
+                    out << get_node_location(patch, 1) << ' ';
+                    output_point_data(1);
+                    out << '\n';
+
+                    out << get_node_location(patch, 2) << ' ';
+                    output_point_data(2);
+                    out << '\n';
+
+                    out << get_node_location(patch, 3) << ' ';
+                    output_point_data(3);
+                    out << '\n';
+
+                    out << get_node_location(patch, 0) << ' ';
+                    output_point_data(0);
+                    out << '\n';
+
+                    out << get_node_location(patch, 4) << ' ';
+                    output_point_data(4);
+                    out << '\n';
+
+                    out << get_node_location(patch, 1) << ' ';
+                    output_point_data(1);
+                    out << '\n';
+                    out << '\n'; // end of first line
+
+                    out << get_node_location(patch, 2) << ' ';
+                    output_point_data(2);
+                    out << '\n';
+
+                    out << get_node_location(patch, 4) << ' ';
+                    output_point_data(4);
+                    out << '\n';
+
+                    out << get_node_location(patch, 3) << ' ';
+                    output_point_data(2);
+                    out << '\n';
+                    out << '\n'; // end of second line
+                  }
                 else
                   // No other reference cells are currently implemented
                   Assert(false, ExcNotImplemented());

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.