gmsh generator changed in 0.18.4 stable ?

About the development of the FEM module/workbench.

Moderator: bernd

Post Reply
qwerkus
Posts: 5
Joined: Thu Sep 24, 2020 10:14 am

gmsh generator changed in 0.18.4 stable ?

Post by qwerkus »

Hello,

I upgraded my computer (ryzen!!!) and moved from ubuntu 18.04 to 20.04. Installation of freecad 0.18.4 stable via ppa went without issue, and most things seem to work. Only thing I can't manage to get working is mesh generation with gmsh. I always end up with the same low resolution mesh and some python errors using the same models that used to work flawlessly under ubuntu 18.04.

Working gmsh in ubuntu 18.04 / freecad 0.18.4
1.jpg
1.jpg (446.03 KiB) Viewed 1069 times
Current error / gmsh result:
2.jpg
2.jpg (400.13 KiB) Viewed 1069 times
Any chance to get this working ?

Thanks for your time.
Jee-Bee
Veteran
Posts: 2566
Joined: Tue Jun 16, 2015 10:32 am
Location: Netherlands

Re: gmsh generator changed in 0.18.4 stable ?

Post by Jee-Bee »

can you check which gmsh you have command line gmsh -version that helps a lot i think
qwerkus
Posts: 5
Joined: Thu Sep 24, 2020 10:14 am

Re: gmsh generator changed in 0.18.4 stable ?

Post by qwerkus »

Jee-Bee wrote: Thu Sep 24, 2020 4:11 pm can you check which gmsh you have command line gmsh -version that helps a lot i think
4.4.1. Don't think there has been a new one for quite some time now.
User avatar
bernd
Veteran
Posts: 12851
Joined: Sun Sep 08, 2013 8:07 pm
Location: Zürich, Switzerland
Contact:

Re: gmsh generator changed in 0.18.4 stable ?

Post by bernd »

Have you tried to set maximum element size in gmsh mesh object?
qwerkus
Posts: 5
Joined: Thu Sep 24, 2020 10:14 am

Re: gmsh generator changed in 0.18.4 stable ?

Post by qwerkus »

bernd wrote: Thu Sep 24, 2020 7:15 pm Have you tried to set maximum element size in gmsh mesh object?
Yes, doesn't seem to work, no matter if I set it to 1mm or 0.0001: always the same result, plus some weird python errors.
User avatar
sgrogan
Veteran
Posts: 6499
Joined: Wed Oct 22, 2014 5:02 pm

Re: gmsh generator changed in 0.18.4 stable ?

Post by sgrogan »

qwerkus wrote: Thu Sep 24, 2020 7:31 pm Yes, doesn't seem to work, no matter if I set it to 1mm or 0.0001: always the same result, plus some weird python errors.
Can you post the geometry? You can delete the mesh and results. I will test on Win. It looks like some default has changed from 0.18.4 to 0.19_pre.
On Linux you must be using the same gmsh executable.
"fight the good fight"
qwerkus
Posts: 5
Joined: Thu Sep 24, 2020 10:14 am

Re: gmsh generator changed in 0.18.4 stable ?

Post by qwerkus »

sgrogan wrote: Thu Sep 24, 2020 9:42 pm
qwerkus wrote: Thu Sep 24, 2020 7:31 pm Yes, doesn't seem to work, no matter if I set it to 1mm or 0.0001: always the same result, plus some weird python errors.
Can you post the geometry? You can delete the mesh and results. I will test on Win. It looks like some default has changed from 0.18.4 to 0.19_pre.
On Linux you must be using the same gmsh executable.
Doesn't matter which geometry. I tried to mesh a simple bar, and get the same result: low res mesh + python errors. What I don't get is why it worked in ubuntu 18.04 with the same freecadversion and now it doesn't. Is some python library broken ? How can I find out which one ?
User avatar
bernd
Veteran
Posts: 12851
Joined: Sun Sep 08, 2013 8:07 pm
Location: Zürich, Switzerland
Contact:

Re: gmsh generator changed in 0.18.4 stable ?

Post by bernd »

Very strange ...

What happens in background ...

- FreeCAD writes the geometry to brep
- FreeCAD writes a geo file for gmsh
- FreeCAD runs gmsh binary with this geo file
- Gmsh mesh the geometry from the brep with the parameter in the geo file and writes a unv file
- FreeCAD reads the unv file and save the mesh inside the gmsh mesh object

The problem could be on various areas. What I would do.

- The location of the geo is printed in report konsole
- Inside the geo is a command to run gmsh
- First check if the max element length was written correct in the geo file
- run gmsh with this geo file and the brep
- import manually the unv into FreeCAD

After this you should know much more where the problem could be.

bernd
qwerkus
Posts: 5
Joined: Thu Sep 24, 2020 10:14 am

Re: gmsh generator changed in 0.18.4 stable ?

Post by qwerkus »

bernd wrote: Fri Sep 25, 2020 10:02 am - The location of the geo is printed in report konsole
- Inside the geo is a command to run gmsh
- First check if the max element length was written correct in the geo file
- run gmsh with this geo file and the brep
- import manually the unv into FreeCAD

After this you should know much more where the problem could be.

bernd
Good plan - thanks a lot for the explanations Bernd; do you mean the python console ? Because my report view doesn't show any geo location.

Did a few experiments, and found out that when running freecad with sudo, gmesh doesn't do anything! It shows no errors, but also no mesh!

Also, I tried freecad-daily, and there it seems to work! Not sure its a good idea to run a dev version of the app, as I'm still a total noob with this software, and definitely not a good python programmer.

Overall I'm not impressed by the calculix on ryzen 7 performance - somehow only marginally faster than my old i5 3570k. Anything I can do to improve this?
Post Reply