The geometry of a single element is described using a polygon-oriented boundary representation of the parameter domain. As we support only (curved) polyhedral elements, an element can be described by the set of its vertices and a description of the boundary polygons. This applies only to the local coordinates of an element; its shape in world coordinates is determined by some transformation routine.
For a threedimensional polyhedron, we specify the number of boundary polygons (faces) and for each of these polygons the number of vertices, the local vertex indices and their order (thus giving an orientation to the polygon such that the surface normal is the outer normal to the polyhedron), and the local indices of the adjacent face across each of the edges of the polygon.
For each vertex, the coordinates in the local coordinate system of the element are given by the element description. Based on these values, the visualization routines may operate in the local coordinate space. The pointer to a function check_inside() is provided by the element description, which checks whether a point in local coordinates is inside the element or not.
The element description is completed by pointers to transformation routines from local coordinates to world coordinates and vice versa, and routines boundary() and neighbour() which give information about the neighbourship of elements. Additionally, the transformation routine from world to local coordinates checks whether a given point is inside the element or not.
typedef struct { int number_of_vertices; /* number of vertices */ int number_of_polygons; /* number of faces */ int *polygon_length; /* vertex counts of the faces */ int **polygon_vertex; /* face to vertex adjacency */ int **polygon_neighbour; /* face to face adjacency */ int dimension_of_coord; /* dim. of local coordinate system */ double **coord; /* local coordinates of the vertices */ int parametric_degree; /* parametric element if > 1 */ int (*world_to_coord)(ELEMENT3D *, float *, double *); void (*coord_to_world)(ELEMENT3D *, double *, float *); int (*check_inside)(ELEMENT3D *, double *); ELEMENT3D *(*neighbour)(ELEMENT3D *, int, int, double *, float *); int (*boundary)(ELEMENT3D *, int); } ELEMENT3D_DESCRIPTION;
The arrays and procedures give following information:
The number of such element descriptions and therefore the amount of storage for them is equal to the number of different element types in one mesh. There are no copies of this necessary for each element.
In the Figures, examples of vertex and face relationships for cubes, tetrahedra, and prisms are depicted. check_inside() is easily implemented using the local coordinates.
The user's data structures (from a numerical method, e.g.) may be
completely different to the structures described above. In case of
implicitly given Finite Difference meshes, the functions
neighbour and boundary are implemented using simple index
arithmetic.
Unstructured grids usually provide such information explicitly.
Copyright © by the Sonderforschungsbereich 256 at the Institut für Angewandte Mathematik, Universität Bonn.