]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
Second derivatives in 3d are not zero, but rather constant.
authorwolf <wolf@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 25 Feb 2003 17:44:59 +0000 (17:44 +0000)
committerwolf <wolf@0785d39b-7218-0410-832d-ea1e28bc413d>
Tue, 25 Feb 2003 17:44:59 +0000 (17:44 +0000)
git-svn-id: https://svn.dealii.org/trunk@7247 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/deal.II/source/fe/fe_nedelec.cc

index 231b5e3a5c264f70c1b1d0c7ec70390f118fb9aa..700a0f048f1ff6ed6df648c305e7db52189b5732 100644 (file)
@@ -625,11 +625,67 @@ FE_Nedelec<3>::shape_grad_grad_component (const unsigned int i,
                                       // first order Nedelec
                                       // elements. their second
                                       // derivatives on the unit cell
-                                      // are linear
+                                      // are constant, but non-zero
       case 1:
       {
-//TODO: not true. this is what presently fails our "shapes" testcase              
-       return Tensor<2,dim>();
+                                        // the format is: first
+                                        // index=shape function
+                                        // number; second
+                                        // index=vector component,
+                                        // third and fourth
+                                        // index=component within
+                                        // second derivative
+       static const double unit_grad_grads[12][3][3][3]
+         = {
+               { { {0, 0, 0}, {0, 0, 1}, {0, 1, 0} },
+                 { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} },
+                 { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} } },
+
+               { { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} },
+                 { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} },
+                 { {0,-1, 0}, {-1, 0, 0}, {0, 0, 0} } },
+
+               { { {0, 0, 0}, {0, 0,-1}, {0,-1, 0} },
+                 { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} },
+                 { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} } },
+
+               { { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} },
+                 { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} },
+                 { {0, 1, 0}, { 1, 0, 0}, {0, 0, 0} } },
+
+               { { {0, 0, 0}, {0, 0,-1}, {0,-1, 0} },
+                 { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} },
+                 { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} } },
+
+               { { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} },
+                 { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} },
+                 { {0, 1, 0}, { 1, 0, 0}, {0, 0, 0} } },
+
+               { { {0, 0, 0}, {0, 0, 1}, {0, 1, 0} },
+                 { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} },
+                 { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} } },
+
+               { { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} },
+                 { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} },
+                 { {0,-1, 0}, {-1, 0, 0}, {0, 0, 0} } },
+
+               { { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} },
+                 { {0, 0, 1}, {0, 0, 0}, {1, 0, 0} },
+                 { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} } },
+
+               { { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} },
+                 { {0, 0,-1}, {0, 0, 0}, {-1, 0, 0} },
+                 { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} } },
+
+               { { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} },
+                 { {0, 0, 1}, {0, 0, 0}, {1, 0, 0} },
+                 { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} } },
+
+               { { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} },
+                 { {0, 0,-1}, {0, 0, 0}, {-1, 0, 0} },
+                 { {0, 0, 0}, {0, 0, 0}, {0, 0, 0} } } };
+
+       return Tensor<2,dim>(unit_grad_grads[i][component]);
       };
 
                                        // no other degrees

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.