CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Meshing & Mesh Conversion (https://www.cfd-online.com/Forums/openfoam-meshing/)
-   -   [Commercial meshers] Fluent3DMeshToFoam (https://www.cfd-online.com/Forums/openfoam-meshing/61672-fluent3dmeshtofoam.html)

simvun February 25, 2008 21:19

Fluent3DMeshToFoam
 
Hi there,

I have a fluent mesh (.msh) file that i wanted to convert in OF-1.4.1 and when using fluent3DMeshToFoam got the following error:

Exec : fluent3DMeshToFoam /home/vuns/OpenFOAM/vuns-1.4.1/run/BluntBody/ BB01 fluent.msh
Date : Feb 26 2008
Time : 12:39:10
Host : flightlab4
PID : 17426
Root : /home/vuns/OpenFOAM/vuns-1.4.1/run/BluntBody/
Case : BB01
Nprocs : 1
Create time

Dimension of grid: 3


--> FOAM FATAL ERROR : Do not understand characters:

From function fluentMeshToFoam::lexer
in file fluentMeshToFoam.L at line 703.

FOAM exiting

However when i used fluentMeshToFoam the converter worked fine. Was just wondering if anyone has seen this before or if i've done something wrong?

Thanks

Simon.

mattijs February 26, 2008 03:27

Is this a mesh only file? We f
 
Is this a mesh only file? We found that the '#' character (used in boolean constants) can give problems. Have a look through the file and remove the offending sections or resave as mesh only.

simvun February 27, 2008 00:41

Hi Mattijs, Thanks for the
 
Hi Mattijs,

Thanks for the advice because on your recommendation i went into the file and realized it was in a dos format. So just converted the file using "dos2unix" command and it worked.

However i've struck another problem but this time with the mesh. Here's the error,


Exec : fluent3DMeshToFoam /home/vuns/OpenFOAM/vuns-1.4.1/run/BluntBody/test/ PotentialBB01 fluent.msh
Date : Feb 27 2008
Time : 16:33:50
Host : flightlab4
PID : 9037
Root : /home/vuns/OpenFOAM/vuns-1.4.1/run/BluntBody/test/
Case : PotentialBB01
Nprocs : 1
Create time

Dimension of grid: 3
Number of points: 55387
PointGroup: 11 start: 0 end: 55386. Reading points...done.
Number of cells: 185764
CellGroup: 12 start: 0 end: 185763 type: 1
Number of faces: 408736
FaceGroup: 13 start: 0 end: 395703. Reading mixed faces...done.
FaceGroup: 14 start: 395704 end: 395747. Reading uniform faces...done.
FaceGroup: 15 start: 395748 end: 395786. Reading uniform faces...done.
FaceGroup: 16 start: 395787 end: 399056. Reading mixed faces...done.
FaceGroup: 17 start: 399057 end: 399289. Reading uniform faces...done.
FaceGroup: 18 start: 399290 end: 399497. Reading uniform faces...done.
FaceGroup: 19 start: 399498 end: 401062. Reading uniform faces...done.
FaceGroup: 20 start: 401063 end: 408735. Reading uniform faces...done.
Zone: 12 name: BODY type: fluid. Reading zone data...done.
Zone: 13 name: int_BODY type: interior. Reading zone data...done.
Zone: 14 name: INLET type: velocity-inlet. Reading zone data...done.
Zone: 15 name: OUTLET type: pressure-outlet. Reading zone data...done.
Zone: 16 name: SYMM type: symmetry. Reading zone data...done.
Zone: 17 name: SYMM02 type: symmetry. Reading zone data...done.
Zone: 18 name: SYMM03 type: symmetry. Reading zone data...done.
Zone: 19 name: GROUND type: wall. Reading zone data...done.
Zone: 20 name: CARBODY type: wall. Reading zone data...done.

FINISHED LEXING

--> FOAM Warning :
From function boundBox::boundBox(const pointField& points)
in file meshes/boundBox/boundBox.C at line 52
cannot find bounding box for zero sized pointFieldreturning zero
Creating patch 0 for zone: 14 name: INLET type: velocity-inlet
Creating patch 1 for zone: 15 name: OUTLET type: pressure-outlet
Creating patch 2 for zone: 16 name: SYMM type: symmetry
Creating patch 3 for zone: 17 name: SYMM02 type: symmetry
Creating patch 4 for zone: 18 name: SYMM03 type: symmetry
Creating patch 5 for zone: 19 name: GROUND type: wall
Creating patch 6 for zone: 20 name: CARBODY type: wall
Creating cellZone 0 name: BODY type: fluid
patch 0 from Fluent indices: 395704 to: 395747 type: velocity-inlet
patch 1 from Fluent indices: 395748 to: 395786 type: pressure-outlet
patch 2 from Fluent indices: 395787 to: 399056 type: symmetry
patch 3 from Fluent indices: 399057 to: 399289 type: symmetry
patch 4 from Fluent indices: 399290 to: 399497 type: symmetry
patch 5 from Fluent indices: 399498 to: 401062 type: wall
patch 6 from Fluent indices: 401063 to: 408735 type: wall

Writing mesh to "/home/vuns/OpenFOAM/vuns-1.4.1/run/BluntBody/test//PotentialBB01/constant/regio n0"

End


Not sure if it will cause a problem or not down the track?

Thanks

Simon.

mattijs February 27, 2008 03:03

Don't think that is a problem.
 
Don't think that is a problem. Might be a region with zero faces in it. Run

checkMesh -allTopology -allGeometry

to see whether there is a problem.

ryan_m May 5, 2008 21:14

I have experienced a similar e
 
I have experienced a similar error with fluent3DMeshToFoam:

FINISHED LEXING

--> FOAM Warning :
From function boundBox::boundBox(const pointField& points)
in file meshes/boundBox/boundBox.C at line 52
cannot find bounding box for zero sized pointFieldreturning zero
Creating patch 0 for zone: 3 name: Wingbottom type: wall
Creating patch 1 for zone: 4 name: Wingtop type: wall
Creating patch 2 for zone: 5 name: Wingtip type: wall
Creating patch 3 for zone: 6 name: Elevatortop type: wall
Creating patch 4 for zone: 7 name: Elevatorbottom type: wall
Creating patch 5 for zone: 8 name: Elevatorside type: wall
Creating patch 6 for zone: 9 name: Stubwingside type: wall
Creating patch 7 for zone: 10 name: Stubwingbottom type: wall
Creating patch 8 for zone: 11 name: Stubwingtop type: wall
Creating patch 9 for zone: 12 name: Rudder type: wall
Creating patch 10 for zone: 13 name: Floatpack type: wall
Creating patch 11 for zone: 14 name: Fuselage type: wall
Creating patch 12 for zone: 15 name: Bottomnose type: wall
Creating patch 13 for zone: 16 name: Topnose type: wall
Creating patch 14 for zone: 17 name: Symwall type: symmetry
Creating patch 15 for zone: 18 name: Bottomwall type: wall
Creating patch 16 for zone: 19 name: Topwall type: wall
Creating patch 17 for zone: 20 name: Sidewall type: wall
Creating patch 18 for zone: 21 name: Outlet type: pressure-outlet
Creating patch 19 for zone: 22 name: Inlet type: velocity-inlet
Creating cellZone 0 name: fluid type: fluid
patch 0 from Fluent indices: 0 to: 74094 type: wall
patch 1 from Fluent indices: 74095 to: 147814 type: wall
patch 2 from Fluent indices: 147815 to: 156374 type: wall
patch 3 from Fluent indices: 156375 to: 171950 type: wall
patch 4 from Fluent indices: 171951 to: 187454 type: wall
patch 5 from Fluent indices: 187455 to: 187730 type: wall
patch 6 from Fluent indices: 187731 to: 193600 type: wall
patch 7 from Fluent indices: 193601 to: 226482 type: wall
patch 8 from Fluent indices: 226483 to: 256634 type: wall
patch 9 from Fluent indices: 256635 to: 288315 type: wall
patch 10 from Fluent indices: 288316 to: 357419 type: wall
patch 11 from Fluent indices: 357420 to: 490004 type: wall
patch 12 from Fluent indices: 490005 to: 498824 type: wall
patch 13 from Fluent indices: 498825 to: 532124 type: wall
patch 14 from Fluent indices: 532125 to: 679769 type: symmetry
patch 15 from Fluent indices: 679770 to: 687631 type: wall
patch 16 from Fluent indices: 687632 to: 695591 type: wall
patch 17 from Fluent indices: 695592 to: 700623 type: wall
patch 18 from Fluent indices: 700624 to: 701969 type: pressure-outlet
patch 19 from Fluent indices: 701970 to: 705957 type: velocity-inlet


--> FOAM FATAL ERROR : Face 19175673 contains vertex labels out of range: 3(10254 0 17727361) Max point index = 5798594#0 Foam::error::printStack(Foam:http://www.cfd-online.com/OpenFOAM_D...part/proud.gifstream&) in "/home/a1099275/OpenFOAM/OpenFOAM-1.4.1/lib/linux64GccDPOpt/libOpenFOAM.so"
#1 Foam::error::abort() in "/home/a1099275/OpenFOAM/OpenFOAM-1.4.1/lib/linux64GccDPOpt/libOpenFOAM.so"
#2 Foam::polyMesh::resetPrimitives(int, Foam::Field<foam::vector<double> > const&, Foam::List<foam::face> const&, Foam::List<int> const&, Foam::List<int> const&, Foam::List<int> const&, Foam::List<int> const&, bool) in "/home/a1099275/OpenFOAM/OpenFOAM-1.4.1/lib/linux64GccDPOpt/libOpenFOAM.so"
#3 Foam::polyTopoChange::changeMesh(Foam::polyMesh&, bool, bool) in "/home/a1099275/OpenFOAM/OpenFOAM-1.4.1/lib/linux64GccDPOpt/libdynamicMesh.so"
#4 main in "/home/a1099275/OpenFOAM/OpenFOAM-1.4.1/applications/bin/linux64GccDPOpt/fluent3 DMeshToFoam"
#5 __libc_start_main in "/lib64/libc.so.6"
#6 __gxx_personality_v0 in "/home/a1099275/OpenFOAM/OpenFOAM-1.4.1/applications/bin/linux64GccDPOpt/fluent3 DMeshToFoam"


From function polyMesh::polyMesh::resetPrimitives
(
const label nUsedFaces,
const pointField& points,
const faceList& faces,
const labelList& owner,
const labelList& neighbour,
const labelList& patchSizes,
const labelList& patchStarts
)

in file meshes/polyMesh/polyMesh.C at line 670.

FOAM aborting

No polyMesh folder was created. Any ideas about the problem?

Thanks very much for any help.

Ryan

mahendra November 14, 2008 08:31

hi Foamers.. I am having a li
 
hi Foamers..
I am having a little problem with fluent3DMeshToFoam.

This the error I am getting..

Exec : fluent3DMeshToFoam disk_imp_14nov.msh
Date : Nov 14 2008
Time : 19:05:27
Host : linux
PID : 18173
Case : /home/ms.wankhede/OpenFOAM/ms.wankhede-1.5/CFD_Projects/disk_trial
nProcs : 1

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



Do not understand characters:

From function fluentMeshToFoam::lexer
in file fluent3DMeshToFoam.L at line 708.

FOAM exiting

How can i get rid of it?

Regards,
Mahendra.

hjasak November 14, 2008 09:43

Did you export your mesh ascii
 
Did you export your mesh ascii?

Hrv

mahendra November 14, 2008 23:24

hello Hrvoje, I exported th
 
hello Hrvoje,

I exported the mesh with default settings in Gambit. Just now i checked it shows format as dos.

Regards,
Mahendra.

mahendra November 15, 2008 01:18

Dear Hrvoje Hi ! Now my mes
 
Dear Hrvoje Hi !

Now my mesh in the ascii format works with OpenFOAM.
Also all the internal walls are recognised as walls by OpenFOAM and i do not need to use <splitmesh>.

Thanks and Regards,
Mahendra.

psosnows January 20, 2009 07:26

hello, I have some trouble
 
hello,

I have some trouble with importing mesh file written in fluent format *.msh.
First, I took the mesh and used dos2unix utility on it (since it was created under Win). After that I used fluent3DMeshToFoam. The only unxepected message during this work was:

--> FOAM Warning :
From function boundBox::boundBox(const pointField& points)
in file meshes/boundBox/boundBox.C at line 52
Cannot find bounding box for zero sized pointField, returning zero

Anyway, the mesh was written. I tried to take a look at it in paraView. I could find the declared patches in "Region Status" field but every time I chose any of them and tried to update, the paraView dumped with "Segmentation Fault" message. I run the "checkMesh -allTopology -allGeometry" and got those results:

Mesh stats
points: 132745
#0 Foam::error::printStack(Foam:http://www.cfd-online.com/OpenFOAM_D...part/proud.gifstream&) in "/home/pawel/OpenFOAM/OpenFOAM-1.5/lib/linuxGccDPOpt/libOpenFOAM.so"
#1 Foam::sigSegv::sigSegvHandler(int) in "/home/pawel/OpenFOAM/OpenFOAM-1.5/lib/linuxGccDPOpt/libOpenFOAM.so"
#2 Uninterpreted: [0xb7f49420]
#3 Foam::primitiveMesh::calcCells(Foam::List<foam::ce ll>&, Foam::UList<int> const&, Foam::UList<int> const&, int) in "/home/pawel/OpenFOAM/OpenFOAM-1.5/lib/linuxGccDPOpt/libOpenFOAM.so"
#4 Foam::primitiveMesh::calcCells() const in "/home/pawel/OpenFOAM/OpenFOAM-1.5/lib/linuxGccDPOpt/libOpenFOAM.so"
#5 Foam::primitiveMesh::cells() const in "/home/pawel/OpenFOAM/OpenFOAM-1.5/lib/linuxGccDPOpt/libOpenFOAM.so"
#6 Foam::printMeshStats(Foam::polyMesh const&, bool) in "/home/pawel/OpenFOAM/OpenFOAM-1.5/applications/bin/linuxGccDPOpt/checkMesh"
#7 main in "/home/pawel/OpenFOAM/OpenFOAM-1.5/applications/bin/linuxGccDPOpt/checkMesh"
#8 __libc_start_main in "/lib/tls/i686/cmov/libc.so.6"
#9 Foam::regIOobject::readIfModified() in "/home/pawel/OpenFOAM/OpenFOAM-1.5/applications/bin/linuxGccDPOpt/checkMesh"
Segmentation fault

can you help me understand what is wrong?

Regards,
Pawel

venkateshtl February 2, 2009 04:14

Hi Hrvoje Jasak sir i
 
Hi Hrvoje Jasak sir


i am new to openFoam so can you help me to convert fluentMeshToopenfoam

hjasak February 2, 2009 08:48

Sure: - save the case from
 
Sure:

- save the case from Fluent in ASCII format
- leave it for me on an ftp server

and I'll pick it up and convert it.

Please let me know where to pick up the case.

Hrv

venkateshtl February 3, 2009 00:50

Simon Vun sir my problem
 
Simon Vun sir

my problem is that i hav done the naca 0012 airfoil case in gambit and i solved in fluent 6.3 ...now i want to compare these results in openfoam 1.4.1..now i need to import to fluentMeshTofoam in openfoam 1.4.1..i am facing problem for converting fluentMeshTofoam ...i hav created the mesh file using gambit and i used windows for importing..can u tell me how to import cas file from dosTounix to be used in opeenfoam...

hellorishi February 6, 2009 09:58

I have added a page to wiki. M
 
I have added a page to wiki. Maybe it will help you to solve your case.

However it is for OF-1.5 and with a different converter. Note: its a procedure for .msh file, so only mesh can be imported and you will have to do the tweaking yourself.

-Rishi

PS: I would request/recommend you to first read the forums and wiki before jumping into any thread and asking fundamental questions, that have been answered a few times.

hellorishi February 6, 2009 09:58

sorry I forgot the wiki link:
 
sorry I forgot the wiki link:
http://openfoamwiki.net/index.php/Fluent3DMeshToFoam

psosnows February 11, 2009 12:07

hello, since my last post (
 
hello,

since my last post ( http://www.cfd-online.com/cgi-bin/Op...0910#POST30910 ), I tried to find some way of getting the mesh. Unfortunately I failed.
Any hint how to overcome this problem will be great.
Thanks in advantage.

makaveli_lcf April 15, 2009 10:58

Hi all!

I converted 3D FLUENT mesh to OpenFOAM format. It has 6 interface patches. So they are saved as type wall. But actually they are just interfaces between to regions of simulation area.
Would you please point me, how to exclude those patches from mesh, so one should not set boundary conditions for them?

Thank you in advance!

makaveli_lcf April 15, 2009 12:02

Hmm..!!

Found, that previously in OF v1.3 fluentMeshToFoam http://openfoamwiki.net/index.php/Im...ith_interfaces saved FLUENT mesh keeping interface patches. And it was possible to treat that patches by yourself with stitchMesh. Is it available in OF v1.5, because it just combines all interfaces into default wall...

marico June 22, 2009 03:14

Hi,

I've got a valid 1.5-mesh and need to transform it into 1.4.1... Therefore I use foamMeshToFluent and after that fluent3DMeshToFoam.
In 1.5 both works. In 1.4.1-dev it reports (after lexing):

FOAM FATAL ERROR: attempt to access element from zero sized list...

Thats not fine... Any ideas???
Marco

renyun0511 September 8, 2009 08:13

fluent3DMeshToFoam
 
hi all,
i want to convert my .msh file to FOAM format on OpenFOAM-1.5,but when i use the fluent3DMeshToFoam,i have some question,would you please give me some advice?
before i used fluent3DMeshToFoam,i have used the dos2unix,but an unexpected error has been occured as follows:
Exec : fluent3DMeshToFoam voim2.msh -scale 0.001
Date : Sep 08 2009
Time : 17:17:23
Host : linux-pw3p
PID : 7618
Case : /home/ry/OpenFOAM/ry-1.5/tutorials/MRFSimpleFoam/voim/mixerVessel2D
nProcs : 1

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

Dimension of grid: 3
Number of points: 80727
PointGroup: 1 start: 0 end: 80726. Reading points...done.
--> FOAM Warning : Found unknown block of type: "13"
--> FOAM Warning : Found unknown block of type: "13"
Number of cells: 385309
CellGroup: 2 start: 0 end: 278416 type: 1
CellGroup: 3 start: 278417 end: 385308 type: 1
Zone: 2 name: rotor type: fluid. Reading zone data...done.
Zone: 3 name: stator type: fluid. Reading zone data...done.
Zone: 4 name: wall type: wall. Reading zone data...done.
Zone: 5 name: interface.4 type: interface. Reading zone data...done.
Zone: 6 name: interface.3 type: interface. Reading zone data...done.
Zone: 7 name: pressure_outlet.2 type: pressure-outlet. Reading zone data...done.
Zone: 8 name: inlet type: velocity-inlet. Reading zone data...done.
Zone: 10 name: default-interior type: interior. Reading zone data...done.

FINISHED LEXING

--> FOAM Warning :
From function boundBox::boundBox(const pointField& points)
in file meshes/boundBox/boundBox.C at line 52
Cannot find bounding box for zero sized pointField, returning zero
Creating cellZone 0 name: rotor type: fluid
Creating cellZone 1 name: stator type: fluid
#0 Foam::error::printStack(Foam::Ostream&) in "/home/ry/OpenFOAM/OpenFOAM-1.5/lib/linuxGccDPOpt/libOpenFOAM.so"
#1 Foam::sigSegv::sigSegvHandler(int) in "/home/ry/OpenFOAM/OpenFOAM-1.5/lib/linuxGccDPOpt/libOpenFOAM.so"
#2 Uninterpreted: [0xffffe420]
#3 Foam::polyTopoChange::getFaceOrder(int, Foam::List<int> const&, Foam::List<int> const&, Foam::List<int>&, Foam::List<int>&, Foam::List<int>&) const in "/home/ry/OpenFOAM/OpenFOAM-1.5/lib/linuxGccDPOpt/libdynamicMesh.so"
#4 Foam::polyTopoChange::compact(bool, bool, int&, Foam::List<int>&, Foam::List<int>&) in "/home/ry/OpenFOAM/OpenFOAM-1.5/lib/linuxGccDPOpt/libdynamicMesh.so"
#5 Foam::polyTopoChange::compactAndReorder(Foam::poly Mesh const&, bool, bool, bool, int&, Foam::Field<Foam::Vector<double> >&, Foam::List<int>&, Foam::List<int>&,
what can i do ?
regards
jennifer

airfoil September 27, 2009 22:33

Hi All,
I am using fluent3DMeshToFoam to convert fully tetra *.msh file to OF_1.6. When I use polyDualMesh 80 to convert tetra to polyhedral, it increase my cell count for example from 65579 to 262316. Why this happen? It suppose to reduce my cell count. It happen to all my msh file regardless of how big the cell count is.
Another question is, after I run meshCheck with my tetra mesh, it show my minimum face area and volume is extremely small. Why this happen? When I check in ANSA, the minumum length of my mesh is on 3mm. I attach the checkMesh output at below.
Please help!

Checking geometry...
Overall domain bounding box (-0.02 -0.02 -0.02) (0.23 0.23 0.23)
Mesh (non-empty, non-wedge) directions (1 1 1)
Mesh (non-empty) directions (1 1 1)
Boundary openness (-5.55567e-18 1.43518e-17 1.8904e-17) OK.
Max cell openness = 2.68989e-16 OK.
Max aspect ratio = 5.5672 OK.
Minumum face area = 2.35896e-06. Maximum face area = 0.000305596. Face area magnitudes OK.
Min volume = 2.60873e-09. Max volume = 1.65414e-06. Total volume = 0.01
55. Cell volumes OK.
Mesh non-orthogonality Max: 58.5029 average: 15.0529
Non-orthogonality check OK.
Face pyramids OK.
Max skewness = 0.640031 OK.

Rgds,
airfoil


gschaider September 28, 2009 12:40

Quote:

Originally Posted by airfoil (Post 230656)
Hi All,
I am using fluent3DMeshToFoam to convert fully tetra *.msh file to OF_1.6. When I use polyDualMesh 80 to convert tetra to polyhedral, it increase my cell count for example from 65579 to 262316. Why this happen? It suppose to reduce my cell count. It happen to all my msh file regardless of how big the cell count is.

Cell count according to whom? checkMesh or paraview? Paraview is wrong. Have a look in checkMesh how many cells are tetraheder and how many are polyeders

Quote:

Originally Posted by airfoil (Post 230656)
Another question is, after I run meshCheck with my tetra mesh, it show my minimum face area and volume is extremely small. Why this happen? When I check in ANSA, the minumum length of my mesh is on 3mm. I attach the checkMesh output at below.
Please help!

Checking geometry...
Overall domain bounding box (-0.02 -0.02 -0.02) (0.23 0.23 0.23)
Mesh (non-empty, non-wedge) directions (1 1 1)
Mesh (non-empty) directions (1 1 1)
Boundary openness (-5.55567e-18 1.43518e-17 1.8904e-17) OK.
Max cell openness = 2.68989e-16 OK.
Max aspect ratio = 5.5672 OK.
Minumum face area = 2.35896e-06. Maximum face area = 0.000305596. Face area magnitudes OK.
Min volume = 2.60873e-09. Max volume = 1.65414e-06. Total volume = 0.01
55. Cell volumes OK.
Mesh non-orthogonality Max: 58.5029 average: 15.0529
Non-orthogonality check OK.
Face pyramids OK.
Max skewness = 0.640031 OK.

I don't understand your problem. If you take 3mm squared and to the power of three you're within a factor of 10 of the reported values

airfoil September 28, 2009 18:17

Hi Bernhard,
Thank you for replying. May I know what is the default unit length for fluent? What I did was, I mesh surface mesh using Ansa. Then I generate tetrahedral mesh with ANSA Tetra-FEM. Later I output the surface mesh and tetra to Fluent .msh ASCII. The *.msh contains surface mesh for boundary patch. When converting to OpenFOAM, I use fluent3DMeshToFoam *.msh -scale 0.001 because my mesh in ANSA is mm unit but dimensional unit for OpenFOAM is meter. That is why I use -scale 0.001.
What is your opinion on this?
Another question, why when I convert to polydualMesh, my cell count will increase? I view it using paraview and my polyhedral cell become finer as compare to tetras. Why is this happen?

Rgds,
Airfoil

gschaider September 30, 2009 19:39

Quote:

Originally Posted by airfoil (Post 230758)
Hi Bernhard,
Thank you for replying. May I know what is the default unit length for fluent? What I did was, I mesh surface mesh using Ansa. Then I generate tetrahedral mesh with ANSA Tetra-FEM. Later I output the surface mesh and tetra to Fluent .msh ASCII. The *.msh contains surface mesh for boundary patch. When converting to OpenFOAM, I use fluent3DMeshToFoam *.msh -scale 0.001 because my mesh in ANSA is mm unit but dimensional unit for OpenFOAM is meter. That is why I use -scale 0.001.
What is your opinion on this?
Another question, why when I convert to polydualMesh, my cell count will increase? I view it using paraview and my polyhedral cell become finer as compare to tetras. Why is this happen?

Because AFAIK paraview decomposes the polyeders into tetraheder before showing them to you. The only real measure for the cell count is checkMesh

airfoil September 30, 2009 22:51

Hi Bernhard,
Thank you for the reply. I don't what is wrong with my mesh. Since then, I had abandon the desire to use fluent3DMeshToFoam. Now I am using ANSA 13 to output my delaunay mesh directly to OF then i do polyDualMesh 80 to convert tetrahedral to polyhedral. However there is an error when I do check mesh.

Checking geometry...
Overall domain bounding box (-5 -1 -0.194) (10 1 1.80605)
Mesh (non-empty, non-wedge) directions (1 1 1)
Mesh (non-empty) directions (1 1 1)
Boundary openness (8.54096e-18 8.41637e-18 -9.16634e-16) OK.
Max cell openness = 2.84773e-16 OK.
Max aspect ratio = 4.67014 OK.
Minumum face area = 2.60311e-07. Maximum face area = 0.0145859. Face area magnitudes OK.
Min volume = 3.41079e-09. Max volume = 0.00201841. Total volume = 59.8916. Cell volumes OK.
Mesh non-orthogonality Max: 47.9936 average: 10.0362
Non-orthogonality check OK.
***Error in face pyramids: 362 faces are incorrectly oriented.
<<Writing 362 faces with incorrect orientation to set wrongOrientedFaces

Max skewness = 1.89527 OK.

May I know what is wrongOrientedFaces mean?

Rgds,
Airfoil

vangelis October 9, 2009 04:21

Just a question.

Did you checkMesh the OpenFOAM mesh output from ANSA
prior to poly conversion?

airfoil October 13, 2009 04:53

2 Attachment(s)
Hi Vangelis,
When I output the mesh from Ansa, it is in tetra. So there is no error when I do checkMesh.
I noticed when I increase the split angle more then 90 deg, it will have no error but the edges is gone. From the other thread http://www.cfd-online.com/Forums/ope...eneration.html, Lillberg mentioned that the angle should be smaller then 90 deg and 45-80 is the best angle. This is true for STAR-CD as well.
Please have a look on the attachment picture. The edge is gone for Poly_95.png. If I do polyDualmesh with 75 degree, the edge is kept but always have zero points error. Could some one please explain this? Appreciate!
http://www.cfd-online.com/users/ll13...sa/poly_75.png

vangelis October 13, 2009 06:31

Hi airfoil,

I would expect that the required feature angle for the conversion should be lower, say 15 or 20 deg, in order to maintain the features of the model.

Have you tried with such values?

airfoil October 13, 2009 07:30

1 Attachment(s)
Hi Vangelis,
I try to use 15 deg and there is error in face pyramid. I attach the checkMesh result below.

lnx1762-014:ll13466> polyDualMesh 15
/*---------------------------------------------------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 1.6 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
Build : 1.6-f802ff2d6c5a
Exec : polyDualMesh 15
Date : Oct 13 2009
Time : 13:13:45
Host : lnx1762-014
PID : 1579
Case : /users/ll13466/training/openfoam/ahmed/35deg/ansa6
nProcs : 1
SigFpe : Enabling floating point exception trapping (FOAM_SIGFPE).

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

Create mesh for time = 0

// using new solver syntax:
p
{
solver GAMG;
preconditioner GAMG;
tolerance 0.0001;
relTol 0;
smoother GaussSeidel;
nPreSweeps 0;
nPostSweeps 2;
pFinestSweeps 2;
cacheAgglomeration true;
nCellsInCoarsestLevel 100;
agglomerator faceAreaPair;
mergeLevels 1;
}

// using new solver syntax:
U
{
solver PBiCG;
preconditioner DILU;
tolerance 1e-06;
relTol 0;
}

// using new solver syntax:
k
{
solver PBiCG;
preconditioner DILU;
tolerance 1e-06;
relTol 0;
}

// using new solver syntax:
epsilon
{
solver PBiCG;
preconditioner DILU;
tolerance 1e-06;
relTol 0;
}

// using new solver syntax:
R
{
solver PBiCG;
preconditioner DILU;
tolerance 1e-06;
relTol 0;
}

// using new solver syntax:
nuTilda
{
solver PBiCG;
preconditioner DILU;
tolerance 1e-06;
relTol 0;
}

Feature:15
minCos :0.965926

Dumping centres of featureFaces to obj file "featureFaces.obj"
Dumping featureEdges to obj file "featureEdges.obj"
Dumping featurePoints that become a single cell to obj file "singleCellFeaturePoints.obj"
Dumping featurePoints that become multiple cells to obj file "multiCellFeaturePoints.obj"
Reading volScalarField p
Reading volScalarField k
Reading volScalarField epsilon
Reading volScalarField nuTilda
Reading volVectorField U
Reading volSymmTensorField R
Writing dual mesh to 1
End

[/users/ll13466/training/openfoam/ahmed/35deg/ansa6] [13:16] [13.Oct] lnx1762-014:ll13466> checkMesh
/*---------------------------------------------------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 1.6 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
Build : 1.6-f802ff2d6c5a
Exec : checkMesh
Date : Oct 13 2009
Time : 13:17:16
Host : lnx1762-014
PID : 1610
Case : /users/ll13466/training/openfoam/ahmed/35deg/ansa6
nProcs : 1
SigFpe : Enabling floating point exception trapping (FOAM_SIGFPE).

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

Create polyMesh for time = 0

Time = 0

Mesh stats
points: 620905
faces: 7055740
internal faces: 6875276
cells: 3482754
boundary patches: 6
point zones: 0
face zones: 0
cell zones: 0

Overall number of cells of each type:
hexahedra: 0
prisms: 0
wedges: 0
pyramids: 0
tet wedges: 0
tetrahedra: 3482754
polyhedra: 0

Checking topology...
Boundary definition OK.
Point usage OK.
Upper triangular ordering OK.
Face vertices OK.
Number of regions: 1 (OK).

Checking patch topology for multiply connected surfaces ...
Patch Faces Points Surface topology
inlet 928 505 ok (non-closed singly connected)
outlet 928 505 ok (non-closed singly connected)
ground 37936 19141 ok (non-closed singly connected)
ground_slip 1386 744 ok (non-closed singly connected)
top_side 20726 10574 ok (non-closed singly connected)
car 118560 59314 ok (non-closed singly connected)

Checking geometry...
Overall domain bounding box (-5 -1 -0.194) (10 1 1.80605)
Mesh (non-empty, non-wedge) directions (1 1 1)
Mesh (non-empty) directions (1 1 1)
Boundary openness (9.31633e-18 1.03805e-17 1.11654e-15) OK.
Max cell openness = 3.08056e-16 OK.
Max aspect ratio = 7.61779 OK.
Minumum face area = 3.482e-06. Maximum face area = 0.00930381. Face area magnitudes OK.
Min volume = 2.63917e-09. Max volume = 0.000275506. Total volume = 59.8916. Cell volumes OK.
Mesh non-orthogonality Max: 60.8783 average: 14.6742
Non-orthogonality check OK.
Face pyramids OK.
Max skewness = 0.802059 OK.

Mesh OK.

Time = 1

Mesh stats
points: 3677823
faces: 4297096
internal faces: 4193893
cells: 620905
boundary patches: 6
point zones: 0
face zones: 0
cell zones: 0

Overall number of cells of each type:
hexahedra: 0
prisms: 0
wedges: 0
pyramids: 0
tet wedges: 0
tetrahedra: 0
polyhedra: 620905

Checking topology...
Boundary definition OK.
Point usage OK.
Upper triangular ordering OK.
Face vertices OK.
Number of regions: 1 (OK).

Checking patch topology for multiply connected surfaces ...
Patch Faces Points Surface topology
inlet 661 1244 ok (non-closed singly connected)
outlet 661 1244 ok (non-closed singly connected)
ground 19854 39353 ok (non-closed singly connected)
ground_slip 940 1782 ok (non-closed singly connected)
top_side 12904 24192 ok (non-closed singly connected)
car 68183 128361 ok (non-closed singly connected)

Checking geometry...
Overall domain bounding box (-5 -1 -0.194) (10 1 1.80605)
Mesh (non-empty, non-wedge) directions (1 1 1)
Mesh (non-empty) directions (1 1 1)
Boundary openness (1.57636e-17 7.8324e-18 1.4391e-15) OK.
Max cell openness = 2.53783e-16 OK.
Max aspect ratio = 4.59728 OK.
Minumum face area = 5.31351e-07. Maximum face area = 0.0141903. Face area magnitudes OK.
Min volume = 9.34748e-09. Max volume = 0.00192506. Total volume = 59.8916. Cell volumes OK.
Mesh non-orthogonality Max: 47.3134 average: 9.77624
Non-orthogonality check OK.
***Error in face pyramids: 182 faces are incorrectly oriented.
<<Writing 182 faces with incorrect orientation to set wrongOrientedFaces
Max skewness = 1.65935 OK.

Failed 1 mesh checks.

End

There is no problem with my tetras. I am using Ansa to generate Delaunay tetra which is the must for polyDualMesh.
Have a look on the picture. It maintained the edges very well and split into small mesh at the edge.
Anything else I can do?

vangelis October 13, 2009 08:34

Sorry airfoil,
I cannot think of anything, apart from trying to run the solver
regardless of the errors in checkMesh

Could you at least visualize the set wrongOrientedFaces?

airfoil October 15, 2009 04:26

Vengelis,
Sorry. How to view the problem faces in paraview? The error set is as below.

/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 1.6 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class faceSet;
location "constant/polyMesh/sets";
object wrongOrientedFaces;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //


182
(
4260149
4260150
4260151
4261475
4261476
4261479
4261480
4262839
4262840
4262841
4263087
4263088
4263089
4263166
4263167
4263168
4263432
4263433
4263434
4264256
4264257
4264258
4264638
4264639
4264643
4265533
4265534
4265535
4266285
4266286
4266287
4267482
4267486
4267487
4269089
4269090
4269091
4269176
4269177
4269178
4270103
4270104
4270105
4270179
4270180
4271025
4271026
4271030
4273857
4273858
4273859
4274338
4274342
4274343
4276672
4276673
4276674
4276937
4276938
4276939
4277862
4277863
4277864
4278247
4278248
4278249
4279102
4279103
4279104
4279173
4279174
4279175
4279202
4279206
4279207
4279643
4279644
4279648
4279651
4279652
4279656
4283956
4283957
4283958
4287369
4287370
4287371
4289046
4289047
4289048
4289049
4291614
4291615
4291619
4228997
4228998
4228999
4231308
4231309
4231310
4298022
4298023
4298024
4233074
4233075
4233076
4233133
4233134
4233135
4233210
4233211
4233212
4233930
4233931
4233932
4234168
4234169
4234170
4235677
4235678
4235679
4235925
4235929
4235930
4235971
4235972
4235973
4237542
4237543
4237544
4237676
4237677
4237678
4237679
4237997
4237998
4237999
4238234
4238235
4238236
4238241
4238242
4238243
4238716
4238717
4238718
4239406
4239410
4239411
4241399
4241400
4241401
4242815
4242816
4242817
4243471
4243472
4243473
4245487
4245488
4245489
4245490
4245494
4245495
4252018
4252019
4252020
4256099
4256103
4256104
4256506
4256507
4256508
4257825
4257826
4257827
4258162
4258163
4258164
4258270
4258271
4258275
)

// ************************************************** *********************** //

gschaider October 16, 2009 06:07

Quote:

Originally Posted by airfoil (Post 232719)
Vengelis,
Sorry. How to view the problem faces in paraview? The error set is as below.

/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 1.6 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class faceSet;
location "constant/polyMesh/sets";
object wrongOrientedFaces;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //


182
(
4260149
4260150

At first: Thanks for sharing all these numbers with us

How to: In paraFoam check "Include Sets" then check the set in question in the list (where the patches are). Afterwards select the set in the "Extract Block"-filter

airfoil October 25, 2009 11:12

Bernhard,
Thank you for the guide. There are problem with the mesh when viewing in Paraview. Does OF have any utility which I can fix the mesh manually?

luonganh89 November 18, 2011 23:46

Hi all!

I don't know extracly your mesh is 3D or 2D
but if Your mesh is 3D I don't see how many cell it is. I have same problem when convert a cube in Gambit to OpenFoam - But don't see the number of cell created - althought Face and Point are good.

Who can give me some advice !!!!

-mAx- November 19, 2011 03:11

use checkMesh utility

luonganh89 November 19, 2011 05:43

Question
 
http://i471.photobucket.com/albums/r...9/question.jpghttp://www.cfd-online.com/Forums/dat...AASUVORK5CYII=

This is my cellzone file - it has only information which isn't like cell file in example ... Can you explain meaning of this file for me ???
I tranformed it from Gambit to OpenFoam Mesh - it's my result file cellzone

airfoil November 19, 2011 06:22

Read the header of constant/polymesh/owner file.

luonganh89 November 19, 2011 10:00

Thank you very much :D
http://i471.photobucket.com/albums/r...nh89/owner.jpg

airfoil November 19, 2011 19:57

Your cell number is 125

hei@ge March 25, 2012 08:36

I now face the same trouble with the fluent3dmeshtofoam,i get the .cas format file,when i execute fluent3dmeshtofoam,i get the error:--> FOAM FATAL ERROR:
Do not understand characters: /
on line 157058

From function fluentMeshToFoam::lexer
in file fluent3DMeshToFoam.L at line 747.

FOAM exiting
Can you help me if you are free?


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