CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM

CAD -> gMsh -> enGrid -> OpenFOAM Problem

Register Blogs Members List Search Today's Posts Mark Forums Read

Like Tree1Likes
  • 1 Post By kroetenechse

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 10, 2009, 03:05
Default CAD -> gMsh -> enGrid -> OpenFOAM Problem
  #1
New Member
 
Alex Gatej
Join Date: Jul 2009
Location: Aachen, Germany
Posts: 11
Rep Power: 16
AlGates is on a distinguished road
Hi all!

After searching and trying for quite a while, I decided to post my problem here, maybe someone has an idea.

I am using gMsh and enGrid for Windows (XP) and OpenFOAM under Ubuntu 9.04. Tried to compile the other 2 on my ubuntu system, but then I always get a QT-4.5.0 Version and the paraFoam command doesn't work anymore, so I prefer to keep my 4.3.4 QT Version and not to use the other 2 softwares on linux.

However... I am quite new to this software and try to do the first calculations in OpenFOAM using my own geometry. I tried it with 2 cylinders being connected on one surface.

The first thing was to design it under a CAD program, import the step file in gMsh, make a 2D mesh, export it as gmesh 2.0 (tried VTK as well...), import it to enGrid and export it as OpenFOAM file-bundle.

The problem is that enGrid nearly always has a problem with the gmsh-mesh and cannot create the 3D mesh, because of some missing or overlapping triangles.

I also tried to create the part in gMsh and to mesh it there. Lead to the same problem.

Here my geo-file of gmsh. Maybe someone has an idea, why this cannot be exported to be used with enGrid.

Code:
Point(1) = {0, 0, 0, 0.1};
Point(2) = {1, 0, 0, 0.1};
Point(3) = {0, 1, 0, 0.1};
Point(4) = {0, -1, 0, 0.1};
Point(5) = {-1, 0, 0, 0.1};
Circle(1) = {3, 1, 2};
Circle(2) = {2, 1, 4};
Circle(3) = {4, 1, 5};
Circle(4) = {5, 1, 3};

Line Loop(5) = {1,2,3,4};
Plane Surface(6) = {5};Extrude {0, 0, 1} {
  Surface{6};
}
Extrude {0, 0, 5} {
  Surface{28};
}
Thank you!
AlGates is offline   Reply With Quote

Old   July 10, 2009, 10:33
Default
  #2
Member
 
Marco Müller
Join Date: Mar 2009
Location: Germany
Posts: 94
Rep Power: 17
marico is on a distinguished road
Hi,

this is not the right place to find help for an (only) enGrid related problem... Try it here:
enGrid discussion board: http://78.140.120.226/phpBB3/

Marco
marico is offline   Reply With Quote

Old   July 10, 2009, 15:25
Default
  #3
New Member
 
Alex Gatej
Join Date: Jul 2009
Location: Aachen, Germany
Posts: 11
Rep Power: 16
AlGates is on a distinguished road
Thanks so far, although this is more a gmsh related problem, because the "gmsh-meshes" are not correctly generated. ;-)
AlGates is offline   Reply With Quote

Old   July 10, 2009, 20:40
Default
  #4
Senior Member
 
Ahmed
Join Date: Mar 2009
Location: NY
Posts: 251
Rep Power: 18
Ahmed is on a distinguished road
Alex
There is a gmsh binary that you can install on your Linux
also there is a binary engrid (.deb) that you can install
I have both installed on my debian Linux and they run ok

Marco Müller
Sorry to disagree with your post, cfd Online is the right home for any fluid mechanics and CFD questions.
I really hope to see engrid forum here

Good luck
Ahmed is offline   Reply With Quote

Old   July 12, 2009, 16:52
Default
  #5
Senior Member
 
Ahmed
Join Date: Mar 2009
Location: NY
Posts: 251
Rep Power: 18
Ahmed is on a distinguished road
Quote:
Originally Posted by AlGates View Post
Hi all!

After searching and trying for quite a while, I decided to post my problem here, maybe someone has an idea.

I am using gMsh and enGrid for Windows (XP) and OpenFOAM under Ubuntu 9.04. Tried to compile the other 2 on my ubuntu system, but then I always get a QT-4.5.0 Version and the paraFoam command doesn't work anymore, so I prefer to keep my 4.3.4 QT Version and not to use the other 2 softwares on linux.

However... I am quite new to this software and try to do the first calculations in OpenFOAM using my own geometry. I tried it with 2 cylinders being connected on one surface.

The first thing was to design it under a CAD program, import the step file in gMsh, make a 2D mesh, export it as gmesh 2.0 (tried VTK as well...), import it to enGrid and export it as OpenFOAM file-bundle.

The problem is that enGrid nearly always has a problem with the gmsh-mesh and cannot create the 3D mesh, because of some missing or overlapping triangles.

I also tried to create the part in gMsh and to mesh it there. Lead to the same problem.

Here my geo-file of gmsh. Maybe someone has an idea, why this cannot be exported to be used with enGrid.

Code:
Point(1) = {0, 0, 0, 0.1};
Point(2) = {1, 0, 0, 0.1};
Point(3) = {0, 1, 0, 0.1};
Point(4) = {0, -1, 0, 0.1};
Point(5) = {-1, 0, 0, 0.1};
Circle(1) = {3, 1, 2};
Circle(2) = {2, 1, 4};
Circle(3) = {4, 1, 5};
Circle(4) = {5, 1, 3};

Line Loop(5) = {1,2,3,4};
Plane Surface(6) = {5};Extrude {0, 0, 1} {
  Surface{6};
}
Extrude {0, 0, 5} {
  Surface{28};
}
Thank you!
Alex
This weekend, I copied your geometry file to gmsh, produced a surface mesh and saved it, using the standard msh format,
reading the file into engrid was straigtforward, using v2, but the quality is really nasty, engrid reader, reads the correct number of nodes but not the elements and the result is nothing similar to the original. This is really annoying, anyway, the best you can do is to be patient and wait till engrid has its own surface mesher/geometry creator modules.
It has always been a problem even using commercial programmes, to read files produced by a certain programme into another programme

Good luck.
It is now that I realize that both programmes have no facilities to produce screen dumps, thus you cannot produce image files to show to others or attach them to posts and reports. pitty
Ahmed is offline   Reply With Quote

Old   July 13, 2009, 11:18
Default
  #6
New Member
 
Alex Gatej
Join Date: Jul 2009
Location: Aachen, Germany
Posts: 11
Rep Power: 16
AlGates is on a distinguished road
Hi Ahmed,

thanks for checking this problem. In the meantime I gave it up as well and used blockMeshDict to set the necessary points and define everything myself. Took some time, but at least it works now.

Thanks for your help!
AlGates is offline   Reply With Quote

Old   August 2, 2010, 18:47
Default
  #7
New Member
 
Philipp Bachmann
Join Date: May 2010
Location: Esslingen, Germany
Posts: 7
Rep Power: 15
kroetenechse is on a distinguished road
Hello Alex,
maybe you found a better way now, but my fellow student and I are working on a problem as you. First CAD -> Gmsh -> enGrid and then OpenFOAM. We got the same problems as you.
Then we tried with netgen instead of Gmsh. After surface meshing with netgen, adjust the 'export filtype' in 'gmsh format' (after that save the part with the ending '.msh'). Then import the file as a gmsh -> v1.0 (ASCII). Then it should work.
There is a nice tutorial of enGrid. You can get it on the enGrid side.
good luck
phil
kittychunk likes this.
kroetenechse is offline   Reply With Quote

Old   August 6, 2010, 13:46
Default
  #8
New Member
 
Alex Gatej
Join Date: Jul 2009
Location: Aachen, Germany
Posts: 11
Rep Power: 16
AlGates is on a distinguished road
Hehe... about 8 months earlier it could have helped. ;-)

But nice, that there is a working solution for this problem.

Thank you for your time.

Alex
AlGates is offline   Reply With Quote

Reply

Tags
engrid, export, gmsh, import, openfoam

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
[CAD formats] Importing CAD Meshes in OpenFOAM vanmaercke OpenFOAM Meshing & Mesh Conversion 14 December 14, 2017 17:30
OpenFOAM Install problem masb OpenFOAM 3 May 25, 2009 12:32
Problem installing OpenFOAM 1.5 installation on RHEL 4. vwsj84 OpenFOAM Installation 4 April 23, 2009 05:48
Can I use OpenFOAM to solve unsteady diffusion problem yongshenglian OpenFOAM Running, Solving & CFD 1 September 17, 2008 13:03
Adventure of fisrst openfoam installation on Ubuntu 710 jussi OpenFOAM Installation 0 April 24, 2008 15:25


All times are GMT -4. The time now is 03:38.