← Back to team overview

dolfin team mailing list archive

Re: Generating high quality meshes

 

On Thursday 21 February 2008 13:36:15 Anders Logg wrote:
> On Thu, Feb 21, 2008 at 12:58:49PM +0100, Johan Hoffman wrote:
> > > Hi everybody
> > >
> > > Does anyone know of a nice tool for creating high quality meshes
> > > in 2D and 3D ? I don't assume that dolfin users build their meshes
> > > manually, correct ?
> > > I have had a look at the Gmsh package:
> > > http://www.geuz.org/gmsh/
> > >
> > > but if anyone knows of a better tool I would be happy to hear about
> > > it.
> > >
> > > Regards
> > > Kristen
> >
> > Hi Kristen,
> >
> > You can try tetgen: http://tetgen.berlios.de/
> >
> > Best,
> > Johan
>
> I know Johan Hake has some nice utilities for generating DOLFIN meshes
> with tetgen. Maybe he can share those?

This should be possible.

It is a c++/python wrapper around Triangel 
<http://www.cs.cmu.edu/~quake/triangle.html>, for 2D meshes and as allready 
mentioned tetgen for 3D meshes, called TriTetMesh.

It saves meshes in the format possible from these two libraries, in addition 
to dolfin. You are also able to set markers to vertices, segments and, 
triangles for 2D and, in addition to these also for tetrahedrons in 3D. This 
information is then written to appropriate Meshfunciton files.

I will just give the code some final love and then I can share it. Thanks to 
Anders for good comments on the usability :)

Cheers,

Johan


References