]> https://gitweb.dealii.org/ - dealii.git/commitdiff
instantiate Function::Spherical and auxiliary conversion functions for dim=1,2 5974/head
authorDenis Davydov <davydden@gmail.com>
Wed, 28 Feb 2018 10:34:23 +0000 (11:34 +0100)
committerDenis Davydov <davydden@gmail.com>
Wed, 28 Feb 2018 17:01:08 +0000 (18:01 +0100)
source/base/CMakeLists.txt
source/base/function_spherical.cc
source/base/geometric_utilities.cc
source/base/geometric_utilities.inst.in [new file with mode: 0644]

index 4a3a7c1473c85ccc211068a9b460c27bee3bdb14..5e80792a1a60580afa07d97d06ccf7fec8c756a8 100644 (file)
@@ -102,6 +102,7 @@ SET(_inst
   data_out_base.inst.in
   function.inst.in
   function_time.inst.in
+  geometric_utilities.inst.in
   mpi.inst.in
   partitioner.inst.in
   polynomials_rannacher_turek.inst.in
index a5826cde3e705c256aae918ec038c7cdbe91e59a..449354d4df067fe00a147265c6a1d49cc6c00c48 100644 (file)
@@ -345,6 +345,8 @@ namespace Functions
 
 
 // explicit instantiations
+  template class Spherical<1>;
+  template class Spherical<2>;
   template class Spherical<3>;
 
 }
index c90e33aa3738a8530109c469d89a4bcf57cc558b..f012d7183234df69bfe25652b9a11bc2b54ff540 100644 (file)
@@ -103,11 +103,8 @@ namespace GeometricUtilities
       return ccoord;
     }
 
-
-    template Point<2> from_spherical<2>(const std::array<double,2> &);
-    template Point<3> from_spherical<3>(const std::array<double,3> &);
-    template std::array<double,2> to_spherical<2>(const Point<2> &);
-    template std::array<double,3> to_spherical<3>(const Point<3> &);
+    // explicit instantiations
+#include "geometric_utilities.inst"
 
   }
 }
diff --git a/source/base/geometric_utilities.inst.in b/source/base/geometric_utilities.inst.in
new file mode 100644 (file)
index 0000000..8823cdd
--- /dev/null
@@ -0,0 +1,21 @@
+// ---------------------------------------------------------------------
+//
+// Copyright (C) 2015 - 2017 by the deal.II authors
+//
+// This file is part of the deal.II library.
+//
+// The deal.II library is free software; you can use it, redistribute
+// it, and/or modify it under the terms of the GNU Lesser General
+// Public License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+// The full text of the license can be found in the file LICENSE at
+// the top level of the deal.II distribution.
+//
+// ---------------------------------------------------------------------
+
+
+for (dim : SPACE_DIMENSIONS)
+{
+    template Point<dim> from_spherical<dim>(const std::array<double,dim> &);
+    template std::array<double,dim> to_spherical<dim>(const Point<dim> &);
+}

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.