]> https://gitweb.dealii.org/ - code-gallery.git/commitdiff
Remove obsolete StandardTensors class from Cook membrane problem 43/head
authorJean-Paul Pelteret <jppelteret@gmail.com>
Mon, 23 Apr 2018 08:18:46 +0000 (10:18 +0200)
committerJean-Paul Pelteret <jppelteret@gmail.com>
Mon, 23 Apr 2018 08:18:46 +0000 (10:18 +0200)
Quasi_static_Finite_strain_Compressible_Elasticity/cook_membrane.cc

index 59de4a47a1fd8fb76f93397612337e1397f3cb75..5655f3f209a45e0df3e15a808d905301ad3e3fb1 100644 (file)
@@ -457,43 +457,6 @@ namespace Cook_Membrane
     }
   }
 
-// @sect3{Some standard tensors}
-
-// Now we define some frequently used second and fourth-order tensors:
-  template <int dim>
-  class StandardTensors
-  {
-  public:
-
-    // $\mathbf{I}$
-    static const SymmetricTensor<2, dim> I;
-    // $\mathbf{I} \otimes \mathbf{I}$
-    static const SymmetricTensor<4, dim> IxI;
-    // $\mathcal{S}$, note that as we only use this fourth-order unit tensor
-    // to operate on symmetric second-order tensors.  To maintain notation
-    // consistent with Holzapfel (2001) we name the tensor $\mathcal{I}$
-    static const SymmetricTensor<4, dim> II;
-    // Fourth-order deviatoric tensor such that
-    // $\textrm{dev} \{ \bullet \} = \{ \bullet \} -
-    //  [1/\textrm{dim}][ \{ \bullet\} :\mathbf{I}]\mathbf{I}$
-    static const SymmetricTensor<4, dim> dev_P;
-  };
-
-  template <int dim>
-  const SymmetricTensor<2, dim>
-  StandardTensors<dim>::I = unit_symmetric_tensor<dim>();
-
-  template <int dim>
-  const SymmetricTensor<4, dim>
-  StandardTensors<dim>::IxI = outer_product(I, I);
-
-  template <int dim>
-  const SymmetricTensor<4, dim>
-  StandardTensors<dim>::II = identity_tensor<dim>();
-
-  template <int dim>
-  const SymmetricTensor<4, dim>
-  StandardTensors<dim>::dev_P = deviator_tensor<dim>();
 
 // @sect3{Time class}
 
@@ -657,7 +620,7 @@ namespace Cook_Membrane
     SymmetricTensor<2,dim,NumberType>
     get_tau_vol(const NumberType &det_F) const
     {
-        return NumberType(get_dPsi_vol_dJ(det_F) * det_F) * StandardTensors<dim>::I;
+        return NumberType(get_dPsi_vol_dJ(det_F) * det_F) * Physics::Elasticity::StandardTensors<dim>::I;
     }
 
     // Next, determine the isochoric Kirchhoff stress
@@ -666,7 +629,7 @@ namespace Cook_Membrane
     SymmetricTensor<2,dim,NumberType>
     get_tau_iso(const SymmetricTensor<2,dim,NumberType> &b_bar) const
     {
-      return StandardTensors<dim>::dev_P * get_tau_bar(b_bar);
+      return Physics::Elasticity::StandardTensors<dim>::dev_P * get_tau_bar(b_bar);
     }
 
     // Then, determine the fictitious Kirchhoff stress
@@ -698,8 +661,8 @@ namespace Cook_Membrane
     {
         // See Holzapfel p265
         return det_F
-        * ( (get_dPsi_vol_dJ(det_F) + det_F * get_d2Psi_vol_dJ2(det_F))*StandardTensors<dim>::IxI
-           - (2.0 * get_dPsi_vol_dJ(det_F))*StandardTensors<dim>::II );
+        * ( (get_dPsi_vol_dJ(det_F) + det_F * get_d2Psi_vol_dJ2(det_F))*Physics::Elasticity::StandardTensors<dim>::IxI
+           - (2.0 * get_dPsi_vol_dJ(det_F))*Physics::Elasticity::StandardTensors<dim>::S );
     }
 
     // Calculate the isochoric part of the tangent $J
@@ -711,17 +674,17 @@ namespace Cook_Membrane
       const SymmetricTensor<2, dim> tau_iso = get_tau_iso(b_bar);
       const SymmetricTensor<4, dim> tau_iso_x_I
         = outer_product(tau_iso,
-                        StandardTensors<dim>::I);
+                        Physics::Elasticity::StandardTensors<dim>::I);
       const SymmetricTensor<4, dim> I_x_tau_iso
-        = outer_product(StandardTensors<dim>::I,
+        = outer_product(Physics::Elasticity::StandardTensors<dim>::I,
                         tau_iso);
       const SymmetricTensor<4, dim> c_bar = get_c_bar();
 
       return (2.0 / dim) * trace(tau_bar)
-             * StandardTensors<dim>::dev_P
+             * Physics::Elasticity::StandardTensors<dim>::dev_P
              - (2.0 / dim) * (tau_iso_x_I + I_x_tau_iso)
-             + StandardTensors<dim>::dev_P * c_bar
-             * StandardTensors<dim>::dev_P;
+             + Physics::Elasticity::StandardTensors<dim>::dev_P * c_bar
+             * Physics::Elasticity::StandardTensors<dim>::dev_P;
     }
 
     // Calculate the fictitious elasticity tensor $\overline{\mathfrak{c}}$.

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.