]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
remove offset parameter from DoFHandler::distribute_dofs() (was never tested/working...
authorheister <heister@0785d39b-7218-0410-832d-ea1e28bc413d>
Mon, 3 Sep 2012 22:31:24 +0000 (22:31 +0000)
committerheister <heister@0785d39b-7218-0410-832d-ea1e28bc413d>
Mon, 3 Sep 2012 22:31:24 +0000 (22:31 +0000)
git-svn-id: https://svn.dealii.org/trunk@26220 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/doc/news/changes.h
deal.II/include/deal.II/dofs/dof_handler.h
deal.II/include/deal.II/dofs/dof_handler_policy.h
deal.II/include/deal.II/multigrid/mg_dof_handler.h
deal.II/source/dofs/dof_handler.cc
deal.II/source/dofs/dof_handler_policy.cc
deal.II/source/multigrid/mg_dof_handler.cc

index 8e3c7ea8c5abf5c12a5856df1ea5a12c428e388c..56a6582e3439436e0fb000cafcca63411200eed8 100644 (file)
@@ -24,7 +24,12 @@ inconvenience this causes.
 </p>
 
 <ol>
-<li> Nothing so far.
+<li> Changed: the optional argument offset got removed from
+DoFHandler and MGDoFHandler::distribute_dofs() because it was
+never working correctly and it is not used.
+<br>
+(Timo Heister, 2012/09/03)
+
 </ol>
 
 
index b236cdea757acb5654cb529a106d4b77170a4dc8..68fdcc45d8c2c96401179430f3e867c675c34522 100644 (file)
@@ -293,18 +293,6 @@ class DoFHandler  :  public Subscriptor
                                       * is first discussed in the introduction
                                       * to the step-2 tutorial program.
                                       *
-                                      * The additional optional
-                                      * parameter @p offset allows you
-                                      * to reserve space for a finite
-                                      * number of additional vector
-                                      * entries in the beginning of
-                                      * all discretization vectors, by
-                                      * starting the enumeration of
-                                      * degrees of freedom on the grid
-                                      * at a nonzero value. By
-                                      * default, this value is of
-                                      * course zero.
-                                      *
                                       * A pointer of the transferred
                                       * finite element is
                                       * stored. Therefore, the
@@ -317,8 +305,7 @@ class DoFHandler  :  public Subscriptor
                                       * releases the lock of this
                                       * object to the finite element.
                                       */
-    virtual void distribute_dofs (const FiniteElement<dim,spacedim> &fe,
-                                  const unsigned int        offset = 0);
+    virtual void distribute_dofs (const FiniteElement<dim,spacedim> &fe);
 
                                      /**
                                       * After distribute_dofs() with
index 65c90440169a3a1f43d31ee70390185918079bc9..c5c0f80d843b65d33dd6991a0534ff83bb4f3a08 100644 (file)
@@ -65,8 +65,7 @@ namespace internal
                                             */
           virtual
           NumberCache
-          distribute_dofs (const unsigned int        offset,
-                           dealii::DoFHandler<dim,spacedim> &dof_handler) const = 0;
+          distribute_dofs (dealii::DoFHandler<dim,spacedim> &dof_handler) const = 0;
 
                                            /**
                                             * Renumber degrees of freedom as
@@ -95,8 +94,7 @@ namespace internal
                                             */
           virtual
           NumberCache
-          distribute_dofs (const unsigned int        offset,
-                           dealii::DoFHandler<dim,spacedim> &dof_handler) const;
+          distribute_dofs (dealii::DoFHandler<dim,spacedim> &dof_handler) const;
 
                                            /**
                                             * Renumber degrees of freedom as
@@ -126,8 +124,7 @@ namespace internal
                                             */
           virtual
           NumberCache
-          distribute_dofs (const unsigned int        offset,
-                           dealii::DoFHandler<dim,spacedim> &dof_handler) const;
+          distribute_dofs (dealii::DoFHandler<dim,spacedim> &dof_handler) const;
 
                                            /**
                                             * Renumber degrees of freedom as
index aa0bf6b665e184fd0deabfce556902aacd287316..3eab55be99cf6e469382c31bdc486bdbb4e90ebf 100644 (file)
@@ -119,8 +119,7 @@ class MGDoFHandler : public DoFHandler<dim,spacedim>
                                       * A copy of the transferred
                                       * finite element is stored.
                                       */
-    virtual void distribute_dofs (const FiniteElement<dim,spacedim> &,
-                                  const unsigned int offset = 0);
+    virtual void distribute_dofs (const FiniteElement<dim,spacedim> &);
 
                                      /**
                                       * Clear all data of this object
index 7a793fd719597c1407af57e894d007ebe7e74c1d..ab9251c238b2b7c3bd1963daabd94ea10721d19f 100644 (file)
@@ -1651,8 +1651,7 @@ DoFHandler<dim,spacedim>::memory_consumption () const
 
 template<int dim, int spacedim>
 void DoFHandler<dim,spacedim>::
-distribute_dofs (const FiniteElement<dim,spacedim> &ff,
-                 const unsigned int                 offset)
+distribute_dofs (const FiniteElement<dim,spacedim> &ff)
 {
   selected_fe = &ff;
 
@@ -1676,8 +1675,7 @@ distribute_dofs (const FiniteElement<dim,spacedim> &ff,
   internal::DoFHandler::Implementation::reserve_space (*this);
 
                                    // hand things off to the policy
-  number_cache = policy->distribute_dofs (offset,
-                                          *this);
+  number_cache = policy->distribute_dofs (*this);
 
                                    // initialize the block info object
                                    // only if this is a sequential
index 5c8185b46ff8fc9f87f6a5c5a200e85e1573fb76..4d7940c2f7c395265dad460b6d8372cca52a800a 100644 (file)
@@ -492,11 +492,10 @@ namespace internal
       template <int dim, int spacedim>
       NumberCache
       Sequential<dim,spacedim>::
-      distribute_dofs (const unsigned int        offset,
-                       DoFHandler<dim,spacedim> &dof_handler) const
+      distribute_dofs (DoFHandler<dim,spacedim> &dof_handler) const
       {
         const unsigned int n_dofs =
-          Implementation::distribute_dofs (offset,
+          Implementation::distribute_dofs (0,
                                            types::invalid_subdomain_id,
                                            dof_handler);
 
@@ -1049,10 +1048,8 @@ namespace internal
       template <int dim, int spacedim>
       NumberCache
       ParallelDistributed<dim, spacedim>::
-      distribute_dofs (const unsigned int        offset,
-                       DoFHandler<dim,spacedim> &dof_handler) const
+      distribute_dofs (DoFHandler<dim,spacedim> &dof_handler) const
       {
-        Assert(offset==0, ExcNotImplemented());
         NumberCache number_cache;
 
 #ifndef DEAL_II_USE_P4EST
index a7ba79987676a2398a4d45a3768f6bb867203b93..4d9d2eff40144838624c59ded9074d128dc9c303 100644 (file)
@@ -1972,8 +1972,7 @@ set_dof_index (const unsigned int obj_level,
 
 
 template <int dim, int spacedim>
-void MGDoFHandler<dim,spacedim>::distribute_dofs (const FiniteElement<dim,spacedim> &fe,
-                                         const unsigned int        offset)
+void MGDoFHandler<dim,spacedim>::distribute_dofs (const FiniteElement<dim,spacedim> &fe)
 {
                                    // first distribute global dofs
   DoFHandler<dim,spacedim>::distribute_dofs (fe);
@@ -1999,7 +1998,7 @@ void MGDoFHandler<dim,spacedim>::distribute_dofs (const FiniteElement<dim,spaced
                                    // separately
   for (unsigned int level=0; level<this->get_tria().n_levels(); ++level)
     {
-      unsigned int next_free_dof = offset;
+      unsigned int next_free_dof = 0;
       cell_iterator cell = begin(level),
                     endc = end(level);
 

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.