Skip to Content.
Sympa Menu

cgal-discuss - Re: [cgal-discuss] Meshing

Subject: CGAL users discussion list

List archive

Re: [cgal-discuss] Meshing


Chronological Thread 
  • From: Bruce Duncan <>
  • To:
  • Subject: Re: [cgal-discuss] Meshing
  • Date: Thu, 12 May 2011 17:30:36 +0100
  • Organization: School of Engineering, University of Edinburgh

Hi Mariette,

I tried this but really struggled to get my Nef_polyhedron_3<Epeck> to talk
to
the Polyhedral_mesh_domain_with_features_3 class. I think converting to Epick
might have worked but I gave up.

I have succeeded in getting the output I think I need by doing this:

- convex_decomposition_3
- for each volume:
- convert to Polyhedron_3
- Delaunay_triangulation_3 of the points of this polyhedron
- iterate over cells of the triangulation and output.

Hope that makes sense. Thanks for all your help, especially in prodding me to
find the convex_decomposition_3 function!

Bruce

On Tuesday 10 May 2011 17:50:08 Mariette Yvinec wrote:
> If I understand well,
> Bruce would like to mesh a polyhedral domain
> while getting in the resulting mesh the original vertices
> of the input polyhedron and an accurate representation
> of the input polyhedron edges.
>
> Therefore, the Polyhedral_mesh_domain_with_features_3oracle
> would do.
> Simply, once the mesh is generated, Bruce should not
> access it through the triangulation but through the C3T3
> and he should use the API of this class to sort out the
> tetrahedra of the triangulation that belong to the meshed domain.
>
> I hope this helps,
> Mariette
>
> Le 10/05/11 13:53, Bruce Duncan a écrit :
> > Hi Laurent,
> >
> > On Friday 06 May 2011 17:09:46 Laurent Rineau (GeometryFactory) wrote:
> >> On jeudi 05 mai 2011 19:06:47 Bruce Duncan wrote:
> >>> Let me know if images or code would help clarify what I'm trying to do.
> >>
> >> Yes, sure! Your message is rather imprecise.
> >
> > I'm not very good at getting my point across clearly. Please bear with
> > me!
> >
> > I've attached a NEF file (and a PNG of one view of it) which may help me
> > to describe what I mean.
> >
> >>> Hi all,
> >>>
> >>> I am writing a mesh generator with quite specific requirements. As a
> >>> result, I need to output a polyhedron in CGNS format.
> >>>
> >>> I can do the CGNS output very easily if I have a set of tetrahedra. In
> >>> fact I have already implemented this to output a Triangulation_3.
> >>>
> >>> At first I tried to use Triangulation_3 and it's siblings directly.
> >>> However, they don't take into account edges and my concave polyhedra
> >>> are destroyed in the process of triangulation. Is there a way around
> >>> this?
> >>
> >> What have you tried exactly? How did you "use Triangulation_3"?
> >
> > std::vector<Nef_polyhedron::Point_3> points;
> > for (Nef_polyhedron::Vertex_const_iterator it =
> > N_[x][y][z].vertices_begin(); it != N_[x][y][z].vertices_end(); ++it)
> >
> > points.push_back(it->point());
> >
> > Delaunay_triangulation T(points.begin(), points.end());
> >
> > and then I have a loop over finite cells of the triangulation and
> > vertices of those cells which outputs the CGNS data.
> >
> > Obviously, the concave polyhedra are made convex and the resulting mesh
> > is wrong.
> >
> > Is there a triangulation class which preserves concavity?
> >
> > Is there a method to cut a concave 3D polyhedron into multiple 3D convex
> > polyhedra?
> >
> >>> Next, I turned to the Mesh_triangulation_3 class. This accepts a
> >>> Polyhedron and gives access to a Triangulation_3. Excellent! The
> >>> problem is that it does not respect the vertices and edges of the
> >>> input Polyhedron. My application really depends on having the vertices
> >>> remain in the same place. Other vertices and edges may be added,
> >>> however. Is there a way to achieve this?
> >>
> >> The class Mesh_triangulation_3<Polyhedron>::type in itself is just a
> >> regular triangulation with speciall vertex and cell types.
> >>
> >> Let's assume you have used the function CGAL::make_mesh_3 or
> >> CGAL::refine_mesh_3 to construct a 3D mesh from your polyhedron.
> >>
> >>> I have tried to use the Polyhedral_mesh_domain_with_features_3 class
> >>> but without much success... I may post a test case about that next
> >>> week.
> >>
> >> The 3D mesh generator, in CGAL, with features or not, will remesh the
> >> polyhedral domain. If there are features, for examples sharp edges to
> >> respect, then those features will remeshed. You cannot use the CGAL 3D
> >> mesh generator in a way to respect the full set of vertices, edges, and
> >> facets of the input polyhedron.
> >
> > OK thanks. I think the Mesh generator is unusable for my case.
> >
> >> If you explain better what you want to achieve, maybe we could suggest
> >> you other ways to do. What is that mesh generator you want to write?
> >> What are its requirements?
> >
> > I am writing a cartesian cut cell grid generator. Given an arbitrary
> > polyhedron (the "solid"), the generator must produce a grid which is
> > mostly cartesian (the "fluid" region) with "cut" cells where the solid
> > intersects a cartesian cell. A cut cell is a tetrahedral 3D mesh with
> > facets which match those of the adjacent solid or fluid cells, but they
> > don't have to map one-to- one.
> >
> > If it might help, and if you have the time, there is a paper describing
> > the method: Developments in Cartesian cut cell methods, D.M.Ingram,
> > Mathematics and Computers in Simulation 61 (2003) [1].
> >
> > Thanks for your help!
> > Bruce
> >
> > [1]
> >
http://www.sciencedirect.com/science?_ob=ArticleURL&_udi=B6V0T-460DH92-
> >
B&_user=809099&_coverDate=01%2F30%2F2003&_rdoc=1&_fmt=high&_orig=gateway&
> >
_origin=gateway&_sort=d&_docanchor=&view=c&_searchStrId=1746953179&_rerun
> >
Origin=scholar.google&_acct=C000043939&_version=1&_urlVersion=0&_userid=8
> > 09099&md5=5f20a5f5b14d167766d7b4ad21f23a82&searchtype=a
> >
> >
> > The University of Edinburgh is a charitable body, registered in
> > Scotland, with registration number SC005336.

Attachment: signature.asc
Description: This is a digitally signed message part.

The University of Edinburgh is a charitable body, registered in
Scotland, with registration number SC005336.



Archive powered by MHonArc 2.6.16.

Top of Page