]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
Do operation in the correct type.
authorbangerth <bangerth@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 30 Apr 2013 16:48:16 +0000 (16:48 +0000)
committerbangerth <bangerth@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 30 Apr 2013 16:48:16 +0000 (16:48 +0000)
git-svn-id: https://svn.dealii.org/trunk@29413 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/source/fe/fe_system.cc

index ab9362dcdfa1ec71c91863cf1167a3be6dacbfa5..88b5f3666ab2adaad2eff13df6eda2df61563b02 100644 (file)
@@ -2677,11 +2677,18 @@ FESystem<dim,spacedim>::multiply_dof_numbers (
         summed_multiplicities += multiplicities[i];
       }
 
-  unsigned char total_conformity = 0xff;
+  // assume maximal conformity and then take away bits
+  // as indicated by the base elements
+  typename FiniteElementData<dim>::Conformity
+    total_conformity
+    = std::numeric_limits<typename FiniteElementData<dim>::Conformity>::max();
 
   for (unsigned int i=0; i<fes.size(); i++)
     if (multiplicities[i]>0)
-      total_conformity &= fes[i]->conforming_space;
+      total_conformity =
+       typename FiniteElementData<dim>::Conformity(total_conformity
+                                                   &
+                                                   fes[i]->conforming_space);
 
   std::vector<unsigned int> dpo;
   dpo.push_back(multiplied_dofs_per_vertex);
@@ -2689,12 +2696,11 @@ FESystem<dim,spacedim>::multiply_dof_numbers (
   if (dim>1) dpo.push_back(multiplied_dofs_per_quad);
   if (dim>2) dpo.push_back(multiplied_dofs_per_hex);
 
-  return FiniteElementData<dim> (
-           dpo,
-           multiplied_n_components,
-           degree,
-           typename FiniteElementData<dim>::Conformity(total_conformity),
-           summed_multiplicities);
+  return FiniteElementData<dim> (dpo,
+                                multiplied_n_components,
+                                degree,
+                                total_conformity,
+                                summed_multiplicities);
 }
 
 

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.