[MOAB-dev] Remove duplicates

Tim Tautges tautges at mcs.anl.gov
Fri Jul 19 10:06:56 CDT 2013


So in essence, you have multiple entities sharing the same connectivity?  The only way I can think of to directly query 
that is to take all the vertices in one entity, and query their adjacent entity of the target dimension.  If there are 
two entities sharing that same connectivity, you'll get both in the list, and the function will return 
MB_MULTIPLE_ENTITIES_FOUND.

I should ask, are you getting into that situation because you're merging vertices but not knowing what to do about the 
connected entities?  If so, there are other functions supporting vertex merging that check for that...

- tim

On 07/18/2013 08:02 AM, Andrew Davis wrote:
>
> Hi All
>
> Does anyone know of a convenient way of removing duplicate entities from a range, lets say for example I had an MBRange
> that i had inserted two MBEntityHandles to, that had the same services that define the entity, but consequently had
> different handles.
>
> Obviously I could parse this list and compare the vertex definition of every entity against every other, this would be
> N^2. Is there a standard moab function for this?
>
> Thanks
>
> Andy
>
>
>
> Sent from my Samsung Galaxy Note™, an AT&T LTE smartphone

-- 
================================================================
"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