ug4
|
Functions | |
bool | IsRegularRefRule (const int edgeMarks) |
returns true if the specified edgeMarks would lead to a regular refinement More... | |
int | Refine (int *newIndsOut, int *newEdgeVrts, bool &newCenterOut, vector3 *, bool *isSnapPoint) |
void | RotateQuad (int vrtsOut[4], const int quad[4], int steps) |
Output are the vertices of a rotated quadrilateral. More... | |
Variables | |
const int | EDGE_FROM_VRTS [8][8] |
Associates the index of the connecting edge with each tuple of vertices. More... | |
const int | EDGE_VRT_INDS [][2] |
the local vertex indices of the given edge More... | |
const int | FACE_CONTAINS_EDGE [][12] |
tells whether the i-th face contains the j-th edge More... | |
const int | FACE_EDGE_INDS [6][4] |
returns the j-th edge of the i-th face More... | |
const int | FACE_FROM_EDGES [][12] |
given two edges, the table returns the face, which contains both (or -1) More... | |
const int | FACE_FROM_VRTS [8][8][8] |
Associates the index of the connecting face with each triple of vertices. More... | |
const int | FACE_VRT_INDS [][4] |
the local vertex indices of the given face More... | |
const int | MAX_NUM_CONVERT_TO_TETS_INDS_OUT = 30 |
const int | MAX_NUM_INDS_OUT = 256 |
const int | NUM_EDGES = 12 |
const int | NUM_FACES = 6 |
const int | NUM_QUADS = 6 |
const int | NUM_TRIS = 0 |
const int | NUM_VERTICES = 8 |
const int | OPPOSED_FACE [NUM_FACES] = {5, 3, 4, 1, 2, 0} |
contains the index of the opposed face of each face More... | |
const int | OPPOSED_FACE_VRT_INDS [][4] |
vertex indices of the face on the opposite side of the i-th face. More... | |
const int | OPPOSED_OBJECT [][NUM_VERTICES] |
bool ug::hex_rules::IsRegularRefRule | ( | const int | edgeMarks | ) |
returns true if the specified edgeMarks would lead to a regular refinement
A regular refinement leads to new elements which are all similar to the original element. I.e. which are of the same type and which have similar angles.
edgeMarks | If the i-th edge shall be refined, the expression 'edgeMarks & (1<<i) != 0' has to be true. You can specify multiple refine-edges using or-combinations. E.g., 'edgeMarks = (1<<i) | (1<<j)' would indicate that the i-th and the j-th edge shall be refined. |
Referenced by ug::Tetrahedron::is_regular_ref_rule(), ug::Hexahedron::is_regular_ref_rule(), ug::Prism::is_regular_ref_rule(), ug::Pyramid::is_regular_ref_rule(), and ug::Octahedron::is_regular_ref_rule().
int ug::hex_rules::Refine | ( | int * | newIndsOut, |
int * | newEdgeVrts, | ||
bool & | newCenterOut, | ||
vector3 * | corners = NULL , |
||
bool * | isSnapPoint = NULL |
||
) |
returns an array of integers, which contains the indices of the objects resulting from the refinement of a hexahedron.
newIndsOut | Array which has to be of size MAX_NUM_INDS_OUT. When the algorithm is done, the array will contain sequences of integers: {{gridObjectID, ind1, ind2, ...}, ...}. gridObjectID is a constant enumerated in GridObjectID and describes the type of the grid-object that is built from the following set of corner indices. Old vertices are referenced by their local index. Vertices created on an edge are indexed by the index of the edge + NUM_VERTICES. Vertices created on a face are referenced by NUM_VERTICES + NUM_EDGES + index_of_face. If an inner vertex has to be created, it is referenced by NUM_VERTICES + NUM_EDGES + NUM_FACES (in this case newCenterOut is set to true). |
newEdgeVrts | Array of size NUM_EDGES, which has to contain 1 for each edge, which shall be refined and 0 for each edge, which won't be refined. |
newCenterOut | If the refinement-rule requires a center vertex, then this parameter will be set to true. If not, it is set to false. |
corners | Ignored. |
isSnapPoint | (optional) An array of size NUM_VERTICES. If all entries are set to 'false' the behaviour is the same as if the array wasn't specified. If a corner of a quadrilateral is a snap-point and if edges of that quadrilateral are refined, then only new edges connected to the snap-point are introduced. Note that only special snap-point constellations are supported. |
References EDGE_FROM_VRTS, EDGE_VRT_INDS, FACE_CONTAINS_EDGE, FACE_EDGE_INDS, FACE_FROM_EDGES, FACE_VRT_INDS, ug::GOID_HEXAHEDRON, ug::GOID_PRISM, ug::GOID_PYRAMID, NUM_EDGES, NUM_FACES, NUM_VERTICES, OPPOSED_FACE, OPPOSED_FACE_VRT_INDS, ug::shared_rules::RecursiveRefine(), RotateQuad(), and UG_LOG.
void ug::hex_rules::RotateQuad | ( | int | vrtsOut[4], |
const int | quad[4], | ||
int | steps | ||
) |
Output are the vertices of a rotated quadrilateral.
Referenced by Refine().
const int ug::hex_rules::EDGE_FROM_VRTS[8][8] |
Associates the index of the connecting edge with each tuple of vertices.
Use two vertex indices to index into this table to retrieve the index of their connecting edge.
Referenced by ug::Tetrahedron::get_edge_index_from_vertices(), ug::Hexahedron::get_edge_index_from_vertices(), ug::Prism::get_edge_index_from_vertices(), ug::Pyramid::get_edge_index_from_vertices(), ug::Octahedron::get_edge_index_from_vertices(), and Refine().
const int ug::hex_rules::EDGE_VRT_INDS[][2] |
the local vertex indices of the given edge
Referenced by ug::Prism::collapse_edge(), ug::Pyramid::collapse_edge(), ug::Tetrahedron::create_edge(), ug::Hexahedron::create_edge(), ug::Prism::create_edge(), ug::Pyramid::create_edge(), ug::Octahedron::create_edge(), ug::Tetrahedron::edge_desc(), ug::Hexahedron::edge_desc(), ug::Prism::edge_desc(), ug::Pyramid::edge_desc(), ug::Octahedron::edge_desc(), ug::Tetrahedron::get_vertex_indices_of_edge(), ug::Hexahedron::get_vertex_indices_of_edge(), ug::Prism::get_vertex_indices_of_edge(), ug::Pyramid::get_vertex_indices_of_edge(), ug::Octahedron::get_vertex_indices_of_edge(), ug::IntersectPlaneWithTetrahedron(), main(), and Refine().
const int ug::hex_rules::FACE_CONTAINS_EDGE[][12] |
tells whether the i-th face contains the j-th edge
Referenced by Refine().
const int ug::hex_rules::FACE_EDGE_INDS[6][4] |
returns the j-th edge of the i-th face
Referenced by ug::Tetrahedron::get_face_edge_index(), ug::Hexahedron::get_face_edge_index(), ug::Prism::get_face_edge_index(), ug::Pyramid::get_face_edge_index(), ug::Octahedron::get_face_edge_index(), and Refine().
const int ug::hex_rules::FACE_FROM_EDGES[][12] |
given two edges, the table returns the face, which contains both (or -1)
Referenced by Refine().
const int ug::hex_rules::FACE_FROM_VRTS[8][8][8] |
Associates the index of the connecting face with each triple of vertices.
Use three vertex indices to index into this table to retrieve the index of their connecting face.
const int ug::hex_rules::FACE_VRT_INDS[][4] |
the local vertex indices of the given face
Referenced by ug::Tetrahedron::create_face(), ug::Hexahedron::create_face(), ug::Prism::create_face(), ug::Pyramid::create_face(), ug::Octahedron::create_face(), ug::Tetrahedron::face_desc(), ug::Hexahedron::face_desc(), ug::Prism::face_desc(), ug::Pyramid::face_desc(), ug::Octahedron::face_desc(), ug::Tetrahedron::get_vertex_indices_of_face(), ug::Hexahedron::get_vertex_indices_of_face(), ug::Prism::get_vertex_indices_of_face(), ug::Pyramid::get_vertex_indices_of_face(), ug::Octahedron::get_vertex_indices_of_face(), main(), and Refine().
const int ug::hex_rules::MAX_NUM_CONVERT_TO_TETS_INDS_OUT = 30 |
Referenced by ug::ConvertToTetrahedra().
const int ug::hex_rules::MAX_NUM_INDS_OUT = 256 |
Referenced by ug::shared_rules::RecursiveRefine(), and ug::Refine().
const int ug::hex_rules::NUM_EDGES = 12 |
Referenced by ug::Tetrahedron::create_edge(), ug::Hexahedron::create_edge(), ug::Prism::create_edge(), ug::Pyramid::create_edge(), ug::Octahedron::create_edge(), ug::Tetrahedron::edge_desc(), ug::Hexahedron::edge_desc(), ug::Prism::edge_desc(), ug::Pyramid::edge_desc(), ug::Octahedron::edge_desc(), ug::Hexahedron::get_vertex_indices_of_edge(), ug::Prism::get_vertex_indices_of_edge(), ug::Pyramid::get_vertex_indices_of_edge(), ug::Octahedron::get_vertex_indices_of_edge(), ug::IntersectPlaneWithTetrahedron(), main(), ug::shared_rules::RecursiveRefine(), Refine(), and ug::Refine().
const int ug::hex_rules::NUM_FACES = 6 |
Referenced by ug::Tetrahedron::create_face(), ug::Hexahedron::create_face(), ug::Prism::create_face(), ug::Pyramid::create_face(), ug::Octahedron::create_face(), ug::Tetrahedron::face_desc(), ug::Hexahedron::face_desc(), ug::Prism::face_desc(), ug::Pyramid::face_desc(), ug::Octahedron::face_desc(), ug::Hexahedron::get_vertex_indices_of_face(), ug::Prism::get_vertex_indices_of_face(), ug::Pyramid::get_vertex_indices_of_face(), ug::Octahedron::get_vertex_indices_of_face(), main(), Refine(), and ug::Refine().
const int ug::hex_rules::NUM_QUADS = 6 |
const int ug::hex_rules::NUM_TRIS = 0 |
const int ug::hex_rules::NUM_VERTICES = 8 |
Referenced by ug::LSGFGlobAssembler< TDomain, TAlgebra, TExtrapolation >::AssembleDefect(), ug::StdGlobAssembler< TDomain, TAlgebra >::AssembleDefect(), ug::StdGlobAssembler< TDomain, TAlgebra >::AssembleErrorEstimator(), ug::LSGFGlobAssembler< TDomain, TAlgebra, TExtrapolation >::AssembleJacobian(), ug::StdGlobAssembler< TDomain, TAlgebra >::AssembleJacobian(), ug::LSGFGlobAssembler< TDomain, TAlgebra, TExtrapolation >::AssembleLinear(), ug::StdGlobAssembler< TDomain, TAlgebra >::AssembleLinear(), ug::LSGFGlobAssembler< TDomain, TAlgebra, TExtrapolation >::AssembleMassMatrix(), ug::StdGlobAssembler< TDomain, TAlgebra >::AssembleMassMatrix(), ug::StdGlobAssembler< TDomain, TAlgebra >::AssembleRhs(), ug::LSGFGlobAssembler< TDomain, TAlgebra, TExtrapolation >::AssembleStiffnessMatrix(), ug::StdGlobAssembler< TDomain, TAlgebra >::AssembleStiffnessMatrix(), ug::FillCornerCoordinates(), ug::LSGFGlobAssembler< TDomain, TAlgebra, TExtrapolation >::FinishTimestepElem(), ug::StdGlobAssembler< TDomain, TAlgebra >::FinishTimestepElem(), ug::Tetrahedron::get_opposing_object(), ug::Hexahedron::get_opposing_object(), ug::Prism::get_opposing_object(), ug::Pyramid::get_opposing_object(), ug::Octahedron::get_opposing_object(), main(), ug::LSGFGlobAssembler< TDomain, TAlgebra, TExtrapolation >::PrepareTimestepElem(), ug::StdGlobAssembler< TDomain, TAlgebra >::PrepareTimestepElem(), ug::shared_rules::RecursiveRefine(), Refine(), and ug::Refine().
const int ug::hex_rules::OPPOSED_FACE[NUM_FACES] = {5, 3, 4, 1, 2, 0} |
contains the index of the opposed face of each face
Referenced by ug::Hexahedron::get_opposing_side(), ug::Prism::get_opposing_side(), and Refine().
const int ug::hex_rules::OPPOSED_FACE_VRT_INDS[][4] |
vertex indices of the face on the opposite side of the i-th face.
Note that the orientation of those faces are different from the orientation of the original faces. The j-th vertex i' is the one on the opposite site of the j-th vertex of face i.
Referenced by Refine().
const int ug::hex_rules::OPPOSED_OBJECT[][NUM_VERTICES] |
for each vertex, a pair containing the object type (0: vrt, 1: edge, 2: face) and an index into the associated array, which describe the object which lies on the opposite side of the hexahedron, to a given vertex.
Referenced by ug::Tetrahedron::get_opposing_object(), ug::Hexahedron::get_opposing_object(), ug::Prism::get_opposing_object(), ug::Pyramid::get_opposing_object(), and ug::Octahedron::get_opposing_object().