]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Provide instantiations of GridOut functions also for dim=1, spacedim=3.
authorWolfgang Bangerth <bangerth@math.tamu.edu>
Mon, 23 Mar 2015 15:35:05 +0000 (10:35 -0500)
committerWolfgang Bangerth <bangerth@math.tamu.edu>
Mon, 23 Mar 2015 18:48:00 +0000 (13:48 -0500)
doc/news/changes.h
source/grid/grid_out.cc
source/grid/grid_out.inst.in

index c5c5e4a34520c7423c0929dcfcf1398ef48bd8f2..9a6eca68c74da45be6f7616e392ff49436b78e86 100644 (file)
@@ -395,6 +395,12 @@ inconvenience this causes.
 <h3>Specific improvements</h3>
 
 <ol>
+  <li> New: The various file format writers of class GridOut were not
+  instantiated for 1d meshes in 3d space. This is now fixed.
+  <br>
+  (Wolfgang Bangerth, 2015/03/23)
+  </li>
+
   <li> New: GridGenerator::create_triangulation_with_removed_cells() creates
   a new mesh out of an existing one by dropping individual cells.
   <br>
index 590155f7236c3e9ba55ddc801dc083b2e38bfd0a..a79f3229dcd5b0b4d8873430ae48630f911672a1 100644 (file)
@@ -3368,6 +3368,15 @@ namespace internal
       Assert(false, ExcNotImplemented());
     }
 
+    void write_eps (const dealii::Triangulation<1,3> &,
+                    std::ostream &,
+                    const Mapping<1,3> *,
+                    const GridOutFlags::Eps<2> &,
+                    const GridOutFlags::Eps<3> &)
+    {
+      Assert(false, ExcNotImplemented());
+    }
+
     void write_eps (const dealii::Triangulation<2,3> &,
                     std::ostream &,
                     const Mapping<2,3> *,
index 924a1040d7e841edad58e1ec590ee89f6865423e..420ba1d8704f88da5cc168d86db96e88306c39bd 100644 (file)
@@ -1,6 +1,6 @@
 // ---------------------------------------------------------------------
 //
-// Copyright (C) 1999 - 2014 by the deal.II authors
+// Copyright (C) 1999 - 2015 by the deal.II authors
 //
 // This file is part of the deal.II library.
 //
@@ -62,42 +62,36 @@ for (deal_II_dimension : DIMENSIONS)
     template void GridOut::write<deal_II_dimension>
       (const Triangulation<deal_II_dimension> &,
        std::ostream &, const Mapping<deal_II_dimension,deal_II_dimension> *) const;
+}
 
-#if deal_II_dimension == 1 || deal_II_dimension ==2
-// explicit instantiations for codimension one
+for (deal_II_dimension : DIMENSIONS; deal_II_space_dimension :  SPACE_DIMENSIONS)
+  {
+#if deal_II_dimension < deal_II_space_dimension
     template void GridOut::write_msh
-      (const Triangulation<deal_II_dimension, deal_II_dimension+1>&,
+      (const Triangulation<deal_II_dimension, deal_II_space_dimension>&,
        std::ostream&) const;
     template void GridOut::write_ucd
-      (const Triangulation<deal_II_dimension, deal_II_dimension+1> &,
+      (const Triangulation<deal_II_dimension, deal_II_space_dimension> &,
        std::ostream &) const;
    template void GridOut::write_gnuplot
-      (const Triangulation<deal_II_dimension,deal_II_dimension+1>&,
+      (const Triangulation<deal_II_dimension,deal_II_space_dimension>&,
        std::ostream&,
-       const Mapping<deal_II_dimension,deal_II_dimension+1>*) const;
+       const Mapping<deal_II_dimension,deal_II_space_dimension>*) const;
    template void GridOut::write_vtk
-      (const Triangulation<deal_II_dimension,deal_II_dimension+1>&,
+      (const Triangulation<deal_II_dimension,deal_II_space_dimension>&,
        std::ostream&) const;
    template void GridOut::write_vtu
-      (const Triangulation<deal_II_dimension,deal_II_dimension+1>&,
+      (const Triangulation<deal_II_dimension,deal_II_space_dimension>&,
        std::ostream&) const;
 
-    template void GridOut::write<deal_II_dimension,deal_II_dimension+1>
-      (const Triangulation<deal_II_dimension,deal_II_dimension+1> &,
+    template void GridOut::write<deal_II_dimension,deal_II_space_dimension>
+      (const Triangulation<deal_II_dimension,deal_II_space_dimension> &,
        std::ostream &, const OutputFormat,
-       const Mapping<deal_II_dimension,deal_II_dimension+1> *) const;
-    template void GridOut::write<deal_II_dimension,deal_II_dimension+1>
-      (const Triangulation<deal_II_dimension,deal_II_dimension+1> &,
-       std::ostream &, const Mapping<deal_II_dimension,deal_II_dimension+1> *) const;
+       const Mapping<deal_II_dimension,deal_II_space_dimension> *) const;
+    template void GridOut::write<deal_II_dimension,deal_II_space_dimension>
+      (const Triangulation<deal_II_dimension,deal_II_space_dimension> &,
+       std::ostream &, const Mapping<deal_II_dimension,deal_II_space_dimension> *) const;
 
-#endif
-#if deal_II_dimension == 3
-   template void GridOut::write_ucd
-     (const Triangulation<1, 3> &,
-      std::ostream &) const;
-   template void GridOut::write_msh
-     (const Triangulation<1, 3> &,
-      std::ostream &) const;
 #endif
   }
 

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.