CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Bugs (http://www.cfd-online.com/Forums/openfoam-bugs/)
-   -   Problem gmshToFoam (http://www.cfd-online.com/Forums/openfoam-bugs/86091-problem-gmshtofoam.html)

lucy March 14, 2011 10:07

Problem gmshToFoam
 
1 Attachment(s)
Hello,

i have created mesh by gmesh 2.7 & I would like to use it with OpenFoam 1.7.1

the command gmshtoFoam displays fatal error message (see below).

Do you have any ideas about this problem ??

Thank you in advance.

Lucy

---------------------------------------------------------------------------------------------

/*---------------------------------------------------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 1.7.x |
| \\ / A nd | Web: www.OpenFOAM.com |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
Build : 1.7.x-4bbf33160caf
Exec : gmshToFoam cav1.msh
Date : Mar 14 2011
Time : 13:48:03
Host : spartan-VirtualBox
PID : 2561
Case : /home/spartan/Documents/projnum/tutorials/incompressible/icoFoam/cavity
nProcs : 1
SigFpe : Enabling floating point exception trapping (FOAM_SIGFPE).

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Create time

Found $MeshFormat tag; assuming version 2 file format.
Starting to read mesh format at line 2
Read format version 2.2 ascii 0

Starting to read physical names at line 5
Physical names:7
Surface 1 front
Surface 2 back
Surface 3 bottom
Surface 4 top
Surface 5 left
Surface 6 right
Volume 7 internal

Starting to read points at line 15
Vertices to be read:0
Vertices read:0

Starting to read cells at line 18
Cells to be read:0

Cells:
total:0
hex :0
prism:0
pyr :0
tet :0



--> FOAM FATAL IO ERROR:
No cells read from file "cav1.msh"
Does your file specify any 3D elements (hex=5, prism=6, pyramid=7, tet=4)?
Perhaps you have not exported the 3D elements?

file: cav1.msh at line 20.

From function readCells(..)
in file gmshToFoam.C at line 719.

FOAM exiting

Technoyoungman November 1, 2011 09:52

Hi Lucy!!
There is a problem when using converter gmshToFoam. Did u rename the Physical Group in *.geo file?
Like Surface 1 front
Surface 2 back
Surface 3 bottom
Surface 4 top
Surface 5 left
Surface 6 right
Volume 7 internal

Then openFoam cannot read. I don't know why. So I didn't rename the physical group. Instead I open the *.msh file from Engits, using Import > Gmsh (2.0.0) and then give the boundary name using Edit Boundary Condition. The you can export the mesh in openFoam format, using Export> OpenFoam (grid only). It works. But it works only in Windows. I can't do it in Linux.
Good luck!!
PS: Just follow the link u can download engits both for Window and Linux.


All times are GMT -4. The time now is 00:50.