[Gmsh] too slow coherence function

Christophe Geuzaine cgeuzaine at ulg.ac.be
Sun Aug 28 11:10:52 CEST 2016


Andrew,

The problem actually seems to come from the way you define the surface: can you regenerate your geometry script after

- removing all the zero-area line loops (e.g. "Line Loop(6) = {5, -5};")
- removing these loops from the definition of the main surface (i.e. simply have "Plane Surface(1) = {205};")

With this you should not have duplicate vertices anymore, which should make "Coherence Mesh" unnecessary.

Let us know,

Christophe


> On 21 Aug 2016, at 17:33, andrew <armitatz at gmail.com> wrote:
> 
> hi,
> 
> Thank you for the response. The file I submitted was a small one and the problem was not so obvious. I am attaching a 'real' file​ that I use on my simulations. It has 3000 cuts in it. This takes 2 hours on a quad core and 1+ hour on a i7 @4ghz. I am using the version 2.13.1.
> 
> Kind regards
> 
> Andrew Tsiantis
> 
> 
> 2016-08-21 17:50 GMT+03:00 Christophe Geuzaine <cgeuzaine at ulg.ac.be>:
> 
> > On 19 Aug 2016, at 21:34, andrew <armitatz at gmail.com> wrote:
> >
> > ​Hi,
> >
> > I try to create a 3d mesh from an extruded 2d mesh. The mesh is a simple box but with cuts in it of zero width. The geometry is created ok and the meshing even when I have 2000-3000 cuts is done in less than a few minutes. However when I convert the mesh for use with openfoam I was getting errors. By adding the command 'Coherence mesh;' after the creation of the mesh, the mesh is converted correctly for use with openfoam by using the ultility 'gmshToFoam'.
> 
> Indeed, it's a limitation of our extrusion algorithm with embedded curves ("Line In Surface"): it currently creates duplicate vertices. The real fix is thus for us to enhance extrusion of embedded curves, but it's not trivial due to the way extruded meshes are generated.
> 
> > The problem is in the use of the 'Coherence Mesh'. It takes almost two hours to execute while the meshing takes a few minutes. Is there a way to improve the Coherence command or to make the same geometry without the duplicate nodes that need so much time to be removed?
> >
> > I attached a file that needs 2.5 minutes on a quad core for meshing and more than ten minutes to remove 1600 duplicates.
> > I have to create thousands of these meshes so a speedup would be welcomed.
> >
> 
> That seems a bit slow: on my laptop meshing and duplicate removal take about the same time (2 minutes each). Which version of Gmsh do you use?
> 
> > kind regards
> >
> > Andrew tsiantis
> >
> > <se.geo>_______________________________________________
> > gmsh mailing list
> > gmsh at onelab.info
> > http://onelab.info/mailman/listinfo/gmsh
> 
> --
> Prof. Christophe Geuzaine
> University of Liege, Electrical Engineering and Computer Science
> http://www.montefiore.ulg.ac.be/~geuzaine
> 
> Tetrahedron V, July 4-5 2016: http://tetrahedron.montefiore.ulg.ac.be
> Free software: http://gmsh.info | http://getdp.info | http://onelab.info
> 
> 
> <3k_cuts.zip>_______________________________________________
> gmsh mailing list
> gmsh at onelab.info
> http://onelab.info/mailman/listinfo/gmsh

-- 
Prof. Christophe Geuzaine
University of Liege, Electrical Engineering and Computer Science 
http://www.montefiore.ulg.ac.be/~geuzaine

Free software: http://gmsh.info | http://getdp.info | http://onelab.info




More information about the gmsh mailing list