getfem-users
[Top][All Lists]
Advanced

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

Re: [Getfem-users] Evaluate solution at mesh nodes.


From: Dawid Midura
Subject: Re: [Getfem-users] Evaluate solution at mesh nodes.
Date: Wed, 19 Oct 2011 16:04:56 -0400

Hi again,

I probably was not clear with my last question. I guess what I need to know is how do I iterate over all nodes in a given instance of getfem::mesh_region? I know how to iterate over all convexes in a region, which I will call R, using mr_visitor as such:

for(getfem::mr_visitor i(R); !i.finished(), ++i) { ... }

Region R represents a discretization of a circular boundary of my problem domain, (which is a washer) and I use triangular elements. I thought i in the above iteration would represent a line segment with both its endpoints laying on the circular boundary, but this does not seem to be the case. So is i a triangle in the mesh in this case, whose one of the faces coincides with one of the segments in the disretization of the circular boundary?
Another question is the following, what does i.f() do? I could not find a reference to it in the library documentation. Is it a number of faces of convex i? When I put i.f() inside the above loop I get i.f() equal to either 1 or 2. But if i represents a triangle in the mesh shouldn't I get i.f() equal to 3? By the way, in getfem is point considered a convex with a single face? 

Attached is an image of the mesh I'm working with. 

Thanks again,
Dawid M.


On Tue, Oct 18, 2011 at 5:02 PM, Dawid Midura <address@hidden> wrote:
Hi all,

I am solving Helmholtz equation in a region laying in between two cocentric circles. I set Neumann type boundary data on the inner circle, and Robin type condition on the outer circle. . I want to compare the FEM solution with the analytic solution that I know to see if I coded the FEM solver correctly. To do so I compare both solutions at the boundaries of the domain. My question is, how do I evaluate the solution at a given mesh vertex? (I have both boundaries set as separate mesh regions) Here, I'm referring to the original, input mesh, not finite element mesh which in addition contains FEM nodes. I hope I said it right. Thus far I have used getfem::interpolator_on_mesh_fem object to evaluate the solution on the inner boundary, but I can't do the same for the outer circular boundary as most of that boundary lies outside of the computational domain (i'm using triangular elements), so what I did up to this point was picking points laying very close to the outer boundary but still in the computational domain and interpolated the solution at those. 

Thanks in advance,
Dawid M.

Attachment: washer.jpg
Description: JPEG image


reply via email to

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