]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
More steps towards compiling each file only once.
authorbangerth <bangerth@0785d39b-7218-0410-832d-ea1e28bc413d>
Mon, 8 Nov 2010 20:47:09 +0000 (20:47 +0000)
committerbangerth <bangerth@0785d39b-7218-0410-832d-ea1e28bc413d>
Mon, 8 Nov 2010 20:47:09 +0000 (20:47 +0000)
git-svn-id: https://svn.dealii.org/trunk@22641 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/source/dofs/block_info.all_dimensions.cc [moved from deal.II/source/dofs/block_info.cc with 76% similarity]
deal.II/source/dofs/block_info.inst.in [new file with mode: 0644]
deal.II/source/dofs/dof_accessor.all_dimensions.cc [moved from deal.II/source/dofs/dof_accessor.cc with 66% similarity]
deal.II/source/dofs/dof_accessor.inst.in
deal.II/source/dofs/dof_faces.all_dimensions.cc [moved from deal.II/source/dofs/dof_faces.cc with 85% similarity]
deal.II/source/dofs/dof_objects.all_dimensions.cc
deal.II/source/dofs/dof_objects.cc [deleted file]
deal.II/source/dofs/dof_objects.inst.in [new file with mode: 0644]

similarity index 76%
rename from deal.II/source/dofs/block_info.cc
rename to deal.II/source/dofs/block_info.all_dimensions.cc
index e3b2991c6f9ac52fe225c51a4f8e030946c1a418..ef0c00742fa29b1ef66f4abdd7f359f57a13783a 100644 (file)
@@ -72,15 +72,7 @@ BlockInfo::initialize(const MGDoFHandler<dim, spacedim>& dof, bool levels_only)
 }
 
 
-template void BlockInfo::initialize(const DoFHandler<deal_II_dimension,deal_II_dimension>&);
-template void BlockInfo::initialize(const MGDoFHandler<deal_II_dimension,deal_II_dimension>&, bool);
-template void BlockInfo::initialize_local(const DoFHandler<deal_II_dimension,deal_II_dimension>&);
-
-#if deal_II_dimension==1 || deal_II_dimension==2
-template void BlockInfo::initialize(const DoFHandler<deal_II_dimension,deal_II_dimension+1>&);
-template void BlockInfo::initialize(const MGDoFHandler<deal_II_dimension,deal_II_dimension+1>&, bool);
-template void BlockInfo::initialize_local(const DoFHandler<deal_II_dimension,deal_II_dimension+1>&);
-#endif
-
+// explicit instantiations
+#include "block_info.inst"
 
 DEAL_II_NAMESPACE_CLOSE
diff --git a/deal.II/source/dofs/block_info.inst.in b/deal.II/source/dofs/block_info.inst.in
new file mode 100644 (file)
index 0000000..2657e34
--- /dev/null
@@ -0,0 +1,26 @@
+//---------------------------------------------------------------------------
+//    $Id$
+//    Version: $Name$
+//
+//    Copyright (C) 2009, 2010 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.
+//
+//---------------------------------------------------------------------------
+
+for (deal_II_dimension : DIMENSIONS)
+  {
+    template void BlockInfo::initialize(const DoFHandler<deal_II_dimension,deal_II_dimension>&);
+    template void BlockInfo::initialize(const MGDoFHandler<deal_II_dimension,deal_II_dimension>&, bool);
+    template void BlockInfo::initialize_local(const DoFHandler<deal_II_dimension,deal_II_dimension>&);
+
+#if deal_II_dimension < 3
+    template void BlockInfo::initialize(const DoFHandler<deal_II_dimension,deal_II_dimension+1>&);
+    template void BlockInfo::initialize(const MGDoFHandler<deal_II_dimension,deal_II_dimension+1>&, bool);
+    template void BlockInfo::initialize_local(const DoFHandler<deal_II_dimension,deal_II_dimension+1>&);
+#endif
+  }
+
similarity index 66%
rename from deal.II/source/dofs/dof_accessor.cc
rename to deal.II/source/dofs/dof_accessor.all_dimensions.cc
index 2cff2085154ee28fc201607eab16feab504f57f2..0763357d2f80e5edf6d4acd51d6f5749e11009ff 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 by the deal.II authors
+//    Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -247,137 +247,7 @@ set_dof_values_by_interpolation (const Vector<number> &local_values,
 
 
 // --------------------------------------------------------------------------
-// explicit instantiations (for DoFHandler)
-
-#if deal_II_dimension == 1
-template class DoFAccessor<1, DoFHandler<1> >;
-#endif
-
-#if deal_II_dimension == 2
-template class DoFAccessor<1, DoFHandler<2> >;
-template class DoFAccessor<2, DoFHandler<2> >;
-
-template class TriaRawIterator   <DoFAccessor<1, DoFHandler<2> > >;
-template class TriaIterator      <DoFAccessor<1, DoFHandler<2> > >;
-template class TriaActiveIterator<DoFAccessor<1, DoFHandler<2> > >;
-#endif
-
-#if deal_II_dimension == 3
-template class DoFAccessor<1, DoFHandler<3> >;
-template class DoFAccessor<2, DoFHandler<3> >;
-template class DoFAccessor<3, DoFHandler<3> >;
-
-template class TriaRawIterator   <DoFAccessor<1, DoFHandler<3> > >;
-template class TriaIterator      <DoFAccessor<1, DoFHandler<3> > >;
-template class TriaActiveIterator<DoFAccessor<1, DoFHandler<3> > >;
-template class TriaRawIterator   <DoFAccessor<2, DoFHandler<3> > >;
-template class TriaIterator      <DoFAccessor<2, DoFHandler<3> > >;
-template class TriaActiveIterator<DoFAccessor<2, DoFHandler<3> > >;
-#endif
-
-
-template class DoFCellAccessor<DoFHandler<deal_II_dimension> >;
-
-template class TriaRawIterator   <DoFCellAccessor<DoFHandler<deal_II_dimension> > >;
-template class TriaIterator      <DoFCellAccessor<DoFHandler<deal_II_dimension> > >;
-template class TriaActiveIterator<DoFCellAccessor<DoFHandler<deal_II_dimension> > >;
-
-
-// --------------------------------------------------------------------------
-// explicit instantiations (for hp::DoFHandler)
-
-#if deal_II_dimension == 1
-template class DoFAccessor<1, hp::DoFHandler<1> >;
-#endif
-
-#if deal_II_dimension == 2
-template class DoFAccessor<1, hp::DoFHandler<2> >;
-template class DoFAccessor<2, hp::DoFHandler<2> >;
-
-template class TriaRawIterator   <DoFAccessor<1, hp::DoFHandler<2> > >;
-template class TriaIterator      <DoFAccessor<1, hp::DoFHandler<2> > >;
-template class TriaActiveIterator<DoFAccessor<1, hp::DoFHandler<2> > >;
-#endif
-
-
-#if deal_II_dimension == 3
-template class DoFAccessor<1, hp::DoFHandler<3> >;
-template class DoFAccessor<2, hp::DoFHandler<3> >;
-template class DoFAccessor<3, hp::DoFHandler<3> >;
-
-template class TriaRawIterator   <DoFAccessor<1, hp::DoFHandler<3> > >;
-template class TriaIterator      <DoFAccessor<1, hp::DoFHandler<3> > >;
-template class TriaActiveIterator<DoFAccessor<1, hp::DoFHandler<3> > >;
-template class TriaRawIterator   <DoFAccessor<2, hp::DoFHandler<3> > >;
-template class TriaIterator      <DoFAccessor<2, hp::DoFHandler<3> > >;
-template class TriaActiveIterator<DoFAccessor<2, hp::DoFHandler<3> > >;
-#endif
-
-
-template class DoFCellAccessor<hp::DoFHandler<deal_II_dimension> >;
-
-template class TriaRawIterator   <DoFCellAccessor<hp::DoFHandler<deal_II_dimension> > >;
-template class TriaIterator      <DoFCellAccessor<hp::DoFHandler<deal_II_dimension> > >;
-template class TriaActiveIterator<DoFCellAccessor<hp::DoFHandler<deal_II_dimension> > >;
-
-
-
-// // --------------------------------------------------------------------------
-// // explicit instantiations (for DoFHandler)
-
-#if deal_II_dimension == 1
-template class DoFAccessor<1, DoFHandler<1,2> >;
-#endif
-
-#if deal_II_dimension == 2
-template class DoFAccessor<1, DoFHandler<2,3> >;
-template class DoFAccessor<2, DoFHandler<2,3> >;
-
-template class TriaRawIterator   <DoFAccessor<1, DoFHandler<2,3> > >;
-template class TriaIterator      <DoFAccessor<1, DoFHandler<2,3> > >;
-template class TriaActiveIterator<DoFAccessor<1, DoFHandler<2,3> > >;
-#endif
-
-
-#if deal_II_dimension != 3
-template class DoFCellAccessor<DoFHandler<deal_II_dimension,deal_II_dimension+1> >;
-
-template class
-TriaRawIterator   <DoFCellAccessor<DoFHandler<deal_II_dimension,deal_II_dimension+1> > >;
-template class
-TriaIterator      <DoFCellAccessor<DoFHandler<deal_II_dimension,deal_II_dimension+1> > >;
-template class
-TriaActiveIterator<DoFCellAccessor<DoFHandler<deal_II_dimension,deal_II_dimension+1> > >;
-#endif
-
-// --------------------------------------------------------------------------
-// explicit instantiations (for hp::DoFHandler)
-
-#if deal_II_dimension == 1
-template class DoFAccessor<1, hp::DoFHandler<1,2> >;
-#endif
-
-#if deal_II_dimension == 2
-template class DoFAccessor<1, hp::DoFHandler<2,3> >;
-template class DoFAccessor<2, hp::DoFHandler<2,3> >;
-
-template class TriaRawIterator   <DoFAccessor<1, hp::DoFHandler<2,3> > >;
-template class TriaIterator      <DoFAccessor<1, hp::DoFHandler<2,3> > >;
-template class TriaActiveIterator<DoFAccessor<1, hp::DoFHandler<2,3> > >;
-#endif
-
-#if deal_II_dimension != 3
-template class DoFCellAccessor<hp::DoFHandler<deal_II_dimension,deal_II_dimension+1> >;
-
-template class
-TriaRawIterator   <DoFCellAccessor<hp::DoFHandler<deal_II_dimension,deal_II_dimension+1> > >;
-template class
-TriaIterator      <DoFCellAccessor<hp::DoFHandler<deal_II_dimension,deal_II_dimension+1> > >;
-template class
-TriaActiveIterator<DoFCellAccessor<hp::DoFHandler<deal_II_dimension,deal_II_dimension+1> > >;
-#endif
-
-
+// explicit instantiations
 #include "dof_accessor.inst"
 
 DEAL_II_NAMESPACE_CLOSE
index 26c3e8022eaa8d2ba6c2543e2f481c186fa986e6..5392e65cc1280acf9cd1c2b73c14c9e19f4dd0e2 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by the deal.II authors
+//    Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2010 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
 //---------------------------------------------------------------------------
 
 
-for (VEC : SERIAL_VECTORS; SCALAR : REAL_SCALARS)
-  {  
+// TODO: This could surely be made more systematic!
+for (deal_II_dimension : DIMENSIONS)
+  {
+// explicit instantiations (for DoFHandler)
+
+#if deal_II_dimension == 1
+    template class DoFAccessor<1, DoFHandler<1> >;
+#endif
+
+#if deal_II_dimension == 2
+    template class DoFAccessor<1, DoFHandler<2> >;
+    template class DoFAccessor<2, DoFHandler<2> >;
+
+    template class TriaRawIterator   <DoFAccessor<1, DoFHandler<2> > >;
+    template class TriaIterator      <DoFAccessor<1, DoFHandler<2> > >;
+    template class TriaActiveIterator<DoFAccessor<1, DoFHandler<2> > >;
+#endif
+
+#if deal_II_dimension == 3
+    template class DoFAccessor<1, DoFHandler<3> >;
+    template class DoFAccessor<2, DoFHandler<3> >;
+    template class DoFAccessor<3, DoFHandler<3> >;
+
+    template class TriaRawIterator   <DoFAccessor<1, DoFHandler<3> > >;
+    template class TriaIterator      <DoFAccessor<1, DoFHandler<3> > >;
+    template class TriaActiveIterator<DoFAccessor<1, DoFHandler<3> > >;
+    template class TriaRawIterator   <DoFAccessor<2, DoFHandler<3> > >;
+    template class TriaIterator      <DoFAccessor<2, DoFHandler<3> > >;
+    template class TriaActiveIterator<DoFAccessor<2, DoFHandler<3> > >;
+#endif
+
+
+    template class DoFCellAccessor<DoFHandler<deal_II_dimension> >;
+
+    template class TriaRawIterator   <DoFCellAccessor<DoFHandler<deal_II_dimension> > >;
+    template class TriaIterator      <DoFCellAccessor<DoFHandler<deal_II_dimension> > >;
+    template class TriaActiveIterator<DoFCellAccessor<DoFHandler<deal_II_dimension> > >;
+
+
+// --------------------------------------------------------------------------
+// explicit instantiations (for hp::DoFHandler)
+
+#if deal_II_dimension == 1
+    template class DoFAccessor<1, hp::DoFHandler<1> >;
+#endif
+
+#if deal_II_dimension == 2
+    template class DoFAccessor<1, hp::DoFHandler<2> >;
+    template class DoFAccessor<2, hp::DoFHandler<2> >;
+
+    template class TriaRawIterator   <DoFAccessor<1, hp::DoFHandler<2> > >;
+    template class TriaIterator      <DoFAccessor<1, hp::DoFHandler<2> > >;
+    template class TriaActiveIterator<DoFAccessor<1, hp::DoFHandler<2> > >;
+#endif
+
+
+#if deal_II_dimension == 3
+    template class DoFAccessor<1, hp::DoFHandler<3> >;
+    template class DoFAccessor<2, hp::DoFHandler<3> >;
+    template class DoFAccessor<3, hp::DoFHandler<3> >;
+
+    template class TriaRawIterator   <DoFAccessor<1, hp::DoFHandler<3> > >;
+    template class TriaIterator      <DoFAccessor<1, hp::DoFHandler<3> > >;
+    template class TriaActiveIterator<DoFAccessor<1, hp::DoFHandler<3> > >;
+    template class TriaRawIterator   <DoFAccessor<2, hp::DoFHandler<3> > >;
+    template class TriaIterator      <DoFAccessor<2, hp::DoFHandler<3> > >;
+    template class TriaActiveIterator<DoFAccessor<2, hp::DoFHandler<3> > >;
+#endif
+
+
+    template class DoFCellAccessor<hp::DoFHandler<deal_II_dimension> >;
+
+    template class TriaRawIterator   <DoFCellAccessor<hp::DoFHandler<deal_II_dimension> > >;
+    template class TriaIterator      <DoFCellAccessor<hp::DoFHandler<deal_II_dimension> > >;
+    template class TriaActiveIterator<DoFCellAccessor<hp::DoFHandler<deal_II_dimension> > >;
+
+
+
+// // --------------------------------------------------------------------------
+// // explicit instantiations (for DoFHandler)
+
+#if deal_II_dimension == 1
+    template class DoFAccessor<1, DoFHandler<1,2> >;
+#endif
+
+#if deal_II_dimension == 2
+    template class DoFAccessor<1, DoFHandler<2,3> >;
+    template class DoFAccessor<2, DoFHandler<2,3> >;
+
+    template class TriaRawIterator   <DoFAccessor<1, DoFHandler<2,3> > >;
+    template class TriaIterator      <DoFAccessor<1, DoFHandler<2,3> > >;
+    template class TriaActiveIterator<DoFAccessor<1, DoFHandler<2,3> > >;
+#endif
+
+
+#if deal_II_dimension != 3
+    template class DoFCellAccessor<DoFHandler<deal_II_dimension,deal_II_dimension+1> >;
+
+    template class
+      TriaRawIterator   <DoFCellAccessor<DoFHandler<deal_II_dimension,deal_II_dimension+1> > >;
+    template class
+      TriaIterator      <DoFCellAccessor<DoFHandler<deal_II_dimension,deal_II_dimension+1> > >;
+    template class
+      TriaActiveIterator<DoFCellAccessor<DoFHandler<deal_II_dimension,deal_II_dimension+1> > >;
+#endif
+
+// --------------------------------------------------------------------------
+// explicit instantiations (for hp::DoFHandler)
+
+#if deal_II_dimension == 1
+    template class DoFAccessor<1, hp::DoFHandler<1,2> >;
+#endif
+
+#if deal_II_dimension == 2
+    template class DoFAccessor<1, hp::DoFHandler<2,3> >;
+    template class DoFAccessor<2, hp::DoFHandler<2,3> >;
+
+    template class TriaRawIterator   <DoFAccessor<1, hp::DoFHandler<2,3> > >;
+    template class TriaIterator      <DoFAccessor<1, hp::DoFHandler<2,3> > >;
+    template class TriaActiveIterator<DoFAccessor<1, hp::DoFHandler<2,3> > >;
+#endif
+
+#if deal_II_dimension != 3
+    template class DoFCellAccessor<hp::DoFHandler<deal_II_dimension,deal_II_dimension+1> >;
+
+    template class
+      TriaRawIterator   <DoFCellAccessor<hp::DoFHandler<deal_II_dimension,deal_II_dimension+1> > >;
+    template class
+      TriaIterator      <DoFCellAccessor<hp::DoFHandler<deal_II_dimension,deal_II_dimension+1> > >;
+    template class
+      TriaActiveIterator<DoFCellAccessor<hp::DoFHandler<deal_II_dimension,deal_II_dimension+1> > >;
+#endif
+  }
+
+
+for (VEC : SERIAL_VECTORS; SCALAR : REAL_SCALARS; deal_II_dimension : DIMENSIONS)
+  {
     template
       void
       DoFCellAccessor<DoFHandler<deal_II_dimension> >::get_interpolated_dof_values
@@ -39,8 +174,8 @@ for (VEC : SERIAL_VECTORS; SCALAR : REAL_SCALARS)
   }
 
 
-for (VEC : SERIAL_VECTORS; SCALAR : REAL_SCALARS)
-  {  
+for (VEC : SERIAL_VECTORS; SCALAR : REAL_SCALARS; deal_II_dimension : DIMENSIONS)
+  {
     template
       void
       DoFCellAccessor<hp::DoFHandler<deal_II_dimension> >::get_interpolated_dof_values
similarity index 85%
rename from deal.II/source/dofs/dof_faces.cc
rename to deal.II/source/dofs/dof_faces.all_dimensions.cc
index c8468a649c26a46ece15388e586a3e60ec37f56b..aae782c96bfe91d95899c929bd59c96cc6734dcc 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 2006 by the deal.II authors
+//    Copyright (C) 2006, 2010 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -23,38 +23,26 @@ namespace internal
 {
   namespace DoFHandler
   {
-    
-#if deal_II_dimension == 1
-
     unsigned int
     DoFFaces<1>::memory_consumption () const
     {
       return 0;
     }
 
-#endif
 
-#if deal_II_dimension == 2
-    
     unsigned int
     DoFFaces<2>::memory_consumption () const
     {
       return MemoryConsumption::memory_consumption (lines);
     }
 
-#endif
 
-#if deal_II_dimension == 3
-    
     unsigned int
     DoFFaces<3>::memory_consumption () const
     {
       return (MemoryConsumption::memory_consumption (quads) +
              MemoryConsumption::memory_consumption (lines) );
     }
-
-#endif
-    
   }
 }
 
index 17915c32cfaa448cf9f5eb418ebceedf0a1ab1b0..6a6cd0a7348cd6f12515564954c35bbeaeea06b3 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 2006 by the deal.II authors
+//    Copyright (C) 2006, 2010 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -32,10 +32,39 @@ namespace internal
     }
 
 
-    // explicit instantiations
-    template unsigned int DoFObjects<1>::memory_consumption () const;
-    template unsigned int DoFObjects<2>::memory_consumption () const;
-    template unsigned int DoFObjects<3>::memory_consumption () const;
+
+    template <int dim>
+    template <int dh_dim, int spacedim>
+    void
+    DoFObjects<dim>::
+    set_dof_index (const dealii::DoFHandler<dh_dim, spacedim> &dof_handler,
+                  const unsigned int       obj_index,
+                  const unsigned int       fe_index,
+                  const unsigned int       local_index,
+                  const unsigned int       global_index)
+    {
+      Assert ((fe_index == dealii::DoFHandler<dh_dim, spacedim>::default_fe_index),
+             ExcMessage ("Only the default FE index is allowed for non-hp DoFHandler objects"));
+      Assert (local_index<dof_handler.get_fe().template n_dofs_per_object<dim>(),
+             ExcIndexRange (local_index, 0, dof_handler.get_fe().template n_dofs_per_object<dim>()));
+      Assert (obj_index * dof_handler.get_fe().template n_dofs_per_object<dim>()+local_index
+             <
+             dofs.size(),
+             ExcInternalError());
+
+      dofs[obj_index * dof_handler.get_fe()
+           .template n_dofs_per_object<dim>() + local_index] = global_index;
+    }
+  }
+}
+
+
+// explicit instantiations
+namespace internal
+{
+  namespace DoFHandler
+  {
+#include "dof_objects.inst"
   }
 }
 
diff --git a/deal.II/source/dofs/dof_objects.cc b/deal.II/source/dofs/dof_objects.cc
deleted file mode 100644 (file)
index 104b2a6..0000000
+++ /dev/null
@@ -1,155 +0,0 @@
-//---------------------------------------------------------------------------
-//    $Id$
-//    Version: $Name$
-//
-//    Copyright (C) 2006 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.
-//
-//---------------------------------------------------------------------------
-
-
-#include <base/exceptions.h>
-#include <base/memory_consumption.h>
-#include <dofs/dof_objects.h>
-#include <dofs/dof_handler.h>
-#include <fe/fe.h>
-
-DEAL_II_NAMESPACE_OPEN
-
-namespace internal
-{
-  namespace DoFHandler
-  {
-    template <int dim>
-    template <int dh_dim, int spacedim>
-    void
-    DoFObjects<dim>::
-    set_dof_index (const dealii::DoFHandler<dh_dim, spacedim> &dof_handler,
-                  const unsigned int       obj_index,
-                  const unsigned int       fe_index,
-                  const unsigned int       local_index,
-                  const unsigned int       global_index)
-    {
-      Assert ((fe_index == dealii::DoFHandler<dh_dim, spacedim>::default_fe_index),
-             ExcMessage ("Only the default FE index is allowed for non-hp DoFHandler objects"));
-      Assert (local_index<dof_handler.get_fe().template n_dofs_per_object<dim>(),
-             ExcIndexRange (local_index, 0, dof_handler.get_fe().template n_dofs_per_object<dim>()));
-      Assert (obj_index * dof_handler.get_fe().template n_dofs_per_object<dim>()+local_index
-             <
-             dofs.size(),
-             ExcInternalError());
-
-      dofs[obj_index * dof_handler.get_fe()
-           .template n_dofs_per_object<dim>() + local_index] = global_index;
-    }
-
-// explicit instantiations
-
-    template class DoFObjects<1>;
-
-    template
-    unsigned int
-    DoFObjects<1>::
-    get_dof_index (const dealii::DoFHandler<deal_II_dimension> &dof_handler,
-                  const unsigned int       obj_index,
-                  const unsigned int       fe_index,
-                  const unsigned int       local_index) const;
-    
-    template
-    void
-    DoFObjects<1>::
-    set_dof_index (const dealii::DoFHandler<deal_II_dimension> &dof_handler,
-                  const unsigned int       obj_index,
-                  const unsigned int       fe_index,
-                  const unsigned int       local_index,
-                  const unsigned int       global_index);
-
-
-    template class DoFObjects<2>;
-
-    template
-    unsigned int
-    DoFObjects<2>::
-    get_dof_index (const dealii::DoFHandler<deal_II_dimension> &dof_handler,
-                  const unsigned int       obj_index,
-                  const unsigned int       fe_index,
-                  const unsigned int       local_index) const;
-    
-    template
-    void
-    DoFObjects<2>::
-    set_dof_index (const dealii::DoFHandler<deal_II_dimension> &dof_handler,
-                  const unsigned int       obj_index,
-                  const unsigned int       fe_index,
-                  const unsigned int       local_index,
-                  const unsigned int       global_index);
-
-    template class DoFObjects<3>;
-
-    template
-    unsigned int
-    DoFObjects<3>::
-    get_dof_index (const dealii::DoFHandler<deal_II_dimension> &dof_handler,
-                  const unsigned int       obj_index,
-                  const unsigned int       fe_index,
-                  const unsigned int       local_index) const;
-    
-    template
-    void
-    DoFObjects<3>::
-    set_dof_index (const dealii::DoFHandler<deal_II_dimension> &dof_handler,
-                  const unsigned int       obj_index,
-                  const unsigned int       fe_index,
-                  const unsigned int       local_index,
-                  const unsigned int       global_index);
-
-
-#if deal_II_dimension!=3
-
-    template
-    unsigned int
-    DoFObjects<1>::
-    get_dof_index (const dealii::DoFHandler<deal_II_dimension,deal_II_dimension+1> &dof_handler,
-                  const unsigned int       obj_index,
-                  const unsigned int       fe_index,
-                  const unsigned int       local_index) const;
-    
-    template
-    void
-    DoFObjects<1>::
-    set_dof_index (const dealii::DoFHandler<deal_II_dimension,deal_II_dimension+1> &dof_handler,
-                  const unsigned int       obj_index,
-                  const unsigned int       fe_index,
-                  const unsigned int       local_index,
-                  const unsigned int       global_index);
-
-
-    template
-    unsigned int
-    DoFObjects<2>::
-    get_dof_index (const dealii::DoFHandler<deal_II_dimension,deal_II_dimension+1> &dof_handler,
-                  const unsigned int       obj_index,
-                  const unsigned int       fe_index,
-                  const unsigned int       local_index) const;
-    
-    template
-    void
-    DoFObjects<2>::
-    set_dof_index (const dealii::DoFHandler<deal_II_dimension,deal_II_dimension+1> &dof_handler,
-                  const unsigned int       obj_index,
-                  const unsigned int       fe_index,
-                  const unsigned int       local_index,
-                  const unsigned int       global_index);
-
-
-#endif
-
-
-  }
-}
-
-DEAL_II_NAMESPACE_CLOSE
diff --git a/deal.II/source/dofs/dof_objects.inst.in b/deal.II/source/dofs/dof_objects.inst.in
new file mode 100644 (file)
index 0000000..e3fcb7f
--- /dev/null
@@ -0,0 +1,60 @@
+//---------------------------------------------------------------------------
+//    $Id$
+//    Version: $Name$
+//
+//    Copyright (C) 2006, 2010 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.
+//
+//---------------------------------------------------------------------------
+
+
+for (deal_II_dimension : DIMENSIONS)
+  {
+    template class DoFObjects<deal_II_dimension>;
+  }
+
+
+for (deal_II_dimension, structdim : DIMENSIONS)
+  {
+    template
+    unsigned int
+    DoFObjects<structdim>::
+    get_dof_index (const dealii::DoFHandler<deal_II_dimension> &dof_handler,
+                  const unsigned int       obj_index,
+                  const unsigned int       fe_index,
+                  const unsigned int       local_index) const;
+
+    template
+    void
+    DoFObjects<structdim>::
+    set_dof_index (const dealii::DoFHandler<deal_II_dimension> &dof_handler,
+                  const unsigned int       obj_index,
+                  const unsigned int       fe_index,
+                  const unsigned int       local_index,
+                  const unsigned int       global_index);
+
+#if (deal_II_dimension < 3) && (structdim < 3)
+
+    template
+    unsigned int
+    DoFObjects<structdim>::
+    get_dof_index (const dealii::DoFHandler<deal_II_dimension,deal_II_dimension+1> &dof_handler,
+                  const unsigned int       obj_index,
+                  const unsigned int       fe_index,
+                  const unsigned int       local_index) const;
+
+    template
+    void
+    DoFObjects<structdim>::
+    set_dof_index (const dealii::DoFHandler<deal_II_dimension,deal_II_dimension+1> &dof_handler,
+                  const unsigned int       obj_index,
+                  const unsigned int       fe_index,
+                  const unsigned int       local_index,
+                  const unsigned int       global_index);
+#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.