CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > General Forums > Main CFD Forum

Cell centres

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 4, 2003, 03:41
Default Cell centres
  #1
Tom
Guest
 
Posts: n/a
Hi, what is the most accurate method to calculate the centre of a general polyhedral cell?
  Reply With Quote

Old   June 4, 2003, 06:28
Default Re: Cell centres
  #2
John
Guest
 
Posts: n/a
Divide it into tetrahedrals and calculate the individual tetra center: the polyhedral center is sumup(ViCi)/sumup(Vi), where Vi is volume of each tetra, and Ci is the center of each tetra.
  Reply With Quote

Old   June 4, 2003, 09:56
Default Re: Cell centres
  #3
Tom
Guest
 
Posts: n/a
Thank you. Will do, but how do I calculate the centre of a tet?
  Reply With Quote

Old   June 4, 2003, 10:04
Default Re: Cell centres
  #4
Tom
Guest
 
Posts: n/a
...and the volume of a tet for that matter?

thank you
  Reply With Quote

Old   June 4, 2003, 13:28
Default Re: Cell centres
  #5
Ananda Himansu
Guest
 
Posts: n/a
the centroid of a tet (or any simplex, the tet being a 3D simplex) is the arithmetic average of [the position vectors representing] its vertices. note that such a statement is not in general true for polytopes other than simplices, which is why you have to decompose a general polyhedron into tets.

pick any vertex of the tet. label it "O". label, in any order, the other three vertices "A", "B", "C". denote the vector from O to A by the label "a", from O to B by "b", similarly "c". the volume of the tet is one-sixth of the magnitude of the scalar or "box" product of the three vectors a, b, c. that is, volume(OABC)=|a.(bxc)|/6. (the analogous formula for a triangle embedded in 3D is that the area of triangle OAB is half the magnitude of the cross-product of a and b, that is, area(OAB)=||axb||/2.)

the decomposition of general polyhedra into the union of tetrahedra with plane faces is not in general exact. for example, if a polyhedron has a quadrilateral for a side, the vertices of the quad need not lie in a plane. then the decomposition of the quad into two or more tets is only an approximation.

these issues have been noted in old papers, and are probably discussed in any CFD text that explains unstructured meshes. also probably covered previously in this forum (do a search).
  Reply With Quote

Old   June 4, 2003, 15:54
Default Re: Cell centres
  #6
john
Guest
 
Posts: n/a
Another means is to calculate the determinate of the following expression:

V=(1/6)*|x1 y1 z1 1 |

|x2 y2 z2 1 |

|x3 y3 z3 1 |

|x4 y4 z4 1 |

where the x, y & z's are the coordinates of the respective points defining the tetrahedron. Note that the volume will always be positive, even though the value of the determinate might be negative depending upon the ordering of the points.

  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
Cells with t below lower limit Purushothama Siemens 2 May 31, 2010 22:58
How to determine the direction of cell face vectors on processor patches sebastian_vogl OpenFOAM Running, Solving & CFD 0 October 27, 2009 09:47
SVN 1226 - Possible bug with cell centres and volumes philippose OpenFOAM Bugs 2 June 5, 2009 14:19
[Commercial meshers] Trimmed cell and embedded refinement mesh conversion issues michele OpenFOAM Meshing & Mesh Conversion 2 July 15, 2005 05:15
Warning 097- AB Siemens 6 November 15, 2004 05:41


All times are GMT -4. The time now is 23:49.