Problem with a hexahedral mesh

Hi!
I am trying to simulate a hyperelastic 3D cylinder with hexahedral elements. I did the mesh with gmsh and save it as a .mesh file. When I do it with tetrahedral elments everything works perfect, but when I try to simulate the mesh with hexahredal elemnts, SfePy can not read well the mesh and give me this error:
sfepy: warning: bad element orientation, trying to correct...
sfepy: warning: bad element orientation, trying to correct...
RuntimeError: elements cannot be oriented! (0, 3_4)
I've attached the .mesh file with hexahedral elements
Thanks a lot for the help!

Hi Patricia,
the problem is in the .mesh file, all elements are stored as tetrahedrals! Probably, the export of hexahedrals from gmsh to the .mesh format is not correct.
Regards Vladimir
On 11/19/2014 09:51 AM, patricia...@upf.edu wrote:
Hi!
I am trying to simulate a hyperelastic 3D cylinder with hexahedral elements. I did the mesh with gmsh and save it as a .mesh file. When I do it with tetrahedral elments everything works perfect, but when I try to simulate the mesh with hexahredal elemnts, SfePy can not read well the mesh and give me this error:
sfepy: warning: bad element orientation, trying to correct...
sfepy: warning: bad element orientation, trying to correct...
RuntimeError: elements cannot be oriented! (0, 3_4)
I've attached the .mesh file with hexahedral elements
Thanks a lot for the help!
-- You received this message because you are subscribed to the Google Groups "sfepy-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sfepy-devel...@googlegroups.com <mailto:sfepy-devel...@googlegroups.com>. To post to this group, send email to sfepy...@googlegroups.com <mailto:sfepy...@googlegroups.com>. Visit this group at http://groups.google.com/group/sfepy-devel.

Ok! Thanks a lot!
El miércoles, 19 de noviembre de 2014 22:40:40 UTC+1, Vladimír Lukeš escribió:
Hi Patricia,
the problem is in the .mesh file, all elements are stored as tetrahedrals! Probably, the export of hexahedrals from gmsh to the .mesh format is not correct.
Regards Vladimir
On 11/19/2014 09:51 AM, patri...@upf.edu <javascript:> wrote:
Hi!
I am trying to simulate a hyperelastic 3D cylinder with hexahedral elements. I did the mesh with gmsh and save it as a .mesh file. When I do it with tetrahedral elments everything works perfect, but when I try to simulate the mesh with hexahredal elemnts, SfePy can not read well the mesh and give me this error:
sfepy: warning: bad element orientation, trying to correct...
sfepy: warning: bad element orientation, trying to correct...
RuntimeError: elements cannot be oriented! (0, 3_4)
I've attached the .mesh file with hexahedral elements
Thanks a lot for the help!
-- You received this message because you are subscribed to the Google Groups "sfepy-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sfepy-d...@googlegroups.com <javascript:> <mailto:sfepy-devel...@googlegroups.com <javascript:>>. To post to this group, send email to sfep...@googlegroups.com <javascript:> <mailto:sfep...@googlegroups.com <javascript:>>. Visit this group at http://groups.google.com/group/sfepy-devel.

Also, the mesh is bad, with intersecting elements. It looks like the connectivity indexing is broken. In each line there are 5 ints, which is good, but the last one should be the same in all (or a group of) elements, as it is a subdomain id. In your file the ids seem to be interspersed in the connectivity.
See
./postproc.py cylinder_hexa_2.mesh --wireframe
Regards, r.
On 11/20/2014 08:51 AM, patricia...@upf.edu wrote:
Ok! Thanks a lot!
El miércoles, 19 de noviembre de 2014 22:40:40 UTC+1, Vladimír Lukeš escribió:
Hi Patricia,
the problem is in the .mesh file, all elements are stored as tetrahedrals! Probably, the export of hexahedrals from gmsh to the .mesh format is not correct.
Regards Vladimir
On 11/19/2014 09:51 AM, patri...@upf.edu <javascript:> wrote:
Hi!
I am trying to simulate a hyperelastic 3D cylinder with hexahedral elements. I did the mesh with gmsh and save it as a .mesh file. When I do it with tetrahedral elments everything works perfect, but when I try to simulate the mesh with hexahredal elemnts, SfePy can not read well the mesh and give me this error:
sfepy: warning: bad element orientation, trying to correct...
sfepy: warning: bad element orientation, trying to correct...
RuntimeError: elements cannot be oriented! (0, 3_4)
I've attached the .mesh file with hexahedral elements
Thanks a lot for the help!
-- You received this message because you are subscribed to the Google Groups "sfepy-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sfepy-d...@googlegroups.com <javascript:> <mailto:sfepy-devel...@googlegroups.com <javascript:>>. To post to this group, send email to sfep...@googlegroups.com <javascript:> <mailto:sfep...@googlegroups.com <javascript:>>. Visit this group at http://groups.google.com/group/sfepy-devel.

Yes sorry! I've found the error. Since .mesh files saved directly from gmsh can not be used directly as input in sfepy (due to some problems with the file format ), I did an script to rewrite the files, and this script was done for tetrahedral meshes and I forgot to change when reformatting the hexahedral mesh. Now, with this mesh it's works!!
Thanks a lot :-)!
El miércoles, 19 de noviembre de 2014 09:51:54 UTC+1, patri...@upf.edu escribió:
Hi!
I am trying to simulate a hyperelastic 3D cylinder with hexahedral elements. I did the mesh with gmsh and save it as a .mesh file. When I do it with tetrahedral elments everything works perfect, but when I try to simulate the mesh with hexahredal elemnts, SfePy can not read well the mesh and give me this error:
sfepy: warning: bad element orientation, trying to correct...
sfepy: warning: bad element orientation, trying to correct...
RuntimeError: elements cannot be oriented! (0, 3_4)
I've attached the .mesh file with hexahedral elements
Thanks a lot for the help!
participants (3)
-
patricia...@upf.edu
-
Robert Cimrman
-
Vladimir Lukes