getfem-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Getfem-commits] r5278 - in /trunk/getfem: doc/sphinx/source/project/ do


From: Yves . Renard
Subject: [Getfem-commits] r5278 - in /trunk/getfem: doc/sphinx/source/project/ doc/sphinx/source/userdoc/ src/
Date: Sat, 02 Apr 2016 07:27:47 -0000

Author: renard
Date: Sat Apr  2 09:27:47 2016
New Revision: 5278

URL: http://svn.gna.org/viewcvs/getfem?rev=5278&view=rev
Log:
minor improvements

Modified:
    trunk/getfem/doc/sphinx/source/project/femdesc.rst
    trunk/getfem/doc/sphinx/source/project/libdesc_event.rst
    trunk/getfem/doc/sphinx/source/userdoc/model_ALE_rotating.rst
    trunk/getfem/src/bgeot_convex_structure.cc
    trunk/getfem/src/bgeot_mesh_structure.cc

Modified: trunk/getfem/doc/sphinx/source/project/femdesc.rst
URL: 
http://svn.gna.org/viewcvs/getfem/trunk/getfem/doc/sphinx/source/project/femdesc.rst?rev=5278&r1=5277&r2=5278&view=diff
==============================================================================
--- trunk/getfem/doc/sphinx/source/project/femdesc.rst  (original)
+++ trunk/getfem/doc/sphinx/source/project/femdesc.rst  Sat Apr  2 09:27:47 2016
@@ -34,19 +34,19 @@
 The following functions give a pointer onto the descriptor of the usual type of
 elements:
 
-.. cfunction:: bgeot::simplex_structure(dim_type d)
+.. c:function:: bgeot::simplex_structure(dim_type d)
 
    description of a simplex of dimension ``d``.
 
-.. cfunction:: bgeot::parallelepiped_structure(dim_type d)
+.. c:function:: bgeot::parallelepiped_structure(dim_type d)
 
    description of a parallelepiped of dimension ``d``.
 
-.. cfunction:: bgeot::convex_product_structure(bgeot::pconvex_structure p1, 
bgeot::pconv$
+.. c:function:: bgeot::convex_product_structure(bgeot::pconvex_structure p1, 
bgeot::pconv$
 
    description of the direct product of ``p1`` and ``p2``.
 
-.. cfunction:: bgeot::prism_structure(dim_type d)
+.. c:function:: bgeot::prism_structure(dim_type d)
 
    description of a prism of dimension ``d``
 
@@ -86,20 +86,20 @@
 
 The following functions build the descriptions:
 
-.. cfunction:: bgeot::simplex_of_reference(dim_type d)
+.. c:function:: bgeot::simplex_of_reference(dim_type d)
 
    description of the simplex of reference of dimension ``d``.
 
-.. cfunction:: bgeot::simplex_of_reference(dim_type d, short_type k)
+.. c:function:: bgeot::simplex_of_reference(dim_type d, short_type k)
 
    description of the simplex of reference of dimension ``d`` with degree ``k``
    Lagrange grid.
 
-.. cfunction:: bgeot::convex_ref_product(pconvex_ref a, pconvex_ref b)
+.. c:function:: bgeot::convex_ref_product(pconvex_ref a, pconvex_ref b)
 
    description of the direct product of two convexes of reference.
 
-.. cfunction:: bgeot::parallelepiped_of_reference(dim_type d)
+.. c:function:: bgeot::parallelepiped_of_reference(dim_type d)
 
    description of the parallelepiped of reference of dimension ``d``.
 

Modified: trunk/getfem/doc/sphinx/source/project/libdesc_event.rst
URL: 
http://svn.gna.org/viewcvs/getfem/trunk/getfem/doc/sphinx/source/project/libdesc_event.rst?rev=5278&r1=5277&r2=5278&view=diff
==============================================================================
--- trunk/getfem/doc/sphinx/source/project/libdesc_event.rst    (original)
+++ trunk/getfem/doc/sphinx/source/project/libdesc_event.rst    Sat Apr  2 
09:27:47 2016
@@ -36,23 +36,23 @@
 ``context_dependencies`` needs to be a parent class of this object. It adds the
 following methods to the object:
 
-.. cfunction:: add_dependency(ct)
+.. c:function:: add_dependency(ct)
 
    Add an object (which has to have ``context_dependencies`` as a parent class)
    to the list of objects from which the current object depend.
 
-.. cfunction:: touch()
+.. c:function:: touch()
 
    Indicates to the dependent objects that something has change in the object.
 
-.. cfunction:: context_check()
+.. c:function:: context_check()
 
    Check if the object has to be updated. if it is the case it makes first a
    check to the dependency list and call the update function of the object. 
(the
    update function of the dependencies are called before the update function of
    the current object).
 
-.. cfunction:: context_valid()
+.. c:function:: context_valid()
 
    Says if the object has still a valid context, i.e. if the object in the
    dependency list still exist.

Modified: trunk/getfem/doc/sphinx/source/userdoc/model_ALE_rotating.rst
URL: 
http://svn.gna.org/viewcvs/getfem/trunk/getfem/doc/sphinx/source/userdoc/model_ALE_rotating.rst?rev=5278&r1=5277&r2=5278&view=diff
==============================================================================
--- trunk/getfem/doc/sphinx/source/userdoc/model_ALE_rotating.rst       
(original)
+++ trunk/getfem/doc/sphinx/source/userdoc/model_ALE_rotating.rst       Sat Apr 
 2 09:27:47 2016
@@ -13,6 +13,7 @@
 
 This section present a set of bricks facilitating the use of an ALE 
formulation for rotating bodies having a rotational symmetry (typically a train 
wheel).
 
+Work in progress ...
 
 Theoretical background
 ++++++++++++++++++++++
@@ -38,34 +39,27 @@
 .. _ud-fig-rotating_cylinder:
 
 .. figure:: images/ALE_rotating_body.png
-   :align: center
-   :scale: 80
+    :height: 200pt
+    :align: center
+    :alt: alternate text
+    :figclass: align-center
 
-Note that the description is given for a three-dimensional body. For 
two-dimensional bodies, the third axes is neglected so that :math:`R(t)` is a 
:math:`2\times 2` rotation matrix.
-
-Denoting :math:`r(t)` the rotation
+Note that the description is given for a three-dimensional body. For 
two-dimensional bodies, the third axes is neglected so that :math:`R(t)` is a 
:math:`2\times 2` rotation matrix. Let us denote :math:`r(t)` the rotation:
 
 .. math::
-   r(t,X) = R(t)X, ~~~~~~~~~
-   A(t) = \left(\begin{array}{ccc}
+   r(t,X) = R(t)X, ~~~~~~~~~ mbox{ and }
+   A = \left(\begin{array}{ccc}
    0 & -1 & 0 \\
    1 & 0 & 0 \\
    0 & 0 & 0
-   \end{array} \right), ~~~~~~~~~
-   \mbox{ and } B(t) = A^2(t) = \left(\begin{array}{ccc}
-   -1 & 0 & 0 \\
-   0 & -1 & 0 \\
-   0 & 0 & 0
-   \end{array} \right),
+   \end{array} \right).
 
-such that
+We have then
 
 .. math::
- \dot{r}(t,X) = \dot{\theta}A(t)R(t)X
+ \dot{r}(t,X) = \dot{\theta}AR(t)X
 
-
-
-The ALE description consists in the decomposition of the motion of the 
cylinder :math:`\varphi(t, X)` in 
+If :math:`\varphi(t, X)` is the deformation of the body which maps the 
reference configuration :math:`\Omega^0` to the deformed configuration 
:math:`\Omega_t` at time :math:`t`, the ALE description consists in the 
decomposition of the deformation of the cylinder in 
 
 .. math::
    \varphi(t, X) = (\tau(t) \circ \bar{\varphi}(t) \circ r(t))(X) = 
\bar{\varphi}(t, r(t, X)) + z(t)
@@ -73,17 +67,51 @@
 With :math:`\bar{X} = R(t)X` the new considered deformation is
 
 .. math::
-  \bar{\varphi}(\bar{X}) = \varphi(X) - z(t)
+  \bar{\varphi}(t,\bar{X}) = \varphi(X) - z(t)
 
+
+Thanks to the rotation symmetry of the reference configuration 
:math:`\Omega^0:`, we note that :math:`\bar{\Omega}^0 = r(t, \Omega^0)` is 
independant of :math:`t` and will serve as the new reference configuration. 
This is illustrated in the following figure: 
 
 .. _ud-fig-rotating_cylinder_conf:
 
 .. figure:: images/ALE_rotating_conf.png
-   :align: center
-   :scale: 80
+    :height: 200pt
+    :align: center
+    :alt: alternate text
+    :figclass: align-center
 
+The denomination ALE of the method is justified by the fact that 
:math:`\bar{\Omega}^0` is an intermediate configuration which is of Euler type 
for the rigid motion and a Lagrangian one for the additional deformation of the 
solid. If we denote
 
-+ analyse ... et graphique eventuel
+.. math::
+  \bar{u}(t,\bar{X}) = \bar{\varphi}(t, \bar{X}) - \bar{X}
+
+the displacement with respect to this intermediate configuration, the 
advantage is that if this additional displacement with respect to the rigid 
body motion is small, it is possible to use a small deformation model (for 
instance linearized elasticity).
+
+Due to the objectivity properties of standard consistutive laws, the 
expression od these laws in the intermediate configuration is most of the time 
identical to the expression in a standard reference configuration except for 
the expression of the time derivative which are modified because the change of 
coordinate is  nonconstant in time :
+
+.. math::
+
+  \Frac{\partial \varphi}{\partial t} = \Frac{\partial \bar{\varphi}}{\partial 
t} + \dot{\theta} \nabla \bar{\varphi} A \bar{X} + \dot{z}(t),
+
+  \Frac{\partial^2 \varphi}{\partial t^2} = \Frac{\partial^2 
\bar{\varphi}}{\partial t^2} + 2\dot{\theta} \nabla\Frac{\partial 
\bar{\varphi}}{\partial t}A \bar{X} + 
\dot{\theta}^2\mbox{div}((\nabla\bar{\varphi}A \bar{X}) \otimes (A \bar{X}) )  
+ \ddot{\theta}\nabla\bar{\varphi}A \bar{X} + \ddot{z}(t).
+
+Note that the term :math:`\dot{\theta} A \bar{X} = \left(\begin{array}{c} 
-\dot{\theta}\bar{X}_2 \\ \dot{\theta}\bar{X}_1 \\ 0 \end{array}\right)` is the 
rigid motion velocity vector. Now, If :math:`\Theta(t,X)` is a quantity 
attached to the material points (for instance the temperature), then, with 
:math:`\bar{\Theta}(t,\bar{X}) = \Theta(t,X)` , one simply has
+
+.. math::
+
+  \Frac{\partial \Theta}{\partial t} = \Frac{\partial \bar{\Theta}}{\partial 
t} + \dot{\theta} \nabla \bar{\Theta} A \bar{X}
+
+This should not be forgotten that a correction has to be provided for each 
evolving variable for which the time derivative intervene in the considered 
model (think for instance to platic flow for plasticity). So that certain model 
bricks canot be used directly (plastic bricks for instance).
+
+|gf| bricks for structural mecanics are mainly considering the displacement as 
the amin unknown. The expression for the displacement is the following:
+
+.. math::
+  \Frac{\partial u}{\partial t} = \Frac{\partial \bar{u}}{\partial t} + 
\dot{\theta} (I_d + \nabla \bar{u}) A \bar{X} + \dot{z}(t),
+
+  \Frac{\partial^2 u}{\partial t^2} = \Frac{\partial^2 \bar{u}}{\partial t^2} 
+ 2\dot{\theta} \nabla\Frac{\partial \bar{u}}{\partial t}A \bar{X} +  
\dot{\theta}^2\mbox{div}(((I_d + \nabla\bar{u})A \bar{X}) \otimes (A \bar{X}) ) 
 + \ddot{\theta} (I_d + \nabla\bar{u}) A \bar{X}  + \ddot{z}(t).
+  
+  
+
 
 
 Main invariants and derivatives
@@ -94,6 +122,8 @@
 
 the available bricks ...
 ++++++++++++++++++++++++
+
+To be adapted ..
 
 This brick represents a large strain elasticity problem. It is defined in the 
files :file:`getfem/getfem_nonlinear_elasticity.h` and 
:file:`getfem/getfem_nonlinear_elasticity.cc`. The function adding this brick 
to a model is ::
 

Modified: trunk/getfem/src/bgeot_convex_structure.cc
URL: 
http://svn.gna.org/viewcvs/getfem/trunk/getfem/src/bgeot_convex_structure.cc?rev=5278&r1=5277&r2=5278&view=diff
==============================================================================
--- trunk/getfem/src/bgeot_convex_structure.cc  (original)
+++ trunk/getfem/src/bgeot_convex_structure.cc  Sat Apr  2 09:27:47 2016
@@ -61,7 +61,7 @@
         for (short_type i : ind_points_of_face(iff))
           cpt[i]--;
       convex_ind_ct ind;
-      for (size_type i = 0; i < nb_points(); ++i)
+      for (short_type i = 0; i < nb_points(); ++i)
         if (cpt[i] == 0) ind.push_back(i);
       it = intersection_points.emplace(ftab, ind).first;
     }

Modified: trunk/getfem/src/bgeot_mesh_structure.cc
URL: 
http://svn.gna.org/viewcvs/getfem/trunk/getfem/src/bgeot_mesh_structure.cc?rev=5278&r1=5277&r2=5278&view=diff
==============================================================================
--- trunk/getfem/src/bgeot_mesh_structure.cc    (original)
+++ trunk/getfem/src/bgeot_mesh_structure.cc    Sat Apr  2 09:27:47 2016
@@ -233,15 +233,18 @@
                                             const std::vector<short_type> 
&ftab,
                                             ind_set &s) const {
     s.resize(0);
+    if (ftab.size() == 0) return;
+    if (ftab.size() == 1) return neighbours_of_convex(ic, ftab[0], s);
     const mesh_convex_structure &q = convex_tab[ic];
     const convex_ind_ct &ind = q.cstruct->ind_common_points_of_faces(ftab);
+    if (ind.size() == 0) return neighbours_of_convex(ic, s);
     std::vector<size_type> ipts(ind.size());
     auto it = ind.cbegin();
     for (size_type &ipt : ipts) ipt = q.pts[*it++];
 
     auto ipt0 = ipts.cbegin();
     auto ipt1 = ipt0 + 1;
-    short_type nbpts(ipts.size()-1);
+    short_type nbpts = short_type(ipts.size()-1);
     for (size_type icv : points_tab[*ipt0]) {
       if (icv != ic &&
           (nbpts == 0 || is_convex_having_points(icv, nbpts, ipt1))




reply via email to

[Prev in Thread] Current Thread [Next in Thread]