CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Visualization & Post-Processing Software > ParaView

[OpenFOAM] Cell Types and Face Layout

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   May 12, 2006, 13:32
Default Cell Types and Face Layout
  #1
Member
 
Terry Jordan
Join Date: Mar 2009
Posts: 95
Rep Power: 17
tj22 is on a distinguished road
Since the file format has changed to owner/neighbor format, does the face numbering for the cells still hold true? Seems not to. I am looking at a dataset with all hexahedrons. And if I grab the faces for the first cell (0) the order of the faces does not correspond to the face numbering in the documentation. Also does not seem to hold true for the next. Can anyone provide me some assistance with the ordering of the faces? I am trying reconstruct the cell in VTK.
tj22 is offline   Reply With Quote

Old   May 12, 2006, 14:11
Default Why don't you just the mesh to
  #2
Senior Member
 
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,907
Rep Power: 33
hjasak will become famous soon enough
Why don't you just the mesh to give you the shapes?

Hrv

OpenFOAM-1.3/src/OpenFOAM/meshes/primitiveMesh/primitiveMesh.H


//- Calculate cell shapes
void calcCellShapes() const;

__________________
Hrvoje Jasak
Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk
hjasak is offline   Reply With Quote

Old   May 12, 2006, 14:56
Default I have figured it out. Thanks
  #3
Member
 
Terry Jordan
Join Date: Mar 2009
Posts: 95
Rep Power: 17
tj22 is on a distinguished road
I have figured it out. Thanks anyways.
tj22 is offline   Reply With Quote

Old   May 15, 2006, 05:10
Default Also: foamToVTK/vtkTopo.C to s
  #4
Senior Member
 
Mattijs Janssens
Join Date: Mar 2009
Posts: 1,419
Rep Power: 26
mattijs is on a distinguished road
Also: foamToVTK/vtkTopo.C to see how cellShapes are converted into VTK shapes.
mattijs is offline   Reply With Quote

Old   May 15, 2006, 15:15
Default Thanks but I still am not find
  #5
Member
 
Terry Jordan
Join Date: Mar 2009
Posts: 95
Rep Power: 17
tj22 is on a distinguished road
Thanks but I still am not finding how the faces from a faces file are layed out. I was using the bubbleColumn example. In the first row of hexes, the normal for the owner faces point into the cell while the faces from the neigbor cells point out.

when I move on to the next row it is the inverse.

In Vtk the points need to be in a certain order to look correct which seems to corresponds to the point layout for foam on the cell type doc.

But I cant seem to find the rhyme or reason of how foam lays out the faces.

Thanks.
tj22 is offline   Reply With Quote

Old   May 15, 2006, 15:21
Default Try this: ~/.OpenFOAM-1.3/c
  #6
Senior Member
 
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,907
Rep Power: 33
hjasak will become famous soon enough
Try this:

~/.OpenFOAM-1.3/cellModels

So, for a hex:


hex
{
index 3;
numberOfPoints 8;

faces
6
(
4(0 4 7 3) // x-min
4(1 2 6 5) // x-max
4(0 1 5 4) // y-min
4(3 7 6 2) // y-max
4(0 3 2 1) // z-min
4(4 5 6 7) // z-max
);

edges
12
(
(0 1) // x-direction
(3 2)
(7 6)
(4 5)
(0 3) // y-direction
(4 7)
(5 6)
(1 2)
(0 4) // z-direction
(1 5)
(2 6)
(3 7)
);

}

A tet is:

tet
{
index 7;
numberOfPoints 4;

faces
4
(
3(1 2 3)
3(0 3 2)
3(0 1 3)
3(0 2 1)
);

edges
6
(
(0 1)
(0 2)
(0 3)
(3 1)
(1 2)
(3 2)
);

}

I hope you can read this.

Hrv
__________________
Hrvoje Jasak
Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk
hjasak is offline   Reply With Quote

Old   May 17, 2006, 14:05
Default I now have an algorithm that w
  #7
Member
 
Terry Jordan
Join Date: Mar 2009
Posts: 95
Rep Power: 17
tj22 is on a distinguished road
I now have an algorithm that works. Thanks anyways.
tj22 is offline   Reply With Quote

Reply


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
udf problem jane Fluent UDF and Scheme Programming 37 February 20, 2018 05:17
[Commercial meshers] Porous Jump creation problem mulfal OpenFOAM Meshing & Mesh Conversion 4 December 9, 2013 12:59
[GAMBIT] Problem with interior faces miro2000 ANSYS Meshing & Geometry 11 August 24, 2013 15:00
WARNING: non-positive face area exist. Alan Main CFD Forum 4 August 17, 2006 08:33
Gambit bug??? Face vertex types Friederike FLUENT 5 April 19, 2005 20:06


All times are GMT -4. The time now is 01:17.