]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Change a bunch of places where we accidentally used 'unsigned int' instead of types...
authorWolfgang Bangerth <bangerth@math.tamu.edu>
Sat, 22 Jan 2011 20:37:16 +0000 (20:37 +0000)
committerWolfgang Bangerth <bangerth@math.tamu.edu>
Sat, 22 Jan 2011 20:37:16 +0000 (20:37 +0000)
git-svn-id: https://svn.dealii.org/trunk@23241 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/include/deal.II/dofs/dof_tools.h
deal.II/source/dofs/dof_handler_policy.cc
deal.II/source/dofs/dof_renumbering.cc
deal.II/source/dofs/dof_tools.cc

index 39f8fde9ed0a07bfbd101534eab1846d8c0a053b..940033f53ea15db68f4b209ae270947041d506f6 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 by the deal.II authors
+//    Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -311,7 +311,7 @@ class DoFTools
                                      * property.
                                      */
     template <int dim, int spacedim>
-    static unsigned int
+    static bool
     fe_is_primitive (const DoFHandler<dim,spacedim> &dh);
 
                                     /**
@@ -325,7 +325,7 @@ class DoFTools
                                      * property.
                                      */
     template <int dim, int spacedim>
-    static unsigned int
+    static bool
     fe_is_primitive (const hp::DoFHandler<dim,spacedim> &dh);
 
                                     /**
@@ -781,7 +781,7 @@ class DoFTools
                                SparsityPattern &sparsity_pattern,
                                 const ConstraintMatrix   &constraints,
                                 const bool                keep_constrained_dofs = true,
-                                const unsigned int        subdomain_id = numbers::invalid_unsigned_int);
+                                const types::subdomain_id_t  subdomain_id = numbers::invalid_unsigned_int);
 
                                     /**
                                      * This function does the same as
@@ -2205,7 +2205,8 @@ DoFTools::n_components (const DoFHandler<dim,spacedim> &dh)
 
 
 template <int dim, int spacedim>
-inline unsigned int
+inline
+bool
 DoFTools::fe_is_primitive (const DoFHandler<dim,spacedim> &dh)
 {
   return dh.get_fe().is_primitive();
@@ -2245,7 +2246,8 @@ DoFTools::n_components (const hp::DoFHandler<dim,spacedim> &dh)
 
 
 template <int dim, int spacedim>
-inline unsigned int
+inline
+bool
 DoFTools::fe_is_primitive (const hp::DoFHandler<dim,spacedim> &dh)
 {
   return dh.get_fe()[0].is_primitive();
index 845eda1fe95a423ff30ce81ba3d742c311c800bd..f4458edc3447c3cb544b733862d6aea5ea12f35c 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 by the deal.II authors
+//    Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -226,7 +226,7 @@ namespace internal
          static
          unsigned int
          distribute_dofs (const unsigned int        offset,
-                          const unsigned int        subdomain_id,
+                          const types::subdomain_id_t subdomain_id,
                           DoFHandler<dim,spacedim> &dof_handler)
            {
              const dealii::Triangulation<dim,spacedim> & tria
index 5678099c13d28d188a9db818cb4f815d5e7befc0..1eb552c568022da063e7b47492d3d6b722c61e1d 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $name$
 //
-//    Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 by the deal.II authors
+//    Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -848,7 +848,7 @@ namespace DoFRenumbering
        for (unsigned int c=0; c<n_buckets; ++c)
          {
            shifts[c]=cumulated;
-           for (unsigned int i=0; i<tria->locally_owned_subdomain(); ++i)
+           for (types::subdomain_id_t i=0; i<tria->locally_owned_subdomain(); ++i)
              shifts[c] += all_dof_counts[c+n_buckets*i];
            for (unsigned int i=0; i<Utilities::System::get_n_mpi_processes (tria->get_communicator()); ++i)
              cumulated += all_dof_counts[c+n_buckets*i];
index e9eddeeac8e845424b04833f7c87756df91836fe..bfe258608573275560a6112c44a09eb1dc94db6e 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 by the deal.II authors
+//    Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -58,7 +58,7 @@ DoFTools::make_sparsity_pattern (const DH               &dof,
                                 SparsityPattern        &sparsity,
                                 const ConstraintMatrix &constraints,
                                 const bool              keep_constrained_dofs,
-                                const unsigned int      subdomain_id)
+                                const types::subdomain_id_t subdomain_id)
 {
   const unsigned int n_dofs = dof.n_dofs();
 
@@ -495,7 +495,7 @@ DoFTools::make_flux_sparsity_pattern (const DH        &dof,
                                      SparsityPattern &sparsity,
                                      const ConstraintMatrix &constraints,
                                      const bool              keep_constrained_dofs,
-                                     const unsigned int      subdomain_id)
+                                     const types::subdomain_id_t subdomain_id)
 {
   const unsigned int n_dofs = dof.n_dofs();
 
@@ -522,7 +522,7 @@ DoFTools::make_flux_sparsity_pattern (const DH        &dof,
                                // current cell is owned by the calling
                                // processor. Otherwise, just continue.
   for (; cell!=endc; ++cell)
-    if ((subdomain_id == numbers::invalid_unsigned_int)
+    if ((subdomain_id == types::invalid_subdomain_id)
         ||
         (subdomain_id == cell->subdomain_id()))
     {
@@ -4198,7 +4198,7 @@ DoFTools::count_dofs_with_subdomain_association (const DH           &dof_handler
   }
 #endif
 
-  std::vector<unsigned int> subdomain_association (dof_handler.n_dofs());
+  std::vector<types::subdomain_id_t> subdomain_association (dof_handler.n_dofs());
   get_subdomain_association (dof_handler, subdomain_association);
 
   std::vector<unsigned char> component_association (dof_handler.n_dofs());

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.