ug4
volume_util.h File Reference

Go to the source code of this file.

Namespaces

 ug
 the ug namespace
 

Functions

template<class TAAPosVRT , class TAAWeightVRT >
UG_API TAAPosVRT::ValueType ug::CalculateCenter (const VolumeVertices *vol, TAAPosVRT &aaPos, TAAWeightVRT &aaWeight)
 returns the weighted center of the vertices of the given volume More...
 
template<class TVertexPositionAttachmentAccessor >
UG_API TVertexPositionAttachmentAccessor::ValueType ug::CalculateCenter (const VolumeVertices *vol, TVertexPositionAttachmentAccessor &aaPosVRT)
 calculates the center of a volume by averaging the positions of its corners More...
 
number ug::CalculateHexahedronAspectRatio (Grid &grid, Hexahedron *tet, Grid::VertexAttachmentAccessor< APosition > &aaPos)
 calculates the aspect ratio of a hexahedral element More...
 
UG_API number ug::CalculateHexahedronVolToRMSFaceAreaRatio (Grid &grid, Hexahedron *hex, Grid::VertexAttachmentAccessor< APosition > &aaPos)
 
number ug::CalculateMinVolumeHeight (Tetrahedron *tet, Grid::VertexAttachmentAccessor< APosition > &aaPos)
 calculates the minimal height of a volume element of type tetrahedron More...
 
number ug::CalculatePyramidAspectRatio (Grid &grid, Pyramid *pyr, Grid::VertexAttachmentAccessor< APosition > &aaPos)
 calculates the aspect ratio of a pyramidal element Pyramid aspect ratio (AR) is the ratio of the height of the pyramid and the average length of the base's (quadrilateral) edges. The AR can be less than 1. The height is the distance from the base to the top of the pyramid in normal direction. More...
 
number ug::CalculateTetrahedronAspectRatio (Grid &grid, Tetrahedron *tet, Grid::VertexAttachmentAccessor< APosition > &aaPos)
 calculates the aspect ratio of a tetrahedral element More...
 
UG_API number ug::CalculateTetrahedronRootMeanSquareFaceArea (Grid &grid, Tetrahedron *tet, Grid::VertexAttachmentAccessor< APosition > &aaPos)
 
UG_API number ug::CalculateTetrahedronVolToRMSFaceAreaRatio (Grid &grid, Tetrahedron *tet, Grid::VertexAttachmentAccessor< APosition > &aaPos)
 
template<class TAAPos >
UG_API bool ug::ContainsPoint (Volume *vol, const vector3 &p, TAAPos aaPos)
 Checks whether a given point lies in the given volume element. More...
 
template<class TVolIter >
void ug::ConvertToTetrahedra (Grid &grid, TVolIter volsBegin, TVolIter volsEnd)
 Converts all volumes in the given range to tetrahedra. More...
 
void ug::GetNeighbours (std::vector< Volume * > &vVolsOut, Grid &grid, Volume *v, int side, bool clearContainer=true)
 collects neighbours of the given side of a volume. More...
 
void ug::InsertCenterVertex (Grid &g, Volume *vol, Vertex *vrt, bool eraseOldVol)
 Refines the volume by connecting its sides with the new center. More...
 
size_t ug::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. More...
 
UG_API bool ug::PointIsInsideTetrahedron (const vector3 &v, Tetrahedron *tet, Grid::VertexAttachmentAccessor< APosition > &aaPos)
 returns true if the point lies inside the tetrahedron More...