]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
Change total_dofs to dofs_per_cell, add a bunch of n_* functionf for the dofs_per_...
authorwolf <wolf@0785d39b-7218-0410-832d-ea1e28bc413d>
Thu, 25 Nov 1999 14:19:40 +0000 (14:19 +0000)
committerwolf <wolf@0785d39b-7218-0410-832d-ea1e28bc413d>
Thu, 25 Nov 1999 14:19:40 +0000 (14:19 +0000)
git-svn-id: https://svn.dealii.org/trunk@1949 0785d39b-7218-0410-832d-ea1e28bc413d

40 files changed:
deal.II/deal.II/include/fe/fe.h
deal.II/deal.II/include/fe/fe_system.h
deal.II/deal.II/include/fe/fe_values.h
deal.II/deal.II/include/multigrid/multigrid.templates.h
deal.II/deal.II/include/numerics/multigrid.templates.h
deal.II/deal.II/source/dofs/dof_accessor.cc
deal.II/deal.II/source/dofs/dof_handler.cc
deal.II/deal.II/source/dofs/dof_renumbering.cc
deal.II/deal.II/source/dofs/dof_tools.cc
deal.II/deal.II/source/dofs/mg_dof_accessor.cc
deal.II/deal.II/source/dofs/mg_dof_handler.cc
deal.II/deal.II/source/fe/fe.cc
deal.II/deal.II/source/fe/fe_lib.criss_cross.cc
deal.II/deal.II/source/fe/fe_lib.cubic.cc
deal.II/deal.II/source/fe/fe_lib.dg.constant.cc
deal.II/deal.II/source/fe/fe_lib.linear.cc
deal.II/deal.II/source/fe/fe_lib.quadratic.cc
deal.II/deal.II/source/fe/fe_lib.quartic.cc
deal.II/deal.II/source/fe/fe_system.cc
deal.II/deal.II/source/fe/fe_values.cc
deal.II/deal.II/source/fe/q1_mapping.cc
deal.II/deal.II/source/multigrid/mg_dof_accessor.cc
deal.II/deal.II/source/multigrid/mg_dof_handler.cc
deal.II/deal.II/source/multigrid/multigrid.cc
deal.II/deal.II/source/numerics/assembler.cc
deal.II/deal.II/source/numerics/data_io.cc
deal.II/deal.II/source/numerics/data_out.cc
deal.II/deal.II/source/numerics/data_out_stack.cc
deal.II/deal.II/source/numerics/error_estimator.cc
deal.II/deal.II/source/numerics/matrices.cc
deal.II/deal.II/source/numerics/multigrid.cc
deal.II/deal.II/source/numerics/solution_transfer.cc
deal.II/deal.II/source/numerics/vectors.cc
tests/deal.II/Makefile
tests/deal.II/fe_tables.cc
tests/deal.II/helmholtz1.th
tests/deal.II/helmholtz1mg.th
tests/deal.II/mglocal.cc
tests/deal.II/wave-test-3.cc
tests/fe/show_shapes.cc

index 3540cb97adf091b6b314ac7af3d2ce3a0d93f9fa..a5a9e20896c9830351d32d48bad8eb5eafb70ca2 100644 (file)
@@ -45,16 +45,6 @@ class FiniteElementData
                                      */
     const unsigned int dofs_per_hex;
 
-                                    /**
-                                     * Number of degrees of freedom on a
-                                     * face. This information is
-                                     * redundant to some fields in the
-                                     * derived classes but makes
-                                     * writing dimension independant
-                                     * programs easier.
-                                     */
-    const unsigned int dofs_per_face;
-    
                                     /**
                                      * First index of dof on a line.
                                      */
@@ -80,6 +70,16 @@ class FiniteElementData
                                      */
     const unsigned int first_face_quad_index;
 
+                                    /**
+                                     * Number of degrees of freedom on a
+                                     * face. This information is
+                                     * redundant to some fields in the
+                                     * derived classes but makes
+                                     * writing dimension independant
+                                     * programs easier.
+                                     */
+    const unsigned int dofs_per_face;
+    
                                     /**
                                      * Total number of degrees of freedom
                                      * on a cell. This information is
@@ -88,7 +88,7 @@ class FiniteElementData
                                      * writing dimension independant
                                      * programs easier.
                                      */
-    const unsigned int total_dofs;
+    const unsigned int dofs_per_cell;
 
                                     /**
                                      * Number of basis functions used for the
@@ -96,20 +96,20 @@ class FiniteElementData
                                      * cell. For a linear mapping, this number
                                      * equals the number of vertices.
                                      */
-    const unsigned int n_transform_functions;
+    const unsigned int transform_functions;
 
     
                                     /**
                                      * Number of components and dimension of
                                      * the image space.
                                      */
-    const unsigned int n_components;
+    const unsigned int components;
 
                                     /**
                                      * Default constructor. Constructs
                                      * an element
                                      * which is not so useful. Checking
-                                     * #total_dofs# is therefore a good way to
+                                     * #dofs_per_cell# is therefore a good way to
                                      * check if something went wrong. 
                                      */
     FiniteElementData ();
@@ -150,10 +150,51 @@ class FiniteElementData
                                      * in derived classes virtual as well.
                                      */
     virtual ~FiniteElementData ();
+
+                                    /**
+                                     * Return the #dofs_per_vertex#.
+                                     */
+    unsigned int n_dofs_per_vertex () const;
+
+                                    /**
+                                     * Return the #dofs_per_line#.
+                                     */
+    unsigned int n_dofs_per_line () const;
+
+                                    /**
+                                     * Return the #dofs_per_quad#.
+                                     */
+    unsigned int n_dofs_per_quad () const;
+
+                                    /**
+                                     * Return the #dofs_per_hex#.
+                                     */
+    unsigned int n_dofs_per_hex () const;
+
+                                    /**
+                                     * Return the #dofs_per_face#.
+                                     */
+    unsigned int n_dofs_per_face () const;
+
+                                    /**
+                                     * Return the #dofs_per_cell#.
+                                     */
+    unsigned int n_dofs_per_cell () const;
+
+                                    /**
+                                     * Return the #components#.
+                                     */
+    unsigned int n_components () const;
+
+                                    /**
+                                     * Return the #transform_functions#.
+                                     */
+    unsigned int n_transform_functions () const;
+    
     
                                     /**
                                      * Comparison operator. It is not clear to
-                                     * me why we have to declare and implement
+                                     * me (WB) why we have to declare and implement
                                      * this one explicitely.
                                      */
     bool operator == (const FiniteElementData<dim> &) const;
@@ -1572,14 +1613,94 @@ class FiniteElement : public FiniteElementBase<dim>
 /* ------------------------------- Inline functions ----------------------- */
 
 
+template <int dim>
+inline
+unsigned int 
+FiniteElementData<dim>::n_dofs_per_vertex () const
+{
+  return dofs_per_vertex;
+};
+
+
+
+template <int dim>
+inline
+unsigned int 
+FiniteElementData<dim>::n_dofs_per_line () const
+{
+  return dofs_per_line;
+};
+
+
+
+template <int dim>
+inline
+unsigned int 
+FiniteElementData<dim>::n_dofs_per_quad () const
+{
+  return dofs_per_quad;
+};
+
+
+
+template <int dim>
+inline
+unsigned int 
+FiniteElementData<dim>::n_dofs_per_hex () const
+{
+  return dofs_per_hex;
+};
+
+
+
+template <int dim>
+inline
+unsigned int 
+FiniteElementData<dim>::n_dofs_per_face () const
+{
+  return dofs_per_face;
+};
+
+
+
+template <int dim>
+inline
+unsigned int 
+FiniteElementData<dim>::n_dofs_per_cell () const
+{
+  return dofs_per_cell;
+};
+
+
+
+template <int dim>
+inline
+unsigned int 
+FiniteElementData<dim>::n_components () const
+{
+  return components;
+};
+
+
+
+template <int dim>
+inline
+unsigned int 
+FiniteElementData<dim>::n_transform_functions () const
+{
+  return transform_functions;
+};
+
+
+
 template <int dim>
 inline
 unsigned int
 FiniteElementBase<dim>::component_to_system_index (unsigned int component,
                                                   unsigned int component_index) const
 {
-  Assert(component<n_components,
-        ExcIndexRange(component, 0, n_components));
+  Assert(component<n_components(),
+        ExcIndexRange(component, 0, n_components()));
   Assert(component_index<component_to_system_table[component].size(),
         ExcIndexRange(component_index, 0,
                       component_to_system_table[component].size()));
@@ -1606,8 +1727,8 @@ unsigned int
 FiniteElementBase<dim>::face_component_to_system_index (unsigned int component,
                                                        unsigned int component_index) const
 {
-  Assert(component<n_components,
-        ExcIndexRange(component, 0, n_components));
+  Assert(component<n_components(),
+        ExcIndexRange(component, 0, n_components()));
   Assert(component_index<face_component_to_system_table[component].size(),
         ExcIndexRange(component_index, 0,
                       face_component_to_system_table[component].size()));
@@ -1626,25 +1747,29 @@ FiniteElementBase<dim>::face_system_to_component_index (unsigned int index) cons
   return face_system_to_component_table[index];
 }
 
+
+
 template <int dim>  
 inline
 unsigned int
 FiniteElementBase<dim>::component_to_base (unsigned int index) const
 {
-  if (n_components == 1)
+  if (n_components() == 1)
     return 0;
   Assert(index < component_to_base_table.size(),
         ExcIndexRange(index, 0, component_to_base_table.size()));
   return component_to_base_table[index];
 }
 
+
+
 template <int dim>
 inline
 bool
 FiniteElementBase<dim>::restriction_is_additive (const unsigned int component) const
 {
-  Assert(component<n_components,
-        ExcIndexRange(component, 0, n_components));
+  Assert(component<n_components(),
+        ExcIndexRange(component, 0, n_components()));
   return restriction_is_additive_flags[component];
 }
 
index 4a2b58908a5a9043e0093c8d1c215995e938c166..52e7fcd8f7002fd057662fb88a2e0449c118a19a 100644 (file)
@@ -552,7 +552,7 @@ FESystem<dim>::FESystem (const FE1 &fe1, const unsigned int n1,
                                                                           fe2, n2)),
                base_elements(2)
 {
-  Assert(fe1.n_transform_functions == fe2.n_transform_functions,
+  Assert(fe1.n_transform_functions() == fe2.n_transform_functions(),
         ExcElementTransformNotEqual());
   
   base_elements[0] = ElementPair(new FE1, n1);
@@ -578,9 +578,9 @@ FESystem<dim>::FESystem (const FE1 &fe1, const unsigned int n1,
                                                                           fe3, n3)),
                base_elements(3)
 {
-  Assert(fe1.n_transform_functions == fe2.n_transform_functions,
+  Assert(fe1.n_transform_functions() == fe2.n_transform_functions(),
         ExcElementTransformNotEqual());
-  Assert(fe1.n_transform_functions == fe3.n_transform_functions,
+  Assert(fe1.n_transform_functions() == fe3.n_transform_functions(),
         ExcElementTransformNotEqual());
   
   base_elements[0] = ElementPair(new FE1, n1);
index 65f596a3173f1c000c37547be7718615625a89d3..6803c8cd11b49a9325e915b7c30176097ff601d8 100644 (file)
@@ -77,7 +77,7 @@
  *  use. Later on, the #fill_fe_*# functions are passed pointers to these
  *  arrays, which they may use to extract the values and gradients of the
  *  transform functions. If a concrete finite element choses not to use this
- *  field, it shall set its field #n_transform_functions# to zero.
+ *  field, it shall set its field #transform_functions# to zero.
  *
  *  The #unit_shape_grads_transform# array is provided by the derived classes
  *  to allow for the inclusion of multiple faces, etc.
@@ -220,7 +220,7 @@ class FEValuesBase
                                      * number of degrees of freedom per
                                      * cell, not per face.
                                      */
-    const unsigned int total_dofs;
+    const unsigned int dofs_per_cell;
 
                                     /**
                                      * Number of basis functions for the
@@ -246,7 +246,7 @@ class FEValuesBase
                                      */
     FEValuesBase (const unsigned int n_q_points,
                  const unsigned int n_support_points,
-                 const unsigned int total_dofs,
+                 const unsigned int dofs_per_cell,
                  const unsigned int n_transform_functions,
                  const unsigned int n_values_array,
                  const UpdateFlags         update_flags,
@@ -908,7 +908,7 @@ class FEFaceValuesBase : public FEValuesBase<dim>
                                      */
     FEFaceValuesBase (const unsigned int n_q_points,
                      const unsigned int n_support_points,
-                     const unsigned int total_dofs,
+                     const unsigned int dofs_per_cell,
                      const unsigned int n_transform_functions,
                      const unsigned int n_faces_or_subfaces,
                      const UpdateFlags         update_flags,
index 7428725849a7ef57866eb38c9356d0cbd18d9c20..9f908631be60336b1504e69c3ebb9c4a4f13e5ab 100644 (file)
@@ -18,7 +18,7 @@ template <typename number>
 void
 MG<dim>::copy_to_mg(const Vector<number>& src)
 {
-  const unsigned int dofs_per_cell = mg_dof_handler->get_fe().total_dofs;
+  const unsigned int dofs_per_cell = mg_dof_handler->get_fe().dofs_per_cell;
   const unsigned int dofs_per_face = mg_dof_handler->get_fe().dofs_per_face;
 
                                   // set the elements of the vectors
@@ -95,7 +95,7 @@ template <typename number>
 void
 MG<dim>::copy_from_mg(Vector<number> &dst) const
 {
-  const unsigned int dofs_per_cell = mg_dof_handler->get_fe().total_dofs;
+  const unsigned int dofs_per_cell = mg_dof_handler->get_fe().dofs_per_cell;
 
   vector<int> global_dof_indices (dofs_per_cell);
   vector<int> level_dof_indices (dofs_per_cell);
index 7428725849a7ef57866eb38c9356d0cbd18d9c20..9f908631be60336b1504e69c3ebb9c4a4f13e5ab 100644 (file)
@@ -18,7 +18,7 @@ template <typename number>
 void
 MG<dim>::copy_to_mg(const Vector<number>& src)
 {
-  const unsigned int dofs_per_cell = mg_dof_handler->get_fe().total_dofs;
+  const unsigned int dofs_per_cell = mg_dof_handler->get_fe().dofs_per_cell;
   const unsigned int dofs_per_face = mg_dof_handler->get_fe().dofs_per_face;
 
                                   // set the elements of the vectors
@@ -95,7 +95,7 @@ template <typename number>
 void
 MG<dim>::copy_from_mg(Vector<number> &dst) const
 {
-  const unsigned int dofs_per_cell = mg_dof_handler->get_fe().total_dofs;
+  const unsigned int dofs_per_cell = mg_dof_handler->get_fe().dofs_per_cell;
 
   vector<int> global_dof_indices (dofs_per_cell);
   vector<int> level_dof_indices (dofs_per_cell);
index 15b8b0531832e2db6d09c0738aa4276e95f17f9d..374e5de19532ee0553e447c2c9fde3b43f3b4514 100644 (file)
@@ -349,7 +349,7 @@ DoFCellAccessor<dim>::get_dof_values (const Vector<number> &values,
   
   Assert (dof_handler != 0, DoFAccessor<1>::ExcInvalidObject());
   Assert (&dof_handler->get_fe() != 0, DoFAccessor<1>::ExcInvalidObject());
-  Assert (local_values.size() == dof_handler->get_fe().total_dofs,
+  Assert (local_values.size() == dof_handler->get_fe().dofs_per_cell,
          DoFAccessor<1>::ExcVectorDoesNotMatch());
   Assert (values.size() == dof_handler->n_dofs(),
          DoFAccessor<1>::ExcVectorDoesNotMatch());
@@ -394,7 +394,7 @@ DoFCellAccessor<dim>::set_dof_values (const Vector<number> &local_values,
   
   Assert (dof_handler != 0, DoFAccessor<1>::ExcInvalidObject());
   Assert (&dof_handler->get_fe() != 0, DoFAccessor<1>::ExcInvalidObject());
-  Assert (local_values.size() == dof_handler->get_fe().total_dofs,
+  Assert (local_values.size() == dof_handler->get_fe().dofs_per_cell,
          DoFAccessor<1>::ExcVectorDoesNotMatch());
   Assert (values.size() == dof_handler->n_dofs(),
          DoFAccessor<1>::ExcVectorDoesNotMatch());
@@ -455,7 +455,7 @@ DoFCellAccessor<dim>::get_dof_values (const Vector<number> &values,
   
   Assert (dof_handler != 0, DoFAccessor<dim>::ExcInvalidObject());
   Assert (&dof_handler->get_fe() != 0, DoFAccessor<dim>::ExcInvalidObject());
-  Assert (local_values.size() == dof_handler->get_fe().total_dofs,
+  Assert (local_values.size() == dof_handler->get_fe().dofs_per_cell,
          DoFAccessor<dim>::ExcVectorDoesNotMatch());
   Assert (values.size() == dof_handler->n_dofs(),
          DoFAccessor<dim>::ExcVectorDoesNotMatch());
@@ -504,7 +504,7 @@ DoFCellAccessor<dim>::set_dof_values (const Vector<number> &local_values,
   
   Assert (dof_handler != 0, DoFAccessor<dim>::ExcInvalidObject());
   Assert (&dof_handler->get_fe() != 0, DoFAccessor<dim>::ExcInvalidObject());
-  Assert (local_values.size() == dof_handler->get_fe().total_dofs,
+  Assert (local_values.size() == dof_handler->get_fe().dofs_per_cell,
          DoFAccessor<dim>::ExcVectorDoesNotMatch());
   Assert (values.size() == dof_handler->n_dofs(),
          DoFAccessor<dim>::ExcVectorDoesNotMatch());
@@ -567,7 +567,7 @@ DoFCellAccessor<dim>::get_dof_values (const Vector<number> &values,
 
   Assert (dof_handler != 0, DoFAccessor<3>::ExcInvalidObject());
   Assert (&dof_handler->get_fe() != 0, DoFAccessor<3>::ExcInvalidObject());
-  Assert (local_values.size() == dof_handler->get_fe().total_dofs,
+  Assert (local_values.size() == dof_handler->get_fe().dofs_per_cell,
          DoFAccessor<3>::ExcVectorDoesNotMatch());
   Assert (values.size() == dof_handler->n_dofs(),
          DoFAccessor<3>::ExcVectorDoesNotMatch());
@@ -620,7 +620,7 @@ DoFCellAccessor<dim>::set_dof_values (const Vector<number> &local_values,
 
   Assert (dof_handler != 0, DoFAccessor<3>::ExcInvalidObject());
   Assert (&dof_handler->get_fe() != 0, DoFAccessor<3>::ExcInvalidObject());
-  Assert (local_values.size() == dof_handler->get_fe().total_dofs,
+  Assert (local_values.size() == dof_handler->get_fe().dofs_per_cell,
          DoFAccessor<3>::ExcVectorDoesNotMatch());
   Assert (values.size() == dof_handler->n_dofs(),
          DoFAccessor<3>::ExcVectorDoesNotMatch());
@@ -659,11 +659,11 @@ template <typename number>
 void
 DoFCellAccessor<dim>::get_interpolated_dof_values (const Vector<number> &values,
                                                   Vector<number>       &interpolated_values) const {
-  const unsigned int total_dofs = dof_handler->get_fe().total_dofs;
+  const unsigned int dofs_per_cell = dof_handler->get_fe().dofs_per_cell;
   
   Assert (dof_handler != 0, DoFAccessor<dim>::ExcInvalidObject());
   Assert (&dof_handler->get_fe() != 0, DoFAccessor<dim>::ExcInvalidObject());
-  Assert (interpolated_values.size() == total_dofs,
+  Assert (interpolated_values.size() == dofs_per_cell,
          DoFAccessor<dim>::ExcVectorDoesNotMatch());
   Assert (values.size() == dof_handler->n_dofs(),
          DoFAccessor<dim>::ExcVectorDoesNotMatch());
@@ -675,8 +675,8 @@ DoFCellAccessor<dim>::get_interpolated_dof_values (const Vector<number> &values,
   else
                                     // otherwise clobber them from the children
     {
-      Vector<number> tmp1(total_dofs);
-      Vector<number> tmp2(total_dofs);
+      Vector<number> tmp1(dofs_per_cell);
+      Vector<number> tmp2(dofs_per_cell);
       
       interpolated_values.clear ();
 
@@ -699,7 +699,7 @@ DoFCellAccessor<dim>::get_interpolated_dof_values (const Vector<number> &values,
                                           // end in adding up the contribution
                                           // from nodes on boundaries of
                                           // children more than once.
-         for (unsigned int i=0; i<total_dofs; ++i)
+         for (unsigned int i=0; i<dofs_per_cell; ++i)
            {
              const unsigned int component
                = dof_handler->get_fe().system_to_component_index(i).first;
@@ -721,11 +721,11 @@ template <typename number>
 void
 DoFCellAccessor<dim>::set_dof_values_by_interpolation (const Vector<number> &local_values,
                                                       Vector<number>       &values) const {
-  const unsigned int total_dofs = dof_handler->get_fe().total_dofs;
+  const unsigned int dofs_per_cell = dof_handler->get_fe().dofs_per_cell;
   
   Assert (dof_handler != 0, DoFAccessor<dim>::ExcInvalidObject());
   Assert (&dof_handler->get_fe() != 0, DoFAccessor<dim>::ExcInvalidObject());
-  Assert (local_values.size() == total_dofs,
+  Assert (local_values.size() == dofs_per_cell,
          DoFAccessor<dim>::ExcVectorDoesNotMatch());
   Assert (values.size() == dof_handler->n_dofs(),
          DoFAccessor<dim>::ExcVectorDoesNotMatch());
@@ -737,7 +737,7 @@ DoFCellAccessor<dim>::set_dof_values_by_interpolation (const Vector<number> &loc
   else
                                     // otherwise distribute them to the children
     {
-      Vector<number> tmp(total_dofs);
+      Vector<number> tmp(dofs_per_cell);
       
       for (unsigned int child=0; child<GeometryInfo<dim>::children_per_cell;
           ++child)
index 72131e8598e99ef93bc19b26e5981dec681e739b..7b480a0e4bccc8f11333ac0fb7aa4fc5538f6eae 100644 (file)
@@ -1981,7 +1981,7 @@ void DoFHandler<dim>::make_sparsity_pattern (SparseMatrixStruct &sparsity) const
   Assert (sparsity.n_cols() == n_dofs(),
          ExcDifferentDimensions (sparsity.n_cols(), n_dofs()));
 
-  const unsigned int dofs_per_cell = selected_fe->total_dofs;
+  const unsigned int dofs_per_cell = selected_fe->dofs_per_cell;
   vector<int> dofs_on_this_cell(dofs_per_cell);
   active_cell_iterator cell = begin_active(),
                       endc = end();
@@ -2003,18 +2003,18 @@ void
 DoFHandler<dim>::make_sparsity_pattern (const vector<vector<bool> > &mask,
                                        SparseMatrixStruct          &sparsity) const
 {
-  const unsigned int dofs_per_cell = selected_fe->total_dofs;
+  const unsigned int dofs_per_cell = selected_fe->dofs_per_cell;
 
   Assert (selected_fe != 0, ExcNoFESelected());
   Assert (sparsity.n_rows() == n_dofs(),
          ExcDifferentDimensions (sparsity.n_rows(), n_dofs()));
   Assert (sparsity.n_cols() == n_dofs(),
          ExcDifferentDimensions (sparsity.n_cols(), n_dofs()));
-  Assert (mask.size() == selected_fe->n_components,
-         ExcInvalidMaskDimension(mask.size(), selected_fe->n_components));
+  Assert (mask.size() == selected_fe->n_components(),
+         ExcInvalidMaskDimension(mask.size(), selected_fe->n_components()));
   for (unsigned int i=0; i<mask.size(); ++i)
-    Assert (mask[i].size() == selected_fe->n_components,
-           ExcInvalidMaskDimension(mask[i].size(), selected_fe->n_components));
+    Assert (mask[i].size() == selected_fe->n_components(),
+           ExcInvalidMaskDimension(mask[i].size(), selected_fe->n_components()));
 
                                   // first build a mask for each dof,
                                   // not like the one given which represents
@@ -2302,15 +2302,15 @@ void DoFHandler<dim>::distribute_cell_to_dof_vector (const Vector<Number> &cell_
   Assert (cell_data.size()==tria->n_active_cells(),
          ExcWrongSize (cell_data.size(), tria->n_active_cells()));
   Assert (dof_data.size()==n_dofs(), ExcWrongSize (dof_data.size(), n_dofs()));
-  Assert (component < selected_fe->n_components,
-         ExcInvalidComponent(component, selected_fe->n_components));
+  Assert (component < selected_fe->n_components(),
+         ExcInvalidComponent(component, selected_fe->n_components()));
 
                                   // store a flag whether we should care
                                   // about different components. this is
                                   // just a simplification, we could ask
                                   // for this at every single place
                                   // equally well
-  const bool consider_components = (selected_fe->n_components != 1);
+  const bool consider_components = (selected_fe->n_components() != 1);
   
                                   // count how often we have added a value
                                   // in the sum for each dof
@@ -2319,7 +2319,7 @@ void DoFHandler<dim>::distribute_cell_to_dof_vector (const Vector<Number> &cell_
   active_cell_iterator cell = begin_active(),
                       endc = end();
   unsigned int present_cell = 0;
-  const unsigned int dofs_per_cell = selected_fe->total_dofs;
+  const unsigned int dofs_per_cell = selected_fe->dofs_per_cell;
   vector<int> dof_indices (dofs_per_cell);
 
   for (; cell!=endc; ++cell, ++present_cell) 
index f7ffda9a5502700e1db76df5cad8ab1d771f4ebc..d2606a949bdcf3ab558a9c0095217ebcff42b6e7 100644 (file)
@@ -370,24 +370,24 @@ template <int dim>
 void DoFRenumbering::component_wise (DoFHandler<dim>            &dof_handler,
                                     const vector<unsigned int> &component_order_arg)
 {
-  const unsigned int dofs_per_cell = dof_handler.get_fe().total_dofs;
+  const unsigned int dofs_per_cell = dof_handler.get_fe().dofs_per_cell;
 
                                   // do nothing if the FE has only
                                   // one component
-  if (dof_handler.get_fe().n_components == 1)
+  if (dof_handler.get_fe().n_components() == 1)
     return;
   
   vector<unsigned int> component_order (component_order_arg);
   if (component_order.size() == 0)
-    for (unsigned int i=0; i<dof_handler.get_fe().n_components; ++i)
+    for (unsigned int i=0; i<dof_handler.get_fe().n_components(); ++i)
       component_order.push_back (i);
 
                                   // check whether the component list has
                                   // the right length and contains all
                                   // component numbers
-  Assert (component_order.size() == dof_handler.get_fe().n_components,
+  Assert (component_order.size() == dof_handler.get_fe().n_components(),
          ExcInvalidComponentOrder());
-  for (unsigned int i=0; i<dof_handler.get_fe().n_components; ++i)
+  for (unsigned int i=0; i<dof_handler.get_fe().n_components(); ++i)
     Assert (find (component_order.begin(), component_order.end(), i)
            != component_order.end(),
            ExcInvalidComponentOrder ());
@@ -410,7 +410,7 @@ void DoFRenumbering::component_wise (DoFHandler<dim>            &dof_handler,
                                   // sorted by dof index. note also that some
                                   // dof indices are entered multiply, so we
                                   // will have to take care of that
-  vector<vector<int> > component_to_dof_map (dof_handler.get_fe().n_components);
+  vector<vector<int> > component_to_dof_map (dof_handler.get_fe().n_components());
   for (typename DoFHandler<dim>::active_cell_iterator cell=dof_handler.begin_active();
        cell!=dof_handler.end(); ++cell)
     {
@@ -432,7 +432,7 @@ void DoFRenumbering::component_wise (DoFHandler<dim>            &dof_handler,
                                   // preserve the order within each component
                                   // and during this also remove duplicate
                                   // entries
-  for (unsigned int component=0; component<dof_handler.get_fe().n_components; ++component)
+  for (unsigned int component=0; component<dof_handler.get_fe().n_components(); ++component)
     {
       sort (component_to_dof_map[component].begin(),
            component_to_dof_map[component].end());
@@ -443,7 +443,7 @@ void DoFRenumbering::component_wise (DoFHandler<dim>            &dof_handler,
   
   int next_free_index = 0;
   vector<int> new_indices (dof_handler.n_dofs(), -1);
-  for (unsigned int component=0; component<dof_handler.get_fe().n_components; ++component)
+  for (unsigned int component=0; component<dof_handler.get_fe().n_components(); ++component)
     {
       const typename vector<int>::const_iterator
        begin_of_component = component_to_dof_map[component].begin(),
index dac0e080eb2e1d602e5ddbc0ae6dde4fc26eeef4..7847191faacf0c0b27a22678a8ac3542f3a00e81 100644 (file)
@@ -19,21 +19,21 @@ DoFTools::extract_dofs(const DoFHandler<dim> &dof,
                       vector<bool>          &selected_dofs)
 {
   const FiniteElement<dim> &fe = dof.get_fe();
-  Assert(local_select.size() == fe.n_components,
-        ExcDimensionMismatch(local_select.size(), fe.n_components));
+  Assert(local_select.size() == fe.n_components(),
+        ExcDimensionMismatch(local_select.size(), fe.n_components()));
   Assert(selected_dofs.size() == dof.n_dofs(),
         ExcDimensionMismatch(selected_dofs.size(), dof.n_dofs()));
 
                                   // preset all values by false
   fill_n (selected_dofs.begin(), dof.n_dofs(), false);
   
-  vector<int> indices(fe.total_dofs);
+  vector<int> indices(fe.dofs_per_cell);
   
   DoFHandler<dim>::active_cell_iterator c;
   for (c = dof.begin_active() ; c != dof.end() ; ++ c)
     {
       c->get_dof_indices(indices);
-      for (unsigned int i=0;i<fe.total_dofs;++i)
+      for (unsigned int i=0;i<fe.dofs_per_cell;++i)
        {
          const unsigned int component = fe.system_to_component_index(i).first;
 
@@ -53,21 +53,21 @@ DoFTools::extract_level_dofs(const unsigned int       level,
                             vector<bool>            &selected_dofs)
 {
   const FiniteElement<dim>& fe = dof.get_fe();
-  Assert(local_select.size() == fe.n_components,
-        ExcDimensionMismatch(local_select.size(), fe.n_components));
+  Assert(local_select.size() == fe.n_components(),
+        ExcDimensionMismatch(local_select.size(), fe.n_components()));
   Assert(selected_dofs.size() == dof.n_dofs(level),
         ExcDimensionMismatch(selected_dofs.size(), dof.n_dofs(level)));
 
                                   // preset all values by false
   fill_n (selected_dofs.begin(), dof.n_dofs(level), false);
 
-  vector<int> indices(fe.total_dofs);
+  vector<int> indices(fe.dofs_per_cell);
   
   MGDoFHandler<dim>::cell_iterator c;
   for (c = dof.begin(level) ; c != dof.end(level) ; ++ c)
     {
       c->get_mg_dof_indices(indices);
-      for (unsigned int i=0;i<fe.total_dofs;++i)
+      for (unsigned int i=0;i<fe.dofs_per_cell;++i)
        {
          const unsigned int component = fe.system_to_component_index(i).first;
          if (local_select[component]  == true)
index 3ff7d0a9f84b1be0946486f5c4320ec703517e9c..0e72ae0e8f1be45ad7ce52fe7568ba1bfc2815b3 100644 (file)
@@ -528,7 +528,7 @@ MGDoFCellAccessor<1>::get_mg_dof_values (const Vector<double> &values,
   Assert (dof_handler != 0, DoFAccessor<1>::DoFAccessor<1>::ExcInvalidObject());
   Assert (mg_dof_handler != 0, DoFAccessor<1>::DoFAccessor<1>::ExcInvalidObject());
   Assert (&dof_handler->get_fe() != 0, DoFAccessor<1>::DoFAccessor<1>::ExcInvalidObject());
-  Assert (dof_values.size() == dof_handler->get_fe().total_dofs,
+  Assert (dof_values.size() == dof_handler->get_fe().dofs_per_cell,
          ExcVectorDoesNotMatch());
   Assert (values.size() == dof_handler->n_dofs(),
          ExcVectorDoesNotMatch());
@@ -565,7 +565,7 @@ MGDoFCellAccessor<2>::get_mg_dof_values (const Vector<double> &values,
   Assert (dof_handler != 0, DoFAccessor<2>::ExcInvalidObject());
   Assert (mg_dof_handler != 0, DoFAccessor<2>::ExcInvalidObject());
   Assert (&dof_handler->get_fe() != 0, DoFAccessor<2>::ExcInvalidObject());
-  Assert (dof_values.size() == dof_handler->get_fe().total_dofs,
+  Assert (dof_values.size() == dof_handler->get_fe().dofs_per_cell,
          DoFAccessor<2>::ExcVectorDoesNotMatch());
   Assert (values.size() == mg_dof_handler->n_dofs(present_level),
          DoFAccessor<2>::ExcVectorDoesNotMatch());
index 9d2763f25faf94f7b437d9e9b6d631c1aa1d3a75..0b4e5c4b482e56d0562b59c7be563db030ebe6f1 100644 (file)
@@ -1548,16 +1548,16 @@ void MGDoFHandler<dim>::make_sparsity_pattern (const unsigned int  level,
   Assert (sparsity.n_cols() == n_dofs(level),
          ExcDifferentDimensions (sparsity.n_cols(), n_dofs(level)));
 
-  const unsigned int total_dofs = selected_fe->total_dofs;
-  vector<int> dofs_on_this_cell(total_dofs);
+  const unsigned int dofs_per_cell = selected_fe->dofs_per_cell;
+  vector<int> dofs_on_this_cell(dofs_per_cell);
   cell_iterator cell = begin(level),
                endc = end(level);
   for (; cell!=endc; ++cell) 
     {
       cell->get_mg_dof_indices (dofs_on_this_cell);
                                       // make sparsity pattern for this cell
-      for (unsigned int i=0; i<total_dofs; ++i)
-       for (unsigned int j=0; j<total_dofs; ++j)
+      for (unsigned int i=0; i<dofs_per_cell; ++i)
+       for (unsigned int j=0; j<dofs_per_cell; ++j)
          sparsity.add (dofs_on_this_cell[i],
                        dofs_on_this_cell[j]);
     };
index 75c6200d563f81e1f580b747f73cb9b197e209c1..9c76b0f53a4aa9c6e1ff98fd841cf5e2b925811b 100644 (file)
@@ -33,9 +33,6 @@ FiniteElementData<dim>::FiniteElementData (const unsigned int dofs_per_vertex,
                dofs_per_line(dofs_per_line),
                dofs_per_quad(dofs_per_quad),
                dofs_per_hex(dofs_per_hex),
-               dofs_per_face(GeometryInfo<dim>::vertices_per_face * dofs_per_vertex+
-                             GeometryInfo<dim>::lines_per_face * dofs_per_line +
-                             dofs_per_quad),
                first_line_index(GeometryInfo<dim>::vertices_per_cell
                                 * dofs_per_vertex),
                first_quad_index(first_line_index+
@@ -49,9 +46,12 @@ FiniteElementData<dim>::FiniteElementData (const unsigned int dofs_per_vertex,
                first_face_quad_index(first_face_line_index+
                                      GeometryInfo<dim-1>::lines_per_cell
                                      * dofs_per_line),
-               total_dofs (first_hex_index+dofs_per_hex),
-               n_transform_functions (n_transform_functions),
-               n_components(n_components)
+               dofs_per_face(GeometryInfo<dim>::vertices_per_face * dofs_per_vertex+
+                             GeometryInfo<dim>::lines_per_face * dofs_per_line +
+                             dofs_per_quad),
+               dofs_per_cell (first_hex_index+dofs_per_hex),
+               transform_functions (n_transform_functions),
+               components(n_components)
 {
   Assert(dim==3, ExcDimensionMismatch(3,dim));
 };
@@ -68,8 +68,6 @@ FiniteElementData<dim>::FiniteElementData (const unsigned int dofs_per_vertex,
                dofs_per_line(dofs_per_line),
                dofs_per_quad(dofs_per_quad),
                dofs_per_hex(0),
-               dofs_per_face(GeometryInfo<dim>::vertices_per_face * dofs_per_vertex+
-                             dofs_per_line),
                first_line_index(GeometryInfo<dim>::vertices_per_cell * dofs_per_vertex),
                first_quad_index(first_line_index+
                                 GeometryInfo<dim>::lines_per_cell * dofs_per_line),
@@ -80,9 +78,11 @@ FiniteElementData<dim>::FiniteElementData (const unsigned int dofs_per_vertex,
                first_face_quad_index(first_line_index+
                                      GeometryInfo<dim-1>::lines_per_cell
                                      * dofs_per_line),
-               total_dofs (first_quad_index+dofs_per_quad),
-               n_transform_functions (n_transform_functions),
-               n_components(n_components)
+               dofs_per_face(GeometryInfo<dim>::vertices_per_face * dofs_per_vertex+
+                             dofs_per_line),
+               dofs_per_cell (first_quad_index+dofs_per_quad),
+               transform_functions (n_transform_functions),
+               components(n_components)
 {
   Assert(dim==2, ExcDimensionMismatch(2,dim));
 };
@@ -98,7 +98,6 @@ FiniteElementData<dim>::FiniteElementData (const unsigned int dofs_per_vertex,
                dofs_per_line(dofs_per_line),
                dofs_per_quad(0),
                dofs_per_hex(0),
-               dofs_per_face(dofs_per_vertex),
                first_line_index(GeometryInfo<dim>::vertices_per_cell * dofs_per_vertex),
                first_quad_index(first_line_index+
                                 GeometryInfo<dim>::lines_per_cell * dofs_per_line),
@@ -109,9 +108,10 @@ FiniteElementData<dim>::FiniteElementData (const unsigned int dofs_per_vertex,
                first_face_quad_index(first_line_index+
                                      GeometryInfo<dim-1>::lines_per_cell
                                      * dofs_per_line),
-               total_dofs (first_line_index+dofs_per_line),
-               n_transform_functions (n_transform_functions),
-               n_components(n_components)
+               dofs_per_face(dofs_per_vertex),
+               dofs_per_cell (first_line_index+dofs_per_line),
+               transform_functions (n_transform_functions),
+               components(n_components)
 {
   Assert(dim==1, ExcDimensionMismatch(1,dim));
 };
@@ -132,8 +132,8 @@ bool FiniteElementData<dim>::operator== (const FiniteElementData<dim> &f) const
          (dofs_per_line == f.dofs_per_line) &&
          (dofs_per_quad == f.dofs_per_quad) &&
          (dofs_per_hex == f.dofs_per_hex) &&
-         (n_transform_functions == f.n_transform_functions) &&
-         (n_components == f.n_components));
+         (transform_functions == f.transform_functions) &&
+         (components == f.components));
 };
 
 
@@ -146,20 +146,20 @@ template <int dim>
 FiniteElementBase<dim>::FiniteElementBase (const FiniteElementData<dim> &fe_data,
                                           const vector<bool> &restriction_is_additive_flags) :
                FiniteElementData<dim> (fe_data),
-               system_to_component_table(total_dofs),
+               system_to_component_table(dofs_per_cell),
                face_system_to_component_table(dofs_per_face),
-               component_to_system_table(n_components, vector<unsigned>(total_dofs)),
-               face_component_to_system_table(n_components, vector<unsigned>(dofs_per_face)),
-               component_to_base_table(n_components),
+               component_to_system_table(components, vector<unsigned>(dofs_per_cell)),
+               face_component_to_system_table(components, vector<unsigned>(dofs_per_face)),
+               component_to_base_table(components),
                restriction_is_additive_flags(restriction_is_additive_flags)
 {
-  Assert(restriction_is_additive_flags.size()==fe_data.n_components,
-        ExcWrongFieldDimension(restriction_is_additive_flags.size(),fe_data.n_components));
+  Assert(restriction_is_additive_flags.size()==fe_data.components,
+        ExcWrongFieldDimension(restriction_is_additive_flags.size(),fe_data.components));
 
   for (unsigned int i=0; i<GeometryInfo<dim>::children_per_cell; ++i) 
     {
-      restriction[i].reinit (total_dofs, total_dofs);
-      prolongation[i].reinit (total_dofs, total_dofs);
+      restriction[i].reinit (dofs_per_cell, dofs_per_cell);
+      prolongation[i].reinit (dofs_per_cell, dofs_per_cell);
     };
 
   switch (dim)
@@ -189,7 +189,7 @@ FiniteElementBase<dim>::FiniteElementBase (const FiniteElementData<dim> &fe_data
                                   // one component; if there are several, then
                                   // the constructor of the derived class needs
                                   // to fill these arrays
-  for (unsigned int j=0 ; j<total_dofs ; ++j)
+  for (unsigned int j=0 ; j<dofs_per_cell ; ++j)
     {
       system_to_component_table[j] = pair<unsigned,unsigned>(0,j);
       component_to_system_table[0][j] = j;
@@ -283,8 +283,8 @@ void FiniteElement<1>::fill_fe_values (const DoFHandler<1>::cell_iterator &cell,
          ExcWrongFieldDimension(jacobians_grad.size(), unit_points.size()));
   Assert ((!compute_q_points) || (q_points.size() == unit_points.size()),
          ExcWrongFieldDimension(q_points.size(), unit_points.size()));
-  Assert ((!compute_support_points) || (support_points.size() == total_dofs),
-         ExcWrongFieldDimension(support_points.size(), total_dofs));
+  Assert ((!compute_support_points) || (support_points.size() == dofs_per_cell),
+         ExcWrongFieldDimension(support_points.size(), dofs_per_cell));
 
 
                                   // local mesh width
@@ -364,8 +364,8 @@ void FiniteElement<1>::fill_fe_subface_values (const DoFHandler<1>::cell_iterato
 
 template <>
 void FiniteElement<1>::get_unit_support_points (vector<Point<1> > &support_points) const {
-  Assert (support_points.size() == total_dofs,
-         ExcWrongFieldDimension(support_points.size(), total_dofs));
+  Assert (support_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension(support_points.size(), dofs_per_cell));
                                   // compute support points. The first ones
                                   // belong to vertex one, the second ones
                                   // to vertex two, all following are
@@ -387,8 +387,8 @@ void FiniteElement<1>::get_unit_support_points (vector<Point<1> > &support_point
 template <>
 void FiniteElement<1>::get_support_points (const DoFHandler<1>::cell_iterator &cell,
                                           vector<Point<1> > &support_points) const {
-  Assert (support_points.size() == total_dofs,
-         ExcWrongFieldDimension(support_points.size(), total_dofs));
+  Assert (support_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension(support_points.size(), dofs_per_cell));
                                   // compute support points. The first ones
                                   // belong to vertex one, the second ones
                                   // to vertex two, all following are
index 53238f07637a2cd03ceecabf6cd33c06eaca7631..3c0adf2f3b31ee86a63dbb1ab52290a6168fbfad 100644 (file)
@@ -516,7 +516,7 @@ inline
 double FECrissCross<2>::shape_value (const unsigned int i,
                                     const Point<2>    &p) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
 
   const double x = p(0),
               y = p(1);
@@ -544,7 +544,7 @@ template <>
 inline
 Tensor<1,2> FECrissCross<2>::shape_grad (const unsigned int i, const Point<2> &p) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
 
   const double x = p(0),
               y = p(1);  
@@ -573,7 +573,7 @@ Tensor<2,2>
 FECrissCross<2>::shape_grad_grad (const unsigned int i,
                                  const Point<2> &) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
                                   // second derivatives on the unit cell
                                   // are always zero, at least almost
                                   // everywhere. see the doc for more
@@ -585,8 +585,8 @@ FECrissCross<2>::shape_grad_grad (const unsigned int i,
 
 template <>
 void FECrissCross<2>::get_unit_support_points (vector<Point<2> > &unit_points) const {
-  Assert(unit_points.size()==total_dofs,
-         ExcWrongFieldDimension (unit_points.size(), total_dofs));
+  Assert(unit_points.size()==dofs_per_cell,
+         ExcWrongFieldDimension (unit_points.size(), dofs_per_cell));
 
   unit_points[0] = Point<2> (0,0);
   unit_points[1] = Point<2> (1,0);
@@ -602,8 +602,8 @@ void FECrissCross<2>::get_support_points (const DoFHandler<2>::cell_iterator &ce
                                          vector<Point<2> > &support_points) const {
   const unsigned int dim = 2;
   
-  Assert (support_points.size() == total_dofs,
-         ExcWrongFieldDimension (support_points.size(), total_dofs));
+  Assert (support_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension (support_points.size(), dofs_per_cell));
 
                                   // copy vertices
   for (unsigned int vertex=0; vertex<GeometryInfo<dim>::vertices_per_cell; ++vertex)
@@ -653,10 +653,10 @@ void FECrissCross<2>::get_face_support_points (const DoFHandler<2>::face_iterato
 template <>
 void FECrissCross<2>::get_local_mass_matrix (const DoFHandler<2>::cell_iterator &cell,
                                             FullMatrix<double> &mass_matrix) const {
-  Assert (mass_matrix.n() == total_dofs,
-         ExcWrongFieldDimension(mass_matrix.n(),total_dofs));
-  Assert (mass_matrix.m() == total_dofs,
-         ExcWrongFieldDimension(mass_matrix.m(),total_dofs));
+  Assert (mass_matrix.n() == dofs_per_cell,
+         ExcWrongFieldDimension(mass_matrix.n(),dofs_per_cell));
+  Assert (mass_matrix.m() == dofs_per_cell,
+         ExcWrongFieldDimension(mass_matrix.m(),dofs_per_cell));
 
   const double x[4] = { cell->vertex(0)(0),
                        cell->vertex(1)(0),
@@ -941,8 +941,8 @@ void FECrissCross<dim>::fill_fe_values (const DoFHandler<dim>::cell_iterator &ce
          ExcWrongFieldDimension(jacobians.size(), unit_points.size()));
   Assert (q_points.size() == unit_points.size(),
          ExcWrongFieldDimension(q_points.size(), unit_points.size()));
-  Assert (support_points.size() == total_dofs,
-         ExcWrongFieldDimension(support_points.size(), total_dofs));
+  Assert (support_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension(support_points.size(), dofs_per_cell));
 
   
   unsigned int n_points=unit_points.size();
@@ -966,7 +966,7 @@ void FECrissCross<dim>::fill_fe_values (const DoFHandler<dim>::cell_iterator &ce
                                       // N_j(xi_l) be the value of the associated
                                       // basis function at xi_l, then
                                       // x_l(xi_l) = sum_j p_j N_j(xi_l)
-      for (unsigned int j=0; j<n_transform_functions; ++j) 
+      for (unsigned int j=0; j<n_transform_functions(); ++j) 
        for (unsigned int l=0; l<n_points; ++l) 
          q_points[l] += support_points[j] * shape_values_transform(j, l);
     };
index 8a99f20dc90dd0054f21ad1ca158a871295a4f6d..e5c37f342d49d24fc5db786428c8cbbdf779d7e7 100644 (file)
@@ -115,7 +115,7 @@ double
 FEQ3<1>::shape_value (const unsigned int i,
                            const Point<1>     &p) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
   const double xi = p(0);
   switch (i)
     {
@@ -134,7 +134,7 @@ Tensor<1,1>
 FEQ3<1>::shape_grad (const unsigned int i,
                           const Point<1>    &p) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
   const double xi = p(0);
                                   // originally, the return type of the
                                   // function was Point<dim>, so we
@@ -158,7 +158,7 @@ Tensor<2,1>
 FEQ3<1>::shape_grad_grad (const unsigned int i,
                                const Point<1>    &p) const
 {
-  Assert (i<total_dofs, ExcIndexRange(i, 0, total_dofs));
+  Assert (i<dofs_per_cell, ExcIndexRange(i, 0, dofs_per_cell));
 
   const double xi = p(0);
   Tensor<2,1> return_value;
@@ -201,10 +201,10 @@ void FEQ3<1>::get_face_support_points (const DoFHandler<1>::face_iterator &,
 template <>
 void FEQ3<1>::get_local_mass_matrix (const DoFHandler<1>::cell_iterator &cell,
                                     FullMatrix<double> &local_mass_matrix) const {
-  Assert (local_mass_matrix.n() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.n(),total_dofs));
-  Assert (local_mass_matrix.m() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.m(),total_dofs));
+  Assert (local_mass_matrix.n() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.n(),dofs_per_cell));
+  Assert (local_mass_matrix.m() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.m(),dofs_per_cell));
 
   const double h = cell->vertex(1)(0) - cell->vertex(0)(0);
   Assert (h>0, ExcJacobiDeterminantHasWrongSign());
@@ -703,7 +703,7 @@ double
 FEQ3<2>::shape_value (const unsigned int i,
                                const Point<2>    &p) const
 {
-  Assert (i<total_dofs, ExcIndexRange(i, 0, total_dofs));
+  Assert (i<dofs_per_cell, ExcIndexRange(i, 0, dofs_per_cell));
 
   const double xi = p(0),
               eta= p(1);
@@ -769,7 +769,7 @@ Tensor<1,2>
 FEQ3<2>::shape_grad (const unsigned int i,
                               const Point<2>    &p) const
 {
-  Assert (i<total_dofs, ExcIndexRange(i, 0, total_dofs));
+  Assert (i<dofs_per_cell, ExcIndexRange(i, 0, dofs_per_cell));
 
   const double xi = p(0),
               eta= p(1);
@@ -823,7 +823,7 @@ Tensor<2,2>
 FEQ3<2>::shape_grad_grad (const unsigned int i,
                                const Point<2>    &p) const
 {
-  Assert (i<total_dofs, ExcIndexRange(i, 0, total_dofs));
+  Assert (i<dofs_per_cell, ExcIndexRange(i, 0, dofs_per_cell));
 
   const double xi = p(0),
               eta= p(1);
@@ -924,10 +924,10 @@ FEQ3<2>::shape_grad_grad (const unsigned int i,
 template <>
 void FEQ3<2>::get_local_mass_matrix (const DoFHandler<2>::cell_iterator &cell,
                                           FullMatrix<double> &local_mass_matrix) const {
-  Assert (local_mass_matrix.n() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.n(),total_dofs));
-  Assert (local_mass_matrix.m() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.m(),total_dofs));
+  Assert (local_mass_matrix.n() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.n(),dofs_per_cell));
+  Assert (local_mass_matrix.m() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.m(),dofs_per_cell));
 
   const double x[4] = { cell->vertex(0)(0),
                        cell->vertex(1)(0),
@@ -1485,8 +1485,8 @@ void FEQ3<2>::get_local_mass_matrix (const DoFHandler<2>::cell_iterator &cell,
 
 template <>
 void FEQ3<2>::get_unit_support_points (vector<Point<2> > &unit_points) const {
-  Assert (unit_points.size() == total_dofs,
-         ExcWrongFieldDimension (unit_points.size(), total_dofs));
+  Assert (unit_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension (unit_points.size(), dofs_per_cell));
 
   unit_points[0] = Point<2>(0,0);
   unit_points[1] = Point<2>(1,0);
@@ -1511,8 +1511,8 @@ void FEQ3<2>::get_unit_support_points (vector<Point<2> > &unit_points) const {
 template <>
 void FEQ3<2>::get_support_points (const DoFHandler<2>::cell_iterator &cell,
                                  vector<Point<2> >  &support_points) const {
-  Assert (support_points.size() == total_dofs,
-         ExcWrongFieldDimension (support_points.size(), total_dofs));
+  Assert (support_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension (support_points.size(), dofs_per_cell));
 
   const double x[4] = { cell->vertex(0)(0),
                        cell->vertex(1)(0),
@@ -9955,7 +9955,7 @@ double
 FEQ3<3>::shape_value (const unsigned int i,
                            const Point<3>    &p) const
 {
-  Assert (i<total_dofs, ExcIndexRange(i, 0, total_dofs));
+  Assert (i<dofs_per_cell, ExcIndexRange(i, 0, dofs_per_cell));
 
   const double xi  = p(0),
               eta = p(1),
@@ -10568,7 +10568,7 @@ Tensor<1,3>
 FEQ3<3>::shape_grad (const unsigned int i,
                               const Point<3>    &p) const
 {
-  Assert (i<total_dofs, ExcIndexRange(i, 0, total_dofs));
+  Assert (i<dofs_per_cell, ExcIndexRange(i, 0, dofs_per_cell));
 
   const double xi  = p(0),
               eta = p(1),
@@ -10783,7 +10783,7 @@ Tensor<2,3>
 FEQ3<3>::shape_grad_grad (const unsigned int i,
                                const Point<3>    &p) const
 {
-  Assert (i<total_dofs, ExcIndexRange(i, 0, total_dofs));
+  Assert (i<dofs_per_cell, ExcIndexRange(i, 0, dofs_per_cell));
 
   const double xi  = p(0),
               eta = p(1),
@@ -11399,10 +11399,10 @@ void
 FEQ3<3>::get_local_mass_matrix (const DoFHandler<3>::cell_iterator &,
                                      FullMatrix<double> &local_mass_matrix) const
 {
-  Assert (local_mass_matrix.n() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.n(),total_dofs));
-  Assert (local_mass_matrix.m() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.m(),total_dofs));
+  Assert (local_mass_matrix.n() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.n(),dofs_per_cell));
+  Assert (local_mass_matrix.m() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.m(),dofs_per_cell));
 
   AssertThrow (false, ExcComputationNotUseful(3));
 };
@@ -11411,8 +11411,8 @@ FEQ3<3>::get_local_mass_matrix (const DoFHandler<3>::cell_iterator &,
 
 template <>
 void FEQ3<3>::get_unit_support_points (vector<Point<3> > &unit_points) const {
-  Assert (unit_points.size() == total_dofs,
-         ExcWrongFieldDimension (unit_points.size(), total_dofs));
+  Assert (unit_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension (unit_points.size(), dofs_per_cell));
   unit_points[0] = Point<3>(0, 0, 0);
   unit_points[1] = Point<3>(1, 0, 0);
   unit_points[2] = Point<3>(1, 0, 1);
@@ -11484,8 +11484,8 @@ void FEQ3<3>::get_unit_support_points (vector<Point<3> > &unit_points) const {
 template <>
 void FEQ3<3>::get_support_points (const typename DoFHandler<3>::cell_iterator &cell,
                                        vector<Point<3> >  &support_points) const {
-  Assert (support_points.size() == total_dofs,
-         ExcWrongFieldDimension (support_points.size(), total_dofs));
+  Assert (support_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension (support_points.size(), dofs_per_cell));
 
   const Point<3> vertices[8] = { cell->vertex(0),
                                 cell->vertex(1),
index a9d8810202d6134c2886a31ef79aaeeba13f9117..0c98e7ccbb8bd9296c572cab9157f7091900cc8f 100644 (file)
@@ -48,7 +48,7 @@ double
 FEDG_Q0<dim>::shape_value (const unsigned int i,
                                const Point<dim>&) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
   return 1.;
 };
 
@@ -60,7 +60,7 @@ Tensor<1,dim>
 FEDG_Q0<dim>::shape_grad (const unsigned int i,
                               const Point<dim>&) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
   return Tensor<1,dim> ();
 };
 
@@ -72,7 +72,7 @@ Tensor<2,dim>
 FEDG_Q0<dim>::shape_grad_grad (const unsigned int i,
                                  const Point<dim> &) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
 
   return Tensor<2,dim>();
 };
@@ -82,10 +82,10 @@ FEDG_Q0<dim>::shape_grad_grad (const unsigned int i,
 template <int dim>
 void FEDG_Q0<dim>::get_local_mass_matrix (const DoFHandler<dim>::cell_iterator &cell,
                                               FullMatrix<double> &local_mass_matrix) const {
-  Assert (local_mass_matrix.n() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.n(),total_dofs));
-  Assert (local_mass_matrix.m() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.m(),total_dofs));
+  Assert (local_mass_matrix.n() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.n(),dofs_per_cell));
+  Assert (local_mass_matrix.m() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.m(),dofs_per_cell));
 
   local_mass_matrix(0,0) = cell->measure();
 };
@@ -95,8 +95,8 @@ void FEDG_Q0<dim>::get_local_mass_matrix (const DoFHandler<dim>::cell_iterator &
 template <int dim>
 void
 FEDG_Q0<dim>::get_unit_support_points (vector<Point<dim> > &unit_points) const {
-  Assert (unit_points.size() == total_dofs,
-         ExcWrongFieldDimension (unit_points.size(), total_dofs));
+  Assert (unit_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension (unit_points.size(), dofs_per_cell));
   for (unsigned int d=0; d<dim; ++d)
     unit_points[0](d) = 0.5;
 };
@@ -106,8 +106,8 @@ template <int dim>
 void
 FEDG_Q0<dim>::get_support_points (const typename DoFHandler<dim>::cell_iterator &cell,
                                       vector<Point<dim> >  &support_points) const {
-  Assert (support_points.size() == total_dofs,
-         ExcWrongFieldDimension (support_points.size(), total_dofs));
+  Assert (support_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension (support_points.size(), dofs_per_cell));
   
   support_points[0] = cell->center();
 };
index 4778488d2ec5089fb2e409daeff1c23bd45733a8..1bea588b69137195d11bdc7bef15de284711043e 100644 (file)
@@ -73,7 +73,7 @@ double
 FEQ1<1>::shape_value(const unsigned int i,
                         const Point<1>     &p) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
   switch (i)
     {
     case 0: return 1.-p(0);
@@ -90,7 +90,7 @@ Tensor<1,1>
 FEQ1<1>::shape_grad(const unsigned int i,
                        const Point<1>&) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
                                   // originally, the return type of the
                                   // function was Point<dim>, so we
                                   // still construct it as that. it should
@@ -112,7 +112,7 @@ Tensor<2,1>
 FEQ1<1>::shape_grad_grad (const unsigned int i,
                              const Point<1> &) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
                                   // second derivatives on the unit cell
                                   // are always zero
   return Tensor<2,1>();
@@ -146,10 +146,10 @@ void FEQ1<1>::get_face_support_points (const DoFHandler<1>::face_iterator &,
 template <>
 void FEQ1<1>::get_local_mass_matrix (const DoFHandler<1>::cell_iterator &cell,
                                         FullMatrix<double> &local_mass_matrix) const {
-  Assert (local_mass_matrix.n() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.n(),total_dofs));
-  Assert (local_mass_matrix.m() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.m(),total_dofs));
+  Assert (local_mass_matrix.n() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.n(),dofs_per_cell));
+  Assert (local_mass_matrix.m() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.m(),dofs_per_cell));
 
   const double h = cell->vertex(1)(0) - cell->vertex(0)(0);
   Assert (h>0, ExcJacobiDeterminantHasWrongSign());
@@ -245,7 +245,7 @@ double
 FEQ1<2>::shape_value (const unsigned int i,
                          const Point<2>& p) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
   switch (i)
     {
       case 0: return (1.-p(0)) * (1.-p(1));
@@ -264,7 +264,7 @@ Tensor<1,2>
 FEQ1<2>::shape_grad (const unsigned int i,
                         const Point<2>& p) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
                                   // originally, the return type of the
                                   // function was Point<dim>, so we
                                   // still construct it as that. it should
@@ -288,7 +288,7 @@ Tensor<2,2>
 FEQ1<2>::shape_grad_grad (const unsigned int i,
                              const Point<2> &) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
 
   switch (i)
     {
@@ -315,10 +315,10 @@ FEQ1<2>::shape_grad_grad (const unsigned int i,
 template <>
 void FEQ1<2>::get_local_mass_matrix (const DoFHandler<2>::cell_iterator &cell,
                                         FullMatrix<double> &local_mass_matrix) const {
-  Assert (local_mass_matrix.n() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.n(),total_dofs));
-  Assert (local_mass_matrix.m() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.m(),total_dofs));
+  Assert (local_mass_matrix.n() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.n(),dofs_per_cell));
+  Assert (local_mass_matrix.m() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.m(),dofs_per_cell));
 
 /* Get the computation of the local mass matrix by these lines in maple:
 
@@ -420,8 +420,8 @@ void FEQ1<2>::get_local_mass_matrix (const DoFHandler<2>::cell_iterator &cell,
 
 template <>
 void FEQ1<2>::get_unit_support_points (vector<Point<2> > &unit_points) const {
-  Assert (unit_points.size() == total_dofs,
-         ExcWrongFieldDimension (unit_points.size(), total_dofs));
+  Assert (unit_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension (unit_points.size(), dofs_per_cell));
 
   unit_points[0] = Point<2> (0,0);
   unit_points[1] = Point<2> (1,0);
@@ -706,7 +706,7 @@ double
 FEQ1<3>::shape_value (const unsigned int i,
                          const Point<3>& p) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
   switch (i)
     {
       case 0: return 1.0-p(0)+(-1.0+p(0))*p(1)+(-1.0+p(0)+(1.0-p(0))*p(1))*p(2);
@@ -729,7 +729,7 @@ Tensor<1,3>
 FEQ1<3>::shape_grad (const unsigned int i,
                         const Point<3>& p) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
                                   // originally, the return type of the
                                   // function was Point<dim>, so we
                                   // still construct it as that. it should
@@ -773,7 +773,7 @@ Tensor<2,3>
 FEQ1<3>::shape_grad_grad (const unsigned int i,
                              const Point<3> &p) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
 
   Tensor<2,3> return_value;
   
@@ -852,10 +852,10 @@ FEQ1<3>::shape_grad_grad (const unsigned int i,
 template <>
 void FEQ1<3>::get_local_mass_matrix (const DoFHandler<3>::cell_iterator &,
                                         FullMatrix<double> &local_mass_matrix) const {
-  Assert (local_mass_matrix.n() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.n(),total_dofs));
-  Assert (local_mass_matrix.m() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.m(),total_dofs));
+  Assert (local_mass_matrix.n() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.n(),dofs_per_cell));
+  Assert (local_mass_matrix.m() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.m(),dofs_per_cell));
 
   AssertThrow (false, ExcComputationNotUseful(3));
 };
@@ -864,8 +864,8 @@ void FEQ1<3>::get_local_mass_matrix (const DoFHandler<3>::cell_iterator &,
 
 template <>
 void FEQ1<3>::get_unit_support_points (vector<Point<3> > &unit_points) const {
-  Assert (unit_points.size() == total_dofs,
-         ExcWrongFieldDimension (unit_points.size(), total_dofs));
+  Assert (unit_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension (unit_points.size(), dofs_per_cell));
 
   unit_points[0] = Point<3> (0,0,0);
   unit_points[1] = Point<3> (1,0,0);
@@ -886,8 +886,8 @@ template <int dim>
 void
 FEQ1<dim>::get_support_points (const typename DoFHandler<dim>::cell_iterator &cell,
                                   vector<Point<dim> >  &support_points) const {
-  Assert (support_points.size() == total_dofs,
-         ExcWrongFieldDimension (support_points.size(), total_dofs));
+  Assert (support_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension (support_points.size(), dofs_per_cell));
   
   for (unsigned int vertex=0; vertex<GeometryInfo<dim>::vertices_per_cell; ++vertex)
     support_points[vertex] = cell->vertex(vertex);
index 0dd21c0f68b8cd29991b59a0d0a6a7b4eb9e9d85..afcda64e039153ad7b768339f09900671c99a02b 100644 (file)
@@ -125,7 +125,7 @@ double
 FEQ2<1>::shape_value(const unsigned int i,
                     const Point<1>     &p) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
   const double xi = p(0);
   switch (i)
     {
@@ -143,7 +143,7 @@ Tensor<1,1>
 FEQ2<1>::shape_grad(const unsigned int i,
                    const Point<1>    &p) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
   const double xi = p(0);
                                   // originally, the return type of the
                                   // function was Point<dim>, so we
@@ -166,7 +166,7 @@ Tensor<2,1>
 FEQ2<1>::shape_grad_grad (const unsigned int i,
                          const Point<1>    &) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
 
   Tensor<2,1> return_value;
   switch (i)
@@ -212,10 +212,10 @@ void FEQ2<1>::get_face_support_points (const DoFHandler<1>::face_iterator &,
 template <>
 void FEQ2<1>::get_local_mass_matrix (const DoFHandler<1>::cell_iterator &cell,
                                     FullMatrix<double> &local_mass_matrix) const {
-  Assert (local_mass_matrix.n() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.n(),total_dofs));
-  Assert (local_mass_matrix.m() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.m(),total_dofs));
+  Assert (local_mass_matrix.n() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.n(),dofs_per_cell));
+  Assert (local_mass_matrix.m() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.m(),dofs_per_cell));
 
   const double h = cell->vertex(1)(0) - cell->vertex(0)(0);
   Assert (h>0, ExcJacobiDeterminantHasWrongSign());
@@ -651,7 +651,7 @@ double
 FEQ2<2>::shape_value (const unsigned int i,
                                const Point<2>    &p) const
 {
-  Assert (i<total_dofs, ExcIndexRange(i, 0, total_dofs));
+  Assert (i<dofs_per_cell, ExcIndexRange(i, 0, dofs_per_cell));
 
   const double xi = p(0),
               eta= p(1);
@@ -677,7 +677,7 @@ Tensor<1,2>
 FEQ2<2>::shape_grad (const unsigned int i,
                               const Point<2>    &p) const
 {
-  Assert (i<total_dofs, ExcIndexRange(i, 0, total_dofs));
+  Assert (i<dofs_per_cell, ExcIndexRange(i, 0, dofs_per_cell));
 
   const double xi = p(0),
               eta= p(1);
@@ -717,7 +717,7 @@ Tensor<2,2>
 FEQ2<2>::shape_grad_grad (const unsigned int i,
                                    const Point<2>    &p) const
 {
-  Assert (i<total_dofs, ExcIndexRange(i, 0, total_dofs));
+  Assert (i<dofs_per_cell, ExcIndexRange(i, 0, dofs_per_cell));
 
   const double xi = p(0),
               eta= p(1);
@@ -788,10 +788,10 @@ FEQ2<2>::shape_grad_grad (const unsigned int i,
 template <>
 void FEQ2<2>::get_local_mass_matrix (const DoFHandler<2>::cell_iterator &cell,
                                               FullMatrix<double> &local_mass_matrix) const {
-  Assert (local_mass_matrix.n() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.n(),total_dofs));
-  Assert (local_mass_matrix.m() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.m(),total_dofs));
+  Assert (local_mass_matrix.n() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.n(),dofs_per_cell));
+  Assert (local_mass_matrix.m() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.m(),dofs_per_cell));
 
 /* Get the computation of the local mass matrix by these lines in maple. Note
    that tphi[i] are the basis function of the linear finite element, which
@@ -1062,8 +1062,8 @@ void FEQ2<2>::get_local_mass_matrix (const DoFHandler<2>::cell_iterator &cell,
 
 template <>
 void FEQ2<2>::get_unit_support_points (vector<Point<2> > &unit_points) const {
-  Assert (unit_points.size() == total_dofs,
-         ExcWrongFieldDimension (unit_points.size(), total_dofs));
+  Assert (unit_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension (unit_points.size(), dofs_per_cell));
   
   unit_points[0] = Point<2> (0,0);
   unit_points[1] = Point<2> (1,0);
@@ -1081,8 +1081,8 @@ void FEQ2<2>::get_unit_support_points (vector<Point<2> > &unit_points) const {
 template <>
 void FEQ2<2>::get_support_points (const DoFHandler<2>::cell_iterator &cell,
                                  vector<Point<2> >  &support_points) const {
-  Assert (support_points.size() == total_dofs,
-         ExcWrongFieldDimension (support_points.size(), total_dofs));
+  Assert (support_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension (support_points.size(), dofs_per_cell));
   
   for (unsigned int vertex=0; vertex<4; ++vertex)
     support_points[vertex] = cell->vertex(vertex);
@@ -2297,7 +2297,7 @@ double
 FEQ2<3>::shape_value (const unsigned int i,
                                const Point<3>    &p) const
 {
-  Assert (i<total_dofs, ExcIndexRange(i, 0, total_dofs));
+  Assert (i<dofs_per_cell, ExcIndexRange(i, 0, dofs_per_cell));
 
   const double xi  = p(0),
               eta = p(1),
@@ -2391,7 +2391,7 @@ Tensor<1,3>
 FEQ2<3>::shape_grad (const unsigned int i,
                               const Point<3>    &p) const
 {
-  Assert (i<total_dofs, ExcIndexRange(i, 0, total_dofs));
+  Assert (i<dofs_per_cell, ExcIndexRange(i, 0, dofs_per_cell));
 
   const double xi  = p(0),
               eta = p(1),
@@ -2495,7 +2495,7 @@ Tensor<2,3>
 FEQ2<3>::shape_grad_grad (const unsigned int i,
                                    const Point<3>    &p) const
 {
-  Assert (i<total_dofs, ExcIndexRange(i, 0, total_dofs));
+  Assert (i<dofs_per_cell, ExcIndexRange(i, 0, dofs_per_cell));
 
   const double xi  = p(0),
               eta = p(1),
@@ -2777,10 +2777,10 @@ return_value[2][2] = 2.0*(-64.0*xi+64.0*xi*xi)*eta+2.0*(64.0*xi-64.0*xi*xi)*eta*
 template <>
 void FEQ2<3>::get_local_mass_matrix (const DoFHandler<3>::cell_iterator &,
                                               FullMatrix<double> &local_mass_matrix) const {
-  Assert (local_mass_matrix.n() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.n(),total_dofs));
-  Assert (local_mass_matrix.m() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.m(),total_dofs));
+  Assert (local_mass_matrix.n() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.n(),dofs_per_cell));
+  Assert (local_mass_matrix.m() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.m(),dofs_per_cell));
 
   AssertThrow (false, ExcComputationNotUseful(3));
 };
@@ -2789,8 +2789,8 @@ void FEQ2<3>::get_local_mass_matrix (const DoFHandler<3>::cell_iterator &,
 
 template <>
 void FEQ2<3>::get_unit_support_points (vector<Point<3> > &unit_points) const {
-  Assert (unit_points.size() == total_dofs,
-         ExcWrongFieldDimension (unit_points.size(), total_dofs));
+  Assert (unit_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension (unit_points.size(), dofs_per_cell));
   
   unit_points[0] = Point<3>(0, 0, 0);
   unit_points[1] = Point<3>(1, 0, 0);
@@ -2826,8 +2826,8 @@ void FEQ2<3>::get_unit_support_points (vector<Point<3> > &unit_points) const {
 template <>
 void FEQ2<3>::get_support_points (const DoFHandler<3>::cell_iterator &cell,
                                  vector<Point<3> >  &support_points) const {
-  Assert (support_points.size() == total_dofs,
-         ExcWrongFieldDimension (support_points.size(), total_dofs));
+  Assert (support_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension (support_points.size(), dofs_per_cell));
 
   const Point<3> vertices[8] = { cell->vertex(0),
                                 cell->vertex(1),
index 9ee95948427f7bd572315fef6a52f3e76a143964..0ea1ef55dcf26237bcc7add20878221331074b8a 100644 (file)
@@ -79,7 +79,7 @@ double
 FEQ4<1>::shape_value(const unsigned int i,
                             const Point<1>     &p) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
   const double xi = p(0);
   switch (i)
     {
@@ -99,7 +99,7 @@ Tensor<1,1>
 FEQ4<1>::shape_grad(const unsigned int i,
                            const Point<1>    &p) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
   const double xi = p(0);
                                   // originally, the return type of the
                                   // function was Point<dim>, so we
@@ -124,7 +124,7 @@ Tensor<2,1>
 FEQ4<1>::shape_grad_grad (const unsigned int i,
                                  const Point<1>    &p) const
 {
-  Assert (i<total_dofs, ExcIndexRange(i, 0, total_dofs));
+  Assert (i<dofs_per_cell, ExcIndexRange(i, 0, dofs_per_cell));
 
   const double xi = p(0);
   Tensor<2,1> return_value;
@@ -168,10 +168,10 @@ void FEQ4<1>::get_face_support_points (const DoFHandler<1>::face_iterator &,
 template <>
 void FEQ4<1>::get_local_mass_matrix (const DoFHandler<1>::cell_iterator &cell,
                                             FullMatrix<double> &local_mass_matrix) const {
-  Assert (local_mass_matrix.n() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.n(),total_dofs));
-  Assert (local_mass_matrix.m() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.m(),total_dofs));
+  Assert (local_mass_matrix.n() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.n(),dofs_per_cell));
+  Assert (local_mass_matrix.m() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.m(),dofs_per_cell));
 
   const double h = cell->vertex(1)(0) - cell->vertex(0)(0);
   Assert (h>0, ExcJacobiDeterminantHasWrongSign());
@@ -985,7 +985,7 @@ double
 FEQ4<2>::shape_value (const unsigned int i,
                              const Point<2>    &p) const
 {
-  Assert (i<total_dofs, ExcIndexRange(i, 0, total_dofs));
+  Assert (i<dofs_per_cell, ExcIndexRange(i, 0, dofs_per_cell));
 
   const double xi = p(0),
               eta= p(1);
@@ -1133,7 +1133,7 @@ Tensor<1,2>
 FEQ4<2>::shape_grad (const unsigned int i,
                             const Point<2>    &p) const
 {
-  Assert (i<total_dofs, ExcIndexRange(i, 0, total_dofs));
+  Assert (i<dofs_per_cell, ExcIndexRange(i, 0, dofs_per_cell));
 
   const double xi = p(0),
               eta= p(1);
@@ -1205,7 +1205,7 @@ Tensor<2,2>
 FEQ4<2>::shape_grad_grad (const unsigned int i,
                                  const Point<2>    &p) const
 {
-  Assert (i<total_dofs, ExcIndexRange(i, 0, total_dofs));
+  Assert (i<dofs_per_cell, ExcIndexRange(i, 0, dofs_per_cell));
 
   const double xi = p(0),
               eta= p(1);
@@ -1342,10 +1342,10 @@ FEQ4<2>::shape_grad_grad (const unsigned int i,
 template <>
 void FEQ4<2>::get_local_mass_matrix (const DoFHandler<2>::cell_iterator &cell,
                                             FullMatrix<double> &local_mass_matrix) const {
-  Assert (local_mass_matrix.n() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.n(),total_dofs));
-  Assert (local_mass_matrix.m() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.m(),total_dofs));
+  Assert (local_mass_matrix.n() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.n(),dofs_per_cell));
+  Assert (local_mass_matrix.m() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.m(),dofs_per_cell));
 
   const double x[4] = { cell->vertex(0)(0),
                        cell->vertex(1)(0),
@@ -2607,8 +2607,8 @@ void FEQ4<2>::get_local_mass_matrix (const DoFHandler<2>::cell_iterator &cell,
 
 template <>
 void FEQ4<2>::get_unit_support_points (vector<Point<2> > &unit_points) const {
-  Assert (unit_points.size() == total_dofs,
-         ExcWrongFieldDimension (unit_points.size(), total_dofs));
+  Assert (unit_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension (unit_points.size(), dofs_per_cell));
 
   unit_points[0] = Point<2>(0,0);
   unit_points[1] = Point<2>(1,0);
@@ -2642,8 +2642,8 @@ void FEQ4<2>::get_unit_support_points (vector<Point<2> > &unit_points) const {
 template <>
 void FEQ4<2>::get_support_points (const DoFHandler<2>::cell_iterator &cell,
                                  vector<Point<2> >  &support_points) const {
-  Assert (support_points.size() == total_dofs,
-         ExcWrongFieldDimension (support_points.size(), total_dofs));
+  Assert (support_points.size() == dofs_per_cell,
+         ExcWrongFieldDimension (support_points.size(), dofs_per_cell));
 
   const double x[4] = { cell->vertex(0)(0),
                        cell->vertex(1)(0),
index bc0afdb8dd0132d6624507d164e2acc9a3fa1e20..eb1f27b455830ecec238c917aeb572a8fe6aba8d 100644 (file)
@@ -141,11 +141,11 @@ FESystem<dim>::build_cell_table()
                                   // Initialize mapping from components to
                                   // linear index. Fortunately, this is
                                   // the inverse of what we just did.
-  for (unsigned int comp=0 ; comp<n_components ; ++comp)
+  for (unsigned int comp=0 ; comp<n_components() ; ++comp)
     component_to_system_table[comp]
-      .resize(base_element(component_to_base_table[comp]).total_dofs);
+      .resize(base_element(component_to_base_table[comp]).dofs_per_cell);
 
-  for (unsigned int sys=0 ; sys < total_dofs ; ++sys)
+  for (unsigned int sys=0 ; sys < dofs_per_cell ; ++sys)
     component_to_system_table[system_to_component_table[sys].first]
       [system_to_component_table[sys].second] = sys;
 }
@@ -252,9 +252,9 @@ FESystem<dim>::build_face_table()
                                   // Initialize mapping from components to
                                   // linear index. Fortunately, this is
                                   // the inverse of what we just did.
-  for (unsigned comp=0 ; comp<n_components ; ++comp)
+  for (unsigned comp=0 ; comp<n_components() ; ++comp)
     face_component_to_system_table[comp]
-      .resize(base_element(component_to_base_table[comp]).total_dofs);
+      .resize(base_element(component_to_base_table[comp]).dofs_per_cell);
 
   for (unsigned sys=0 ; sys < dofs_per_face ; ++sys)
     face_component_to_system_table[face_system_to_component_table[sys].first]
@@ -468,11 +468,11 @@ void FESystem<dim>::initialize ()
                                   // distribute the matrices of the base
                                   // finite elements to the matrices of
                                   // this object
-  for (unsigned int component=0; component<n_components; ++component)
+  for (unsigned int component=0; component<n_components(); ++component)
                                     // transform restriction and
                                     // prolongation matrices
-    for (unsigned int i=0; i<base_element(component_to_base_table[component]).total_dofs; ++i)
-      for (unsigned int j=0; j<base_element(component_to_base_table[component]).total_dofs; ++j)
+    for (unsigned int i=0; i<base_element(component_to_base_table[component]).dofs_per_cell; ++i)
+      for (unsigned int j=0; j<base_element(component_to_base_table[component]).dofs_per_cell; ++j)
                                         // only fill block diagonals, no
                                         // intermixing of subelements
        for (unsigned int child=0; child<GeometryInfo<dim>::children_per_cell; ++child)
@@ -504,8 +504,8 @@ FESystem<1>::multiply_dof_numbers (const FiniteElementData<1> &fe_data,
 {
   return FiniteElementData<1> (fe_data.dofs_per_vertex * N,
                               fe_data.dofs_per_line * N,
-                              fe_data.n_transform_functions,
-                              fe_data.n_components * N);
+                              fe_data.n_transform_functions(),
+                              fe_data.n_components() * N);
 };
 
 
@@ -518,8 +518,8 @@ FESystem<1>::multiply_dof_numbers (const FiniteElementData<1> &fe1,
 {
   return FiniteElementData<1> (fe1.dofs_per_vertex * N1 + fe2.dofs_per_vertex * N2 ,
                               fe1.dofs_per_line * N1 + fe2.dofs_per_line * N2 ,
-                              fe1.n_transform_functions,
-                              fe1.n_components * N1 + fe2.n_components * N2 );
+                              fe1.n_transform_functions(),
+                              fe1.n_components() * N1 + fe2.n_components() * N2 );
 };
 
 
@@ -538,10 +538,10 @@ FESystem<1>::multiply_dof_numbers (const FiniteElementData<1> &fe1,
                               fe1.dofs_per_line * N1
                               + fe2.dofs_per_line * N2
                               + fe3.dofs_per_line * N3,
-                              fe1.n_transform_functions,
-                              fe1.n_components * N1
-                              + fe2.n_components * N2
-                              + fe3.n_components * N3);
+                              fe1.n_transform_functions(),
+                              fe1.n_components() * N1
+                              + fe2.n_components() * N2
+                              + fe3.n_components() * N3);
 };
 
 #endif
@@ -557,8 +557,8 @@ FESystem<2>::multiply_dof_numbers (const FiniteElementData<2> &fe_data,
   return FiniteElementData<2> (fe_data.dofs_per_vertex * N,
                               fe_data.dofs_per_line * N,
                               fe_data.dofs_per_quad * N,
-                              fe_data.n_transform_functions,
-                              fe_data.n_components * N);
+                              fe_data.n_transform_functions(),
+                              fe_data.n_components() * N);
 };
 
 template <>
@@ -571,8 +571,8 @@ FESystem<2>::multiply_dof_numbers (const FiniteElementData<2> &fe1,
   return FiniteElementData<2> (fe1.dofs_per_vertex * N1 + fe2.dofs_per_vertex * N2 ,
                               fe1.dofs_per_line * N1 + fe2.dofs_per_line * N2 ,
                               fe1.dofs_per_quad * N1 + fe2.dofs_per_quad * N2 ,
-                              fe1.n_transform_functions,
-                              fe1.n_components * N1 + fe2.n_components * N2 );
+                              fe1.n_transform_functions(),
+                              fe1.n_components() * N1 + fe2.n_components() * N2 );
 };
 
 
@@ -594,10 +594,10 @@ FESystem<2>::multiply_dof_numbers (const FiniteElementData<2> &fe1,
                               fe1.dofs_per_quad * N1
                               + fe2.dofs_per_quad * N2
                               + fe3.dofs_per_quad * N3 ,
-                              fe1.n_transform_functions,
-                              fe1.n_components * N1
-                              + fe2.n_components * N2
-                              + fe3.n_components * N3 );
+                              fe1.n_transform_functions(),
+                              fe1.n_components() * N1
+                              + fe2.n_components() * N2
+                              + fe3.n_components() * N3 );
 };
 
 #endif
@@ -614,8 +614,8 @@ FESystem<3>::multiply_dof_numbers (const FiniteElementData<3> &fe_data,
                               fe_data.dofs_per_line * N,
                               fe_data.dofs_per_quad * N,
                               fe_data.dofs_per_hex * N,
-                              fe_data.n_transform_functions,
-                              fe_data.n_components * N);
+                              fe_data.n_transform_functions(),
+                              fe_data.n_components() * N);
 };
 
 template <>
@@ -629,8 +629,8 @@ FESystem<3>::multiply_dof_numbers (const FiniteElementData<3> &fe1,
                               fe1.dofs_per_line * N1 + fe2.dofs_per_line * N2 ,
                               fe1.dofs_per_quad * N1 + fe2.dofs_per_quad * N2 ,
                               fe1.dofs_per_hex * N1 + fe2.dofs_per_hex * N2 ,
-                              fe1.n_transform_functions,
-                              fe1.n_components * N1 + fe2.n_components * N2 );
+                              fe1.n_transform_functions(),
+                              fe1.n_components() * N1 + fe2.n_components() * N2 );
 };
 
 
@@ -655,10 +655,10 @@ FESystem<3>::multiply_dof_numbers (const FiniteElementData<3> &fe1,
                               fe1.dofs_per_hex * N1
                               + fe2.dofs_per_hex * N2
                               + fe3.dofs_per_hex * N3 ,
-                              fe1.n_transform_functions,
-                              fe1.n_components * N1
-                              + fe2.n_components * N2
-                              + fe3.n_components * N3 );
+                              fe1.n_transform_functions(),
+                              fe1.n_components() * N1
+                              + fe2.n_components() * N2
+                              + fe3.n_components() * N3 );
 };
 
 #endif
@@ -671,7 +671,7 @@ FESystem<dim>::compute_restriction_is_additive_flags (const FiniteElement<dim> &
 {
   vector<bool> tmp;
   for (unsigned int i=0; i<n_elements; ++i)
-    for (unsigned int component=0; component<fe.n_components; ++component)
+    for (unsigned int component=0; component<fe.n_components(); ++component)
       tmp.push_back (fe.restriction_is_additive (component));
   return tmp;
 };
@@ -686,10 +686,10 @@ FESystem<dim>::compute_restriction_is_additive_flags (const FiniteElement<dim> &
 {
   vector<bool> tmp;
   for (unsigned int i=0; i<N1; ++i)
-    for (unsigned int component=0; component<fe1.n_components; ++component)
+    for (unsigned int component=0; component<fe1.n_components(); ++component)
       tmp.push_back (fe1.restriction_is_additive (component));
   for (unsigned int i=0; i<N2; ++i)
-    for (unsigned int component=0; component<fe2.n_components; ++component)
+    for (unsigned int component=0; component<fe2.n_components(); ++component)
       tmp.push_back (fe2.restriction_is_additive (component));
   return tmp;
 };
@@ -706,13 +706,13 @@ FESystem<dim>::compute_restriction_is_additive_flags (const FiniteElement<dim> &
 {
   vector<bool> tmp;
   for (unsigned int i=0; i<N1; ++i)
-    for (unsigned int component=0; component<fe1.n_components; ++component)
+    for (unsigned int component=0; component<fe1.n_components(); ++component)
       tmp.push_back (fe1.restriction_is_additive (component));
   for (unsigned int i=0; i<N2; ++i)
-    for (unsigned int component=0; component<fe2.n_components; ++component)
+    for (unsigned int component=0; component<fe2.n_components(); ++component)
       tmp.push_back (fe2.restriction_is_additive (component));
   for (unsigned int i=0; i<N3; ++i)
-    for (unsigned int component=0; component<fe3.n_components; ++component)
+    for (unsigned int component=0; component<fe3.n_components(); ++component)
       tmp.push_back (fe3.restriction_is_additive (component));
   return tmp;
 };
@@ -725,7 +725,7 @@ double
 FESystem<dim>::shape_value (const unsigned int i,
                            const Point<dim>  &p) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
 
   pair<unsigned,unsigned> comp = system_to_component_index(i);
   
@@ -740,7 +740,7 @@ Tensor<1,dim>
 FESystem<dim>::shape_grad (const unsigned int  i,
                           const Point<dim>   &p) const
 {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
 
   pair<unsigned,unsigned> comp = system_to_component_index(i);
   
@@ -755,7 +755,7 @@ Tensor<2,dim>
 FESystem<dim>::shape_grad_grad (const unsigned int  i,
                                const Point<dim>   &p) const
  {
-  Assert((i<total_dofs), ExcIndexRange(i, 0, total_dofs));
+  Assert((i<dofs_per_cell), ExcIndexRange(i, 0, dofs_per_cell));
 
 
   pair<unsigned,unsigned> comp = system_to_component_index(i);
@@ -770,21 +770,21 @@ template <int dim>
 void FESystem<dim>::get_unit_support_points (
   vector<Point<dim> > &unit_support_points) const
 {
-  Assert(unit_support_points.size() == total_dofs,
-        ExcWrongFieldDimension (unit_support_points.size(), total_dofs));
+  Assert(unit_support_points.size() == dofs_per_cell,
+        ExcWrongFieldDimension (unit_support_points.size(), dofs_per_cell));
 
-  vector<Point<dim> > base_unit_support_points (base_element(0).total_dofs);
+  vector<Point<dim> > base_unit_support_points (base_element(0).dofs_per_cell);
   unsigned int component = 0;
   for (unsigned int base_el=0 ; base_el<n_base_elements(); ++base_el)
     {
-      const unsigned int base_element_total_dofs
-       =base_element(base_el).total_dofs;
+      const unsigned int base_element_dofs_per_cell
+       =base_element(base_el).dofs_per_cell;
  
-      base_unit_support_points.resize(base_element_total_dofs);
+      base_unit_support_points.resize(base_element_dofs_per_cell);
       base_element(base_el).get_unit_support_points (base_unit_support_points);
       for (unsigned int n = 0 ; n < element_multiplicity(base_el); ++n)
        {
-         for (unsigned int i=0; i<base_element_total_dofs; ++i)
+         for (unsigned int i=0; i<base_element_dofs_per_cell; ++i)
            {
              unit_support_points[component_to_system_index(component,i)]
                = base_unit_support_points[i];
@@ -799,14 +799,14 @@ void FESystem<dim>::get_unit_support_points (
 //   vector<vector<Point<dim> > > base_us_points(n_base_elements());
 //   for (unsigned int base_el=0 ; base_el<n_base_elements(); ++base_el)
 //     {
-//       const unsigned int base_element_total_dofs
-//     =base_element(base_el).total_dofs;
+//       const unsigned int base_element_dofs_per_cell
+//     =base_element(base_el).dofs_per_cell;
 
-//       base_us_points[base_el].resize(base_element_total_dofs);
+//       base_us_points[base_el].resize(base_element_dofs_per_cell);
 //       base_element(base_el).get_unit_support_points (base_us_points[base_el]);
 //     }
 
-//   for (unsigned int i=0; i<total_dofs; ++i)
+//   for (unsigned int i=0; i<dofs_per_cell; ++i)
 //     {
 //       const unsigned int comp=system_to_component_index(i).first,
 //                  base_dof=system_to_component_index(i).second,
@@ -822,21 +822,21 @@ template <int dim>
 void FESystem<dim>::get_support_points (const DoFHandler<dim>::cell_iterator &cell,
                                        vector<Point<dim> > &support_points) const
 {
-  Assert(support_points.size() == total_dofs,
-        ExcWrongFieldDimension (support_points.size(), total_dofs));
+  Assert(support_points.size() == dofs_per_cell,
+        ExcWrongFieldDimension (support_points.size(), dofs_per_cell));
 
-  vector<Point<dim> > base_support_points (base_element(0).total_dofs);
+  vector<Point<dim> > base_support_points (base_element(0).dofs_per_cell);
   unsigned int component = 0;
   for (unsigned int base_el=0 ; base_el<n_base_elements(); ++base_el)
     {
-      const unsigned int base_element_total_dofs
-       =base_element(base_el).total_dofs;
+      const unsigned int base_element_dofs_per_cell
+       =base_element(base_el).dofs_per_cell;
       
-      base_support_points.resize(base_element_total_dofs);
+      base_support_points.resize(base_element_dofs_per_cell);
       base_element(base_el).get_support_points (cell, base_support_points);
       for (unsigned int n = 0 ; n < element_multiplicity(base_el); ++n)
        {
-         for (unsigned int i=0; i<base_element_total_dofs; ++i)
+         for (unsigned int i=0; i<base_element_dofs_per_cell; ++i)
            {
              support_points[component_to_system_index(component,i)]
                = base_support_points[i];
@@ -880,10 +880,10 @@ template <int dim>
 void FESystem<dim>::get_local_mass_matrix (const DoFHandler<dim>::cell_iterator &cell,
                                           FullMatrix<double>  &local_mass_matrix) const
 {
-  Assert (local_mass_matrix.n() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.n(),total_dofs));
-  Assert (local_mass_matrix.m() == total_dofs,
-         ExcWrongFieldDimension(local_mass_matrix.m(),total_dofs));
+  Assert (local_mass_matrix.n() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.n(),dofs_per_cell));
+  Assert (local_mass_matrix.m() == dofs_per_cell,
+         ExcWrongFieldDimension(local_mass_matrix.m(),dofs_per_cell));
 
                                   // track which component we are
                                   // presently working with, since we
@@ -895,9 +895,9 @@ void FESystem<dim>::get_local_mass_matrix (const DoFHandler<dim>::cell_iterator
     {
                                       // first get the local mass matrix for
                                       // the base object
-      const unsigned int base_element_total_dofs=base_element(base_el).total_dofs;
-      FullMatrix<double> base_mass_matrix (base_element_total_dofs,
-                                          base_element_total_dofs);
+      const unsigned int base_element_dofs_per_cell=base_element(base_el).dofs_per_cell;
+      FullMatrix<double> base_mass_matrix (base_element_dofs_per_cell,
+                                          base_element_dofs_per_cell);
       base_element(base_el).get_local_mass_matrix (cell, base_mass_matrix);
       
                                       // now distribute it to the mass matrix
@@ -905,8 +905,8 @@ void FESystem<dim>::get_local_mass_matrix (const DoFHandler<dim>::cell_iterator
       const unsigned int el_multiplicity=element_multiplicity(base_el);
       for (unsigned int n=0; n<el_multiplicity; ++n)
        {
-         for (unsigned int i=0; i<base_element_total_dofs; ++i)
-           for (unsigned int j=0; j<base_element_total_dofs; ++j)
+         for (unsigned int i=0; i<base_element_dofs_per_cell; ++i)
+           for (unsigned int j=0; j<base_element_dofs_per_cell; ++j)
                                             // only fill diagonals of the blocks
              local_mass_matrix (component_to_system_index(component,i),
                                 component_to_system_index(component,j))
@@ -914,7 +914,7 @@ void FESystem<dim>::get_local_mass_matrix (const DoFHandler<dim>::cell_iterator
          ++component;
        };
     };
-  Assert (component == n_components, ExcInternalError());
+  Assert (component == n_components(), ExcInternalError());
 };
 
 
@@ -999,7 +999,7 @@ FESystem<dim>::fill_fe_values (const DoFHandler<dim>::cell_iterator &cell,
                               const FullMatrix<double>  &shape_values_transform,
                               const vector<vector<Tensor<1,dim> > > &shape_grad_transform) const
 {
-  vector<Point<dim> > supp(base_elements[0].first->total_dofs);
+  vector<Point<dim> > supp(base_elements[0].first->dofs_per_cell);
 
   base_elements[0].first->fill_fe_values (cell, unit_points, jacobians, compute_jacobians,
                                          jacobians_grad, compute_jacobians_grad,
@@ -1013,13 +1013,13 @@ FESystem<dim>::fill_fe_values (const DoFHandler<dim>::cell_iterator &cell,
       
       for (unsigned m=0 ; m < element_multiplicity(0) ; ++ m)
        {
-         for (unsigned i=0 ; i < base_element(0).total_dofs ; ++i)
+         for (unsigned i=0 ; i < base_element(0).dofs_per_cell ; ++i)
            support_points[component_to_system_index(component,i)] = supp[i];
          ++component;
        }
       for (unsigned base=1 ; base < n_base_elements() ; ++base)
        {
-         supp.resize(base_elements[base].first->total_dofs);
+         supp.resize(base_elements[base].first->dofs_per_cell);
          base_elements[base].first->fill_fe_values (cell, unit_points, jacobians, false,
                                                     jacobians_grad, false,
                                                     supp, true,
@@ -1028,7 +1028,7 @@ FESystem<dim>::fill_fe_values (const DoFHandler<dim>::cell_iterator &cell,
          
          for (unsigned m=0 ; m < element_multiplicity(base) ; ++ m)
            {
-             for (unsigned i=0 ; i < base_element(base).total_dofs ; ++i)
+             for (unsigned i=0 ; i < base_element(base).dofs_per_cell ; ++i)
                support_points[component_to_system_index(component,i)] = supp[i];
              ++component;
            }
index 29cc85dec0d1c1af7780e944295d9f26cc4c2354..d3adb919c4ac16ceabe50bdbcaffa4068ce25a28 100644 (file)
 template <int dim>
 FEValuesBase<dim>::FEValuesBase (const unsigned int n_q_points,
                                 const unsigned int n_support_points,
-                                const unsigned int total_dofs,
+                                const unsigned int dofs_per_cell,
                                 const unsigned int n_transform_functions,
                                 const unsigned int n_values_arrays,
                                 const UpdateFlags update_flags,
                                 const FiniteElement<dim> &fe)
                :
                n_quadrature_points (n_q_points),
-               total_dofs (total_dofs),
+               dofs_per_cell (dofs_per_cell),
                n_transform_functions (n_transform_functions),
-               shape_values (n_values_arrays, FullMatrix<double>(total_dofs, n_q_points)),
-               shape_gradients (total_dofs, vector<Tensor<1,dim> >(n_q_points)),
-               shape_2nd_derivatives (total_dofs, vector<Tensor<2,dim> >(n_q_points)),
+               shape_values (n_values_arrays, FullMatrix<double>(dofs_per_cell, n_q_points)),
+               shape_gradients (dofs_per_cell, vector<Tensor<1,dim> >(n_q_points)),
+               shape_2nd_derivatives (dofs_per_cell, vector<Tensor<2,dim> >(n_q_points)),
                weights (n_q_points, 0),
                JxW_values (n_q_points, 0),
                quadrature_points (n_q_points, Point<dim>()),
@@ -66,7 +66,7 @@ template <int dim>
 void FEValuesBase<dim>::get_function_values (const Vector<double> &fe_function,
                                             vector<double>       &values) const
 {
-  Assert (fe->n_components == 1,
+  Assert (fe->n_components() == 1,
          ExcWrongNoOfComponents());
   Assert (selected_dataset<shape_values.size(),
          ExcIndexRange (selected_dataset, 0, shape_values.size()));
@@ -75,7 +75,7 @@ void FEValuesBase<dim>::get_function_values (const Vector<double> &fe_function,
 
                                   // get function values of dofs
                                   // on this cell
-  Vector<double> dof_values (total_dofs);
+  Vector<double> dof_values (dofs_per_cell);
   if (present_cell->active())
     present_cell->get_dof_values (fe_function, dof_values);
   else
@@ -87,7 +87,7 @@ void FEValuesBase<dim>::get_function_values (const Vector<double> &fe_function,
                                   // add up contributions of trial
                                   // functions
   for (unsigned int point=0; point<n_quadrature_points; ++point)
-    for (unsigned int shape_func=0; shape_func<total_dofs; ++shape_func)
+    for (unsigned int shape_func=0; shape_func<dofs_per_cell; ++shape_func)
       values[point] += (dof_values(shape_func) *
                        shape_values[selected_dataset](shape_func, point));
 };
@@ -102,12 +102,12 @@ void FEValuesBase<dim>::get_function_values (const Vector<double>     &fe_functi
   Assert (selected_dataset<shape_values.size(),
          ExcIndexRange (selected_dataset, 0, shape_values.size()));
   for (unsigned i=0;i<values.size();++i)
-    Assert (values[i].size() == fe->n_components,
+    Assert (values[i].size() == fe->n_components(),
            ExcWrongNoOfComponents());
 
                                   // get function values of dofs
                                   // on this cell
-  Vector<double> dof_values (total_dofs);
+  Vector<double> dof_values (dofs_per_cell);
   if (present_cell->active())
     present_cell->get_dof_values (fe_function, dof_values);
   else
@@ -120,7 +120,7 @@ void FEValuesBase<dim>::get_function_values (const Vector<double>     &fe_functi
                                   // add up contributions of trial
                                   // functions
   for (unsigned int point=0; point<n_quadrature_points; ++point)
-    for (unsigned int shape_func=0; shape_func<total_dofs; ++shape_func)
+    for (unsigned int shape_func=0; shape_func<dofs_per_cell; ++shape_func)
       values[point](fe->system_to_component_index(shape_func).first)
        += (dof_values(shape_func) * shape_values[selected_dataset](shape_func, point));
 };
@@ -147,14 +147,14 @@ template <int dim>
 void FEValuesBase<dim>::get_function_grads (const Vector<double>   &fe_function,
                                            vector<Tensor<1,dim> > &gradients) const
 {
-  Assert (fe->n_components == 1,
+  Assert (fe->n_components() == 1,
          ExcWrongNoOfComponents());
   Assert (gradients.size() == n_quadrature_points,
          ExcWrongVectorSize(gradients.size(), n_quadrature_points));
 
                                   // get function values of dofs
                                   // on this cell
-  Vector<double> dof_values (total_dofs);
+  Vector<double> dof_values (dofs_per_cell);
   if (present_cell->active())
     present_cell->get_dof_values (fe_function, dof_values);
   else
@@ -166,7 +166,7 @@ void FEValuesBase<dim>::get_function_grads (const Vector<double>   &fe_function,
                                   // add up contributions of trial
                                   // functions
   for (unsigned int point=0; point<n_quadrature_points; ++point)
-    for (unsigned int shape_func=0; shape_func<total_dofs; ++shape_func)
+    for (unsigned int shape_func=0; shape_func<dofs_per_cell; ++shape_func)
       {
        Tensor<1,dim> tmp(shape_gradients[shape_func][point]);
        tmp *= dof_values(shape_func);
@@ -183,12 +183,12 @@ void FEValuesBase<dim>::get_function_grads (const Vector<double>            &fe_
   Assert (selected_dataset<shape_values.size(),
          ExcIndexRange (selected_dataset, 0, shape_values.size()));
   for (unsigned i=0;i<gradients.size();++i)
-    Assert (gradients[i].size() == fe->n_components,
-           ExcWrongVectorSize(gradients[i].size(), fe->n_components));
+    Assert (gradients[i].size() == fe->n_components(),
+           ExcWrongVectorSize(gradients[i].size(), fe->n_components()));
 
                                   // get function values of dofs
                                   // on this cell
-  Vector<double> dof_values (total_dofs);
+  Vector<double> dof_values (dofs_per_cell);
   if (present_cell->active())
     present_cell->get_dof_values (fe_function, dof_values);
   else
@@ -201,7 +201,7 @@ void FEValuesBase<dim>::get_function_grads (const Vector<double>            &fe_
                                   // add up contributions of trial
                                   // functions
   for (unsigned int point=0; point<n_quadrature_points; ++point)
-    for (unsigned int shape_func=0; shape_func<total_dofs; ++shape_func)
+    for (unsigned int shape_func=0; shape_func<dofs_per_cell; ++shape_func)
       {
        Tensor<1,dim> tmp(shape_gradients[shape_func][point]);
        tmp *= dof_values(shape_func);
@@ -230,14 +230,14 @@ template <int dim>
 void FEValuesBase<dim>::get_function_2nd_derivatives (const Vector<double>   &fe_function,
                                                      vector<Tensor<2,dim> > &second_derivatives) const
 {
-  Assert (fe->n_components == 1,
+  Assert (fe->n_components() == 1,
          ExcWrongNoOfComponents());
   Assert (second_derivatives.size() == n_quadrature_points,
          ExcWrongVectorSize(second_derivatives.size(), n_quadrature_points));
 
                                   // get function values of dofs
                                   // on this cell
-  Vector<double> dof_values (total_dofs);
+  Vector<double> dof_values (dofs_per_cell);
   if (present_cell->active())
     present_cell->get_dof_values (fe_function, dof_values);
   else
@@ -249,7 +249,7 @@ void FEValuesBase<dim>::get_function_2nd_derivatives (const Vector<double>   &fe
                                   // add up contributions of trial
                                   // functions
   for (unsigned int point=0; point<n_quadrature_points; ++point)
-    for (unsigned int shape_func=0; shape_func<total_dofs; ++shape_func)
+    for (unsigned int shape_func=0; shape_func<dofs_per_cell; ++shape_func)
       {
        Tensor<2,dim> tmp(shape_2nd_derivatives[shape_func][point]);
        tmp *= dof_values(shape_func);
@@ -303,24 +303,24 @@ FEValues<dim>::FEValues (const FiniteElement<dim> &fe,
                         const UpdateFlags         update_flags)
                :
                FEValuesBase<dim> (quadrature.n_quadrature_points,
-                                  fe.total_dofs,
-                                  fe.total_dofs,
-                                  fe.n_transform_functions,
+                                  fe.dofs_per_cell,
+                                  fe.dofs_per_cell,
+                                  fe.transform_functions,
                                   1,
                                   update_flags,
                                   fe),
-               unit_shape_gradients(fe.total_dofs,
+               unit_shape_gradients(fe.dofs_per_cell,
                                     vector<Tensor<1,dim> >(quadrature.n_quadrature_points)),
-               unit_shape_2nd_derivatives(fe.total_dofs,
+               unit_shape_2nd_derivatives(fe.dofs_per_cell,
                                           vector<Tensor<2,dim> >(quadrature.n_quadrature_points)),
-               unit_shape_gradients_transform(fe.n_transform_functions,
+               unit_shape_gradients_transform(fe.n_transform_functions(),
                                               vector<Tensor<1,dim> >(quadrature.n_quadrature_points)),
                unit_quadrature_points(quadrature.get_quad_points())
 {
   Assert ((update_flags & update_normal_vectors) == false,
          ExcInvalidUpdateFlag());
 
-  for (unsigned int i=0; i<fe.total_dofs; ++i)
+  for (unsigned int i=0; i<fe.dofs_per_cell; ++i)
     for (unsigned int j=0; j<n_quadrature_points; ++j) 
       {
        shape_values[0](i,j) = fe.shape_value(i, unit_quadrature_points[j]);
@@ -377,7 +377,7 @@ void FEValues<dim>::reinit (const typename DoFHandler<dim>::cell_iterator &cell)
                                   // compute gradients on real element if
                                   // requested
   if (update_flags & update_gradients) 
-    for (unsigned int i=0; i<fe->total_dofs; ++i)
+    for (unsigned int i=0; i<fe->dofs_per_cell; ++i)
       for (unsigned int j=0; j<n_quadrature_points; ++j)
        for (unsigned int s=0; s<dim; ++s)
          {
@@ -394,7 +394,7 @@ void FEValues<dim>::reinit (const typename DoFHandler<dim>::cell_iterator &cell)
   
   Tensor<2,dim> tmp1, tmp2;
   if (update_flags & update_second_derivatives)
-    for (unsigned int i=0; i<fe->total_dofs; ++i)
+    for (unsigned int i=0; i<fe->dofs_per_cell; ++i)
       for (unsigned int j=0; j<n_quadrature_points; ++j)
        {
                                                   // tmp1 := (d_k d_l phi) J_lj
@@ -436,7 +436,7 @@ void FEValues<dim>::reinit (const typename DoFHandler<dim>::cell_iterator &cell)
 template <int dim>
 FEFaceValuesBase<dim>::FEFaceValuesBase (const unsigned int n_q_points,
                                         const unsigned int n_support_points,
-                                        const unsigned int total_dofs,
+                                        const unsigned int dofs_per_cell,
                                         const unsigned int n_transform_functions,
                                         const unsigned int n_faces_or_subfaces,
                                         const UpdateFlags         update_flags,
@@ -444,16 +444,16 @@ FEFaceValuesBase<dim>::FEFaceValuesBase (const unsigned int n_q_points,
                :
                FEValuesBase<dim> (n_q_points,
                                   n_support_points,
-                                  total_dofs,
+                                  dofs_per_cell,
                                   n_transform_functions,
                                   n_faces_or_subfaces,
                                   update_flags,
                                   fe),
                unit_shape_gradients (n_faces_or_subfaces,
-                                     vector<vector<Tensor<1,dim> > >(total_dofs,
+                                     vector<vector<Tensor<1,dim> > >(dofs_per_cell,
                                                                   vector<Tensor<1,dim> >(n_q_points))),
                unit_shape_2nd_derivatives(n_faces_or_subfaces,
-                                          vector<vector<Tensor<2,dim> > >(total_dofs,
+                                          vector<vector<Tensor<2,dim> > >(dofs_per_cell,
                                                                           vector<Tensor<2,dim> >(n_q_points))),
                unit_shape_gradients_transform (n_faces_or_subfaces,
                                                vector<vector<Tensor<1,dim> > >(n_transform_functions,
@@ -492,8 +492,8 @@ FEFaceValues<dim>::FEFaceValues (const FiniteElement<dim> &fe,
                :
                FEFaceValuesBase<dim> (quadrature.n_quadrature_points,
                                       fe.dofs_per_face,
-                                      fe.total_dofs,
-                                      fe.n_transform_functions,
+                                      fe.dofs_per_cell,
+                                      fe.n_transform_functions(),
                                       GeometryInfo<dim>::faces_per_cell,
                                       update_flags,
                                       fe)
@@ -509,7 +509,7 @@ FEFaceValues<dim>::FEFaceValues (const FiniteElement<dim> &fe,
   for (unsigned int face=0; face<GeometryInfo<dim>::faces_per_cell; ++face)
     QProjector<dim>::project_to_face (quadrature, face, unit_quadrature_points[face]);
 
-  for (unsigned int i=0; i<fe.total_dofs; ++i)
+  for (unsigned int i=0; i<fe.dofs_per_cell; ++i)
     for (unsigned int j=0; j<n_quadrature_points; ++j) 
       for (unsigned int face=0; face<GeometryInfo<dim>::faces_per_cell; ++face)
        {
@@ -574,7 +574,7 @@ void FEFaceValues<dim>::reinit (const typename DoFHandler<dim>::cell_iterator &c
                                   // compute gradients on real element if
                                   // requested
   if (update_flags & update_gradients) 
-    for (unsigned int i=0; i<fe->total_dofs; ++i)
+    for (unsigned int i=0; i<fe->dofs_per_cell; ++i)
       {
        fill_n (shape_gradients[i].begin(),
                n_quadrature_points,
@@ -593,7 +593,7 @@ void FEFaceValues<dim>::reinit (const typename DoFHandler<dim>::cell_iterator &c
 
   Tensor<2,dim> tmp1, tmp2;
   if (update_flags & update_second_derivatives)
-    for (unsigned int i=0; i<fe->total_dofs; ++i)
+    for (unsigned int i=0; i<fe->dofs_per_cell; ++i)
       for (unsigned int j=0; j<n_quadrature_points; ++j)
        {
                                           // tmp1 := (d_k d_l phi) J_lj
@@ -642,8 +642,8 @@ FESubfaceValues<dim>::FESubfaceValues (const FiniteElement<dim> &fe,
                :
                FEFaceValuesBase<dim> (quadrature.n_quadrature_points,
                                       0,
-                                      fe.total_dofs,
-                                      fe.n_transform_functions,
+                                      fe.dofs_per_cell,
+                                      fe.n_transform_functions(),
                                       GeometryInfo<dim>::faces_per_cell * GeometryInfo<dim>::subfaces_per_face,
                                       update_flags,
                                       fe)
@@ -665,7 +665,7 @@ FESubfaceValues<dim>::FESubfaceValues (const FiniteElement<dim> &fe,
                                           face, subface,
                                           unit_quadrature_points[face*(1<<(dim-1))+subface]);
 
-  for (unsigned int i=0; i<fe.total_dofs; ++i)
+  for (unsigned int i=0; i<fe.dofs_per_cell; ++i)
     for (unsigned int j=0; j<n_quadrature_points; ++j) 
       for (unsigned int face=0; face<GeometryInfo<dim>::faces_per_cell; ++face)
        for (unsigned int subface=0; subface<GeometryInfo<dim>::subfaces_per_face; ++subface)
@@ -748,7 +748,7 @@ void FESubfaceValues<dim>::reinit (const typename DoFHandler<dim>::cell_iterator
                                   // compute gradients on real element if
                                   // requested
   if (update_flags & update_gradients) 
-    for (unsigned int i=0; i<fe->total_dofs; ++i) 
+    for (unsigned int i=0; i<fe->dofs_per_cell; ++i) 
       {
        fill_n (shape_gradients[i].begin(),
                n_quadrature_points,
@@ -766,7 +766,7 @@ void FESubfaceValues<dim>::reinit (const typename DoFHandler<dim>::cell_iterator
 
   Tensor<2,dim> tmp1, tmp2;
   if (update_flags & update_second_derivatives)
-    for (unsigned int i=0; i<fe->total_dofs; ++i)
+    for (unsigned int i=0; i<fe->dofs_per_cell; ++i)
       for (unsigned int j=0; j<n_quadrature_points; ++j)
        {
                                           // tmp1 := (d_k d_l phi) J_lj
index a2fb96532771b8baf82bb8a04e78d00a8394b497..32b7ac9fcda9f0a253f228adc89a35efeb7a9a61 100644 (file)
@@ -572,8 +572,8 @@ void FEQ1Mapping<dim>::fill_fe_values (const DoFHandler<dim>::cell_iterator &cel
          ExcWrongFieldDimension(jacobians_grad.size(), unit_points.size()));
   Assert ((!compute_q_points) || (q_points.size() == unit_points.size()),
          ExcWrongFieldDimension(q_points.size(), unit_points.size()));
-  Assert ((!compute_support_points) || (support_points.size() == total_dofs),
-         ExcWrongFieldDimension(support_points.size(), total_dofs));
+  Assert ((!compute_support_points) || (support_points.size() == dofs_per_cell),
+         ExcWrongFieldDimension(support_points.size(), dofs_per_cell));
 
   
   unsigned int n_points=unit_points.size();
index 3ff7d0a9f84b1be0946486f5c4320ec703517e9c..0e72ae0e8f1be45ad7ce52fe7568ba1bfc2815b3 100644 (file)
@@ -528,7 +528,7 @@ MGDoFCellAccessor<1>::get_mg_dof_values (const Vector<double> &values,
   Assert (dof_handler != 0, DoFAccessor<1>::DoFAccessor<1>::ExcInvalidObject());
   Assert (mg_dof_handler != 0, DoFAccessor<1>::DoFAccessor<1>::ExcInvalidObject());
   Assert (&dof_handler->get_fe() != 0, DoFAccessor<1>::DoFAccessor<1>::ExcInvalidObject());
-  Assert (dof_values.size() == dof_handler->get_fe().total_dofs,
+  Assert (dof_values.size() == dof_handler->get_fe().dofs_per_cell,
          ExcVectorDoesNotMatch());
   Assert (values.size() == dof_handler->n_dofs(),
          ExcVectorDoesNotMatch());
@@ -565,7 +565,7 @@ MGDoFCellAccessor<2>::get_mg_dof_values (const Vector<double> &values,
   Assert (dof_handler != 0, DoFAccessor<2>::ExcInvalidObject());
   Assert (mg_dof_handler != 0, DoFAccessor<2>::ExcInvalidObject());
   Assert (&dof_handler->get_fe() != 0, DoFAccessor<2>::ExcInvalidObject());
-  Assert (dof_values.size() == dof_handler->get_fe().total_dofs,
+  Assert (dof_values.size() == dof_handler->get_fe().dofs_per_cell,
          DoFAccessor<2>::ExcVectorDoesNotMatch());
   Assert (values.size() == mg_dof_handler->n_dofs(present_level),
          DoFAccessor<2>::ExcVectorDoesNotMatch());
index 9d2763f25faf94f7b437d9e9b6d631c1aa1d3a75..0b4e5c4b482e56d0562b59c7be563db030ebe6f1 100644 (file)
@@ -1548,16 +1548,16 @@ void MGDoFHandler<dim>::make_sparsity_pattern (const unsigned int  level,
   Assert (sparsity.n_cols() == n_dofs(level),
          ExcDifferentDimensions (sparsity.n_cols(), n_dofs(level)));
 
-  const unsigned int total_dofs = selected_fe->total_dofs;
-  vector<int> dofs_on_this_cell(total_dofs);
+  const unsigned int dofs_per_cell = selected_fe->dofs_per_cell;
+  vector<int> dofs_on_this_cell(dofs_per_cell);
   cell_iterator cell = begin(level),
                endc = end(level);
   for (; cell!=endc; ++cell) 
     {
       cell->get_mg_dof_indices (dofs_on_this_cell);
                                       // make sparsity pattern for this cell
-      for (unsigned int i=0; i<total_dofs; ++i)
-       for (unsigned int j=0; j<total_dofs; ++j)
+      for (unsigned int i=0; i<dofs_per_cell; ++i)
+       for (unsigned int j=0; j<dofs_per_cell; ++j)
          sparsity.add (dofs_on_this_cell[i],
                        dofs_on_this_cell[j]);
     };
index e5d997ccf65f5bfce3764941ea7a4f76987bab97..84dc85d452eea667c98464fc568f2cc0f6121485 100644 (file)
@@ -68,7 +68,7 @@ template <int dim>
 void MGTransferPrebuilt::build_matrices (const MGDoFHandler<dim> &mg_dof) 
 {
   const unsigned int n_levels      = mg_dof.get_tria().n_levels();
-  const unsigned int dofs_per_cell = mg_dof.get_fe().total_dofs;
+  const unsigned int dofs_per_cell = mg_dof.get_fe().dofs_per_cell;
   
                                   // reset the size of the array of
                                   // matrices
index d4043020434d9ad6bb73955578165615c4b277f8..41f44c8102688c00d4edb9b282394f3d04b27e39 100644 (file)
@@ -37,8 +37,8 @@ Assembler<dim>::Assembler (Triangulation<dim>  *tria,
                           const int            index,
                           const AssemblerData *local_data) :
                DoFCellAccessor<dim> (tria,level,index, &local_data->dof),
-               cell_matrix (dof_handler->get_fe().total_dofs),
-               cell_vector (Vector<double>(dof_handler->get_fe().total_dofs)),
+               cell_matrix (dof_handler->get_fe().dofs_per_cell),
+               cell_vector (Vector<double>(dof_handler->get_fe().dofs_per_cell)),
                assemble_matrix (local_data->assemble_matrix),
                assemble_rhs (local_data->assemble_rhs),
                matrix(local_data->matrix),
@@ -61,7 +61,7 @@ template <int dim>
 void Assembler<dim>::assemble (const Equation<dim> &equation) {
                                   // re-init fe values for this cell
   fe_values.reinit (DoFHandler<dim>::cell_iterator (*this));
-  const unsigned int n_dofs = dof_handler->get_fe().total_dofs;
+  const unsigned int n_dofs = dof_handler->get_fe().dofs_per_cell;
 
   if (assemble_matrix)
     cell_matrix.clear ();
index c45d4cb103ec1ccc255a902fbaf0a7d5776e7672..5deb30cdd344ae8616cd9f4649b41ed472c50246 100644 (file)
@@ -597,7 +597,7 @@ void DataOut_Old<dim>::write_gnuplot (ostream &out, unsigned int accuracy) const
   vector< vector <Vector<double> > >
     values (dof_data.size(),
            vector< Vector<double> >(points.n_quadrature_points,
-                                    Vector<double>(dofs->get_fe().n_components
+                                    Vector<double>(dofs->get_fe().n_components()
                                     )));
 
   unsigned int cell_index=0;
@@ -621,7 +621,7 @@ void DataOut_Old<dim>::write_gnuplot (ostream &out, unsigned int accuracy) const
                    Point<dim> pt = fe.quadrature_point(supp_pt);
                    out << pt << "  ";
                    for (unsigned int i=0; i!=dof_data.size(); ++i)
-                     for (unsigned int j=0; j < dofs->get_fe().n_components; ++j)
+                     for (unsigned int j=0; j < dofs->get_fe().n_components(); ++j)
                        out << values[i][supp_pt](j)
                            << ' ';
                    for (unsigned int i=0; i<cell_data.size(); ++i)
@@ -647,7 +647,7 @@ void DataOut_Old<dim>::write_gnuplot (ostream &out, unsigned int accuracy) const
                    out << pt << "  ";
                    
                    for (unsigned int i=0; i!=dof_data.size(); ++i)
-                     for (unsigned int j=0; j < dofs->get_fe().n_components; ++j)
+                     for (unsigned int j=0; j < dofs->get_fe().n_components(); ++j)
                        out << values[i][supp_pt](j)
                            << ' ';
                    for (unsigned int i=0; i<cell_data.size(); ++i)
@@ -683,7 +683,7 @@ void DataOut_Old<dim>::write_gnuplot (ostream &out, unsigned int accuracy) const
                            out << pt << "  ";
                            
                            for (unsigned int i=0; i!=dof_data.size(); ++i)
-                             for (unsigned int j=0; j < dofs->get_fe().n_components; ++j)
+                             for (unsigned int j=0; j < dofs->get_fe().n_components(); ++j)
                                out << values[i][supp_pt](j)
                                    << ' ';
                            for (unsigned int i=0; i<cell_data.size(); ++i)
index 875305b13dd08c2050ab372ad68d1538a5869588..2df1890c80452c1c4d080471b27d3d8baf5ea186 100644 (file)
@@ -64,8 +64,8 @@ void DataOut_DoFData<dim>::add_data_vector (const Vector<double> &vec,
           (names.size() == 1))
          ||
          ((vec.size() == dofs->n_dofs()) &&
-          (names.size() == dofs->get_fe().n_components)),
-         ExcInvalidNumberOfNames (names.size(), dofs->get_fe().n_components));
+          (names.size() == dofs->get_fe().n_components())),
+         ExcInvalidNumberOfNames (names.size(), dofs->get_fe().n_components()));
   for (unsigned int i=0; i<names.size(); ++i)
     Assert (names[i].find_first_not_of("abcdefghijklmnopqrstuvwxyz"
                                       "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
@@ -153,7 +153,7 @@ void DataOut<dim>::build_patches (const unsigned int n_subdivisions)
 {
   Assert (dofs != 0, ExcNoDoFHandlerSelected());
   
-  const unsigned int n_components   = dofs->get_fe().n_components;
+  const unsigned int n_components   = dofs->get_fe().n_components();
   const unsigned int n_datasets     = dof_data.size() * n_components +
                                      cell_data.size();
   
index 521969ad5bc443fc8e2d27949911979586282689..4ede3bd6493e02f503ef7ec40395862f0fbb5b6d 100644 (file)
@@ -122,8 +122,8 @@ void DataOutStack<dim>::add_data_vector (const Vector<number> &vec,
           (names.size() == 1))
          ||
          ((vec.size() == dof_handler->n_dofs()) &&
-          (names.size() == dof_handler->get_fe().n_components)),
-         ExcInvalidNumberOfNames (names.size(), dof_handler->get_fe().n_components));
+          (names.size() == dof_handler->get_fe().n_components())),
+         ExcInvalidNumberOfNames (names.size(), dof_handler->get_fe().n_components()));
   for (unsigned int i=0; i<names.size(); ++i)
     Assert (names[i].find_first_not_of("abcdefghijklmnopqrstuvwxyz"
                                       "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
@@ -170,7 +170,7 @@ void DataOutStack<dim>::build_patches (const unsigned int n_subdivisions)
   
   Assert (dof_handler != 0, ExcNoDoFHandlerSelected());
   
-  const unsigned int n_components   = dof_handler->get_fe().n_components;
+  const unsigned int n_components   = dof_handler->get_fe().n_components();
   const unsigned int n_datasets     = dof_data.size() * n_components +
                                      cell_data.size();
   
index 36010e7b463b84dda6f1a3625aa16489cfc276bb..e3605c7cb85177fb7662b55179591b4b72951f80 100644 (file)
@@ -36,7 +36,7 @@ void KellyErrorEstimator<1>::estimate (const DoFHandler<1>  &dof,
                                       const vector<bool>   &component_mask_,
                                       const Function<1>    *coefficient)
 {
-  const unsigned int n_components = dof.get_fe().n_components;
+  const unsigned int n_components = dof.get_fe().n_components();
 
                                   // if no mask given: treat all components
   vector<bool> component_mask ((component_mask_.size() == 0)    ?
@@ -187,7 +187,7 @@ void KellyErrorEstimator<dim>::estimate (const DoFHandler<dim>    &dof,
                                         const vector<bool>       &component_mask_,
                                         const Function<dim>      *coefficient)
 {
-  const unsigned int n_components = dof.get_fe().n_components;
+  const unsigned int n_components = dof.get_fe().n_components();
 
                                   // if no mask given: treat all components
   vector<bool> component_mask ((component_mask_.size() == 0)    ?
index 69f52cd80345f13b15461d3715f134068765a6a3..0e079544511734866ce4eeb70bee85c05c731e54 100644 (file)
@@ -81,7 +81,7 @@ void MatrixCreator<dim>::create_mass_matrix (const DoFHandler<dim>    &dof,
                                             SparseMatrix<double>     &matrix) {
   const FiniteElement<dim> &fe = dof.get_fe();
 
-  const unsigned int dofs_per_cell = fe.total_dofs;
+  const unsigned int dofs_per_cell = fe.dofs_per_cell;
   
   FullMatrix<double>  local_mass_matrix (dofs_per_cell, dofs_per_cell);
   vector<int>         dofs_on_this_cell (dofs_per_cell);
@@ -128,7 +128,7 @@ void MatrixCreator<dim>::create_boundary_mass_matrix (const DoFHandler<dim>    &
                                                      vector<int>              &dof_to_boundary_mapping,
                                                      const Function<dim>      *a) {
   const FiniteElement<dim> &fe = dof.get_fe();
-  const unsigned int n_components  = fe.n_components;
+  const unsigned int n_components  = fe.n_components();
   const bool         fe_is_system  = (n_components != 1);
   
   Assert (matrix.n() == dof.n_boundary_dofs(rhs), ExcInternalError());
@@ -143,7 +143,7 @@ void MatrixCreator<dim>::create_boundary_mass_matrix (const DoFHandler<dim>    &
   Assert (n_components == rhs.begin()->second->n_components,
          ExcComponentMismatch());
   
-  const unsigned int dofs_per_cell = fe.total_dofs,
+  const unsigned int dofs_per_cell = fe.dofs_per_cell,
                     dofs_per_face = fe.dofs_per_face;
   
   FullMatrix<double> cell_matrix(dofs_per_cell, dofs_per_cell);
@@ -196,9 +196,9 @@ void MatrixCreator<dim>::create_boundary_mass_matrix (const DoFHandler<dim>    &
                  a->vector_value_list (fe_values.get_quadrature_points(),
                                        coefficient_values_system);
                  for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-                   for (unsigned int i=0; i<fe_values.total_dofs; ++i) 
+                   for (unsigned int i=0; i<fe_values.dofs_per_cell; ++i) 
                      {
-                       for (unsigned int j=0; j<fe_values.total_dofs; ++j)
+                       for (unsigned int j=0; j<fe_values.dofs_per_cell; ++j)
                          if (fe.system_to_component_index(i).first ==
                              fe.system_to_component_index(j).first)
                            {
@@ -218,9 +218,9 @@ void MatrixCreator<dim>::create_boundary_mass_matrix (const DoFHandler<dim>    &
                }
              else
                for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-                 for (unsigned int i=0; i<fe_values.total_dofs; ++i) 
+                 for (unsigned int i=0; i<fe_values.dofs_per_cell; ++i) 
                    {
-                     for (unsigned int j=0; j<fe_values.total_dofs; ++j)
+                     for (unsigned int j=0; j<fe_values.dofs_per_cell; ++j)
                        if (fe.system_to_component_index(i).first ==
                            fe.system_to_component_index(j).first)
                          {
@@ -246,9 +246,9 @@ void MatrixCreator<dim>::create_boundary_mass_matrix (const DoFHandler<dim>    &
                  a->value_list (fe_values.get_quadrature_points(),
                                 coefficient_values_scalar);
                  for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-                   for (unsigned int i=0; i<fe_values.total_dofs; ++i) 
+                   for (unsigned int i=0; i<fe_values.dofs_per_cell; ++i) 
                      {
-                       for (unsigned int j=0; j<fe_values.total_dofs; ++j)
+                       for (unsigned int j=0; j<fe_values.dofs_per_cell; ++j)
                          cell_matrix(i,j) += (values(i,point) *
                                               values(j,point) *
                                               weights[point] *
@@ -260,9 +260,9 @@ void MatrixCreator<dim>::create_boundary_mass_matrix (const DoFHandler<dim>    &
                }
              else
                for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-                 for (unsigned int i=0; i<fe_values.total_dofs; ++i) 
+                 for (unsigned int i=0; i<fe_values.dofs_per_cell; ++i) 
                    {
-                     for (unsigned int j=0; j<fe_values.total_dofs; ++j)
+                     for (unsigned int j=0; j<fe_values.dofs_per_cell; ++j)
                        cell_matrix(i,j) += (values(i,point) *
                                             values(j,point) *
                                             weights[point]);
@@ -392,7 +392,7 @@ void MatrixCreator<dim>::create_laplace_matrix (const DoFHandler<dim>    &dof,
                                                const Quadrature<dim>    &q,
                                                SparseMatrix<double>     &matrix,
                                                const Function<dim> * const a) {
-  const unsigned int n_components  = dof.get_fe().n_components;
+  const unsigned int n_components  = dof.get_fe().n_components();
   Assert ((n_components==1) || (a==0), ExcNotImplemented());
 
   Vector<double> dummy;   // no entries, should give an error if accessed
@@ -459,7 +459,7 @@ void MatrixCreator<dim>::create_laplace_matrix (const DoFHandler<dim>    &dof,
                                                Vector<double>           &rhs_vector,
                                                const Function<dim> * const a)
 {
-  const unsigned int n_components  = dof.get_fe().n_components;
+  const unsigned int n_components  = dof.get_fe().n_components();
   Assert ((n_components==1) || (a==0), ExcNotImplemented());
 
   UpdateFlags update_flags = UpdateFlags(update_q_points  |
@@ -645,10 +645,10 @@ template <int dim>
 void MassMatrix<dim>::assemble (FullMatrix<double>      &cell_matrix,
                                const FEValues<dim>     &fe_values,
                                const typename DoFHandler<dim>::cell_iterator &) const {
-  const unsigned int dofs_per_cell = fe_values.total_dofs,
+  const unsigned int dofs_per_cell = fe_values.dofs_per_cell,
                     n_q_points    = fe_values.n_quadrature_points;
   const FiniteElement<dim>    &fe  = fe_values.get_fe();
-  const unsigned int n_components  = fe.n_components;
+  const unsigned int n_components  = fe.n_components();
 
   Assert (cell_matrix.n() == dofs_per_cell,
          Equation<dim>::ExcWrongSize(cell_matrix.n(), dofs_per_cell));
@@ -733,10 +733,10 @@ void MassMatrix<dim>::assemble (FullMatrix<double>  &cell_matrix,
                                const DoFHandler<dim>::cell_iterator &) const {
   Assert (right_hand_side != 0, ExcNoRHSSelected());
 
-  const unsigned int dofs_per_cell = fe_values.total_dofs,
+  const unsigned int dofs_per_cell = fe_values.dofs_per_cell,
                     n_q_points    = fe_values.n_quadrature_points;
   const FiniteElement<dim>    &fe  = fe_values.get_fe();
-  const unsigned int n_components  = fe.n_components;
+  const unsigned int n_components  = fe.n_components();
 
                                   // for system elements: not
                                   // implemented at present
@@ -798,10 +798,10 @@ void MassMatrix<dim>::assemble (Vector<double>      &rhs,
                                const DoFHandler<dim>::cell_iterator &) const {
   Assert (right_hand_side != 0, ExcNoRHSSelected());
 
-  const unsigned int dofs_per_cell = fe_values.total_dofs,
+  const unsigned int dofs_per_cell = fe_values.dofs_per_cell,
                     n_q_points    = fe_values.n_quadrature_points;
   const FiniteElement<dim>    &fe  = fe_values.get_fe();
-  const unsigned int n_components  = fe.n_components;
+  const unsigned int n_components  = fe.n_components();
 
                                   // for system elements: not
                                   // implemented at present
@@ -843,10 +843,10 @@ void LaplaceMatrix<dim>::assemble (FullMatrix<double>         &cell_matrix,
                                   const DoFHandler<dim>::cell_iterator &) const {
   Assert (right_hand_side != 0, ExcNoRHSSelected());
   
-  const unsigned int dofs_per_cell = fe_values.total_dofs,
+  const unsigned int dofs_per_cell = fe_values.dofs_per_cell,
                     n_q_points    = fe_values.n_quadrature_points;
   const FiniteElement<dim>    &fe  = fe_values.get_fe();
-  const unsigned int n_components  = fe.n_components;
+  const unsigned int n_components  = fe.n_components();
 
                                   // for system elements: might be
                                   // not so useful, not implemented
@@ -909,11 +909,11 @@ template <int dim>
 void LaplaceMatrix<dim>::assemble (FullMatrix<double>  &cell_matrix,
                                   const FEValues<dim> &fe_values,
                                   const DoFHandler<dim>::cell_iterator &) const {
-  const unsigned int dofs_per_cell = fe_values.total_dofs,
+  const unsigned int dofs_per_cell = fe_values.dofs_per_cell,
                     n_q_points    = fe_values.n_quadrature_points;
 
   const FiniteElement<dim>    &fe  = fe_values.get_fe();
-  const unsigned int n_components  = fe.n_components;
+  const unsigned int n_components  = fe.n_components();
 
                                   // for system elements: might be
                                   // not so useful, not implemented
@@ -966,10 +966,10 @@ void LaplaceMatrix<dim>::assemble (Vector<double>      &rhs,
                                   const DoFHandler<dim>::cell_iterator &) const {
   Assert (right_hand_side != 0, ExcNoRHSSelected());
 
-  const unsigned int dofs_per_cell = fe_values.total_dofs,
+  const unsigned int dofs_per_cell = fe_values.dofs_per_cell,
                     n_q_points    = fe_values.n_quadrature_points;
   const FiniteElement<dim>    &fe  = fe_values.get_fe();
-  const unsigned int n_components  = fe.n_components;
+  const unsigned int n_components  = fe.n_components();
 
                                   // for system elements: might be
                                   // not so useful, not implemented
@@ -1001,23 +1001,23 @@ MatrixCreator<dim>::create_interpolation_matrix(const FiniteElement<dim> &high,
                                                const FiniteElement<dim> &low,
                                                FullMatrix<double>& result)
 {
-  Assert (high.n_components == low.n_components,
+  Assert (high.n_components() == low.n_components(),
          ExcInvalidFE());
   
-  result.reinit (low.total_dofs, high.total_dofs);
+  result.reinit (low.dofs_per_cell, high.dofs_per_cell);
 
                                   // Initialize FEValues at the support points
                                   // of the low element.
-  vector<double> phantom_weights(low.total_dofs,1.);
-  vector<Point<dim> > support_points(low.total_dofs);
+  vector<double> phantom_weights(low.dofs_per_cell,1.);
+  vector<Point<dim> > support_points(low.dofs_per_cell);
   low.get_unit_support_points(support_points);
   Quadrature<dim> low_points(support_points,
                             phantom_weights);
 
   FEValues<dim> fe(high, low_points, UpdateFlags(0));
   
-  for (unsigned int i=0; i<low.total_dofs; ++i)
-    for (unsigned int j=0; j<high.total_dofs; ++j)
+  for (unsigned int i=0; i<low.dofs_per_cell; ++i)
+    for (unsigned int j=0; j<high.dofs_per_cell; ++j)
                                       // shape functions need to belong
                                       // to the same component
       if (low.system_to_component_index(i).first ==
index e5d997ccf65f5bfce3764941ea7a4f76987bab97..84dc85d452eea667c98464fc568f2cc0f6121485 100644 (file)
@@ -68,7 +68,7 @@ template <int dim>
 void MGTransferPrebuilt::build_matrices (const MGDoFHandler<dim> &mg_dof) 
 {
   const unsigned int n_levels      = mg_dof.get_tria().n_levels();
-  const unsigned int dofs_per_cell = mg_dof.get_fe().total_dofs;
+  const unsigned int dofs_per_cell = mg_dof.get_fe().dofs_per_cell;
   
                                   // reset the size of the array of
                                   // matrices
index 1a1f79ee75aac3744357d22ef09e14c7e3995b05..01c369c37c1020c069ba4774771c6242b85319c1 100644 (file)
@@ -55,7 +55,7 @@ void SolutionTransfer<dim, number>::prepare_for_pure_refinement()
   clear();
 
   const unsigned int n_active_cells = dof_handler->get_tria().n_active_cells();
-  const unsigned int dofs_per_cell  = dof_handler->get_fe().total_dofs;
+  const unsigned int dofs_per_cell  = dof_handler->get_fe().dofs_per_cell;
   n_dofs_old=dof_handler->n_dofs();
 
   indices_on_cell=vector<vector<int> > (n_active_cells,
@@ -98,7 +98,7 @@ SolutionTransfer<dim, number>::refine_interpolate(const Vector<number> &in,
   Assert(out.size()==dof_handler->n_dofs(),
         ExcWrongVectorSize(out.size(),dof_handler->n_dofs()));
 
-  unsigned int dofs_per_cell=dof_handler->get_fe().total_dofs;  
+  unsigned int dofs_per_cell=dof_handler->get_fe().dofs_per_cell;  
   Vector<number> local_values(dofs_per_cell);
 
   DoFHandler<dim>::cell_iterator cell = dof_handler->begin(),
@@ -154,7 +154,7 @@ prepare_for_coarsening_and_refinement(const vector<Vector<number> > &all_in)
   clear();
 
   const unsigned int n_active_cells = dof_handler->get_tria().n_active_cells();
-  const unsigned int dofs_per_cell  = dof_handler->get_fe().total_dofs;
+  const unsigned int dofs_per_cell  = dof_handler->get_fe().dofs_per_cell;
   n_dofs_old=dof_handler->n_dofs();
 
   for (unsigned int i=0; i<in_size; ++i)
@@ -291,7 +291,7 @@ interpolate (const vector<Vector<number> > &all_in,
     };
 
   
-  const unsigned int dofs_per_cell=dof_handler->get_fe().total_dofs;  
+  const unsigned int dofs_per_cell=dof_handler->get_fe().dofs_per_cell;  
   Vector<number> local_values(dofs_per_cell);
 
   vector<int>             *indexptr;
index 041ab2d6349fdd426a6c4303c77f3054962d2235..b28c76cf17d8863394ddc75f6b13f7f4a3f77c0c 100644 (file)
@@ -46,11 +46,11 @@ void VectorTools<dim>::interpolate (const DoFHandler<dim> &dof,
                                    const Function<dim>   &function,
                                    Vector<double>        &vec)
 {
-  Assert (dof.get_fe().n_components == function.n_components,
+  Assert (dof.get_fe().n_components() == function.n_components,
          ExcComponentMismatch());
   
   const FiniteElement<dim> &fe           = dof.get_fe();
-  const unsigned int        n_components = fe.n_components;
+  const unsigned int        n_components = fe.n_components();
   const bool                fe_is_system = (n_components != 1);
   
   DoFHandler<dim>::active_cell_iterator cell = dof.begin_active(),
@@ -67,7 +67,7 @@ void VectorTools<dim>::interpolate (const DoFHandler<dim> &dof,
                                   // avoided to evaluate
                                   // the vectorfunction multiply at
                                   // the same point on a cell.
-  vector<Point<dim> > unit_support_points (fe.total_dofs);
+  vector<Point<dim> > unit_support_points (fe.dofs_per_cell);
   fe.get_unit_support_points(unit_support_points);
 
                                   // The following works well
@@ -85,10 +85,10 @@ void VectorTools<dim>::interpolate (const DoFHandler<dim> &dof,
                                   // support point by setting
                                   // #true# in the boolean vector 
                                   // #is_representative_point#.
-//   vector<bool>  is_representative_point(fe.total_dofs, false);
+//   vector<bool>  is_representative_point(fe.dofs_per_cell, false);
 //   is_representative_point[0]=true;
 //   unsigned int n_rep_points=1;
-//   for (unsigned int last_rep_point=0, i=1; i<fe.total_dofs; ++i)
+//   for (unsigned int last_rep_point=0, i=1; i<fe.dofs_per_cell; ++i)
 //     {
 //       if (unit_support_points[i] != unit_support_points[last_rep_point])
 //     {
@@ -98,12 +98,12 @@ void VectorTools<dim>::interpolate (const DoFHandler<dim> &dof,
 //     }
 //    };
 
-//   vector<int>         dofs_on_cell (fe.total_dofs);
-//   vector<Point<dim> > support_points (fe.total_dofs);
+//   vector<int>         dofs_on_cell (fe.dofs_per_cell);
+//   vector<Point<dim> > support_points (fe.dofs_per_cell);
 
 //   vector<Point<dim> > rep_points (n_rep_points);
 //   vector<Vector<double> > function_values_at_rep_points (
-//     n_rep_points, Vector<double>(fe.n_components));
+//     n_rep_points, Vector<double>(fe.n_components()));
 
 //   for (; cell!=endc; ++cell)
 //     {
@@ -115,7 +115,7 @@ void VectorTools<dim>::interpolate (const DoFHandler<dim> &dof,
 //                                    // pick out the representative
 //                                    // support points
 //       unsigned int j=0;
-//       for (unsigned int i=0; i<fe.total_dofs; ++i)
+//       for (unsigned int i=0; i<fe.dofs_per_cell; ++i)
 //     if (is_representative_point[i])
 //       rep_points[j++]=support_points[i];
 //       Assert(j == n_rep_points, ExcInternalError());
@@ -133,7 +133,7 @@ void VectorTools<dim>::interpolate (const DoFHandler<dim> &dof,
 //                                    // therefore the first #last_rep_point# is 0
 //                                    // and we need to start with
 //                                    // `last_rep_point = -1'
-//       for (unsigned int i=0; i<fe.total_dofs; ++i)
+//       for (unsigned int i=0; i<fe.dofs_per_cell; ++i)
 //     {
 //       if (is_representative_point[i])
 //         ++last_rep_point;
@@ -164,7 +164,7 @@ void VectorTools<dim>::interpolate (const DoFHandler<dim> &dof,
                                   // point by the #dof_to_rep_dof_table#.
 
                                   // the following vector collects all dofs i,
-                                  // 0<=i<fe.total_dofs, for that
+                                  // 0<=i<fe.dofs_per_cell, for that
                                   // unit_support_points[i] 
                                   // is a representative one. i.e.
                                   // the following vector collects all rep dofs.
@@ -175,13 +175,13 @@ void VectorTools<dim>::interpolate (const DoFHandler<dim> &dof,
                                   // to the rep index.
   vector<unsigned int> dof_to_rep_index_table;
   unsigned int n_rep_points=0;
-  for (unsigned int i=0; i<fe.total_dofs; ++i)
+  for (unsigned int i=0; i<fe.dofs_per_cell; ++i)
     {
       bool representative=true;
                                       // the following loop is looped
                                       // the other way round to get
                                       // the minimal effort of
-                                      // O(fe.total_dofs) for multiple
+                                      // O(fe.dofs_per_cell) for multiple
                                       // support points that are placed
                                       // one after the other.
       for (unsigned int j=dofs_of_rep_points.size(); j>0; --j)
@@ -203,10 +203,10 @@ void VectorTools<dim>::interpolate (const DoFHandler<dim> &dof,
        }
     }
   Assert(dofs_of_rep_points.size()==n_rep_points, ExcInternalError());
-  Assert(dof_to_rep_index_table.size()==fe.total_dofs, ExcInternalError());
+  Assert(dof_to_rep_index_table.size()==fe.dofs_per_cell, ExcInternalError());
 
-  vector<int>         dofs_on_cell (fe.total_dofs);
-  vector<Point<dim> > support_points (fe.total_dofs);
+  vector<int>         dofs_on_cell (fe.dofs_per_cell);
+  vector<Point<dim> > support_points (fe.dofs_per_cell);
 
   vector<Point<dim> > rep_points (n_rep_points);
 
@@ -218,7 +218,7 @@ void VectorTools<dim>::interpolate (const DoFHandler<dim> &dof,
                                   // more efficient one respectively
   vector<double>          function_values_scalar (n_rep_points);
   vector<Vector<double> > function_values_system (n_rep_points,
-                                                 Vector<double>(fe.n_components));
+                                                 Vector<double>(fe.n_components()));
 
   for (; cell!=endc; ++cell)
     {
@@ -246,7 +246,7 @@ void VectorTools<dim>::interpolate (const DoFHandler<dim> &dof,
                                           // distribute the function
                                           // values to the global
                                           // vector
-         for (unsigned int i=0; i<fe.total_dofs; ++i)
+         for (unsigned int i=0; i<fe.dofs_per_cell; ++i)
            {
              const unsigned int component
                = fe.system_to_component_index(i).first;
@@ -265,7 +265,7 @@ void VectorTools<dim>::interpolate (const DoFHandler<dim> &dof,
                                           // distribute the function
                                           // values to the global
                                           // vector
-         for (unsigned int i=0; i<fe.total_dofs; ++i)
+         for (unsigned int i=0; i<fe.dofs_per_cell; ++i)
            vec(dofs_on_cell[i]) 
              = function_values_scalar[dof_to_rep_index_table[i]];
        };
@@ -281,8 +281,8 @@ VectorTools<dim>::interpolate(const DoFHandler<dim>           &high_dof,
                              const Vector<double>            &high,
                              Vector<double>                  &low)
 {
-  Vector<double> cell_high(high_dof.get_fe().total_dofs);
-  Vector<double> cell_low(low_dof.get_fe().total_dofs);
+  Vector<double> cell_high(high_dof.get_fe().dofs_per_cell);
+  Vector<double> cell_low(low_dof.get_fe().dofs_per_cell);
   
   DoFHandler<dim>::active_cell_iterator h = high_dof.begin_active();
   DoFHandler<dim>::active_cell_iterator l = low_dof.begin_active();
@@ -333,7 +333,7 @@ void VectorTools<dim>::project (const DoFHandler<dim>    &dof,
                                const Quadrature<dim-1>  &q_boundary,
                                const bool                project_to_boundary_first)
 {
-  Assert (dof.get_fe().n_components == function.n_components,
+  Assert (dof.get_fe().n_components() == function.n_components,
          ExcInvalidFE());
   
   const FiniteElement<dim> &fe = dof.get_fe();
@@ -435,7 +435,7 @@ void VectorTools<dim>::create_right_hand_side (const DoFHandler<dim>    &dof,
                                               const Function<dim>      &rhs,
                                               Vector<double>           &rhs_vector)
 {
-  Assert (dof.get_fe().n_components == rhs.n_components,
+  Assert (dof.get_fe().n_components() == rhs.n_components,
          ExcComponentMismatch());
   
   UpdateFlags update_flags = UpdateFlags(update_q_points |
@@ -475,16 +475,16 @@ VectorTools<1>::interpolate_boundary_values (const DoFHandler<1> &dof,
          ExcInvalidBoundaryIndicator());
 
   const FiniteElement<1> &fe = dof.get_fe();
-  Assert (fe.n_components == boundary_function.n_components,
+  Assert (fe.n_components() == boundary_function.n_components,
          ExcComponentMismatch());
-  Assert (fe.dofs_per_vertex == fe.n_components,
+  Assert (fe.dofs_per_vertex == fe.n_components(),
          ExcComponentMismatch());
 
                                   // set the component mask to either
                                   // the original value or a vector
                                   // of #true#s
   const vector<bool> component_mask ((component_mask_.size() == 0) ?
-                                    vector<bool> (fe.n_components, true) :
+                                    vector<bool> (fe.n_components(), true) :
                                     component_mask_);
   Assert (count(component_mask.begin(), component_mask.end(), true) > 0,
          ExcComponentMismatch());
@@ -558,7 +558,7 @@ VectorTools<dim>::interpolate_boundary_values (const DoFHandler<dim> &dof,
          ExcInvalidBoundaryIndicator());
 
   const FiniteElement<dim> &fe           = dof.get_fe();
-  const unsigned int        n_components = fe.n_components;
+  const unsigned int        n_components = fe.n_components();
   const bool                fe_is_system = (n_components != 1);
   
   Assert (n_components == boundary_function.n_components,
@@ -568,7 +568,7 @@ VectorTools<dim>::interpolate_boundary_values (const DoFHandler<dim> &dof,
                                   // the original value or a vector
                                   // of #true#s
   const vector<bool> component_mask ((component_mask_.size() == 0) ?
-                                    vector<bool> (fe.n_components, true) :
+                                    vector<bool> (fe.n_components(), true) :
                                     component_mask_);
   Assert (count(component_mask.begin(), component_mask.end(), true) > 0,
          ExcComponentMismatch());
@@ -584,7 +584,7 @@ VectorTools<dim>::interpolate_boundary_values (const DoFHandler<dim> &dof,
                                   // respectively
   vector<double>          dof_values_scalar (fe.dofs_per_face);
   vector<Vector<double> > dof_values_system (fe.dofs_per_face,
-                                            Vector<double>(fe.n_components));
+                                            Vector<double>(fe.n_components()));
        
   DoFHandler<dim>::active_face_iterator face = dof.begin_active_face(),
                                        endf = dof.end_face();
@@ -636,7 +636,7 @@ VectorTools<dim>::project_boundary_values (const DoFHandler<dim>    &dof,
                                           const Quadrature<dim-1>  &q,
                                           map<int,double>          &boundary_values)
 {
-  Assert (dof.get_fe().n_components == boundary_functions.begin()->second->n_components,
+  Assert (dof.get_fe().n_components() == boundary_functions.begin()->second->n_components,
          ExcComponentMismatch());
   
   vector<int>    dof_to_boundary_mapping;
@@ -722,7 +722,7 @@ VectorTools<dim>::integrate_difference (const DoFHandler<dim>    &dof,
 {
   const unsigned int        n_q_points   = q.n_quadrature_points;
   const FiniteElement<dim> &fe           = dof.get_fe();
-  const unsigned int        n_components = fe.n_components;
+  const unsigned int        n_components = fe.n_components();
   const bool                fe_is_system = (n_components != 1);
 
   Assert( !((n_components == 1) && (norm == mean)),
index e29c38c8045a9851633e626dc87657b41083c971..0ba860a6e335825beb3e537e4fec8cdd3ef0f557 100644 (file)
@@ -67,6 +67,7 @@ targets = $(addsuffix .target, $(executables))
 %.target : %
        @echo ============================ Executing Testcase:   $<
        @./$< > $(subst testcase,output,$<)
+       @diff $(subst testcase,output,$<) $(subst testcase,expect,$<)
 
 # this is the main target
 # make dependence so that it first wants to compile all files then
index 2a3abdc20fc60bd18d204be3cc27f54a11e1b7ee..bb0c25868b4188ce01dc5d2533f725892f36ca71 100644 (file)
@@ -40,22 +40,22 @@ print_fe_statistics(const FiniteElement<dim>& fe)
 //  DoFHandler<dim>::active_cell_iterator cell = dof.begin_active();
   DoFHandler<dim>::active_face_iterator face = dof.begin_active_face();
 
-  vector<Point<dim> > unit_points(fe.total_dofs);
-  vector<Point<dim> > support_points(fe.total_dofs);
+  vector<Point<dim> > unit_points(fe.dofs_per_cell);
+  vector<Point<dim> > support_points(fe.dofs_per_cell);
   vector<Point<dim> > face_support_points(fe.dofs_per_face);
 
 //  fe.get_unit_support_points(unit_points);
 //  fe.get_support_points(cell, boundary, support_points);
   fe.get_face_support_points(face, face_support_points);
   
-  deallog << "total_dofs" << " " << fe.total_dofs;
+  deallog << "dofs_per_cell" << " " << fe.dofs_per_cell;
   deallog << ": vertex" << " " << fe.dofs_per_vertex;
   deallog << "  line" << " " << fe.dofs_per_line;
   deallog << "  quad" <<  " " <<fe.dofs_per_quad << endl;
-  deallog << "n_transform_fct " << fe.n_transform_functions << endl;
-  deallog << "n_components " << fe.n_components << endl;
+  deallog << "n_transform_fct " << fe.n_transform_functions() << endl;
+  deallog << "n_components " << fe.n_components() << endl;
   deallog.push("components");
-  for (unsigned i=0;i<fe.total_dofs;++i)
+  for (unsigned i=0;i<fe.dofs_per_cell;++i)
     {
       pair<unsigned,unsigned> p = fe.system_to_component_index(i);
       deallog << "Index " << i << " ("
index 7510fab761e2e8cab58c3442f1386451dc61551e..85373d700faee6c732074079b502cf5ae2c1fa94 100644 (file)
@@ -8,7 +8,7 @@ Helmholtz::build_all(MATRIX& A,
                     const Quadrature<dim>& quadrature,
                     const Function<dim>& rhs)
 {
-  const unsigned int fe_dofs = dof.get_fe().total_dofs;
+  const unsigned int fe_dofs = dof.get_fe().n_dofs_per_cell();
   FEValues<dim> fe(dof.get_fe(), quadrature,
                   UpdateFlags(update_gradients | update_JxW_values |
                               update_q_points));
index 11d952711ee9dae06753a5eee54ac02658b06c5d..b4d358e180698638e2c5d60560f192dbd9f7df01 100644 (file)
@@ -6,7 +6,7 @@ Helmholtz::build_mgmatrix(MGMatrix<MATRIX>& A,
                          const MGDoFHandler<dim>& dof,
                          const Quadrature<dim>& quadrature)
 {
-  const unsigned int fe_dofs = dof.get_fe().total_dofs;
+  const unsigned int fe_dofs = dof.get_fe().n_dofs_per_cell();
   FEValues<dim> fe(dof.get_fe(), quadrature,
                   UpdateFlags(update_gradients | update_JxW_values |
                               update_q_points));
index 7664abf5cd8624a9dce87657457e5a76193a7a4d..db69323f4ead3d75f89df1ba71010d3dea1b8a1e 100644 (file)
@@ -181,7 +181,7 @@ void write_gnuplot (const MGDoFHandler<2>& dofs, const Vector<double>& v, unsign
   MGDoFHandler<2>::cell_iterator cell;
   MGDoFHandler<2>::cell_iterator endc = dofs.end(level);
 
-  Vector<double> values(dofs.get_fe().total_dofs);
+  Vector<double> values(dofs.get_fe().dofs_per_cell);
   
   unsigned int cell_index=0;
   for (cell=dofs.begin(level); cell!=endc; ++cell, ++cell_index) 
index b9f69f252585e15504d4a02f40d925268fe45e66..0d226d9d276aecb23605ab56cacda2f373e25d32 100644 (file)
@@ -2108,7 +2108,7 @@ void EndEnergy<dim>::compute_vectors (const PartOfDomain pod,
                                      Vector<double> &final_v_bar) const {
   const double y_offset = 300000000;
   const double n_q_points = quadrature->n_quadrature_points;
-  const unsigned int total_dofs = fe->total_dofs;
+  const unsigned int dofs_per_cell = fe->dofs_per_cell;
   
   final_u_bar.reinit (dof->n_dofs());
   final_v_bar.reinit (dof->n_dofs());
@@ -2125,7 +2125,7 @@ void EndEnergy<dim>::compute_vectors (const PartOfDomain pod,
   FEValues<dim> fe_values_primal (*primal_fe, *quadrature,
                                  update_gradients);
   
-  FullMatrix<double>  cell_matrix (total_dofs, total_dofs);
+  FullMatrix<double>  cell_matrix (dofs_per_cell, dofs_per_cell);
 
   vector<Tensor<1,dim> > local_u_grad (n_q_points);
   vector<double>         local_v (n_q_points);
@@ -2133,7 +2133,7 @@ void EndEnergy<dim>::compute_vectors (const PartOfDomain pod,
   vector<double> density_values(quadrature->n_quadrature_points);
   vector<double> stiffness_values(quadrature->n_quadrature_points);
 
-  vector<int> cell_dof_indices (total_dofs);
+  vector<int> cell_dof_indices (dofs_per_cell);
 
   for (; cell!=endc; ++cell, ++primal_cell)
     {
@@ -2172,9 +2172,9 @@ void EndEnergy<dim>::compute_vectors (const PartOfDomain pod,
       const FullMatrix<double>            &shape_values = fe_values.get_shape_values ();
       const vector<double>      &JxW_values (fe_values.get_JxW_values());
       
-      vector<double> local_functional1 (total_dofs, 0);
-      vector<double> local_functional2 (total_dofs, 0);
-      for (unsigned int shape_func=0; shape_func<total_dofs; ++shape_func)
+      vector<double> local_functional1 (dofs_per_cell, 0);
+      vector<double> local_functional2 (dofs_per_cell, 0);
+      for (unsigned int shape_func=0; shape_func<dofs_per_cell; ++shape_func)
        for (unsigned int point=0; point<n_q_points; ++point) 
          {
            local_functional1[shape_func] += local_u_grad[point] *
@@ -2188,7 +2188,7 @@ void EndEnergy<dim>::compute_vectors (const PartOfDomain pod,
          };
 
       cell->get_dof_indices (cell_dof_indices);
-      for (unsigned int shape_func=0; shape_func<total_dofs; ++shape_func)
+      for (unsigned int shape_func=0; shape_func<dofs_per_cell; ++shape_func)
        {
          final_u_bar(cell_dof_indices[shape_func]) += local_functional1[shape_func];
          final_v_bar(cell_dof_indices[shape_func]) += local_functional2[shape_func];
@@ -2250,7 +2250,7 @@ void SeismicSignal<dim>::compute_functionals (Vector<double> &j1,
                                              Vector<double> &j2) {
   const double y_offset = 1.0;
   const unsigned int n_q_points = quadrature_face->n_quadrature_points;
-  const unsigned int total_dofs = fe->total_dofs;
+  const unsigned int dofs_per_cell = fe->dofs_per_cell;
   
   j1.reinit (dof->n_dofs());
   j2.reinit (dof->n_dofs());
@@ -2260,7 +2260,7 @@ void SeismicSignal<dim>::compute_functionals (Vector<double> &j1,
   cell = dof->begin_active();
   endc = dof->end();
 
-  vector<int> cell_dof_indices (total_dofs);
+  vector<int> cell_dof_indices (dofs_per_cell);
 
   FEFaceValues<dim> fe_face_values (*fe, *quadrature_face,
                                    UpdateFlags(update_JxW_values     |
@@ -2287,8 +2287,8 @@ void SeismicSignal<dim>::compute_functionals (Vector<double> &j1,
                                           // \int w(x,t) phi_i(x,y,t) ds
                                           // through this line for each
                                           // of the basis functions
-         vector<double> local_integral (total_dofs, 0);
-         for (unsigned int shape_func=0; shape_func<total_dofs; ++shape_func)
+         vector<double> local_integral (dofs_per_cell, 0);
+         for (unsigned int shape_func=0; shape_func<dofs_per_cell; ++shape_func)
            for (unsigned int point=0; point<n_q_points; ++point)
              local_integral[shape_func] += shape_values(shape_func,point) *
                                            (EvaluateSeismicSignal<dim>
@@ -2296,7 +2296,7 @@ void SeismicSignal<dim>::compute_functionals (Vector<double> &j1,
                                            JxW_values[point];
 
          cell->get_dof_indices (cell_dof_indices);
-         for (unsigned int shape_func=0; shape_func<total_dofs; ++shape_func)
+         for (unsigned int shape_func=0; shape_func<dofs_per_cell; ++shape_func)
            j1(cell_dof_indices[shape_func]) += local_integral[shape_func];
        };
 };
@@ -2379,7 +2379,7 @@ void SplitSignal<1>::compute_functionals (Vector<double> &,
 template <int dim>
 void SplitSignal<dim>::compute_functionals (Vector<double> &j1,
                                            Vector<double> &j2) {
-  const unsigned int total_dofs = fe->total_dofs;
+  const unsigned int dofs_per_cell = fe->dofs_per_cell;
   const unsigned int n_q_points = quadrature_face->n_quadrature_points;
   
   j1.reinit (dof->n_dofs());
@@ -2393,7 +2393,7 @@ void SplitSignal<dim>::compute_functionals (Vector<double> &j1,
   cell = dof->begin_active();
   endc = dof->end();
 
-  vector<int> dof_indices (fe->total_dofs);
+  vector<int> dof_indices (fe->dofs_per_cell);
   FEFaceValues<dim> fe_face_values (*fe, *quadrature_face, update_JxW_values);
   
   for (; cell!=endc; ++cell)
@@ -2421,7 +2421,7 @@ void SplitSignal<dim>::compute_functionals (Vector<double> &j1,
          const vector<double>     &JxW_values   = fe_face_values.get_JxW_values();
          cell->get_dof_indices (dof_indices);
 
-         for (unsigned int i=0; i<total_dofs; ++i)
+         for (unsigned int i=0; i<dofs_per_cell; ++i)
            {
              double sum=0;
              for (unsigned int j=0; j<n_q_points; ++j)
@@ -2454,7 +2454,7 @@ void SplitLine<1>::compute_endtime_vectors (Vector<double> &final_u_bar,
   const unsigned int dim = 1;
 
   const double n_q_points = quadrature->n_quadrature_points;
-  const unsigned int total_dofs = fe->total_dofs;
+  const unsigned int dofs_per_cell = fe->dofs_per_cell;
 
   final_u_bar.reinit (dof->n_dofs());
   final_v_bar.reinit (dof->n_dofs());
@@ -2463,7 +2463,7 @@ void SplitLine<1>::compute_endtime_vectors (Vector<double> &final_u_bar,
                                        endc = dof->end ();
 
   FEValues<dim> fe_values (*fe, *quadrature, update_JxW_values);
-  vector<int> cell_dof_indices (total_dofs);
+  vector<int> cell_dof_indices (dofs_per_cell);
 
   for (; cell!=endc; ++cell)
     {
@@ -2476,14 +2476,14 @@ void SplitLine<1>::compute_endtime_vectors (Vector<double> &final_u_bar,
       const FullMatrix<double>  &shape_values = fe_values.get_shape_values ();
       const vector<double>      &JxW_values (fe_values.get_JxW_values());
 
-      vector<double> local_functional (total_dofs, 0);
-      for (unsigned int shape_func=0; shape_func<total_dofs; ++shape_func)
+      vector<double> local_functional (dofs_per_cell, 0);
+      for (unsigned int shape_func=0; shape_func<dofs_per_cell; ++shape_func)
        for (unsigned int point=0; point<n_q_points; ++point) 
          local_functional[shape_func] += shape_values(shape_func,point) *
                                           JxW_values[point];
 
       cell->get_dof_indices (cell_dof_indices);
-      for (unsigned int shape_func=0; shape_func<total_dofs; ++shape_func)
+      for (unsigned int shape_func=0; shape_func<dofs_per_cell; ++shape_func)
        final_u_bar(cell_dof_indices[shape_func]) += local_functional[shape_func];
     };
 };
@@ -2499,7 +2499,7 @@ void SplitLine<1>::compute_endtime_vectors (Vector<double> &final_u_bar,
 template <int dim>
 void OneBranch1d<dim>::compute_functionals (Vector<double> &j1,
                                            Vector<double> &j2) {
-  const unsigned int total_dofs = fe->total_dofs;
+  const unsigned int dofs_per_cell = fe->dofs_per_cell;
   const unsigned int n_q_points = quadrature->n_quadrature_points;
   
   j1.reinit (dof->n_dofs());
@@ -2513,7 +2513,7 @@ void OneBranch1d<dim>::compute_functionals (Vector<double> &j1,
   cell = dof->begin_active();
   endc = dof->end();
 
-  vector<int> dof_indices (fe->total_dofs);
+  vector<int> dof_indices (fe->dofs_per_cell);
   FEValues<dim> fe_values (*fe, *quadrature, update_JxW_values);
   
   for (; cell!=endc; ++cell)
@@ -2525,7 +2525,7 @@ void OneBranch1d<dim>::compute_functionals (Vector<double> &j1,
        const vector<double>      &JxW_values   = fe_values.get_JxW_values();
        cell->get_dof_indices (dof_indices);
        
-       for (unsigned int i=0; i<total_dofs; ++i)
+       for (unsigned int i=0; i<dofs_per_cell; ++i)
          {
            double sum=0;
            for (unsigned int j=0; j<n_q_points; ++j)
@@ -2548,7 +2548,7 @@ void OneBranch1d<dim>::compute_functionals (Vector<double> &j1,
 template <int dim>
 void SecondCrossing<dim>::compute_functionals (Vector<double> &j1,
                                               Vector<double> &j2) {
-  const unsigned int total_dofs = fe->total_dofs;
+  const unsigned int dofs_per_cell = fe->dofs_per_cell;
   const unsigned int n_q_points = quadrature->n_quadrature_points;
   
   j1.reinit (dof->n_dofs());
@@ -2562,7 +2562,7 @@ void SecondCrossing<dim>::compute_functionals (Vector<double> &j1,
   cell = dof->begin_active();
   endc = dof->end();
 
-  vector<int> dof_indices (fe->total_dofs);
+  vector<int> dof_indices (fe->dofs_per_cell);
   FEValues<dim> fe_values (*fe, *quadrature, update_JxW_values);
   
   for (; cell!=endc; ++cell)
@@ -2574,7 +2574,7 @@ void SecondCrossing<dim>::compute_functionals (Vector<double> &j1,
        const vector<double>      &JxW_values   = fe_values.get_JxW_values();
        cell->get_dof_indices (dof_indices);
        
-       for (unsigned int i=0; i<total_dofs; ++i)
+       for (unsigned int i=0; i<dofs_per_cell; ++i)
          {
            double sum=0;
            for (unsigned int j=0; j<n_q_points; ++j)
@@ -2755,9 +2755,9 @@ double EvaluateEnergyContent<dim>::compute_energy (const PartOfDomain pod) const
                           UpdateFlags(update_gradients      |
                                       update_JxW_values     |
                                       update_q_points));
-  FullMatrix<double>  cell_matrix (fe->total_dofs, fe->total_dofs);
-  Vector<double>   local_u (fe->total_dofs);
-  Vector<double>   local_v (fe->total_dofs);
+  FullMatrix<double>  cell_matrix (fe->dofs_per_cell, fe->dofs_per_cell);
+  Vector<double>   local_u (fe->dofs_per_cell);
+  Vector<double>   local_v (fe->dofs_per_cell);
   
   vector<double> density_values(quadrature->n_quadrature_points);
   vector<double> stiffness_values(quadrature->n_quadrature_points);
@@ -2794,8 +2794,8 @@ double EvaluateEnergyContent<dim>::compute_energy (const PartOfDomain pod) const
       density->value_list (fe_values.get_quadrature_points(),
                           density_values);
       for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-       for (unsigned int i=0; i<fe->total_dofs; ++i) 
-         for (unsigned int j=0; j<fe->total_dofs; ++j)
+       for (unsigned int i=0; i<fe->dofs_per_cell; ++i) 
+         for (unsigned int j=0; j<fe->dofs_per_cell; ++j)
            cell_matrix(i,j) += (values(i,point) *
                                 values(j,point)) *
                                weights[point] *
@@ -2809,8 +2809,8 @@ double EvaluateEnergyContent<dim>::compute_energy (const PartOfDomain pod) const
       stiffness->value_list (fe_values.get_quadrature_points(),
                             stiffness_values);
       for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-       for (unsigned int i=0; i<fe->total_dofs; ++i) 
-         for (unsigned int j=0; j<fe->total_dofs; ++j)
+       for (unsigned int i=0; i<fe->dofs_per_cell; ++i) 
+         for (unsigned int j=0; j<fe->dofs_per_cell; ++j)
            cell_matrix(i,j) += (gradients[i][point] *
                                 gradients[j][point]) *
                                weights[point] *
@@ -3130,7 +3130,7 @@ double EvaluateOneBranch1d<1>::evaluate () {
                                      endc = dof->end();
   double u_integrated=0;
   FEValues<1>  fe_values (*fe, *quadrature, update_JxW_values);
-  vector<double> cell_u (fe->total_dofs);
+  vector<double> cell_u (fe->dofs_per_cell);
   
   for (; cell!=endc; ++cell)
     if ((cell->center()(0) > -0.6) &&
@@ -3207,7 +3207,7 @@ double EvaluateSecondCrossing1d<1>::evaluate () {
                                      endc = dof->end();
   double u_integrated=0;
   FEValues<1>  fe_values (*fe, *quadrature, UpdateFlags(update_JxW_values | update_q_points));
-  vector<double> cell_u (fe->total_dofs);
+  vector<double> cell_u (fe->dofs_per_cell);
   
   for (; cell!=endc; ++cell)
     if ((cell->center()(0) > -0.03) &&
@@ -5512,7 +5512,7 @@ void TimeStep_Wave<dim>::create_matrices ()
   mass_matrix.reinit (system_sparsity);
 
                                   // now actually assemble the matrices
-  const unsigned int total_dofs       = fe.total_dofs,
+  const unsigned int dofs_per_cell       = fe.dofs_per_cell,
                     n_q_points       = quadrature.n_quadrature_points;
 
   const bool   density_constant = parameters.density_constant,
@@ -5540,9 +5540,9 @@ void TimeStep_Wave<dim>::create_matrices ()
 
                                   // indices of all the dofs on this
                                   // cell
-  vector<int>    dof_indices_on_cell (total_dofs);
-  FullMatrix<double> cell_mass_matrix (total_dofs, total_dofs);
-  FullMatrix<double> cell_laplace_matrix (total_dofs, total_dofs);
+  vector<int>    dof_indices_on_cell (dofs_per_cell);
+  FullMatrix<double> cell_mass_matrix (dofs_per_cell, dofs_per_cell);
+  FullMatrix<double> cell_laplace_matrix (dofs_per_cell, dofs_per_cell);
 
   
   for (typename DoFHandler<dim>::active_cell_iterator cell=dof_handler->begin_active();
@@ -5573,8 +5573,8 @@ void TimeStep_Wave<dim>::create_matrices ()
       
                                       // now do the loop
       for (unsigned int q_point=0; q_point<fe_values.n_quadrature_points; ++q_point)
-       for (unsigned int i=0; i<total_dofs; ++i)
-         for (unsigned int j=0; j<total_dofs; ++j)
+       for (unsigned int i=0; i<dofs_per_cell; ++i)
+         for (unsigned int j=0; j<dofs_per_cell; ++j)
            {
              cell_mass_matrix(i,j) += (shape_values(i, q_point) *
                                        shape_values(j, q_point) *
@@ -5587,8 +5587,8 @@ void TimeStep_Wave<dim>::create_matrices ()
            };
 
                                       // now transfer to global matrices
-      for (unsigned int i=0; i<total_dofs; ++i)
-       for (unsigned int j=0; j<total_dofs; ++j)
+      for (unsigned int i=0; i<dofs_per_cell; ++i)
+       for (unsigned int j=0; j<dofs_per_cell; ++j)
          {
            mass_matrix.add(dof_indices_on_cell[i],
                            dof_indices_on_cell[j],
@@ -5677,7 +5677,7 @@ TimeStep_Wave<dim>::transfer_old_solutions (const typename DoFHandler<dim>::cell
     {
                                       // get values from
                                       // old cell and set on the new one
-      Vector<double> cell_data (fe.total_dofs);
+      Vector<double> cell_data (fe.dofs_per_cell);
 
       old_cell->get_interpolated_dof_values (old_grid_u, cell_data);
       new_cell->set_dof_values_by_interpolation (cell_data, old_u);
@@ -6131,7 +6131,7 @@ TimeStep_Dual<dim>::build_rhs (const DoFHandler<dim>::cell_iterator &old_cell,
   const TimeStep_Dual<dim> &previous_time_level
     = static_cast<const TimeStepBase_Wave<dim>*>(next_timestep)->get_timestep_dual();
 
-  const unsigned int total_dofs = fe.total_dofs;
+  const unsigned int dofs_per_cell = fe.dofs_per_cell;
   const double time_step = get_forward_timestep();
 
                                   // both cells are on the same refinement
@@ -6143,26 +6143,26 @@ TimeStep_Dual<dim>::build_rhs (const DoFHandler<dim>::cell_iterator &old_cell,
       const vector<vector<Tensor<1,dim> > >&gradients = fe_values.get_shape_grads ();
       const vector<double>                 &weights   = fe_values.get_JxW_values ();
 
-      FullMatrix<double>    cell_matrix (total_dofs, total_dofs);
+      FullMatrix<double>    cell_matrix (dofs_per_cell, dofs_per_cell);
 
       vector<double> density_values(fe_values.n_quadrature_points);
       parameters.density->value_list (fe_values.get_quadrature_points(),
                                      density_values);
       for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-       for (unsigned int i=0; i<total_dofs; ++i) 
-         for (unsigned int j=0; j<total_dofs; ++j)
+       for (unsigned int i=0; i<dofs_per_cell; ++i) 
+         for (unsigned int j=0; j<dofs_per_cell; ++j)
            cell_matrix(i,j) += (values(i,point) *
                                 values(j,point)) *
                                weights[point] *
                                density_values[point];
 
-      Vector<double> tmp (total_dofs);
+      Vector<double> tmp (dofs_per_cell);
                                       // this is the right hand side of the
                                       // first equation
                                       // for the theta scheme:
                                       //    rhs1 := Mv^1 + kMu^1
                                       //           -(1-theta)theta k^2 Av^1
-      Vector<double> rhs1 (total_dofs);
+      Vector<double> rhs1 (dofs_per_cell);
 
                                       // this is the part of the right hand side
                                       // of the second equation which depends
@@ -6170,16 +6170,16 @@ TimeStep_Dual<dim>::build_rhs (const DoFHandler<dim>::cell_iterator &old_cell,
                                       // step.
                                       // for the theta scheme:
                                       //    rhs2 := Mu^1-(1-theta)kAv^1
-      Vector<double> rhs2 (total_dofs);
+      Vector<double> rhs2 (dofs_per_cell);
            
                                       // vector of values of the function on the
                                       // old grid restricted to one cell
-      Vector<double> old_dof_values_v (total_dofs);
+      Vector<double> old_dof_values_v (dofs_per_cell);
                                       // vector of old u and v times the local
                                       // mass matrix
-      Vector<double> local_M_u (total_dofs);
-      Vector<double> local_M_v (total_dofs);
-      Vector<double> local_A_v (total_dofs);      
+      Vector<double> local_M_u (dofs_per_cell);
+      Vector<double> local_M_v (dofs_per_cell);
+      Vector<double> local_A_v (dofs_per_cell);      
                                       // transfer v+k*u. Note that we need
                                       // old_dof_values_u again below
       old_cell->get_dof_values (previous_time_level.v, old_dof_values_v);
@@ -6195,8 +6195,8 @@ TimeStep_Dual<dim>::build_rhs (const DoFHandler<dim>::cell_iterator &old_cell,
       parameters.stiffness->value_list (fe_values.get_quadrature_points(),
                                        stiffness_values);
       for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-       for (unsigned int i=0; i<total_dofs; ++i) 
-         for (unsigned int j=0; j<total_dofs; ++j)
+       for (unsigned int i=0; i<dofs_per_cell; ++i) 
+         for (unsigned int j=0; j<dofs_per_cell; ++j)
            cell_matrix(i,j) += (gradients[i][point] *
                                 gradients[j][point]) *
                                weights[point] *
@@ -6216,9 +6216,9 @@ TimeStep_Dual<dim>::build_rhs (const DoFHandler<dim>::cell_iterator &old_cell,
 
                                       // transfer into the global
                                       // right hand side
-      vector<int> new_dof_indices (total_dofs, -1);
+      vector<int> new_dof_indices (dofs_per_cell, -1);
       new_cell->get_dof_indices (new_dof_indices);
-      for (unsigned int i=0; i<total_dofs; ++i)
+      for (unsigned int i=0; i<dofs_per_cell; ++i)
        {
          right_hand_side1(new_dof_indices[i]) += rhs1(i);
          right_hand_side2(new_dof_indices[i]) += rhs2(i);
@@ -6235,14 +6235,14 @@ TimeStep_Dual<dim>::build_rhs (const DoFHandler<dim>::cell_iterator &old_cell,
                                       // for the theta scheme:
                                       //    rhs1 := Mv^0 + kMu^1
                                       //           -(1-theta)theta k^2 Av^1
-      Vector<double> rhs1 (total_dofs);
+      Vector<double> rhs1 (dofs_per_cell);
                                       // this is the part of the right hand side
                                       // of the second equation which depends
                                       // on the solutions of the previous time
                                       // step.
                                       // for the theta scheme:
                                       //    rhs2 := Mu^1-(1-theta)kAv^1
-      Vector<double> rhs2 (total_dofs);
+      Vector<double> rhs2 (dofs_per_cell);
 
                                       // collect the contributions of the
                                       // child cells (and possibly their
@@ -6251,9 +6251,9 @@ TimeStep_Dual<dim>::build_rhs (const DoFHandler<dim>::cell_iterator &old_cell,
       
                                       // transfer into the global
                                       // right hand side
-      vector<int> new_dof_indices (total_dofs);
+      vector<int> new_dof_indices (dofs_per_cell);
       new_cell->get_dof_indices (new_dof_indices);
-      for (unsigned int i=0; i<total_dofs; ++i) 
+      for (unsigned int i=0; i<dofs_per_cell; ++i) 
        {
          right_hand_side1(new_dof_indices[i]) += rhs1(i);
          right_hand_side2(new_dof_indices[i]) += rhs2(i);
@@ -6268,8 +6268,8 @@ TimeStep_Dual<dim>::build_rhs (const DoFHandler<dim>::cell_iterator &old_cell,
                                       // vector of values of the function
                                       // on the old grid restricted to
                                       // the large (old) cell
-      Vector<double>  old_dof_values_u (total_dofs);
-      Vector<double>  old_dof_values_v (total_dofs);
+      Vector<double>  old_dof_values_u (dofs_per_cell);
+      Vector<double>  old_dof_values_v (dofs_per_cell);
       old_cell->get_dof_values (previous_time_level.u, old_dof_values_u);
       old_cell->get_dof_values (previous_time_level.v, old_dof_values_v);
 
@@ -6305,36 +6305,36 @@ TimeStep_Dual<dim>::collect_from_children (const DoFHandler<dim>::cell_iterator
   const TimeStep_Dual<dim> &previous_time_level
     = static_cast<const TimeStepBase_Wave<dim>*>(next_timestep)->get_timestep_dual();
 
-  const unsigned int total_dofs = fe.total_dofs;
+  const unsigned int dofs_per_cell = fe.dofs_per_cell;
   const double time_step = get_forward_timestep();
 
-  FullMatrix<double>   cell_matrix (total_dofs, total_dofs);
+  FullMatrix<double>   cell_matrix (dofs_per_cell, dofs_per_cell);
 
                                       // these will hold the values of the
                                       // solution on the old grid, i.e. on
                                       // the small cells
-  Vector<double>  local_old_dof_values_u (total_dofs);
-  Vector<double>  local_old_dof_values_v (total_dofs);
+  Vector<double>  local_old_dof_values_u (dofs_per_cell);
+  Vector<double>  local_old_dof_values_v (dofs_per_cell);
 
                                       // same for the contributions to the
                                       // right hand sides of the projection
-  Vector<double>  local_M_u (total_dofs);
-  Vector<double>  local_M_v (total_dofs);
-  Vector<double>  local_A_v (total_dofs);
+  Vector<double>  local_M_u (dofs_per_cell);
+  Vector<double>  local_M_v (dofs_per_cell);
+  Vector<double>  local_A_v (dofs_per_cell);
       
                                   // this is the right hand side of the
                                   // first equation
                                   // for the theta scheme:
                                   //    rhs1 := Mv^0 + kMu^1
                                   //           -(1-theta)theta k^2 Av^1
-  Vector<double> child_rhs1 (total_dofs);
+  Vector<double> child_rhs1 (dofs_per_cell);
                                   // this is the part of the right hand side
                                   // of the second equation which depends
                                   // on the solutions of the previous time
                                   // step.
                                   // for the theta scheme:
                                   //    rhs2 := Mu^1-(1-theta)kAv^1
-  Vector<double> child_rhs2 (total_dofs);
+  Vector<double> child_rhs2 (dofs_per_cell);
       
   for (unsigned int c=0; c<GeometryInfo<dim>::children_per_cell; ++c) 
     {
@@ -6370,8 +6370,8 @@ TimeStep_Dual<dim>::collect_from_children (const DoFHandler<dim>::cell_iterator
          parameters.density->value_list (fe_values.get_quadrature_points(),
                                          density_values);
          for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-           for (unsigned int i=0; i<total_dofs; ++i) 
-             for (unsigned int j=0; j<total_dofs; ++j)
+           for (unsigned int i=0; i<dofs_per_cell; ++i) 
+             for (unsigned int j=0; j<dofs_per_cell; ++j)
                cell_matrix(i,j) += (values(i,point) *
                                     values(j,point)) *
                                    weights[point] *
@@ -6387,8 +6387,8 @@ TimeStep_Dual<dim>::collect_from_children (const DoFHandler<dim>::cell_iterator
          parameters.stiffness->value_list (fe_values.get_quadrature_points(),
                                                stiffness_values);
          for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-           for (unsigned int i=0; i<total_dofs; ++i) 
-             for (unsigned int j=0; j<total_dofs; ++j)
+           for (unsigned int i=0; i<dofs_per_cell; ++i) 
+             for (unsigned int j=0; j<dofs_per_cell; ++j)
                cell_matrix(i,j) += (gradients[i][point] *
                                     gradients[j][point]) *
                                    weights[point] *
@@ -6433,29 +6433,29 @@ TimeStep_Dual<dim>::distribute_to_children (const DoFHandler<dim>::cell_iterator
                                   // increased with each level of recursion
   unsigned int level_difference = 1;  
   
-  const unsigned int total_dofs = fe.total_dofs;
+  const unsigned int dofs_per_cell = fe.dofs_per_cell;
   const double time_step = get_forward_timestep();
 
-  FullMatrix<double>    cell_matrix(total_dofs, total_dofs);
+  FullMatrix<double>    cell_matrix(dofs_per_cell, dofs_per_cell);
                                   // set up a vector which will hold the
                                   // restriction of the old
                                   // functions (u,v) to a childcell
-  Vector<double> local_old_dof_values_u (total_dofs);
-  Vector<double> local_old_dof_values_v (total_dofs);
+  Vector<double> local_old_dof_values_u (dofs_per_cell);
+  Vector<double> local_old_dof_values_v (dofs_per_cell);
 
                                   // vector of old u and v times the local
                                   // mass matrix (on the small cells
                                   // respectively)
-  Vector<double> local_M_u (total_dofs);
-  Vector<double> local_M_v (total_dofs);
-  Vector<double> local_A_v (total_dofs);
+  Vector<double> local_M_u (dofs_per_cell);
+  Vector<double> local_M_v (dofs_per_cell);
+  Vector<double> local_A_v (dofs_per_cell);
 
                                   // this is the right hand side of the
                                   // first equation
                                   // for the theta scheme:
                                   //    rhs1 := Mv^1 + kMu^1
                                   //           -(1-theta)theta k^2 Av^1
-  Vector<double> rhs1 (total_dofs);
+  Vector<double> rhs1 (dofs_per_cell);
 
                                   // this is the part of the right hand side
                                   // of the second equation which depends
@@ -6463,11 +6463,11 @@ TimeStep_Dual<dim>::distribute_to_children (const DoFHandler<dim>::cell_iterator
                                   // step.
                                   // for the theta scheme:
                                   //    rhs2 := Mu^1-(1-theta)kAv^1
-  Vector<double> rhs2 (total_dofs);
+  Vector<double> rhs2 (dofs_per_cell);
            
                                   // indices of the dofs of a cell on
                                   // the new grid
-  vector<int> new_dof_indices (total_dofs, -1);
+  vector<int> new_dof_indices (dofs_per_cell, -1);
 
       
                                       // loop over the child cells
@@ -6508,8 +6508,8 @@ TimeStep_Dual<dim>::distribute_to_children (const DoFHandler<dim>::cell_iterator
          parameters.density->value_list (fe_values.get_quadrature_points(),
                                          density_values);
          for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-           for (unsigned int i=0; i<total_dofs; ++i) 
-             for (unsigned int j=0; j<total_dofs; ++j)
+           for (unsigned int i=0; i<dofs_per_cell; ++i) 
+             for (unsigned int j=0; j<dofs_per_cell; ++j)
                cell_matrix(i,j) += (values(i,point) *
                                     values(j,point)) *
                                    weights[point] *
@@ -6525,8 +6525,8 @@ TimeStep_Dual<dim>::distribute_to_children (const DoFHandler<dim>::cell_iterator
          parameters.stiffness->value_list (fe_values.get_quadrature_points(),
                                            stiffness_values);
          for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-           for (unsigned int i=0; i<total_dofs; ++i) 
-             for (unsigned int j=0; j<total_dofs; ++j)
+           for (unsigned int i=0; i<dofs_per_cell; ++i) 
+             for (unsigned int j=0; j<dofs_per_cell; ++j)
                cell_matrix(i,j) += (gradients[i][point] *
                                     gradients[j][point]) *
                                    weights[point] *
@@ -6547,7 +6547,7 @@ TimeStep_Dual<dim>::distribute_to_children (const DoFHandler<dim>::cell_iterator
                                           // transfer into the global
                                           // right hand side
          new_child->get_dof_indices (new_dof_indices);
-         for (unsigned int i=0; i<total_dofs; ++i)
+         for (unsigned int i=0; i<dofs_per_cell; ++i)
            {
              right_hand_side1(new_dof_indices[i]) += rhs1(i);
              right_hand_side2(new_dof_indices[i]) += rhs2(i);
@@ -6859,8 +6859,8 @@ TimeStep_ErrorEstimation<dim>::estimate_error_dual (const DoFHandler<dim>::cell_
   const FiniteElement<dim> &primal_fe = get_timestep_primal().fe,
                           &dual_fe   = get_timestep_dual().fe;
 
-  const unsigned int        total_dofs_primal = primal_fe.total_dofs,
-                           total_dofs_dual   = dual_fe.total_dofs;  
+  const unsigned int        dofs_per_cell_primal = primal_fe.dofs_per_cell,
+                           dofs_per_cell_dual   = dual_fe.dofs_per_cell;  
 
 
                                   // none of the two cells has children
@@ -6871,16 +6871,16 @@ TimeStep_ErrorEstimation<dim>::estimate_error_dual (const DoFHandler<dim>::cell_
                                       // hold the solution interpolated
                                       // up to the ansatz degree of the
                                       // dual problem.
-      Vector<double> local_u(total_dofs_dual), local_v(total_dofs_dual);
-      Vector<double> local_u_bar(total_dofs_dual), local_v_bar(total_dofs_dual);
+      Vector<double> local_u(dofs_per_cell_dual), local_v(dofs_per_cell_dual);
+      Vector<double> local_u_bar(dofs_per_cell_dual), local_v_bar(dofs_per_cell_dual);
 
                                       // same thing for old solutions
-      Vector<double> local_u_old(total_dofs_dual), local_v_old(total_dofs_dual);
-      Vector<double> local_u_bar_old(total_dofs_dual), local_v_bar_old(total_dofs_dual);
+      Vector<double> local_u_old(dofs_per_cell_dual), local_v_old(dofs_per_cell_dual);
+      Vector<double> local_u_bar_old(dofs_per_cell_dual), local_v_bar_old(dofs_per_cell_dual);
 
                                       // vectors to hold dof values on
                                       // the primal/dual cell (temporary)
-      Vector<double> primal_tmp(total_dofs_primal);
+      Vector<double> primal_tmp(dofs_per_cell_primal);
       
                                       // fill local solution vectors
       primal_cell->get_dof_values (primal_problem.u, primal_tmp);
@@ -6926,12 +6926,12 @@ TimeStep_ErrorEstimation<dim>::estimate_error_dual (const DoFHandler<dim>::cell_
                                   // thereon
   if (!primal_cell_old->has_children() && primal_cell->has_children())
     {
-      Vector<double> local_u_old(total_dofs_dual), local_v_old(total_dofs_dual);
-      Vector<double> local_u_bar_old(total_dofs_dual), local_v_bar_old(total_dofs_dual);
+      Vector<double> local_u_old(dofs_per_cell_dual), local_v_old(dofs_per_cell_dual);
+      Vector<double> local_u_bar_old(dofs_per_cell_dual), local_v_bar_old(dofs_per_cell_dual);
 
                                       // vectors to hold dof values on
                                       // the primal/dual cell (temporary)
-      Vector<double> primal_tmp(total_dofs_primal);
+      Vector<double> primal_tmp(dofs_per_cell_primal);
       
                                       // fill local old solution vectors.
                                       // no problems here, since the two
@@ -6976,11 +6976,11 @@ TimeStep_ErrorEstimation<dim>::estimate_error_dual (const DoFHandler<dim>::cell_
                                       // hold the solution interpolated
                                       // up to the ansatz degree of the
                                       // dual problem.
-      Vector<double> local_u(total_dofs_dual), local_v(total_dofs_dual);
-      Vector<double> local_u_bar(total_dofs_dual), local_v_bar(total_dofs_dual);
-      Vector<double> local_u_bar_old(total_dofs_dual), local_v_bar_old(total_dofs_dual);
-      Vector<double> local_Ih_u_bar(total_dofs_dual), local_Ih_v_bar(total_dofs_dual);
-      Vector<double> local_Ih_u_bar_old(total_dofs_dual), local_Ih_v_bar_old(total_dofs_dual);
+      Vector<double> local_u(dofs_per_cell_dual), local_v(dofs_per_cell_dual);
+      Vector<double> local_u_bar(dofs_per_cell_dual), local_v_bar(dofs_per_cell_dual);
+      Vector<double> local_u_bar_old(dofs_per_cell_dual), local_v_bar_old(dofs_per_cell_dual);
+      Vector<double> local_Ih_u_bar(dofs_per_cell_dual), local_Ih_v_bar(dofs_per_cell_dual);
+      Vector<double> local_Ih_u_bar_old(dofs_per_cell_dual), local_Ih_v_bar_old(dofs_per_cell_dual);
       
                                       // vectors to hold dof values on
                                       // the primal/dual cell (temporary)
@@ -7065,7 +7065,7 @@ compute_error_on_new_children (const DoFHandler<dim>::cell_iterator &primal_cell
   const TimeStep_Dual<dim>   &dual_problem   = get_timestep_dual();
 
   const FiniteElement<dim> &dual_fe  = get_timestep_dual().fe;
-  const unsigned int total_dofs_dual = dual_fe.total_dofs;
+  const unsigned int dofs_per_cell_dual = dual_fe.dofs_per_cell;
   
   
   for (unsigned int child=0; child<GeometryInfo<dim>::children_per_cell; ++child)
@@ -7073,8 +7073,8 @@ compute_error_on_new_children (const DoFHandler<dim>::cell_iterator &primal_cell
                                       // we have the solutions on the
                                       // old (large) cell, we restrict it to
                                       // each of the small cells
-      Vector<double> child_u_old(total_dofs_dual), child_v_old(total_dofs_dual);
-      Vector<double> child_u_bar_old(total_dofs_dual), child_v_bar_old(total_dofs_dual);
+      Vector<double> child_u_old(dofs_per_cell_dual), child_v_old(dofs_per_cell_dual);
+      Vector<double> child_u_bar_old(dofs_per_cell_dual), child_v_bar_old(dofs_per_cell_dual);
 
       dual_fe.prolongate(child).vmult (child_u_old, local_u_old);
       dual_fe.prolongate(child).vmult (child_v_old, local_v_old);
@@ -7107,8 +7107,8 @@ compute_error_on_new_children (const DoFHandler<dim>::cell_iterator &primal_cell
                                           // hold the solution interpolated
                                           // up to the ansatz degree of the
                                           // dual problem.
-         Vector<double> local_u(total_dofs_dual), local_v(total_dofs_dual);
-         Vector<double> local_u_bar(total_dofs_dual), local_v_bar(total_dofs_dual);
+         Vector<double> local_u(dofs_per_cell_dual), local_v(dofs_per_cell_dual);
+         Vector<double> local_u_bar(dofs_per_cell_dual), local_v_bar(dofs_per_cell_dual);
          
                                           // vectors to hold dof values on
                                           // the primal/dual cell (temporary)
@@ -7160,17 +7160,17 @@ TimeStep_ErrorEstimation<dim>::collect_error_from_children (const DoFHandler<dim
   
   ErrorOnCell error_sum;
 
-  const unsigned int total_dofs_dual = local_u_bar.size();
+  const unsigned int dofs_per_cell_dual = local_u_bar.size();
   
   for (unsigned int child=0; child<GeometryInfo<dim>::children_per_cell; ++child)
     {
                                       // we have the solutions on the
                                       // new (large) cell, we restrict it to
                                       // each of the small cells
-      Vector<double> child_u(total_dofs_dual), child_v(total_dofs_dual);
-      Vector<double> child_u_bar(total_dofs_dual), child_v_bar(total_dofs_dual);
-      Vector<double> child_Ih_u_bar(total_dofs_dual), child_Ih_v_bar(total_dofs_dual);
-      Vector<double> child_Ih_u_bar_old(total_dofs_dual), child_Ih_v_bar_old(total_dofs_dual);      
+      Vector<double> child_u(dofs_per_cell_dual), child_v(dofs_per_cell_dual);
+      Vector<double> child_u_bar(dofs_per_cell_dual), child_v_bar(dofs_per_cell_dual);
+      Vector<double> child_Ih_u_bar(dofs_per_cell_dual), child_Ih_v_bar(dofs_per_cell_dual);
+      Vector<double> child_Ih_u_bar_old(dofs_per_cell_dual), child_Ih_v_bar_old(dofs_per_cell_dual);      
 
       dual_fe.prolongate(child).vmult (child_u, local_u);
       dual_fe.prolongate(child).vmult (child_v, local_v);
@@ -7199,8 +7199,8 @@ TimeStep_ErrorEstimation<dim>::collect_error_from_children (const DoFHandler<dim
                                         // the old cell was not further
                                         // refined -> go on here directly
        {
-         Vector<double> local_u_old(total_dofs_dual), local_v_old(total_dofs_dual);
-         Vector<double> local_u_bar_old(total_dofs_dual), local_v_bar_old(total_dofs_dual);
+         Vector<double> local_u_old(dofs_per_cell_dual), local_v_old(dofs_per_cell_dual);
+         Vector<double> local_u_bar_old(dofs_per_cell_dual), local_v_bar_old(dofs_per_cell_dual);
 
                                           // vectors to hold dof values on
                                           // the primal/dual cell (temporary)
@@ -7215,10 +7215,10 @@ TimeStep_ErrorEstimation<dim>::collect_error_from_children (const DoFHandler<dim
          old_primal_child->get_dof_values (primal_problem_old.v, primal_tmp);
          embedding_matrix.vmult (local_v_old, primal_tmp);
 
-         Vector<double> child_difference_u_bar (total_dofs_dual);
-         Vector<double> child_difference_v_bar (total_dofs_dual);
-         Vector<double> local_difference_u_bar_old (total_dofs_dual);
-         Vector<double> local_difference_v_bar_old (total_dofs_dual);
+         Vector<double> child_difference_u_bar (dofs_per_cell_dual);
+         Vector<double> child_difference_v_bar (dofs_per_cell_dual);
+         Vector<double> local_difference_u_bar_old (dofs_per_cell_dual);
+         Vector<double> local_difference_v_bar_old (dofs_per_cell_dual);
 
          child_difference_u_bar =  child_u_bar;
          child_difference_u_bar -= child_Ih_u_bar;
@@ -7303,12 +7303,12 @@ TimeStep_ErrorEstimation<dim>::error_formula (const DoFHandler<dim>::active_cell
                                   // identity on this cell
   ErrorOnCell error_on_cell;
 
-  const unsigned int total_dofs = get_timestep_dual().fe.total_dofs;
+  const unsigned int dofs_per_cell = get_timestep_dual().fe.dofs_per_cell;
   
                                   // two temporaries needed for the
                                   // calculation of the scalar products
-  Vector<double> tmp1(total_dofs);
-  Vector<double> tmp2(total_dofs);
+  Vector<double> tmp1(dofs_per_cell);
+  Vector<double> tmp2(dofs_per_cell);
 
 
   vector<double> stiffness(fe_values.n_quadrature_points);
@@ -7338,8 +7338,8 @@ TimeStep_ErrorEstimation<dim>::error_formula (const DoFHandler<dim>::active_cell
   parameters.density->value_list (fe_values.get_quadrature_points(),
                                  density_values);
   for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-    for (unsigned int i=0; i<total_dofs; ++i) 
-      for (unsigned int j=0; j<total_dofs; ++j)
+    for (unsigned int i=0; i<dofs_per_cell; ++i) 
+      for (unsigned int j=0; j<dofs_per_cell; ++j)
        {
          mass_matrix(i,j) += (values(i,point) *
                               values(j,point)) *
@@ -7574,14 +7574,14 @@ void TimeStep_ErrorEstimation<dim>::make_interpolation_matrices () {
   const FiniteElement<dim> &primal_fe = get_timestep_primal().fe,
                           &dual_fe   = get_timestep_dual().fe;
   
-  embedding_matrix.reinit (dual_fe.total_dofs,
-                          primal_fe.total_dofs);
+  embedding_matrix.reinit (dual_fe.dofs_per_cell,
+                          primal_fe.dofs_per_cell);
 
-  vector<Point<dim> > unit_support_points (dual_fe.total_dofs);
+  vector<Point<dim> > unit_support_points (dual_fe.dofs_per_cell);
   dual_fe.get_unit_support_points (unit_support_points);
   
-  for (unsigned int i=0; i<dual_fe.total_dofs; ++i)
-    for (unsigned int j=0; j<primal_fe.total_dofs; ++j)
+  for (unsigned int i=0; i<dual_fe.dofs_per_cell; ++i)
+    for (unsigned int j=0; j<primal_fe.dofs_per_cell; ++j)
       embedding_matrix(i,j) = primal_fe.shape_value (j, unit_support_points[i]);
 
 
@@ -7596,21 +7596,21 @@ void TimeStep_ErrorEstimation<dim>::make_interpolation_matrices () {
                                   // primal space and then back to the
                                   // dual space (by injection, using
                                   // the matrix constructed above)
-  FullMatrix<double> inverse_interpolation (primal_fe.total_dofs,
-                                           dual_fe.total_dofs);
-  unit_support_points.resize (primal_fe.total_dofs);
+  FullMatrix<double> inverse_interpolation (primal_fe.dofs_per_cell,
+                                           dual_fe.dofs_per_cell);
+  unit_support_points.resize (primal_fe.dofs_per_cell);
   primal_fe.get_unit_support_points (unit_support_points);
   
-  for (unsigned int i=0; i<primal_fe.total_dofs; ++i)
-    for (unsigned int j=0; j<dual_fe.total_dofs; ++j)
+  for (unsigned int i=0; i<primal_fe.dofs_per_cell; ++i)
+    for (unsigned int j=0; j<dual_fe.dofs_per_cell; ++j)
       inverse_interpolation(i,j) = dual_fe.shape_value (j, unit_support_points[i]);
 
-  interpolation_matrix.reinit (dual_fe.total_dofs, dual_fe.total_dofs);
+  interpolation_matrix.reinit (dual_fe.dofs_per_cell, dual_fe.dofs_per_cell);
   embedding_matrix.mmult (interpolation_matrix, inverse_interpolation);
   
-  difference_matrix.reinit (dual_fe.total_dofs, dual_fe.total_dofs);
+  difference_matrix.reinit (dual_fe.dofs_per_cell, dual_fe.dofs_per_cell);
                                   // initialize with the unit matrix
-  for (unsigned int i=0; i<dual_fe.total_dofs; ++i)
+  for (unsigned int i=0; i<dual_fe.dofs_per_cell; ++i)
     difference_matrix(i,i) = 1.;
                                   // compute difference
   difference_matrix.add (-1, interpolation_matrix);
@@ -8453,7 +8453,7 @@ TimeStep_Primal<dim>::build_rhs (const DoFHandler<dim>::cell_iterator &old_cell,
   const TimeStep_Primal<dim> &previous_time_level
     = static_cast<const TimeStepBase_Wave<dim>*>(previous_timestep)->get_timestep_primal();
 
-  const unsigned int total_dofs = fe.total_dofs;
+  const unsigned int dofs_per_cell = fe.dofs_per_cell;
   const double time_step = get_backward_timestep();
 
                                   // both cells are on the same refinement
@@ -8462,7 +8462,7 @@ TimeStep_Primal<dim>::build_rhs (const DoFHandler<dim>::cell_iterator &old_cell,
     {
       fe_values.reinit (old_cell);
 
-      FullMatrix<double>                    cell_matrix (total_dofs, total_dofs);
+      FullMatrix<double>                    cell_matrix (dofs_per_cell, dofs_per_cell);
       const FullMatrix<double>             &values    = fe_values.get_shape_values ();
       const vector<vector<Tensor<1,dim> > >&gradients = fe_values.get_shape_grads ();
       const vector<double>                 &weights   = fe_values.get_JxW_values ();
@@ -8472,20 +8472,20 @@ TimeStep_Primal<dim>::build_rhs (const DoFHandler<dim>::cell_iterator &old_cell,
       parameters.density->value_list (fe_values.get_quadrature_points(),
                                      density_values);
       for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-       for (unsigned int i=0; i<total_dofs; ++i) 
-         for (unsigned int j=0; j<total_dofs; ++j)
+       for (unsigned int i=0; i<dofs_per_cell; ++i) 
+         for (unsigned int j=0; j<dofs_per_cell; ++j)
            cell_matrix(i,j) += (values(i,point) *
                                 values(j,point)) *
                                weights[point] *
                                density_values[point];
 
-      Vector<double> tmp (total_dofs);
+      Vector<double> tmp (dofs_per_cell);
                                       // this is the right hand side of the
                                       // first equation
                                       // for the theta scheme:
                                       //    rhs1 := Mu^0 + kMv^0
                                       //           -(1-theta)theta k^2 Au^0
-      Vector<double> rhs1 (total_dofs);
+      Vector<double> rhs1 (dofs_per_cell);
 
                                       // this is the part of the right hand side
                                       // of the second equation which depends
@@ -8493,16 +8493,16 @@ TimeStep_Primal<dim>::build_rhs (const DoFHandler<dim>::cell_iterator &old_cell,
                                       // step.
                                       // for the theta scheme:
                                       //    rhs2 := Mv^0-(1-theta)kA^0
-      Vector<double> rhs2 (total_dofs);
+      Vector<double> rhs2 (dofs_per_cell);
            
                                       // vector of values of the function on the
                                       // old grid restricted to one cell
-      Vector<double>     old_dof_values_u (total_dofs);
+      Vector<double>     old_dof_values_u (dofs_per_cell);
                                       // vector of old u and v times the local
                                       // mass matrix
-      Vector<double> local_M_u (total_dofs);
-      Vector<double> local_M_v (total_dofs);
-      Vector<double> local_A_u (total_dofs);      
+      Vector<double> local_M_u (dofs_per_cell);
+      Vector<double> local_M_v (dofs_per_cell);
+      Vector<double> local_A_u (dofs_per_cell);      
                                       // transfer u+k*v. Note that we need
                                       // old_dof_values_u again below
       old_cell->get_dof_values (previous_time_level.u, old_dof_values_u);
@@ -8518,8 +8518,8 @@ TimeStep_Primal<dim>::build_rhs (const DoFHandler<dim>::cell_iterator &old_cell,
       parameters.stiffness->value_list (fe_values.get_quadrature_points(),
                                            stiffness_values);
       for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-       for (unsigned int i=0; i<total_dofs; ++i) 
-         for (unsigned int j=0; j<total_dofs; ++j)
+       for (unsigned int i=0; i<dofs_per_cell; ++i) 
+         for (unsigned int j=0; j<dofs_per_cell; ++j)
            cell_matrix(i,j) += (gradients[i][point] *
                                 gradients[j][point]) *
                                weights[point] *
@@ -8540,9 +8540,9 @@ TimeStep_Primal<dim>::build_rhs (const DoFHandler<dim>::cell_iterator &old_cell,
 
                                       // transfer into the global
                                       // right hand side
-      vector<int> new_dof_indices (total_dofs, -1);
+      vector<int> new_dof_indices (dofs_per_cell, -1);
       new_cell->get_dof_indices (new_dof_indices);
-      for (unsigned int i=0; i<total_dofs; ++i)
+      for (unsigned int i=0; i<dofs_per_cell; ++i)
        {
          right_hand_side1(new_dof_indices[i]) += rhs1(i);
          right_hand_side2(new_dof_indices[i]) += rhs2(i);
@@ -8559,7 +8559,7 @@ TimeStep_Primal<dim>::build_rhs (const DoFHandler<dim>::cell_iterator &old_cell,
                                       // for the theta scheme:
                                       //    rhs1 := Mu^0 + kMv^0
                                       //           -(1-theta)theta k^2 Au^0
-      Vector<double> rhs1 (total_dofs);
+      Vector<double> rhs1 (dofs_per_cell);
 
                                       // this is the part of the right hand side
                                       // of the second equation which depends
@@ -8567,7 +8567,7 @@ TimeStep_Primal<dim>::build_rhs (const DoFHandler<dim>::cell_iterator &old_cell,
                                       // step.
                                       // for the theta scheme:
                                       //    rhs2 := Mv^0-(1-theta)kA^0
-      Vector<double> rhs2 (total_dofs);
+      Vector<double> rhs2 (dofs_per_cell);
 
                                       // collect the contributions of the
                                       // child cells (and possibly their
@@ -8576,9 +8576,9 @@ TimeStep_Primal<dim>::build_rhs (const DoFHandler<dim>::cell_iterator &old_cell,
 
                                       // transfer into the global
                                       // right hand side
-      vector<int> new_dof_indices (total_dofs);
+      vector<int> new_dof_indices (dofs_per_cell);
       new_cell->get_dof_indices (new_dof_indices);
-      for (unsigned int i=0; i<total_dofs; ++i) 
+      for (unsigned int i=0; i<dofs_per_cell; ++i) 
        {
          right_hand_side1(new_dof_indices[i]) += rhs1(i);
          right_hand_side2(new_dof_indices[i]) += rhs2(i);
@@ -8593,8 +8593,8 @@ TimeStep_Primal<dim>::build_rhs (const DoFHandler<dim>::cell_iterator &old_cell,
                                       // vector of values of the function
                                       // on the old grid restricted to
                                       // the large (old) cell
-      Vector<double>  old_dof_values_u (total_dofs);
-      Vector<double>  old_dof_values_v (total_dofs);
+      Vector<double>  old_dof_values_u (dofs_per_cell);
+      Vector<double>  old_dof_values_v (dofs_per_cell);
       old_cell->get_dof_values (previous_time_level.u, old_dof_values_u);
       old_cell->get_dof_values (previous_time_level.v, old_dof_values_v);
 
@@ -8631,29 +8631,29 @@ TimeStep_Primal<dim>::collect_from_children (const DoFHandler<dim>::cell_iterato
   const TimeStep_Primal<dim> &previous_time_level
     = static_cast<const TimeStepBase_Wave<dim>*>(previous_timestep)->get_timestep_primal();
 
-  const unsigned int total_dofs = fe.total_dofs;
+  const unsigned int dofs_per_cell = fe.dofs_per_cell;
   const double time_step = get_backward_timestep();
 
   
-  FullMatrix<double>   cell_matrix (total_dofs, total_dofs);
+  FullMatrix<double>   cell_matrix (dofs_per_cell, dofs_per_cell);
   
                                   // these will hold the values of the
                                   // solution on the old grid, i.e. on
                                   // the small cells
-  Vector<double>  local_old_dof_values_u (total_dofs);
-  Vector<double>  local_old_dof_values_v (total_dofs);
+  Vector<double>  local_old_dof_values_u (dofs_per_cell);
+  Vector<double>  local_old_dof_values_v (dofs_per_cell);
   
                                   // same for the contributions to the
                                   // right hand sides of the projection
-  Vector<double>  local_M_u (total_dofs);
-  Vector<double>  local_M_v (total_dofs);
-  Vector<double>  local_A_u (total_dofs);
+  Vector<double>  local_M_u (dofs_per_cell);
+  Vector<double>  local_M_v (dofs_per_cell);
+  Vector<double>  local_A_u (dofs_per_cell);
                                   // this is the right hand side of the
                                   // first equation
                                   // for the theta scheme:
                                   //    rhs1 := Mu^0 + kMv^0
                                   //           -(1-theta)theta k^2 Au^0
-  Vector<double> child_rhs1 (total_dofs);
+  Vector<double> child_rhs1 (dofs_per_cell);
 
                                   // this is the part of the right hand side
                                   // of the second equation which depends
@@ -8661,7 +8661,7 @@ TimeStep_Primal<dim>::collect_from_children (const DoFHandler<dim>::cell_iterato
                                   // step.
                                   // for the theta scheme:
                                   //    rhs2 := Mv^0-(1-theta)kA^0
-  Vector<double> child_rhs2 (total_dofs);
+  Vector<double> child_rhs2 (dofs_per_cell);
 
   for (unsigned int c=0; c<GeometryInfo<dim>::children_per_cell; ++c) 
     {
@@ -8697,8 +8697,8 @@ TimeStep_Primal<dim>::collect_from_children (const DoFHandler<dim>::cell_iterato
          parameters.density->value_list (fe_values.get_quadrature_points(),
                                          density_values);
          for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-           for (unsigned int i=0; i<total_dofs; ++i) 
-             for (unsigned int j=0; j<total_dofs; ++j)
+           for (unsigned int i=0; i<dofs_per_cell; ++i) 
+             for (unsigned int j=0; j<dofs_per_cell; ++j)
                cell_matrix(i,j) += (values(i,point) *
                                     values(j,point)) *
                                    weights[point] *
@@ -8715,8 +8715,8 @@ TimeStep_Primal<dim>::collect_from_children (const DoFHandler<dim>::cell_iterato
          parameters.stiffness->value_list (fe_values.get_quadrature_points(),
                                            stiffness_values);
          for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-           for (unsigned int i=0; i<total_dofs; ++i) 
-             for (unsigned int j=0; j<total_dofs; ++j)
+           for (unsigned int i=0; i<dofs_per_cell; ++i) 
+             for (unsigned int j=0; j<dofs_per_cell; ++j)
                cell_matrix(i,j) += (gradients[i][point] *
                                     gradients[j][point]) *
                                    weights[point] *
@@ -8762,29 +8762,29 @@ TimeStep_Primal<dim>::distribute_to_children (const DoFHandler<dim>::cell_iterat
                                   // increased with each level of recursion
   unsigned int level_difference = 1;  
   
-  const unsigned int total_dofs = fe.total_dofs;
+  const unsigned int dofs_per_cell = fe.dofs_per_cell;
   const double time_step = get_backward_timestep();
 
-  FullMatrix<double>    cell_matrix(total_dofs, total_dofs);
+  FullMatrix<double>    cell_matrix(dofs_per_cell, dofs_per_cell);
                                   // set up a vector which will hold the
                                   // restriction of the old
                                   // functions (u,v) to a childcell
-  Vector<double> local_old_dof_values_u (total_dofs);
-  Vector<double> local_old_dof_values_v (total_dofs);
+  Vector<double> local_old_dof_values_u (dofs_per_cell);
+  Vector<double> local_old_dof_values_v (dofs_per_cell);
 
                                   // vector of old u and v times the local
                                   // mass matrix (on the small cells
                                   // respectively)
-  Vector<double> local_M_u (total_dofs);
-  Vector<double> local_M_v (total_dofs);
-  Vector<double> local_A_u (total_dofs);
+  Vector<double> local_M_u (dofs_per_cell);
+  Vector<double> local_M_v (dofs_per_cell);
+  Vector<double> local_A_u (dofs_per_cell);
 
                                   // this is the right hand side of the
                                   // first equation
                                   // for the theta scheme:
                                   //    rhs1 := Mu^0 + kMv^0
                                   //           -(1-theta)theta k^2 Au^0
-  Vector<double> rhs1 (total_dofs);
+  Vector<double> rhs1 (dofs_per_cell);
 
                                   // this is the part of the right hand side
                                   // of the second equation which depends
@@ -8792,11 +8792,11 @@ TimeStep_Primal<dim>::distribute_to_children (const DoFHandler<dim>::cell_iterat
                                   // step.
                                   // for the theta scheme:
                                   //    rhs2 := Mv^0-(1-theta)kA^0
-  Vector<double> rhs2 (total_dofs);
+  Vector<double> rhs2 (dofs_per_cell);
            
                                   // indices of the dofs of a cell on
                                   // the new grid
-  vector<int> new_dof_indices (total_dofs, -1);
+  vector<int> new_dof_indices (dofs_per_cell, -1);
 
       
                                       // loop over the child cells
@@ -8837,8 +8837,8 @@ TimeStep_Primal<dim>::distribute_to_children (const DoFHandler<dim>::cell_iterat
          parameters.density->value_list (fe_values.get_quadrature_points(),
                                              density_values);
          for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-           for (unsigned int i=0; i<total_dofs; ++i) 
-             for (unsigned int j=0; j<total_dofs; ++j)
+           for (unsigned int i=0; i<dofs_per_cell; ++i) 
+             for (unsigned int j=0; j<dofs_per_cell; ++j)
                cell_matrix(i,j) += (values(i,point) *
                                     values(j,point)) *
                                    weights[point] *
@@ -8854,8 +8854,8 @@ TimeStep_Primal<dim>::distribute_to_children (const DoFHandler<dim>::cell_iterat
          parameters.stiffness->value_list (fe_values.get_quadrature_points(),
                                                stiffness_values);
          for (unsigned int point=0; point<fe_values.n_quadrature_points; ++point)
-           for (unsigned int i=0; i<total_dofs; ++i) 
-             for (unsigned int j=0; j<total_dofs; ++j)
+           for (unsigned int i=0; i<dofs_per_cell; ++i) 
+             for (unsigned int j=0; j<dofs_per_cell; ++j)
                cell_matrix(i,j) += (gradients[i][point] *
                                     gradients[j][point]) *
                                    weights[point] *
@@ -8876,7 +8876,7 @@ TimeStep_Primal<dim>::distribute_to_children (const DoFHandler<dim>::cell_iterat
                                           // transfer into the global
                                           // right hand side
          new_child->get_dof_indices (new_dof_indices);
-         for (unsigned int i=0; i<total_dofs; ++i)
+         for (unsigned int i=0; i<dofs_per_cell; ++i)
            {
              right_hand_side1(new_dof_indices[i]) += rhs1(i);
              right_hand_side2(new_dof_indices[i]) += rhs2(i);
index 8d8cbe1b215a65f80c3b7dbfd46c1e8562e9adc7..656be2921abcfb9180c8054f9ec2f7c496349118 100644 (file)
@@ -36,7 +36,7 @@ plot_shape_functions(FiniteElement<dim>& finel, const char* name)
        {
          gnuplot << q.quad_point(k);
          
-         for (unsigned int i=0;i<finel.total_dofs;++i)
+         for (unsigned int i=0;i<finel.dofs_per_cell;++i)
            {
              gnuplot << " "<< fe.shape_value(i,k);
            }

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.