]> https://gitweb.dealii.org/ - dealii.git/commitdiff
missing instantiation added and moved functions to driver file
authorGuido Kanschat <dr.guido.kanschat@gmail.com>
Wed, 9 Mar 2005 20:18:36 +0000 (20:18 +0000)
committerGuido Kanschat <dr.guido.kanschat@gmail.com>
Wed, 9 Mar 2005 20:18:36 +0000 (20:18 +0000)
git-svn-id: https://svn.dealii.org/trunk@10070 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/deal.II/source/multigrid/mg_dof_tools.cc
deal.II/deal.II/source/multigrid/mg_tools.pattern.in.h [new file with mode: 0644]

index 9e667dd66760d97a6bbb566f6017e502d6b05c66..84f03ce2b69545d0544ec4274037f782ccabb5d4 100644 (file)
@@ -653,95 +653,25 @@ MGTools::reinit_vector (const MGDoFHandler<dim> &mg_dof,
 
 
 // explicit instantiations
-template void
-MGTools::make_sparsity_pattern<deal_II_dimension> (const MGDoFHandler<deal_II_dimension> &,
-                                 SparsityPattern &,
-                                 const unsigned int);
-
-template void
-MGTools::make_flux_sparsity_pattern<deal_II_dimension> (const MGDoFHandler<deal_II_dimension> &,
-                                      SparsityPattern &,
-                                      const unsigned int);
-
-template void
-MGTools::make_flux_sparsity_pattern_edge<deal_II_dimension> (const MGDoFHandler<deal_II_dimension> &,
-                                           SparsityPattern &,
-                                           const unsigned int);
-
-template void
-MGTools::make_sparsity_pattern<deal_II_dimension> (const MGDoFHandler<deal_II_dimension> &,
-                                 CompressedSparsityPattern &,
-                                 const unsigned int);
-
-template void
-MGTools::make_flux_sparsity_pattern<deal_II_dimension> (const MGDoFHandler<deal_II_dimension> &,
-                                      CompressedSparsityPattern &,
-                                      const unsigned int);
-
-template void
-MGTools::make_flux_sparsity_pattern_edge<deal_II_dimension> (const MGDoFHandler<deal_II_dimension> &,
-                                           CompressedSparsityPattern &,
-                                           const unsigned int);
-
-template void
-MGTools::make_sparsity_pattern<deal_II_dimension> (const MGDoFHandler<deal_II_dimension> &,
-                                 BlockSparsityPattern &,
-                                 const unsigned int);
-template void
-MGTools::make_flux_sparsity_pattern<deal_II_dimension> (const MGDoFHandler<deal_II_dimension> &,
-                                      BlockSparsityPattern &,
-                                      const unsigned int);
-
-template void
-MGTools::make_flux_sparsity_pattern_edge<deal_II_dimension> (const MGDoFHandler<deal_II_dimension> &,
-                                           BlockSparsityPattern &,
-                                           const unsigned int);
-
-template void
-MGTools::make_sparsity_pattern<deal_II_dimension> (const MGDoFHandler<deal_II_dimension> &,
-                                 CompressedBlockSparsityPattern &,
-                                 const unsigned int);
-
-template void
-MGTools::make_flux_sparsity_pattern<deal_II_dimension> (const MGDoFHandler<deal_II_dimension> &,
-                                      CompressedBlockSparsityPattern &,
-                                      const unsigned int);
-
-template void
-MGTools::make_flux_sparsity_pattern_edge<deal_II_dimension> (const MGDoFHandler<deal_II_dimension> &,
-                                           CompressedBlockSparsityPattern &,
-                                           const unsigned int);
-
-#if deal_II_dimension > 1
-template void
-MGTools::make_flux_sparsity_pattern<deal_II_dimension> (const MGDoFHandler<deal_II_dimension> &,
-                                      SparsityPattern &,
-                                      const unsigned int,
-                                      const Table<2,DoFTools::Coupling>&,
-                                      const Table<2,DoFTools::Coupling>&);
-
-template void
-MGTools::make_flux_sparsity_pattern<deal_II_dimension> (const MGDoFHandler<deal_II_dimension> &,
-                                      CompressedSparsityPattern &,
-                                      const unsigned int,
-                                      const Table<2,DoFTools::Coupling>&,
-                                      const Table<2,DoFTools::Coupling>&);
-
-template void
-MGTools::make_flux_sparsity_pattern<deal_II_dimension> (const MGDoFHandler<deal_II_dimension> &,
-                                      BlockSparsityPattern &,
-                                      const unsigned int,
-                                      const Table<2,DoFTools::Coupling>&,
-                                      const Table<2,DoFTools::Coupling>&);
-
-template void
-MGTools::make_flux_sparsity_pattern<deal_II_dimension> (const MGDoFHandler<deal_II_dimension> &,
-                                      CompressedBlockSparsityPattern &,
-                                      const unsigned int,
-                                      const Table<2,DoFTools::Coupling>&,
-                                      const Table<2,DoFTools::Coupling>&);
 
-#endif
+// Functions for building sparsity patterns are in a driver file. We
+// call it for all different patterns known.
+#define PATTERN SparsityPattern
+#include "mg_tools.pattern.in.h"
+#undef PATTERN
+
+#define PATTERN CompressedSparsityPattern
+#include "mg_tools.pattern.in.h"
+#undef PATTERN
+
+#define PATTERN BlockSparsityPattern
+#include "mg_tools.pattern.in.h"
+#undef PATTERN
+
+#define PATTERN CompressedBlockSparsityPattern
+#include "mg_tools.pattern.in.h"
+#undef PATTERN
+
 
 template void MGTools::reinit_vector<deal_II_dimension> (
   const MGDoFHandler<deal_II_dimension>&,
diff --git a/deal.II/deal.II/source/multigrid/mg_tools.pattern.in.h b/deal.II/deal.II/source/multigrid/mg_tools.pattern.in.h
new file mode 100644 (file)
index 0000000..c3e08fe
--- /dev/null
@@ -0,0 +1,56 @@
+//---------------------------------------------------------------------------
+//    $Id$
+//    Version: $Name$
+//
+//    Copyright (C) 2002, 2003, 2005 by the deal.II authors
+//
+//    This file is subject to QPL and may not be  distributed
+//    without copyright and license information. Please refer
+//    to the file deal.II/doc/license.html for the  text  and
+//    further information on this license.
+//
+//---------------------------------------------------------------------------
+
+// Driver file for MGTools::Make_*_sparsity_* routines.
+
+// Call this file after defining PATTERN to the desired sparsity
+// pattern type.
+
+
+template void
+MGTools::make_sparsity_pattern<deal_II_dimension> (
+  const MGDoFHandler<deal_II_dimension> &,
+  PATTERN &,
+  const unsigned int);
+
+template void
+MGTools::make_flux_sparsity_pattern<deal_II_dimension> (
+  const MGDoFHandler<deal_II_dimension> &,
+  PATTERN &,
+  const unsigned int);
+
+template void
+MGTools::make_flux_sparsity_pattern_edge<deal_II_dimension> (
+  const MGDoFHandler<deal_II_dimension> &,
+  PATTERN &,
+  const unsigned int);
+
+#if deal_II_dimension > 1
+
+template void
+MGTools::make_flux_sparsity_pattern<deal_II_dimension> (
+  const MGDoFHandler<deal_II_dimension> &,
+  PATTERN &,
+  const unsigned int,
+  const Table<2,DoFTools::Coupling>&,
+  const Table<2,DoFTools::Coupling>&);
+
+template void
+MGTools::make_flux_sparsity_pattern_edge<deal_II_dimension> (
+  const MGDoFHandler<deal_II_dimension> &,
+  PATTERN &,
+  const unsigned int,
+  const Table<2,DoFTools::Coupling>&);
+
+#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.