33 #ifndef __H__LIB_GRID__VOLUME_UTIL__
34 #define __H__LIB_GRID__VOLUME_UTIL__
64 void GetNeighbours(std::vector<Volume*>& vVolsOut, Grid& grid, Volume* v,
65 int side,
bool clearContainer =
true);
73 Grid::VertexAttachmentAccessor<APosition>& aaPos);
81 Grid::VertexAttachmentAccessor<APosition>& aaPos);
88 Grid::VertexAttachmentAccessor<APosition>& aaPos);
108 Grid::VertexAttachmentAccessor<APosition>& aaPos
118 Grid::VertexAttachmentAccessor<APosition>& aaPos);
127 Grid::VertexAttachmentAccessor<APosition>& aaPos);
135 Grid::VertexAttachmentAccessor<APosition>& aaPos);
146 Grid::VertexAttachmentAccessor<APosition>& aaPos);
176 template <
class TAAPos>
183 template<
class TVertexPositionAttachmentAccessor>
185 typename TVertexPositionAttachmentAccessor::ValueType
186 CalculateCenter(
const VolumeVertices* vol, TVertexPositionAttachmentAccessor& aaPosVRT);
193 template<
class TAAPosVRT,
class TAAWeightVRT>
195 typename TAAPosVRT::ValueType
196 CalculateCenter(
const VolumeVertices* vol, TAAPosVRT& aaPos, TAAWeightVRT& aaWeight);
211 template <
class TVolIter>
UG_API bool ContainsPoint(const EdgeVertices *e, const vector_t &p, TAAPos aaPos)
Returns true if the given point lies on the given edge.
Definition: edge_util_impl.hpp:513
void GetNeighbours(std::vector< Face * > &vFacesOut, Grid &grid, Face *f, int side, bool clearContainer)
collects neighbours of the given side of a face.
Definition: face_util.cpp:363
void InsertCenterVertex(Grid &g, Face *f, Vertex *vrt, bool eraseOldFace)
Refines the face by connecting its sides with the new center.
Definition: face_util.cpp:394
void ConvertToTetrahedra(Grid &grid, TVolIter volsBegin, TVolIter volsEnd)
Converts all volumes in the given range to tetrahedra.
Definition: volume_util_impl.hpp:162
UG_API number CalculateHexahedronVolToRMSFaceAreaRatio(Grid &grid, Hexahedron *hex, Grid::VertexAttachmentAccessor< APosition > &aaPos)
Definition: volume_util.cpp:313
UG_API number CalculateTetrahedronVolToRMSFaceAreaRatio(Grid &grid, Tetrahedron *tet, Grid::VertexAttachmentAccessor< APosition > &aaPos)
Definition: volume_util.cpp:285
number CalculateMinVolumeHeight(Tetrahedron *tet, Grid::VertexAttachmentAccessor< APosition > &aaPos)
calculates the minimal height of a volume element of type tetrahedron
Definition: volume_util.cpp:109
UG_API number CalculateTetrahedronRootMeanSquareFaceArea(Grid &grid, Tetrahedron *tet, Grid::VertexAttachmentAccessor< APosition > &aaPos)
Definition: volume_util.cpp:257
number CalculatePyramidAspectRatio(Grid &grid, Pyramid *pyr, Grid::VertexAttachmentAccessor< AVector3 > &aaPos)
calculates the aspect ratio of a pyramidal element Pyramid aspect ratio (AR) is the ratio of the heig...
Definition: volume_util.cpp:228
size_t IntersectPlaneWithTetrahedron(vector3 intsOut[4], const vector3 &planePoint, const vector3 &planeNormal, const vector3 t[4])
Returns the number of intersections and the intersection points in intsOut.
Definition: volume_util.cpp:325
number CalculateHexahedronAspectRatio(Grid &grid, Hexahedron *hex, Grid::VertexAttachmentAccessor< AVector3 > &aaPos)
calculates the aspect ratio of a hexahedral element
Definition: volume_util.cpp:171
number CalculateTetrahedronAspectRatio(Grid &grid, Tetrahedron *tet, Grid::VertexAttachmentAccessor< AVector3 > &aaPos)
calculates the aspect ratio of a tetrahedral element
Definition: volume_util.cpp:138
#define UG_API
Definition: ug_config.h:65
double number
Definition: types.h:124
void CalculateCenter(vector_t ¢erOut, const vector_t *pointSet, size_t numPoints)
calculates the center of a point-set
Definition: math_util_impl.hpp:98
bool PointIsInsideTetrahedron(const vector_t &v, const vector_t &v0, const vector_t &v1, const vector_t &v2, const vector_t &v3)
Returns true if the point lies inside or on the boundary of a tetrahedron.
Definition: math_util_impl.hpp:1110
MathVector< 3, number > vector3
a 3d vector
Definition: ugmath_types.h:72