Skip to Content.
Sympa Menu

cgal-discuss - Re: [cgal-discuss] 3D meshing - Subdomain index of a cell and it's mirror

Subject: CGAL users discussion list

List archive

Re: [cgal-discuss] 3D meshing - Subdomain index of a cell and it's mirror


Chronological Thread 
  • From: "Laurent Rineau (GeometryFactory)" <>
  • To:
  • Subject: Re: [cgal-discuss] 3D meshing - Subdomain index of a cell and it's mirror
  • Date: Tue, 4 May 2010 13:57:04 +0200
  • Organization: GeometryFactory

On Monday 03 May 2010 18:43:42 Ramin H wrote:
> Hi,
> I still don't know everything about C3T3 even though I have read the
> documentation. In a 3D triangulation, let's say the cell representing a
> facet does not belong to domain (subdomain=0). If we find the mirror cell
> of this facet, should it belong to the domain (subdomain > 0) ?
>
> To test this idea, I wrote the following code:
>
> for(Facet_iterator facet_it = c3t3_.facets_begin() ;
> facet_it != c3t3_.facets_end() ;
> ++facet_it)
> {
> Facet facet = *facet_it;
> const Facet f = c3t3_.triangulation().mirror_facet(facet);
> if( (int)(facet.first->subdomain_index()) ==
> (int)(f.first->subdomain_index()) )
> {
> std::cerr << "Cell and it's mirror have equal subindex: " <<
> (int)(f.first->subdomain_index()) << std::endl;
> }
> }
>
> Here is some sample output:
> Cell and it's mirror have equal subindex: 1
> Cell and it's mirror have equal subindex: 1
> Cell and it's mirror have equal subindex: 0
> Cell and it's mirror have equal subindex: 1
> Cell and it's mirror have equal subindex: 1
> Cell and it's mirror have equal subindex: 1
> Cell and it's mirror have equal subindex: 0
> Cell and it's mirror have equal subindex: 1
>
> Is this correct behavior? If Facet_iterator is iterating over the facets on
> the surface, why a cell representing that facet and it's mirror both can
> have subdomain index equal to 1 or 0?

No it is not a correct behavior. There is an inconsistency between the
answers
provided by the mesh domain oracle to the two following questions :
- does a given segment/ray intersects the boundary of the domain,
- is a given center of cell in the domain or not.

Does your domain class (CGAL::Polyhedral_mesh_domain_3 or something like
that)
use a filtered (exact) kernel or an inexact one?

--
Laurent Rineau, PhD
R&D Engineer at GeometryFactory http://www.geometryfactory.com/
Release Manager of the CGAL Project http://www.cgal.org/



Archive powered by MHonArc 2.6.16.

Top of Page