[MOAB-dev] Boundary nodes and faces

Tim Tautges tautges at mcs.anl.gov
Thu Aug 15 10:07:58 CDT 2013



On 08/15/2013 09:35 AM, Vijay S. Mahadevan wrote:
>> Don't forget to check the return value for errors :).
>
> I always do.
>
>> You can get the adj element using get_adjacencies.
>
> I was expecting a reverse adjacency routine. But considering the API,
> using the same routine to do the reverse lookup might make sense too.
>

It's helpful to think of adjacencies as directionless (in terms of dimension), cuts down on the special-case code.

> The snippet works as it should and I can get access to all my boundary
> faces, vertices and elements. If you want me to create a public API
> routine to get to this data from Interface, let me know how the
> signature of the function should look. It would be a useful thing for
> almost all FEM codes.
>

At this point I'd prefer not to, sounds too special-casey (just barely).  But it is in the FAQ, if that helps.

- tim

> Vijay
>
> On Thu, Aug 15, 2013 at 8:57 AM, Tim Tautges <tautges at mcs.anl.gov> wrote:
>> Don't forget to check the return value for errors :).
>>
>> You can get the adj element using get_adjacencies.
>>
>> - tim
>>
>>
>> On 08/15/2013 02:26 AM, Vijay S. Mahadevan wrote:
>>>
>>> This was actually simpler than I thought. Couple of lines solved the
>>> issue:
>>>
>>> skinner.find_skin(fileset, elocal, false, bndyfaces, bndyelems);
>>> pcomm->filter_pstatus(bndyfaces,PSTATUS_NOT_OWNED,PSTATUS_NOT);
>>> mbiface->get_connectivity(bndyfaces, bndyvtx, false);
>>>
>>> I thought that the bndyelems range would contain all the element handles
>>> that contain the face after the find_skin call.
>>> But this is not the case. My next related question (but not about the
>>> skinner though) is whether I can do the reverse
>>> lookup of the element to which a face belongs to ?
>>>
>>> Vijay
>>>
>>>
>>> On Wed, Aug 14, 2013 at 10:01 PM, Vijay S. Mahadevan <vijay.m at gmail.com
>>> <mailto:vijay.m at gmail.com>> wrote:
>>>
>>>      Tim, Iulian,
>>>
>>>      Thanks for the pointers. I think going from the highest-dimension down
>>> and removing shared entities from the list
>>>      makes sense. I have a partial implementation that already does this
>>> and will check whether this algorithm yields
>>>      what I need.
>>>
>>>      I was originally thinking that Skinner:: find_geometric_skin would
>>> give me the boundary vertices but doing it by the
>>>      process of elimination might be the right way since there is no
>>> reliance on GEOM_DIMENSION tag being explicitly defined.
>>>
>>>      Shall update soon.
>>>      Vijay
>>>
>>>
>>>      On Wed, Aug 14, 2013 at 9:50 PM, Tim Tautges <tautges at mcs.anl.gov
>>> <mailto:tautges at mcs.anl.gov>> wrote:
>>>
>>>          Note, I've added this to the MOAB faq,
>>> http://trac.mcs.anl.gov/__projects/ITAPS/wiki/__ParallelGeomSkin
>>>          <http://trac.mcs.anl.gov/projects/ITAPS/wiki/ParallelGeomSkin>.
>>>
>>>
>>>          - tim
>>>
>>>
>>>          On 08/14/2013 09:31 PM, Tim Tautges wrote:
>>>
>>>              This is tricky.  As you say, if you get the local skin,
>>> that'll include interior entities shared
>>>              with/ghosted from other
>>>              procs.  If you get the skin and remove the shared entities,
>>> that'll remove the vertices that are on the
>>>              geometric skin
>>>              but also shared with other procs.  The right way to do this
>>> is:
>>>
>>>              - get the highest-dimensional entities on the skin (1d if in
>>> 2d, 2d if in 3d)
>>>              - remove any shared entities from that range (because if it's
>>> shared, then by definition there will be d+1 -
>>>              dimensional
>>>              entities on the other proc)
>>>              - if you're in 3d and you also want skin edges, get the edges
>>> adj to the entities in the range (remember the
>>>              UNION arg
>>>              on get_adjacencies), put in tmp range, then do the same for
>>> vertices, also put in tmp range
>>>              - merge the tmp range with the original range
>>>
>>>              Like I said, tricky, but welcome to parallel mesh.
>>>
>>>
>>>          --
>>>
>>> ==============================__==============================__====
>>>
>>>          "You will keep in perfect peace him whose mind is
>>>             steadfast, because he trusts in you."               Isaiah 26:3
>>>
>>>                        Tim Tautges            Argonne National Laboratory
>>>                    (tautges at mcs.anl.gov <mailto:tautges at mcs.anl.gov>)
>>> (telecommuting from UW-Madison)
>>>            phone (gvoice): (608) 354-1459 <tel:%28608%29%20354-1459>
>>> 1500 Engineering Dr.
>>>                       fax: (608) 263-4499 <tel:%28608%29%20263-4499>
>>> Madison, WI 53706
>>>
>>>
>>>
>>
>> --
>> ================================================================
>> "You will keep in perfect peace him whose mind is
>>    steadfast, because he trusts in you."               Isaiah 26:3
>>
>>               Tim Tautges            Argonne National Laboratory
>>           (tautges at mcs.anl.gov)      (telecommuting from UW-Madison)
>>   phone (gvoice): (608) 354-1459      1500 Engineering Dr.
>>              fax: (608) 263-4499      Madison, WI 53706
>>
>

-- 
================================================================
"You will keep in perfect peace him whose mind is
   steadfast, because he trusts in you."               Isaiah 26:3

              Tim Tautges            Argonne National Laboratory
          (tautges at mcs.anl.gov)      (telecommuting from UW-Madison)
  phone (gvoice): (608) 354-1459      1500 Engineering Dr.
             fax: (608) 263-4499      Madison, WI 53706



More information about the moab-dev mailing list