Hi Andriy, If I do dal::bit_vector nn = mf_u.basic_dof_on_region(region_1);
How can I get the size (length) of nn? I could write a loop to find out its length but is there a more convenience way like nn.size()? Could you please advise? Thank you very much Regards Zhenghuai Guo From: Zhenghuai Guo Sent: Monday, March 18, 2019 8:24 PM To: '[email protected]' <[email protected]> Cc: [email protected] Subject: RE: [Getfem-users] mesh_deformation Hi Andriy, I think I did not make it clear to you. It is great to get the displacement values at arbitrary geometrical locations by interpolation. As you mentioned, this can be heavy. So I think at the moment I only need the values at the nodes. So I am now trying to obtain the node coordinates and the corresponding displacement values by dofs. I need this information to calculate the spatial displacement distribution functions. Thank you Regards Zhenghuai Guo From: Andriy Andreykiv <[email protected]<mailto:[email protected]>> Sent: Monday, March 18, 2019 7:26 PM To: Zhenghuai Guo <[email protected]<mailto:[email protected]>> Cc: [email protected]<mailto:[email protected]> Subject: Re: [Getfem-users] mesh_deformation Dear Zhenghuai Guo, Probably you can try to do this with the methods from http://getfem.org/userdoc/interMM.html. In particular, have a look at Interpolation on a cloud of points: void getfem::ga_interpolation_mti(md, expr, mti, result, extrapolation = 0, rg=mesh_region::all_convexes(), nbpoints = size_type(-1)); I assume you can create a cloud of points from a single point. But the above is a "heavy" tool which involves interpolation. Of course if you know that you have a node in that specific location, you can extract the degrees of freedom from the displacement vector. So, let me know what you're using it for. Best regards, Andriy On Sat, 16 Mar 2019 at 10:27, Zhenghuai Guo <[email protected]<mailto:[email protected]>> wrote: Hi Andriy, I have calculated a displacement field u on a meshfem mfu. For some analysis, I would like to 1. Obtain the displacement values on certain geometrical locations based on the geometrical coordinates. Could you please advise me to how to do this? Thank you very much Regards Zhenghuai Guo
