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

[CGNS] converting CGNS mesh with cgnsToFoam

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 5, 2010, 09:04
Default converting CGNS mesh with cgnsToFoam
  #1
bb_
New Member
 
Join Date: Jul 2010
Posts: 20
Rep Power: 16
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, 133 views)
bb_ is offline   Reply With Quote

Old   August 24, 2010, 13:33
Default
  #2
Senior Member
 
Elvis
Join Date: Mar 2009
Location: Sindelfingen, Germany
Posts: 620
Blog Entries: 6
Rep Power: 24
elvis will become famous soon enough
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, 16:29
Default
  #3
Senior Member
 
Martin Beaudoin
Join Date: Mar 2009
Posts: 332
Rep Power: 22
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, 05:04
Default
  #4
bb_
New Member
 
Join Date: Jul 2010
Posts: 20
Rep Power: 16
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


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
[ICEM] CGNS mesh failing in CFX siw ANSYS Meshing & Geometry 5 November 23, 2017 20:07
Problems with CGNS mesh and develop version BopngMa SU2 2 September 15, 2015 17:38
[snappyHexMesh] No layers in a small gap bobburnquist OpenFOAM Meshing & Mesh Conversion 6 August 26, 2015 10:38
[snappyHexMesh] snappyHexMesh won't work - zeros everywhere! sc298 OpenFOAM Meshing & Mesh Conversion 2 March 27, 2011 22:11
Icemcfd 11: Loss of mesh from surface mesh option? Joe CFX 2 March 26, 2007 19:10


All times are GMT -4. The time now is 05:21.