# refineMesh inverses face normals?

 User Name Remember Me Password
 Register Blogs Members List Search Today's Posts Mark Forums Read

 LinkBack Thread Tools Display Modes
 August 2, 2012, 13:16 refineMesh inverses face normals? #1 New Member   Roland Engberg Join Date: Jan 2011 Posts: 14 Rep Power: 8 Sponsored Links My home-brewed code crashes on meshes refined with the "refineMesh" utility. To find out what is happening I made a small mesh consisting of two cells and used refineMesh to split both cells. I wrote a code which calculates the snGrad of a scalar field, loops over all cells and writes the snGrads (which are very important for my code) and the face normals Sf() to the output file. It seems that refineMesh inverses the face normals of some faces. Consequently, the snGrad of these faces has the opposite sign. Interestingly, the normals of the "new" faces created with refineMesh point in the correct direction whereas the normals of "old" internal cells are inversed. Does anybody know why the nomals are inversed? Thanks in advance! Roland
 Sponsored Links

August 2, 2012, 15:05
#2
Senior Member

Philip Cardiff
Join Date: Mar 2009
Location: Dublin,Ireland
Posts: 638
Rep Power: 23
Quote:
 Originally Posted by RoE It seems that refineMesh inverses the face normals of some faces.
Hi Roland,

The normal on an internal face point from the cell owner to the cell neighbour. refineMesh probably has to reassign owners and neighbours after refining.
But the new normals should still be correctly pointing from the new owners to new neighbours. Why is it a problem?

Best regards,
Philip

 August 3, 2012, 11:28 #3 New Member   Roland Engberg Join Date: Jan 2011 Posts: 14 Rep Power: 8 Hi Philip, the normals do point from the new owners to the new neighbours. I knew I had read about the normal orientation and its relation to the owner/neighbour thingy, but I could not remember where exactly... So that was just the information I needed! My code runs on refined meshes now Thank you & best wishes, Roland

 August 3, 2012, 11:41 #4 Senior Member     Philip Cardiff Join Date: Mar 2009 Location: Dublin,Ireland Posts: 638 Rep Power: 23 That's Great Philip

 Thread Tools Display Modes Linear Mode

 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 OffTrackbacks are On Pingbacks are On Refbacks are On Forum Rules

 Similar Threads Thread Thread Starter Forum Replies Last Post hsieh Open Source Meshers: Gmsh, Netgen, CGNS, ... 32 September 13, 2011 05:50 hjasak OpenFOAM Native Meshers: blockMesh 11 August 15, 2008 07:36 SSL FLUENT 2 January 26, 2008 12:55 Rasmus Gjesing (Gjesing) OpenFOAM Native Meshers: blockMesh 10 April 2, 2007 14:00 michele OpenFOAM Other Meshers: ICEM, Star, Ansys, Pointwise, GridPro, Ansa, ... 2 July 15, 2005 04:15

 Sponsored Links

All times are GMT -4. The time now is 15:36.

 Contact Us - CFD Online - Top