[Gmsh] unstable behaviour with 2nd order elements

Christophe Geuzaine cgeuzaine at ulg.ac.be
Thu Nov 20 19:53:27 CET 2008


Francisco Gilabert Villegas wrote:
> 
> Hi again Christophe,
> 
> below is the result of your indication:
> 

Ok, great: I think the problem should be fixed in tomorrow's snapshot. 
Could you give it a try and let us know?

Thanks!

Christophe

> 
> 
> GNU gdb 6.8
> Copyright (C) 2008 Free Software Foundation, Inc.
> License GPLv3+: GNU GPL version 3 or later 
> <http://gnu.org/licenses/gpl.html>
> This is free software: you are free to change and redistribute it.
> There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
> and "show warranty" for details.
> This GDB was configured as "i586-suse-linux"...
> (gdb) r fail_2nd_order.geo -3 -order 2
> Starting program: /home/fgilabert/FEM/tmp/demo_gmsh/gmsh 
> fail_2nd_order.geo -3 -order 2
> Info    : Reading 'fail_2nd_order.geo'
> Info    : Read 'fail_2nd_order.geo'
> Info    : Meshing 1D...
> Info    : Meshing curve 1 (Line)
> Info    : Meshing curve 2 (Line)
> Info    : Meshing curve 3 (Line)
> Info    : Meshing curve 4 (Line)
> Info    : Mesh 1D complete (0 s)
> Info    : Mesh
> Info    : Meshing 2D...
> Info    : Meshing surface 6 (Plane, MeshAdapt+Delaunay)
> Info    : Recombining triangles for surface 6
> Info    : Meshing surface 15 (extruded)
> Info    : Meshing surface 19 (extruded)
> Info    : Meshing surface 23 (extruded)
> Info    : Meshing surface 27 (extruded)
> Info    : Meshing surface 28 (extruded)
> Info    : Mesh 2D complete (0.036002 s)
> Info    : Mesh
> Info    : Meshing 3D...
> Info    : Meshing volume 1 (extruded)
> Info    : Mesh 3D complete (0.004 s)
> Info    : Mesh
> Info    : Generating High Order Nodes (q = 2) ...
> 
> Program received signal SIGSEGV, Segmentation fault.
> 0x080c6f9c in getFaceVertices (gr=0x8477be8, ele=0x8496d68, 
> vf=@0xbfb0fc94, blocked=@0xbfb0fc70, faceVertices=@0xbfb0fe18, 
> edgeVertices=@0xbfb0fe30,
>     linear=false, nPts=1) at HighOrder.cpp:624
> 624       for (int i = 0; i < 3; i++) tmp[(i + orientation) % 3] = vtcs[i];
> (gdb) backtrace
> #0  0x080c6f9c in getFaceVertices (gr=0x8477be8, ele=0x8496d68, 
> vf=@0xbfb0fc94, blocked=@0xbfb0fc70, faceVertices=@0xbfb0fe18, 
> edgeVertices=@0xbfb0fe30,
>     linear=false, nPts=1) at HighOrder.cpp:624
> #1  0x080cbef3 in setHighOrder (gr=0x8477be8, edgeVertices=@0xbfb0fe30, 
> faceVertices=@0xbfb0fe18, linear=false, incomplete=false, nPts=1, 
> displ2D=0x0,
>     displ3D=0x0) at HighOrder.cpp:933
> #2  0x080ce101 in SetOrderN (m=0x8466148, order=2, linear=false, 
> incomplete=false) at HighOrder.cpp:1151
> #3  0x0806a7f4 in GenerateMesh (m=0x8466148, ask=3) at Generator.cpp:564
> #4  0x080ef6d8 in GModel::mesh (this=0x8466148, dimension=3) at 
> GModel.cpp:332
> #5  0x0804fd09 in GmshBatch () at Gmsh.cpp:111
> #6  0x0804d371 in main (argc=Cannot access memory at address 0x0
> ) at Main.cpp:30
> 
> 
> 
> Thanks a lot
> 
> Francisco
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> Dr. Francisco A. Gilabert Villegas
> Mecánica de Medios Continuos y Modelización
> 
> Instituto de Tecnología Cerámica
> Campus Universitario Riu Sec | Avda. Vicent Sos Baynat, s/n
> 12006 Castellón (Spain)
> Tel. 34 964 34 24 24
> Fax 34 964 34 24 25
> 
> CONFIDENCIALIDAD
> La información contenida en este mensaje y/o archivo(s) adjunto(s) es 
> confidencial/privilegiada y está destinada
> a ser leída sólo por la(s) persona(s) a la(s) que va dirigida. Si usted 
> lee este mensaje y no es el destinatario señalado,
> el empleado o el agente responsable de entregar el mensaje al 
> destinatario, o ha recibido esta comunicación por
> error le informamos que está totalmente prohibida, y puede ser ilegal, 
> cualquier divulgación, distribución o
> reproducción de esta comunicación, y le rogamos que nos lo notifique 
> inmediatamente y nos devuelva el mensaje
> original al e-mail: itc at itc.uji.es. Gracias.
> 
> 
> 
> -----Mensaje original-----
> De: Geuzaine Christophe [mailto:cgeuzaine at ulg.ac.be]
> Enviado el: jue 20/11/2008 17:18
> Para: Francisco Gilabert Villegas
> CC: Christophe Geuzaine; Jean-François Remacle
> Asunto: Re: RE[3]: [Gmsh] unstable behaviour with 2nd order elements
> 
>  > Dear Christophe,
>  >
>  > Thanks for your help.
>  >
>  > I recompiled gmsh using -nogui flag. The compilation seemed to be ok.
>  >
>  > Then, I run gmsh in the following way:
>  >
>  > ./gmsh -3 -order 2 fail_2nd_order.geo
>  >
>  > And the result was:
>  >
>  > Info    : Reading 'fail_2nd_order.geo'
>  > Info    : Read 'fail_2nd_order.geo'
>  > Info    : Meshing 1D...
>  > Info    : Meshing curve 1 (Line)
>  > Info    : Meshing curve 2 (Line)
>  > Info    : Meshing curve 3 (Line)
>  > Info    : Meshing curve 4 (Line)
>  > Info    : Mesh 1D complete (0 s)
>  > Info    : Mesh
>  > Info    : Meshing 2D...
>  > Info    : Meshing surface 6 (Plane, MeshAdapt+Delaunay)
>  > Info    : Recombining triangles for surface 6
>  > Info    : Meshing surface 15 (extruded)
>  > Info    : Meshing surface 19 (extruded)
>  > Info    : Meshing surface 23 (extruded)
>  > Info    : Meshing surface 27 (extruded)
>  > Info    : Meshing surface 28 (extruded)
>  > Info    : Mesh 2D complete (0.052003 s)
>  > Info    : Mesh
>  > Info    : Meshing 3D...
>  > Info    : Meshing volume 1 (extruded)
>  > Info    : Mesh 3D complete (0.004 s)
>  > Info    : Mesh
>  > Info    : Generating High Order Nodes (q = 2) ...
>  > Violación de segmento
>  >
>  >
>  > The last sentence is saying "segmentation fault" (in spanish, sorry).
>  >
>  > Maybe it can be useful for you the result of the compilation:
>  > The attached files "recompilation_part1.txt" and 
> "recompilation_part2.txt"
>  > store the out of this process.
>  >
> 
> The compilation looks ok...
> 
> Could you run the same example in the debugger with
> 
>  > gdb gmsh
> (gdb) r fail_2nd_order.geo -3 -order 2
> 
> and when it crashes type
> 
> (gdb) backtrace
> 
> 
> 
> 
> 
> 
> 
>  > If you detect that I am making something in a strange way, please
>  > tell me and I will verify.
>  >
>  >
>  >
>  > Thank you again
>  >
>  > Francisco
>  >
>  >
>  >
>  >
>  >
>  >
>  >
>  >
>  >
>  >
>  > Dr. Francisco A. Gilabert Villegas
>  > Mecánica de Medios Continuos y Modelización
>  >
>  > Instituto de Tecnología Cerámica
>  > Campus Universitario Riu Sec | Avda. Vicent Sos Baynat, s/n
>  > 12006 Castellón (Spain)
>  > Tel. 34 964 34 24 24
>  > Fax 34 964 34 24 25
>  >
>  > CONFIDENCIALIDAD
>  > La información contenida en este mensaje y/o archivo(s) adjunto(s) es
>  > confidencial/privilegiada y está destinada
>  > a ser leída sólo por la(s) persona(s) a la(s) que va dirigida. Si usted
>  > lee este mensaje y no es el destinatario señalado,
>  > el empleado o el agente responsable de entregar el mensaje al
>  > destinatario, o ha recibido esta comunicación por
>  > error le informamos que está totalmente prohibida, y puede ser ilegal,
>  > cualquier divulgación, distribución o
>  > reproducción de esta comunicación, y le rogamos que nos lo notifique
>  > inmediatamente y nos devuelva el mensaje
>  > original al e-mail: itc at itc.uji.es. Gracias.
>  >
>  >
>  >
>  > -----Mensaje original-----
>  > De: Christophe Geuzaine [mailto:cgeuzaine at ulg.ac.be]
>  > Enviado el: jue 20/11/2008 13:28
>  > Para: Francisco Gilabert Villegas
>  > CC: Jean-François Remacle
>  > Asunto: Re: [Gmsh] unstable behaviour with 2nd order elements
>  >
>  > Francisco Gilabert Villegas wrote:
>  >> Dear Christophe,
>  >>
>  >> Thanks for your swift answer.
>  >>
>  >> I checked the nightly version (20-Nov-2008 01:11) on Linux.
>  >> In 2D, everything is correct. Additionally I tested some complex
>  >> geometries and all was ok.
>  >>
>  >> But in 3D, the anomalous behaviour persist. At least, this time,
>  >> at the end of the execution you can read "segmentation fault" in
>  >> the command line.
>  >>
>  >
>  > Hi Francisco - Unfortunately I cannot reproduce this on our Linux box.
>  > I've run it with valgrind, which also returns no errors...
>  >
>  > Could you try to recompile the code from source? To make it easy you
>  > could build the command-line version of the code (no GUI):
>  >
>  > * download the latest source snapshot
>  >
>  > * configure it with "./configure --disable-gui"
>  >
>  > * then build with "make"
>  >
>  > The only external dependency should be the GNU scientific library (GSL).
>  > Installing the GSL should be relatively simple (select the "gsl-devel"
>  > package or something similar in your Linux distro package manager).
>  >
>  > Christophe
>  >
>  >
>  >
>  >
>  >> I used the same simple code a in the previous message, but this
>  >> time adding a simple extrusion of the square (see below):
>  >>
>  >> //--------------------------------------------
>  >> mm = 0.001;
>  >> Lx = 1000*mm;
>  >> Ly = 1000*mm;
>  >> Lz = 1000*mm;
>  >> lc = 100*mm;
>  >> p1ewp; Point(p1)={-Lx/2,-Ly/2,-Lz/2,lc};
>  >> p2ewp; Point(p2)={-Lx/2,+Ly/2,-Lz/2,lc};
>  >> p3ewp; Point(p3)={+Lx/2,+Ly/2,-Lz/2,lc};
>  >> p4ewp; Point(p4)={+Lx/2,-Ly/2,-Lz/2,lc};
>  >> l1ewl; Line(l1) = {p1, p2};
>  >> l2ewl; Line(l2) = {p2, p3};
>  >> l3ewl; Line(l3) = {p3, p4};
>  >> l4ewl; Line(l4) = {p4, p1};
>  >> ll1ewll; Line Loop(ll1) = {l1, l2, l3, l4};
>  >> s1ews; Plane Surface(s1) = {ll1};
>  >> Recombine Surface{s1};
>  >>
>  >> Ext1[]=Extrude {0, 0, Lz} { // NEW
>  >>  Surface{s1};               // NEW
>  >>  Layers{10,1};              // NEW
>  >>  Recombine;                 // NEW
>  >> };                          // NEW
>  >> //--------------------------------------------
>  >>
>  >>
>  >> Thank you very much for your help
>  >>
>  >> Francisco
>  >>
>  >>
>  >>
>  >>
>  >>
>  >>
>  >>
>  >>
>  >>
>  >> Dr. Francisco A. Gilabert Villegas
>  >> Mecánica de Medios Continuos y Modelización
>  >>
>  >> Instituto de Tecnología Cerámica
>  >> Campus Universitario Riu Sec | Avda. Vicent Sos Baynat, s/n
>  >> 12006 Castellón (Spain)
>  >> Tel. 34 964 34 24 24
>  >> Fax 34 964 34 24 25
>  >>
>  >> CONFIDENCIALIDAD
>  >> La información contenida en este mensaje y/o archivo(s) adjunto(s) es
>  >> confidencial/privilegiada y está destinada
>  >> a ser leída sólo por la(s) persona(s) a la(s) que va dirigida. Si usted
>  >> lee este mensaje y no es el destinatario señalado,
>  >> el empleado o el agente responsable de entregar el mensaje al
>  >> destinatario, o ha recibido esta comunicación por
>  >> error le informamos que está totalmente prohibida, y puede ser ilegal,
>  >> cualquier divulgación, distribución o
>  >> reproducción de esta comunicación, y le rogamos que nos lo notifique
>  >> inmediatamente y nos devuelva el mensaje
>  >> original al e-mail: itc at itc.uji.es. Gracias.
>  >>
>  >>
>  >>
>  >>
>  >>
>  >> ------------------------------------------------------------------------
>  >>
>  >> _______________________________________________
>  >> gmsh mailing list
>  >> gmsh at geuz.org
>  >> http://www.geuz.org/mailman/listinfo/gmsh
>  >
>  >
>  > --
>  > Prof. Christophe Geuzaine
>  > University of Liege, Electrical Engineering and Computer Science
>  > http://www.montefiore.ulg.ac.be/~geuzaine
>  >
>  >
>  >
>  >
>  >
> 
> 
> 
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> gmsh mailing list
> gmsh at geuz.org
> http://www.geuz.org/mailman/listinfo/gmsh


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