FEM Workbench Gmsh mesh rendering incorrectly

Post here for help on using FreeCAD's graphical user interface (GUI).
Forum rules
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help

Also, be nice to others! Read the FreeCAD code of conduct!
Post Reply
paddyk
Posts: 2
Joined: Tue Jan 04, 2022 1:38 pm

FEM Workbench Gmsh mesh rendering incorrectly

Post by paddyk »

Good day.

I am currently having issues with the mesh rendering for a mesh generated my GMSH in the FEM workbench. Steps to reproduce: open the "FemCalculixCantilever3D_newSolver" example, double click "FEMMeshGmsh", click "Apply" to compute mesh.

The displayed mesh appears random. See attached image below
1641342745.png
1641342745.png (264.23 KiB) Viewed 2713 times
.

The report view displays the following:
02:37:39 <PropShape> PropertyTopoShape.cpp(416): Pending recompute for generating element map: FemCalculixCantilever3D_newSolver#Box
02:37:39 <App> PropertyContainer.cpp(496): FemCalculixCantilever3D_newSolver#Result_mesh.ViewObject.Proxy (App::PropertyPythonObject) restore error: Node count not supported by ViewProviderFemMesh, [4|5|6|8|10|13|15|20] are allowed
02:37:41 <App> PropertyLinks.cpp(392): FemCalculixCantilever3D_newSolver#FemConstraintForce.References auto change element reference FemCalculixCantilever3D_newSolver#Box Face2 -> Face2
02:37:41 <App> PropertyLinks.cpp(392): FemCalculixCantilever3D_newSolver#FemConstraintForce.Direction auto change element reference FemCalculixCantilever3D_newSolver#Box Edge7 -> Edge7
02:37:41 <App> PropertyLinks.cpp(392): FemCalculixCantilever3D_newSolver#FemConstraintFixed.References auto change element reference FemCalculixCantilever3D_newSolver#Box Face1 -> Face1
02:37:51 ElementDimension: 3
02:37:51 No Group meshing for analysis.
02:37:51 Failed to create the directory /usr/share/freecad/examples/FemCalculixCantilever3D_newSolver/FEMMeshGmsh. For the moment the tmp dir /tmp/fcfem_vpi4kz37 is used.
02:37:51 Dir '/usr/share/freecad/examples/FemCalculixCantilever3D_newSolver/FEMMeshGmsh' doesn't exist or cannot be created.
02:37:51 Dir '/tmp/fcfem_3q8cy9bo' will be used instead.
02:37:51 /tmp/fcfem_3q8cy9bo/Box_Geometry.brep
02:37:51 /tmp/fcfem_3q8cy9bo/Box_Mesh.unv
02:37:51 /tmp/fcfem_3q8cy9bo/shape2mesh.geo
02:37:51 /usr/bin/gmsh
02:37:51 New mesh was added to the mesh object.
02:37:51 Clean run of Gmsh


I am running Arch Linux with the freecad-linkstage3 branch:
OS: Arch Linux (qtile)
Word size of FreeCAD: 64-bit
Version: 0.20.30757 (Git)
Build type: Release
Branch: makepkg
Hash: 35236909983ff3550c0f74954fd9686004021501
Python version: 3.10.1
Qt version: 5.15.2
Coin version: 4.0.1
OCC version: 7.5.3
Locale: English/South Africa (en_ZA)

I have tried using the standard freecad-git branch on the AUR, and have encountered the same issue along with the same error reported here https://forum.freecadweb.org/viewtopic.php?f=4&t=64525.

The maximum deflection of the beam with hand calculations gives a deflection of 87.7714mm, with the FEM result showing 87.94mm (which I think indicates an error with the rendering of the mesh rather than the mesh itself.

Furthermore, opening the "mesh.unv" file produced shows the expected mesh shown
1641344454.png
1641344454.png (71.75 KiB) Viewed 2713 times
.

I am have searched the forum and have been unable to find any mention of similar issues.

Thanks in advance
Best regards
Pat
practicalNonsense
Posts: 1
Joined: Fri Feb 04, 2022 2:56 am

Re: FEM Workbench Gmsh mesh rendering incorrectly

Post by practicalNonsense »

Hello, I can't offer any advice, as I am relatively new to both free cad and FEM, but I am having the same issue except with the stable version.
This makes me think it may not be an issue with Freecad, if it is present in a stable release? Possibly due to a Gmsh update?

OS: Arch Linux
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.24291 (Git)
Build type: Release
Branch: makepkg
Hash: 7b5e18a0759de778b74d3a5c17eba9cb815035ac
Python version: 3.10.1
Qt version: 5.15.2
Coin version: 4.0.1
OCC version: 7.5.3
Locale: English/United States (en_US)
User avatar
uwestoehr
Veteran
Posts: 4961
Joined: Sun Jan 27, 2019 3:21 am
Location: Germany
Contact:

Re: FEM Workbench Gmsh mesh rendering incorrectly

Post by uwestoehr »

Works for me with

OS: Windows 10 Version 2009
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.24267 +99 (Git)
Build type: Release
Branch: Branch_0.19.3
Hash: 6530e364184ce05ccff39501e175cf2237e6ee4b
Python version: 3.8.6+
Qt version: 5.15.2
Coin version: 4.0.1
OCC version: 7.5.3
Locale: German/Germany (de_DE)


and also with
OS: Windows 10 Version 2009
Word size of FreeCAD: 64-bit
Version: 0.20.27399 (Git)
Build type: Release
Branch: Cutting-Feature
Hash: 05a9c88ab2dad40d4393203bed5aa861e5587d8d
Python version: 3.8.6+
Qt version: 5.15.2
Coin version: 4.0.1
OCC version: 7.5.3
Locale: German/Germany (de_DE)

Maybe you need to update your Gmsh version. Here on Windows, Gmsh 4.9.2 is used.
user1234
Veteran
Posts: 3345
Joined: Mon Jul 11, 2016 5:08 pm

Re: FEM Workbench Gmsh mesh rendering incorrectly

Post by user1234 »

gmsh in FreeCAD does not work with vtk9.

Greetings
user1234
User avatar
Kunda1
Veteran
Posts: 13434
Joined: Thu Jan 05, 2017 9:03 pm

Re: FEM Workbench Gmsh mesh rendering incorrectly

Post by Kunda1 »

user1234 wrote: Fri Feb 04, 2022 4:05 am gmsh in FreeCAD does not work with vtk9.
error?
Alone you go faster. Together we go farther
Please mark thread [Solved]
Want to contribute back to FC? Checkout:
'good first issues' | Open TODOs and FIXMEs | How to Help FreeCAD | How to report Bugs
Post Reply