getfem-commits
[Top][All Lists]
Advanced

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

[Getfem-commits] r4644 - /trunk/getfem/src/getfem/getfem_deformable_mesh


From: andriy . andreykiv
Subject: [Getfem-commits] r4644 - /trunk/getfem/src/getfem/getfem_deformable_mesh.h
Date: Mon, 12 May 2014 14:45:33 -0000

Author: andrico
Date: Mon May 12 16:45:33 2014
New Revision: 4644

URL: http://svn.gna.org/viewcvs/getfem?rev=4644&view=rev
Log:
extending the size of the vector to basic_dof in deformable_mesh::deform_mesh

Modified:
    trunk/getfem/src/getfem/getfem_deformable_mesh.h

Modified: trunk/getfem/src/getfem/getfem_deformable_mesh.h
URL: 
http://svn.gna.org/viewcvs/getfem/trunk/getfem/src/getfem/getfem_deformable_mesh.h?rev=4644&r1=4643&r2=4644&view=diff
==============================================================================
--- trunk/getfem/src/getfem/getfem_deformable_mesh.h    (original)
+++ trunk/getfem/src/getfem/getfem_deformable_mesh.h    Mon May 12 16:45:33 2014
@@ -79,6 +79,8 @@
       //this vector will track if a point can be deformed
       std::vector<bool> deform_pt_flag(ppts.size(), true);
       size_type cv;
+      base_vector dU_basic(mf.nb_basic_dof());
+      mf.extend_vector(dU,dU_basic);
       for(cv << conv_indices; 
         cv!=bgeot::size_type(-1); cv << conv_indices) 
       {
@@ -92,13 +94,14 @@
           "mesh_fem should be isoparametric to the mesh, "
           "with nb_points() of convex * dim == size of 
ind_basic_dof_of_element");
 
+
         for(size_type pt = 0; pt < num_points; ++pt) 
         { 
           /** iterate through each components of point [pt]and deform the 
component*/
           if(deform_pt_flag[pt_index[pt]])
             for (size_type comp = 0; comp < ddim; ++comp)
               //move pts by dU;
-                ppts[pt_index[pt]][comp] += dU[dof[pt*ddim + comp]];
+                ppts[pt_index[pt]][comp] += dU_basic[dof[pt*ddim + comp]];
 
           //flag current [pt] to deformed
           deform_pt_flag[pt_index[pt]] = false;




reply via email to

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