]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Fixed wrong numbering of degrees of freedom in interface_constraints
authorMarkus Buerg <buerg@math.tamu.edu>
Wed, 10 Nov 2010 15:49:55 +0000 (15:49 +0000)
committerMarkus Buerg <buerg@math.tamu.edu>
Wed, 10 Nov 2010 15:49:55 +0000 (15:49 +0000)
git-svn-id: https://svn.dealii.org/trunk@22680 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/source/fe/fe_nedelec.cc
tests/fe/nedelec_crash_01/cmp/generic

index e904eb39c016945955113f0c3bff67779dcc8549..c024ab8133841566ac604ddfe67f7a0ee7a440ed 100644 (file)
@@ -101,37 +101,45 @@ deg (p)
           
           unsigned int target_row = 0;
           
-          for (unsigned int i = 0; i < this->dofs_per_face; ++i, ++target_row)
-            for (unsigned int j = 0; j < this->dofs_per_face; ++j)
-              this->interface_constraints (target_row, j)
-                = face_embeddings[0] (i, j);
-          
-          for (unsigned int i = this->degree; i < this->dofs_per_face;
-               ++i, ++target_row)
-            for (unsigned int j = 0; j < this->dofs_per_face; ++j)
-              this->interface_constraints (target_row, j)
-                = face_embeddings[1] (i, j);
+          for (unsigned int i = 0; i < 2; ++i)
+            for (unsigned int j = this->degree; j < 2 * this->degree;
+                 ++j, ++target_row)
+              for (unsigned int k = 0; k < this->dofs_per_face; ++k)
+                this->interface_constraints (target_row, k)
+                  = face_embeddings[2 * i] (j, k);
           
           for (unsigned int i = 0; i < 2; ++i)
-            for (unsigned int j = i * this->degree; j < (i + 1) * this->degree;
+            for (unsigned int j = 3 * this->degree;
+                 j < GeometryInfo<3>::lines_per_face * this->degree;
                  ++j, ++target_row)
               for (unsigned int k = 0; k < this->dofs_per_face; ++k)
                 this->interface_constraints (target_row, k)
-                  = face_embeddings[2] (j, k);
+                  = face_embeddings[i] (j, k);
           
-          for (unsigned int i = 3 * this->degree;
-               i < GeometryInfo<3>::lines_per_face * this->degree;
-               ++i, ++target_row)
-            for (unsigned int j = 0; j < this->dofs_per_face; ++j)
-              this->interface_constraints (target_row, j)
-                = face_embeddings[2] (i, j);
+          for (unsigned int i = 0; i < 2; ++i)
+            for (unsigned int j = 0; j < 2; ++j)
+              for (unsigned int k = i * this->degree;
+                   k < (i + 1) * this->degree; ++k, ++target_row)
+                for (unsigned int l = 0; l < this->dofs_per_face; ++l)
+                  this->interface_constraints (target_row, l)
+                    = face_embeddings[i + 2 * j] (k, l);
           
           for (unsigned int i = 0; i < 2; ++i)
-            for (unsigned int j = (2 * i + 1) * this->degree;
-                 j < 2 * (i + 1) * this->degree; ++j, ++target_row)
+            for (unsigned int j = 0; j < 2; ++j)
+              for (unsigned int k = (i + 2) * this->degree;
+                   k < (i + 3) * this->degree; ++k, ++target_row)
+                for (unsigned int l = 0; l < this->dofs_per_face; ++l)
+                  this->interface_constraints (target_row, l)
+                    = face_embeddings[2 * i + j] (k, l);
+          
+          for (unsigned int i = 0; i < GeometryInfo<3>::max_children_per_face;
+               ++i)
+            for (unsigned int
+                   j = GeometryInfo<3>::lines_per_face * this->degree;
+                 j < this->dofs_per_face; ++j, ++target_row)
               for (unsigned int k = 0; k < this->dofs_per_face; ++k)
                 this->interface_constraints (target_row, k)
-                  = face_embeddings[3] (j, k);
+                  = face_embeddings[i] (j, k);
           
           break;
         }
index 58aefa2e74e28de01bb62a5f7b7e9e1d4af72594..431dd8c97f24dcc6b466b2c820a3e8df5114c301 100644 (file)
@@ -1,91 +1,2 @@
 
-DEAL:d2-p0::Setup
-DEAL:d2-p0::Triangulation hypercube 2D refinement 1 steps 4 active cells 5 total cells 
-DEAL:d2-p0::Form 0
-DEAL:d2-p0::Difference d*d 0
-DEAL:d2-p0::Form 1
-DEAL:d2-p0::d^2            0
-DEAL:d2-p0::d*d^2          0
-DEAL:d2-p0::Difference d*d 0
-DEAL:d2-p0::Triangulation hypercube 2D refinement 2 local  steps 7 active cells 9 total cells 
-DEAL:d2-p0::Form 0
-DEAL:d2-p0::Difference d*d 0
-DEAL:d2-p0::Form 1
-DEAL:d2-p0::d^2            0
-DEAL:d2-p0::d*d^2          0
-DEAL:d2-p0::Difference d*d 0
-DEAL:d2-p0::Triangulation hypercube 2D refinement 3 local  steps 25 active cells 33 total cells 
-DEAL:d2-p0::Form 0
-DEAL:d2-p0::Difference d*d 0
-DEAL:d2-p0::Form 1
-DEAL:d2-p0::d^2            0
-DEAL:d2-p0::d*d^2          0
-DEAL:d2-p0::Difference d*d 0
-DEAL:d2-p1::Setup
-DEAL:d2-p1::Triangulation hypercube 2D refinement 1 steps 4 active cells 5 total cells 
-DEAL:d2-p1::Form 0
-DEAL:d2-p1::Difference d*d 0
-DEAL:d2-p1::Form 1
-DEAL:d2-p1::d^2            0
-DEAL:d2-p1::d*d^2          0
-DEAL:d2-p1::Difference d*d 0
-DEAL:d2-p1::Triangulation hypercube 2D refinement 2 local  steps 7 active cells 9 total cells 
-DEAL:d2-p1::Form 0
-DEAL:d2-p1::Difference d*d 0
-DEAL:d2-p1::Form 1
-DEAL:d2-p1::d^2            0
-DEAL:d2-p1::d*d^2          0
-DEAL:d2-p1::Difference d*d 0
-DEAL:d2-p1::Triangulation hypercube 2D refinement 3 local  steps 25 active cells 33 total cells 
-DEAL:d2-p1::Form 0
-DEAL:d2-p1::Difference d*d 0
-DEAL:d2-p1::Form 1
-DEAL:d2-p1::d^2            0
-DEAL:d2-p1::d*d^2          0
-DEAL:d2-p1::Difference d*d 0
-DEAL:d2-p2::Setup
-DEAL:d2-p2::Triangulation hypercube 2D refinement 1 steps 4 active cells 5 total cells 
-DEAL:d2-p2::Form 0
-DEAL:d2-p2::Difference d*d 0
-DEAL:d2-p2::Form 1
-DEAL:d2-p2::d^2            0
-DEAL:d2-p2::d*d^2          0
-DEAL:d2-p2::Difference d*d 0
-DEAL:d2-p2::Triangulation hypercube 2D refinement 2 local  steps 7 active cells 9 total cells 
-DEAL:d2-p2::Form 0
-DEAL:d2-p2::Difference d*d 0
-DEAL:d2-p2::Form 1
-DEAL:d2-p2::d^2            0
-DEAL:d2-p2::d*d^2          0
-DEAL:d2-p2::Difference d*d 0
-DEAL:d2-p2::Triangulation hypercube 2D refinement 3 local  steps 25 active cells 33 total cells 
-DEAL:d2-p2::Form 0
-DEAL:d2-p2::Difference d*d 0
-DEAL:d2-p2::Form 1
-DEAL:d2-p2::d^2            0
-DEAL:d2-p2::d*d^2          0
-DEAL:d2-p2::Difference d*d 0
-DEAL:d3-p0::Setup
-DEAL:d3-p0::Triangulation hypercube 3D refinement 1 steps 8 active cells 9 total cells 
-DEAL:d3-p0::Form 0
-DEAL:d3-p0::Difference d*d 0
-DEAL:d3-p0::Form 1
-DEAL:d3-p0::d^2            0
-DEAL:d3-p0::d*d^2          0
-DEAL:d3-p0::Difference d*d 0
-DEAL:d3-p0::Form 2
-DEAL:d3-p0::d^2            0
-DEAL:d3-p0::d*d^2          0
-DEAL:d3-p0::Difference d*d 0
-DEAL:d3-p1::Setup
-DEAL:d3-p1::Triangulation hypercube 3D refinement 1 steps 8 active cells 9 total cells 
-DEAL:d3-p1::Form 0
-DEAL:d3-p1::Difference d*d 0
-DEAL:d3-p1::Form 1
-DEAL:d3-p1::d^2            0
-DEAL:d3-p1::d*d^2          0
-DEAL:d3-p1::Difference d*d 0
-DEAL:d3-p1::Form 2
-DEAL:d3-p1::d^2            0
-DEAL:d3-p1::d*d^2          0
-DEAL:d3-p1::Difference d*d 0
+DEAL::Triangulation hypercube 3D refinement 2 local  steps 15 active cells 17 total cells 

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.