CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM Meshing & Mesh Conversion

converting CGNS mesh with cgnsToFoam

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

Reply
 
LinkBack Thread Tools Display Modes
Old   August 5, 2010, 08:04
Default converting CGNS mesh with cgnsToFoam
  #1
bb_
New Member
 
Join Date: Jul 2010
Posts: 20
Rep Power: 6
bb_ is on a distinguished road
Hello,

I'm trying to convert a cgns block mesh generated with NUMECA Autogrid/IGG into the foam specific format with the utitlity cgnsToFoam. Some of the simpler examples seem to work just fine. However, with more complex meshes (more blocks, finer mesh) pretty much always an error occurs. At the end of the conversion the following message is shown:

***Number of faces with non-consecutive shared points: xxx

cgnsToFoam doesn't crash and exists normally though. The checkMesh output also shows an error message if run with such a converted mesh:

<<Writing xxx conflicting points to set nonManifoldPoints

When viewing the mesh with paraview (see attached image), it seems as if there are internal patch faces in the geometry which are not connected to the rest of the mesh. They always occur on internal blocking interfaces where two blocks are connected (I've made sure that they are properly connected with IGG). Therefore, I think the problem arises when trying to connect multiple blocks.

Using the cgnsToFoam parameter "-mergeTolerance" seems to have an influence in that a larger value reduces the number of non-consecutive shared points. But so far, I didn't succed in getting them to zero.

Does anyone got a similar error message when trying to convert a mesh with cgnsToFoam? Any suggestions on how to deal with this kind of problem?

Any help greatly appreciated.
Attached Images
File Type: jpg screenshot.jpg (78.3 KB, 78 views)
bb_ is offline   Reply With Quote

Old   August 24, 2010, 12:33
Default
  #2
Senior Member
 
Elvis
Join Date: Mar 2009
Location: Sindelfingen, Germany
Posts: 577
Blog Entries: 5
Rep Power: 13
elvis is on a distinguished road
I would contact Martin Beaudoin http://www.cfd-online.com/Forums/members/mbeaudoin.html maybe he will help you

http://www.cfd-online.com/Forums/ope...available.html
elvis is offline   Reply With Quote

Old   August 24, 2010, 15:29
Default
  #3
Senior Member
 
Martin Beaudoin
Join Date: Mar 2009
Posts: 330
Rep Power: 13
mbeaudoin will become famous soon enough
Hello,

The cgnsToFoam converter was developed to support multi-blocks meshes.

The error message reported by cgnsToFoam or checkMesh comes from a basic mesh validation test from inside primitiveMesh::checkFaceFaces() in primitiveMeshCheck.C.

The test complains because common vertices shared between 2 faces are not consecutive on both faces.

The problem might be caused by the presence of the "internal patches" your picture is showing.

Are those "internal patches" supposed to be there in the first place?

If not, I would suggest you first try to validate the content of your CGNS file with a simple tool like adfviewer from the cgnstools utility set.

If you can see those "internal patches" with adfviewer, then the problem is probably coming from your CGNS generator.

Try to clean-up the problem at the source, because cgnsToFoam will basically convert all the patches present in your CGNS file, good or bad.

If after all this you still have problems with cgnsToFoam, please post the cgnsToFoam conversion messages so I could see more information.

Regards,

Martin

Quote:
Originally Posted by bb_ View Post
Hello,

I'm trying to convert a cgns block mesh generated with NUMECA Autogrid/IGG into the foam specific format with the utitlity cgnsToFoam. Some of the simpler examples seem to work just fine. However, with more complex meshes (more blocks, finer mesh) pretty much always an error occurs. At the end of the conversion the following message is shown:

***Number of faces with non-consecutive shared points: xxx

cgnsToFoam doesn't crash and exists normally though. The checkMesh output also shows an error message if run with such a converted mesh:

<<Writing xxx conflicting points to set nonManifoldPoints

When viewing the mesh with paraview (see attached image), it seems as if there are internal patch faces in the geometry which are not connected to the rest of the mesh. They always occur on internal blocking interfaces where two blocks are connected (I've made sure that they are properly connected with IGG). Therefore, I think the problem arises when trying to connect multiple blocks.

Using the cgnsToFoam parameter "-mergeTolerance" seems to have an influence in that a larger value reduces the number of non-consecutive shared points. But so far, I didn't succed in getting them to zero.

Does anyone got a similar error message when trying to convert a mesh with cgnsToFoam? Any suggestions on how to deal with this kind of problem?

Any help greatly appreciated.
mbeaudoin is offline   Reply With Quote

Old   August 25, 2010, 04:04
Default
  #4
bb_
New Member
 
Join Date: Jul 2010
Posts: 20
Rep Power: 6
bb_ is on a distinguished road
Hey,

thanks for the reply! Sadly, I guess the whole topic is quite complicated...

These internal patches aren't supposed to be there ... the error is occuring at internal block faces that should be connected - The picture is showing a circular pipe, meshed with a butterfly O-grid. Those strange faces occur where the central block is adjacent to the surrounding blocks of the O-ring.

I checked the various cgns-files coming form IGG with adfviewer and cgnsplot. I'm not sure if there's a problem. At first sight everything looks ok. However, I compared cgns-files coming from IGG and ICEM and noticed some differences. For example, when using ICEM, the nodes describing the blocks in adfviewer have child-nodes called "1to1Connections". I assume they hold the appropriate information concerning the internal block connections. These entries are missing in IGG-cgns files. Here, all block faces are summarized in a node called "Boundary Conditions".

So I assume that the cgns generator in IGG failes to give this information and the conversion therefore failes. A full output of cgnsToFoam is something similar to:

--> FOAM Warning : More than one CGNS Base were found in the file.
Only the first one will be treated.
--> FOAM Warning :
From function polyMesh:olyMesh(... construct from shapes...)
in file meshes/polyMesh/polyMeshFromShapeMesh.C at line 582
Found 4592 undefined faces in mesh; adding to default patch.
Output of mesh and boundary conditions


Another strange thing: i can successfully import the cgns file into CFX-Pre. Passing it on to ICEM works too. However, using the cgns output of ICEM fails with yet another error message:

terminate called after throwing an instance of 'CGNSOO::cgns_exception'
what(): CGNS error in file:pen while calling cg_open
Error exit: Element connectivity incorrectly defined
Aborted

While exporting it from ICEM to fluent and using fluentMeshToFoam works just fine....

For now this is a workaround for me, although a quite dirty one... Not sure if it's possible to locate the error. Anyway, many thanks.
bb_ is offline   Reply With Quote

Reply

Tags
blocking, cgns, cgnstofoam, igg, mesh conversion

Thread Tools
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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
[ICEM] surface mesh merging problem everest ANSYS Meshing & Geometry 39 June 5, 2013 19:02
Converting a mesh with splitted cells using fluentMeshToFoam jlpelerin OpenFOAM Other Meshers: ICEM, Star, Ansys, Pointwise, GridPro, Ansa, ... 4 April 25, 2011 16:56
Error when importing cgns mesh created with numeca Pe2 CFX 1 May 14, 2009 18:30
Icemcfd 11: Loss of mesh from surface mesh option? Joe CFX 2 March 26, 2007 18:10
export or convert gambit mesh to CGNS zaidun FLUENT 6 April 20, 2006 04:48


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