Classes | |
class | ExcInvalidCoordinate |
class | ExcInvalidSubface |
Static Public Member Functions | |
static unsigned int | n_children (const RefinementCase< dim > &refinement_case) |
static unsigned int | n_subfaces (const internal::SubfaceCase< dim > &subface_case) |
static double | subface_ratio (const internal::SubfaceCase< dim > &subface_case, const unsigned int subface_no) |
static RefinementCase< dim-1 > | face_refinement_case (const RefinementCase< dim > &cell_refinement_case, const unsigned int face_no, const bool face_orientation=true, const bool face_flip=false, const bool face_rotation=false) |
static RefinementCase< dim > | min_cell_refinement_case_for_face_refinement (const RefinementCase< dim-1 > &face_refinement_case, const unsigned int face_no, const bool face_orientation=true, const bool face_flip=false, const bool face_rotation=false) |
static RefinementCase< 1 > | line_refinement_case (const RefinementCase< dim > &cell_refinement_case, const unsigned int line_no) |
static RefinementCase< dim > | min_cell_refinement_case_for_line_refinement (const unsigned int line_no) |
static unsigned int | child_cell_on_face (const RefinementCase< dim > &ref_case, const unsigned int face, const unsigned int subface, const bool face_orientation=true, const bool face_flip=false, const bool face_rotation=false, const RefinementCase< dim-1 > &face_refinement_case=RefinementCase< dim-1 >::isotropic_refinement) |
static unsigned int | line_to_cell_vertices (const unsigned int line, const unsigned int vertex) |
static unsigned int | face_to_cell_vertices (const unsigned int face, const unsigned int vertex, const bool face_orientation=true, const bool face_flip=false, const bool face_rotation=false) |
static unsigned int | face_to_cell_lines (const unsigned int face, const unsigned int line, const bool face_orientation=true, const bool face_flip=false, const bool face_rotation=false) |
static unsigned int | standard_to_real_face_vertex (const unsigned int vertex, const bool face_orientation=true, const bool face_flip=false, const bool face_rotation=false) |
static unsigned int | real_to_standard_face_vertex (const unsigned int vertex, const bool face_orientation=true, const bool face_flip=false, const bool face_rotation=false) |
static unsigned int | standard_to_real_face_line (const unsigned int line, const bool face_orientation=true, const bool face_flip=false, const bool face_rotation=false) |
static unsigned int | real_to_standard_face_line (const unsigned int line, const bool face_orientation=true, const bool face_flip=false, const bool face_rotation=false) |
static Point< dim > | unit_cell_vertex (const unsigned int vertex) |
static unsigned int | child_cell_from_point (const Point< dim > &p) |
static Point< dim > | cell_to_child_coordinates (const Point< dim > &p, const unsigned int child_index, const RefinementCase< dim > refine_case=RefinementCase< dim >::isotropic_refinement) |
static Point< dim > | child_to_cell_coordinates (const Point< dim > &p, const unsigned int child_index, const RefinementCase< dim > refine_case=RefinementCase< dim >::isotropic_refinement) |
static bool | is_inside_unit_cell (const Point< dim > &p) |
static bool | is_inside_unit_cell (const Point< dim > &p, const double eps) |
static Point< dim > | project_to_unit_cell (const Point< dim > &p) |
static double | distance_to_unit_cell (const Point< dim > &p) |
Static Public Attributes | |
static const unsigned int | max_children_per_cell = 1 << dim |
static const unsigned int | faces_per_cell = 2 * dim |
static const unsigned int | max_children_per_face = GeometryInfo<dim-1>::max_children_per_cell |
static const unsigned int | vertices_per_cell = 1 << dim |
static const unsigned int | vertices_per_face = GeometryInfo<dim-1>::vertices_per_cell |
static const unsigned int | lines_per_face = GeometryInfo<dim-1>::lines_per_cell |
static const unsigned int | quads_per_face = GeometryInfo<dim-1>::quads_per_cell |
static const unsigned int | lines_per_cell |
static const unsigned int | quads_per_cell |
static const unsigned int | hexes_per_cell |
static const unsigned int | ucd_to_deal [vertices_per_cell] |
static const unsigned int | dx_to_deal [vertices_per_cell] |
static const unsigned int | vertex_to_face [vertices_per_cell][dim] |
static const unsigned int | unit_normal_direction [faces_per_cell] |
static const int | unit_normal_orientation [faces_per_cell] |
static const unsigned int | opposite_face [faces_per_cell] |
It is the one central point in the library where information about the numbering of vertices, lines, or faces of the reference cell is collected. Consequently, the information of this class is used extensively in the geometric description of Triangulation objects, as well as in various other parts of the code. In particular, it also serves as the focus of writing code in a dimension independent way; for example, instead of writing a loop over vertices 0<=v<4 in 2d, one would write it as 0<=v<GeometryInfo<dim>::vertices_per_cell, thus allowing the code to work in 3d as well without changes.
The most frequently used parts of the class are its static members like vertices_per_cell, faces_per_cell, etc. However, the class also offers information about more abstract questions like the orientation of faces, etc. The following documentation gives a textual description of many of these concepts.
From version 5.2 onwards deal.II is based on a numbering scheme that uses a lexicographic ordering (with x running fastest) wherever possible, hence trying to adopt a kind of 'canonical' ordering.
The ordering of vertices and faces (lines) in 2d is defined by
N1) vertices are numbered in lexicographic ordering
N2) faces (lines in 2d): first the two faces with normals in x- and then y-direction. For each two faces: first the face with normal in negative coordinate direction, then the one with normal in positive direction, i.e. the faces are ordered according to their normals pointing in -x, x, -y, y direction.
N3) the direction of a line is represented by the direction of point 0 towards point 1 and is always in one of the coordinate directions
N4/ face lines in 3d are ordered, such that the induced 2d local coordinate system (x,y) implies (right hand rule) a normal in face normal direction, see N2/.
The resulting numbering of vertices and faces (lines) in 2d as well as the directions of lines is shown in the following.
* 3 * 2-->--3 * | | * 0^ ^1 * | | * 0-->--1 * 2 *
Note that the orientation of lines has to be correct upon construction of a grid; however, it is automatically preserved upon refinement.
Further we define that child lines have the same direction as their parent, i.e. that line->child(0)->vertex(0)==line->vertex(0)
and line->child(1)->vertex(1)==line->vertex(1)
. This also implies, that the first sub-line (line->child(0)
) is the one at vertex(0) of the old line.
Similarly we define, that the four children of a quad are adjacent to the vertex with the same number of the old quad.
Note that information about several of these conventions can be extracted at run- or compile-time from the member functions and variables of the present class.
When explicit coordinates are required for points in a cell (e.g for quadrature formulae or the point of definition of trial functions), we define the following coordinate system for the unit cell:
* y^ 2-----3 * | | | * | | | * | | | * | 0-----1 * *------------>x *
Here, vertex 0 is the origin of the coordinate system, vertex 1 has coordinates (1,0)
, vertex 2 at (0,1)
and vertex 3 at (1,1)
. The GeometryInfo<dim>::unit_cell_vertex() function can be used to query this information at run-time.
By convention, we will use the following numbering conventions for vertices, lines and faces of hexahedra in three space dimensions. Before giving these conventions we declare the following sketch to be the standard way of drawing 3d pictures of hexahedra:
* *-------* *-------* * /| | / /| * / | | / / | * z / | | / / | * ^ * | | *-------* | * | ^y | *-------* | | * * | / | / / | | / * | / | / / | | / * |/ |/ / | |/ * *------>x *-------* *-------* *
Note again that information about several of the following conventions can be extracted at run- or compile-time from the member functions and variables of the present class.
The ordering of vertices in 3d is defined by the same rules as in the 2d case, i.e.
N1) vertices are numbered in lexicographic ordering.
Hence, the vertices are numbered as follows
* 6-------7 6-------7 * /| | / /| * / | | / / | * / | | / / | * 4 | | 4-------5 | * | 2-------3 | | 3 * | / / | | / * | / / | | / * |/ / | |/ * 0-------1 0-------1 *
We note, that first the vertices on the bottom face (z=0) are numbered exactly the same way as are the vertices on a quadrilateral. Then the vertices on the top face (z=1) are numbered similarly by moving the bottom face to the top. Again, the GeometryInfo<dim>::unit_cell_vertex() function can be used to query this information at run-time.
Here, the same holds as for the vertices:
N4) line ordering in 3d:
* *---7---* *---7---* * /| | / /| * 4 | 11 4 5 11 * / 10 | / / | * * | | *---6---* | * | *---3---* | | * * | / / | 9 / * 8 0 1 8 | 1 * |/ / | |/ * *---2---* *---2---* *
* *--->---* *--->---* * /| | / /| * ^ | ^ ^ ^ ^ * / ^ | / / | * * | | *--->---* | * | *--->---* | | * * | / / | ^ / * ^ ^ ^ ^ | ^ * |/ / | |/ * *--->---* *--->---* *
The fact that edges (just as vertices and faces) are entities that are stored in their own right rather than constructed from cells each time they are needed, means that adjacent cells actually have pointers to edges that are thus shared between them. This implies that the convention that sets of parallel edges have parallel directions is not only a local condition. Before a list of cells is passed to an object of the Triangulation class for creation of a triangulation, you therefore have to make sure that cells are oriented in a compatible fashion, so that edge directions are globally according to above convention. However, the GridReordering class can do this for you, by reorienting cells and edges of an arbitrary list of input cells that need not be already sorted.
The numbering of faces in 3d is defined by a rule analogous to 2d:
N2a) faces (quads in 3d): first the two faces with normals in x-, then y- and z-direction. For each two faces: first the face with normal in negative coordinate direction, then the one with normal in positive direction, i.e. the faces are ordered according to their normals pointing in -x, x, -y, y, -z, z direction.
Therefore, the faces are numbered in the ordering: left, right, front, back, bottom and top face:
* *-------* *-------* * /| | / /| * / | 3 | / 5 / | * / | | / / | * * | | *-------* | * | 0 *-------* | | 1 * * | / / | | / * | / 4 / | 2 | / * |/ / | |/ * *-------* *-------* *
The standard direction of the faces is such, that the induced 2d local coordinate system (x,y) implies (right hand rule) a normal in face normal direction, see N2a). In the following we show the local coordinate system and the numbering of face lines:
* Face 0 Face 1 * *-------* *-------* * /| | / /| * 3 1 | / 3 1 * y/ | | / y/ | * * |x | *-------* |x * | *-------* | | * * 0 / / | 0 / * | 2 / | | 2 * |/ / | |/ * *-------* *-------* *
* x Face 3 Face 2 * *---1---* *-------* * /| | / /| * / | 3 / / | * / 2 | x/ / | * * | | *---1---* | * | *---0---*y | | * * | / / | 3 / * | / / 2 | / * |/ / | |/ * *-------* *---0---*y *
* Face 4 y Face 5 * *-------* *---3---* * /| | / /| * / | | 0 1 | * / | | / / | * * |y | *---2---* x | * | *---3---* | | * * | / / | | / * | 0 1 | | / * |/ / | |/ * *---2---* x *-------* *
The face line numbers (0,1,2,3) correspond to following cell line numbers.
The face normals can be deduced from the face orientation by applying the right hand side rule (x,y -> normal). We note, that in the standard orientation of faces in 2d, faces 0 and 2 have normals that point into the cell, and faces 1 and 3 have normals pointing outward. In 3d, faces 0, 2, and 4 have normals that point into the cell, while the normals of faces 1, 3, and 5 point outward. This information, again, can be queried from GeometryInfo<dim>::unit_normal_orientation.
However, it turns out that a significant number of 3d meshes cannot satisfy this convention. This is due to the fact that the face convention for one cell already implies something for the neighbor, since they share a common face and fixing it for the first cell also fixes the normal vectors of the opposite faces of both cells. It is easy to construct cases of loops of cells for which this leads to cases where we cannot find orientations for all faces that are consistent with this convention.
For this reason, above convention is only what we call the standard orientation. deal.II actually allows faces in 3d to have either the standard direction, or its opposite, in which case the lines that make up a cell would have reverted orders, and the above line equivalences would not hold any more. You can ask a cell whether a given face has standard orientation by calling cell->face_orientation(face_no)
: if the result is true
, then the face has standard orientation, otherwise its normal vector is pointing the other direction. There are not very many places in application programs where you need this information actually, but a few places in the library make use of this. Note that in 2d, the result is always true
. More information on the topic can be found in the glossary article on this topic.
In order to allow all kinds of meshes in 3d, including Moebius-loops, for example, a face might even be rotated looking from one cell, whereas it is according to the standard looking at it from the neighboring cell sharing that particular face. In order to cope with this, two flags face_flip
and face_rotation
are available, to represent rotations by 90 and 180 degree, respectively. Setting both flags accumulates to a rotation of 270 degrees (all counterclockwise). You can ask the cell for these flags like for the face_orientation
. In order to enable rotated faces, even lines can deviate from their standard direction in 3d. This information is available as the line_orientation
flag for cells and faces in 3d. Again, this is something that should be internal to the library and application program will probably never have to bother about it.
The eight children of an isotropically refined cell are numbered according to the vertices they are adjacent to:
* *----*----* *----*----* * /| 6 | 7 | / 6 / 7 /| * *6| | | *----*----*7| * /| *----*----* / 4 / 5 /| * * * |/| | | *----*----* |/| * |4* | 2 | 3 | | 4 | 5 |5*3| * |/|2*----*----* | | |/| * * * |/ 2 / 3 / *----*----* |/ * |0*----*----* | | |1* * |/0 / 1 / | 0 | 1 |/ * *----*----* *----*----* *
Taking into account the orientation of the faces, the following children are adjacent to the respective faces:
Note that, again, the above list only holds for faces in their standard orientation. If a face is not in standard orientation, then the children at positions 1 and 2 (counting from 0 to 3) would be swapped. In fact, this is what the child_cell_on_face and the face_to_cell_vertices functions of GeometryInfo<3> do, when invoked with a face_orientation=false
argument.
The information which child cell is at which position of which face is most often used when computing jump terms across faces with hanging nodes, using objects of type FESubfaceValues. Sitting on one cell, you would look at a face and figure out which child of the neighbor is sitting on a given subface between the present and the neighboring cell. To avoid having to query the standard orientation of the faces of the two cells every time in such cases, you should use a function call like cell->neighbor_child_on_subface(face_no,subface_no)
, which returns the correct result both in 2d (where face orientations are immaterial) and 3d (where it is necessary to use the face orientation as additional argument to GeometryInfo<3>::child_cell_on_face
).
For anisotropic refinement, the child cells can not be numbered according to adjacent vertices, thus the following conventions are used:
* RefinementCase<3>::cut_x * * *----*----* *----*----* * /| | | / / /| * / | | | / 0 / 1 / | * / | 0 | 1 | / / / | * * | | | *----*----* | * | 0 | | | | | | 1 | * | *----*----* | | | * * | / / / | 0 | 1 | / * | / 0 / 1 / | | | / * |/ / / | | |/ * *----*----* *----*----* *
* RefinementCase<3>::cut_y * * *---------* *---------* * /| | / 1 /| * * | | *---------* | * /| | 1 | / 0 /| | * * |1| | *---------* |1| * | | | | | | | | * |0| *---------* | |0| * * | |/ 1 / | 0 | |/ * | *---------* | | * * |/ 0 / | |/ * *---------* *---------* *
* RefinementCase<3>::cut_z * * *---------* *---------* * /| 1 | / /| * / | | / 1 / | * / *---------* / / * * * 1/| | *---------* 1/| * | / | 0 | | 1 | / | * |/ *---------* | |/ * * * 0/ / *---------* 0/ * | / 0 / | | / * |/ / | 0 |/ * *---------* *---------* *
* RefinementCase<3>::cut_xy * * *----*----* *----*----* * /| | | / 2 / 3 /| * * | | | *----*----* | * /| | 2 | 3 | / 0 / 1 /| | * * |2| | | *----*----* |3| * | | | | | | | | | | * |0| *----*----* | | |1| * * | |/ 2 / 3 / | 0 | 1 | |/ * | *----*----* | | | * * |/ 0 / 1 / | | |/ * *----*----* *----*----* *
* RefinementCase<3>::cut_xz * * *----*----* *----*----* * /| 1 | 3 | / / /| * / | | | / 1 / 3 / | * / *----*----* / / / * * * 1/| | | *----*----* 3/| * | / | 0 | 2 | | 1 | 3 | / | * |/ *----*----* | | |/ * * * 0/ / / *----*----* 2/ * | / 0 / 2 / | | | / * |/ / / | 0 | 2 |/ * *----*----* *----*----* *
* RefinementCase<3>::cut_yz * * *---------* *---------* * /| 3 | / 3 /| * * | | *---------* | * /|3*---------* / 2 /|3* * * |/| | *---------* |/| * |2* | 1 | | 2 |2* | * |/|1*---------* | |/|1* * * |/ 1 / *---------* |/ * |0*---------* | |0* * |/ 0 / | 0 |/ * *---------* *---------* *
This information can also be obtained by the GeometryInfo<3>::child_cell_on_face
function.
We define the following coordinate system for the explicit coordinates of the vertices of the unit cell:
* 6-------7 6-------7 * /| | / /| * / | | / / | * z / | | / / | * ^ 4 | | 4-------5 | * | ^y | 2-------3 | | 3 * | / | / / | | / * | / | / / | | / * |/ |/ / | |/ * *------>x 0-------1 0-------1 *
By the convention laid down as above, the vertices have the following coordinates (lexicographic, with x running fastest):
(0,0,0)
; (1,0,0)
; (0,1,0)
; (1,1,0)
; (0,0,1)
; (1,0,1)
; (0,1,1)
; (1,1,1)
.
static unsigned int GeometryInfo< dim >::n_children | ( | const RefinementCase< dim > & | refinement_case | ) | [static] |
Return the number of children of a cell (or face) refined with ref_case
.
static unsigned int GeometryInfo< dim >::n_subfaces | ( | const internal::SubfaceCase< dim > & | subface_case | ) | [static] |
Return the number of subfaces of a face refined according to internal::SubfaceCase face_ref_case
.
static double GeometryInfo< dim >::subface_ratio | ( | const internal::SubfaceCase< dim > & | subface_case, | |
const unsigned int | subface_no | |||
) | [static] |
Given a face on the reference element with a internal::SubfaceCase<dim>
face_refinement_case
this function returns the ratio between the area of the subface_no
th subface and the area(=1) of the face.
E.g. for internal::SubfaceCase<3>cut_xy
the ratio is 1/4 for each of the subfaces.
static RefinementCase<dim-1> GeometryInfo< dim >::face_refinement_case | ( | const RefinementCase< dim > & | cell_refinement_case, | |
const unsigned int | face_no, | |||
const bool | face_orientation = true , |
|||
const bool | face_flip = false , |
|||
const bool | face_rotation = false | |||
) | [static] |
Given a cell refined with the RefinementCase
cell_refinement_case
return the SubfaceCase
of the face_no
th face.
static RefinementCase<dim> GeometryInfo< dim >::min_cell_refinement_case_for_face_refinement | ( | const RefinementCase< dim-1 > & | face_refinement_case, | |
const unsigned int | face_no, | |||
const bool | face_orientation = true , |
|||
const bool | face_flip = false , |
|||
const bool | face_rotation = false | |||
) | [static] |
Given the SubfaceCase face_refinement_case
of the face_no
th face, return the smallest RefinementCase of the cell, which corresponds to that refinement of the face.
static RefinementCase<1> GeometryInfo< dim >::line_refinement_case | ( | const RefinementCase< dim > & | cell_refinement_case, | |
const unsigned int | line_no | |||
) | [static] |
Given a cell refined with the RefinementCase cell_refinement_case
return the RefinementCase of the line_no
th face.
static RefinementCase<dim> GeometryInfo< dim >::min_cell_refinement_case_for_line_refinement | ( | const unsigned int | line_no | ) | [static] |
Return the minimal / smallest RefinementCase of the cell, which ensures refinement of line line_no
.
static unsigned int GeometryInfo< dim >::child_cell_on_face | ( | const RefinementCase< dim > & | ref_case, | |
const unsigned int | face, | |||
const unsigned int | subface, | |||
const bool | face_orientation = true , |
|||
const bool | face_flip = false , |
|||
const bool | face_rotation = false , |
|||
const RefinementCase< dim-1 > & | face_refinement_case = RefinementCase< dim-1 >::isotropic_refinement | |||
) | [static] |
This field stores which child cells are adjacent to a certain face of the mother cell.
For example, in 2D the layout of a cell is as follows:
* . 3 * . 2-->--3 * . | | * . 0 ^ ^ 1 * . | | * . 0-->--1 * . 2 *
Now, when refined, the layout is like this:
* *--*--* * | 2|3 | * *--*--* * | 0|1 | * *--*--* *
Thus, the child cells on face 0 are (ordered in the direction of the face) 0 and 2, on face 3 they are 2 and 3, etc.
For three spatial dimensions, the exact order of the children is laid down in the general documentation of this class.
Through the face_orientation
, face_flip
and face_rotation
arguments this function handles faces oriented in the standard and non-standard orientation. face_orientation
defaults to true
, face_flip
and face_rotation
default to false
(standard orientation) and has no effect in 2d. The concept of face orientations is explained in this glossary entry.
In the case of anisotropically refined cells and faces, the RefinementCase
of the face, face_ref_case
, might have an influence on which child is behind which given subface, thus this is an additional argument, defaulting to isotropic refinement of the face.
static unsigned int GeometryInfo< dim >::line_to_cell_vertices | ( | const unsigned int | line, | |
const unsigned int | vertex | |||
) | [static] |
Map line vertex number to cell vertex number, i.e. give the cell vertex number of the vertex
th vertex of line line
, e.g. GeometryInfo<2>::line_to_cell_vertices(3,0)=2
.
The order of the lines, as well as their direction (which in turn determines which is the first and which the second vertex on a line) is the canonical one in deal.II, as described in the general documentation of this class.
For dim=2
this call is simply passed down to the face_to_cell_vertices() function.
static unsigned int GeometryInfo< dim >::face_to_cell_vertices | ( | const unsigned int | face, | |
const unsigned int | vertex, | |||
const bool | face_orientation = true , |
|||
const bool | face_flip = false , |
|||
const bool | face_rotation = false | |||
) | [static] |
Map face vertex number to cell vertex number, i.e. give the cell vertex number of the vertex
th vertex of face face
, e.g. GeometryInfo<2>::face_to_cell_vertices(3,0)=2
.
Through the face_orientation
, face_flip
and face_rotation
arguments this function handles faces oriented in the standard and non-standard orientation. face_orientation
defaults to true
, face_flip
and face_rotation
default to false
(standard orientation) and has no effect in 2d.
As the children of a cell are ordered according to the vertices of the cell, this call is passed down to the child_cell_on_face() function. Hence this function is simply a wrapper of child_cell_on_face() giving it a suggestive name.
static unsigned int GeometryInfo< dim >::face_to_cell_lines | ( | const unsigned int | face, | |
const unsigned int | line, | |||
const bool | face_orientation = true , |
|||
const bool | face_flip = false , |
|||
const bool | face_rotation = false | |||
) | [static] |
Map face line number to cell line number, i.e. give the cell line number of the line
th line of face face
, e.g. GeometryInfo<3>::face_to_cell_lines(5,0)=4
.
Through the face_orientation
, face_flip
and face_rotation
arguments this function handles faces oriented in the standard and non-standard orientation. face_orientation
defaults to true
, face_flip
and face_rotation
default to false
(standard orientation) and has no effect in 2d.
static unsigned int GeometryInfo< dim >::standard_to_real_face_vertex | ( | const unsigned int | vertex, | |
const bool | face_orientation = true , |
|||
const bool | face_flip = false , |
|||
const bool | face_rotation = false | |||
) | [static] |
Map the vertex index vertex
of a face in standard orientation to one of a face with arbitrary face_orientation
, face_flip
and face_rotation
. The values of these three flags default to true
, false
and false
, respectively. this combination describes a face in standard orientation.
This function is only implemented in 3D.
static unsigned int GeometryInfo< dim >::real_to_standard_face_vertex | ( | const unsigned int | vertex, | |
const bool | face_orientation = true , |
|||
const bool | face_flip = false , |
|||
const bool | face_rotation = false | |||
) | [static] |
Map the vertex index vertex
of a face with arbitrary face_orientation
, face_flip
and face_rotation
to a face in standard orientation. The values of these three flags default to true
, false
and false
, respectively. this combination describes a face in standard orientation.
This function is only implemented in 3D.
static unsigned int GeometryInfo< dim >::standard_to_real_face_line | ( | const unsigned int | line, | |
const bool | face_orientation = true , |
|||
const bool | face_flip = false , |
|||
const bool | face_rotation = false | |||
) | [static] |
Map the line index line
of a face in standard orientation to one of a face with arbitrary face_orientation
, face_flip
and face_rotation
. The values of these three flags default to true
, false
and false
, respectively. this combination describes a face in standard orientation.
This function is only implemented in 3D.
static unsigned int GeometryInfo< dim >::real_to_standard_face_line | ( | const unsigned int | line, | |
const bool | face_orientation = true , |
|||
const bool | face_flip = false , |
|||
const bool | face_rotation = false | |||
) | [static] |
Map the line index line
of a face with arbitrary face_orientation
, face_flip
and face_rotation
to a face in standard orientation. The values of these three flags default to true
, false
and false
, respectively. this combination describes a face in standard orientation.
This function is only implemented in 3D.
static Point<dim> GeometryInfo< dim >::unit_cell_vertex | ( | const unsigned int | vertex | ) | [static] |
Return the position of the ith
vertex on the unit cell. The order of vertices is the canonical one in deal.II, as described in the general documentation of this class.
static unsigned int GeometryInfo< dim >::child_cell_from_point | ( | const Point< dim > & | p | ) | [static] |
Given a point p
in unit coordinates, return the number of the child cell in which it would lie in. If the point lies on the interface of two children, return any one of their indices. The result is always less than GeometryInfo<dimension>::max_children_per_cell.
The order of child cells is described the general documentation of this class.
static Point<dim> GeometryInfo< dim >::cell_to_child_coordinates | ( | const Point< dim > & | p, | |
const unsigned int | child_index, | |||
const RefinementCase< dim > | refine_case = RefinementCase< dim >::isotropic_refinement | |||
) | [static] |
Given coordinates p
on the unit cell, return the values of the coordinates of this point in the coordinate system of the given child. Neither original nor returned coordinates need actually be inside the cell, we simply perform a scale-and-shift operation with a shift that depends on the number of the child.
static Point<dim> GeometryInfo< dim >::child_to_cell_coordinates | ( | const Point< dim > & | p, | |
const unsigned int | child_index, | |||
const RefinementCase< dim > | refine_case = RefinementCase< dim >::isotropic_refinement | |||
) | [static] |
The reverse function to the one above: take a point in the coordinate system of the child, and transform it to the coordinate system of the mother cell.
static bool GeometryInfo< dim >::is_inside_unit_cell | ( | const Point< dim > & | p | ) | [static] |
Return true if the given point is inside the unit cell of the present space dimension.
static bool GeometryInfo< dim >::is_inside_unit_cell | ( | const Point< dim > & | p, | |
const double | eps | |||
) | [static] |
Return true if the given point is inside the unit cell of the present space dimension. This * function accepts an additional * parameter which specifies how * much the point position may * actually be outside the true * unit cell. This is useful because in practice we may often not be able to compute the coordinates of a point in reference coordinates exactly, but only up to numerical roundoff.
The tolerance parameter may be less than zero, indicating that the point should be safely inside the cell.
static Point<dim> GeometryInfo< dim >::project_to_unit_cell | ( | const Point< dim > & | p | ) | [static] |
Projects a given point onto the unit cell, i.e. each coordinate outside [0..1] is modified to lie within that interval.
static double GeometryInfo< dim >::distance_to_unit_cell | ( | const Point< dim > & | p | ) | [static] |
Returns the infinity norm of the vector between a given point p
outside the unit cell to the closest unit cell boundary. For points inside the cell, this is defined as zero.
const unsigned int GeometryInfo< dim >::max_children_per_cell = 1 << dim [static] |
Maximum number of children of a refined cell, i.e. the number of children of an isotropically refined cell.
If a cell is refined anisotropically, the actual number of children may be less than the value given here.
const unsigned int GeometryInfo< dim >::faces_per_cell = 2 * dim [static] |
Number of faces of a cell.
const unsigned int GeometryInfo< dim >::max_children_per_face = GeometryInfo<dim-1>::max_children_per_cell [static] |
Maximum number of children of a refined face, i.e. the number of children of an isotropically refined face.
If a cell is refined anisotropically, the actual number of children may be less than the value given here.
const unsigned int GeometryInfo< dim >::vertices_per_cell = 1 << dim [static] |
Number of vertices of a cell.
const unsigned int GeometryInfo< dim >::vertices_per_face = GeometryInfo<dim-1>::vertices_per_cell [static] |
Number of vertices on each face.
const unsigned int GeometryInfo< dim >::lines_per_face = GeometryInfo<dim-1>::lines_per_cell [static] |
Number of lines on each face.
const unsigned int GeometryInfo< dim >::quads_per_face = GeometryInfo<dim-1>::quads_per_cell [static] |
Number of quads on each face.
const unsigned int GeometryInfo< dim >::lines_per_cell [static] |
Initial value:
(2*GeometryInfo<dim-1>::lines_per_cell + GeometryInfo<dim-1>::vertices_per_cell)
The formula to compute this makes use of the fact that when going from one dimension to the next, the object of the lower dimension is copied once (thus twice the old number of lines) and then a new line is inserted between each vertex of the old object and the corresponding one in the copy.
const unsigned int GeometryInfo< dim >::quads_per_cell [static] |
Initial value:
(2*GeometryInfo<dim-1>::quads_per_cell + GeometryInfo<dim-1>::lines_per_cell)
This number is computed recursively just as the previous one, with the exception that new quads result from connecting an original line and its copy.
const unsigned int GeometryInfo< dim >::hexes_per_cell [static] |
Initial value:
(2*GeometryInfo<dim-1>::hexes_per_cell + GeometryInfo<dim-1>::quads_per_cell)
const unsigned int GeometryInfo< dim >::ucd_to_deal[vertices_per_cell] [static] |
Rearrange vertices for UCD output. For a cell being written in UCD format, each entry in this field contains the number of a vertex in deal.II
that corresponds to the UCD numbering at this location.
Typical example: write a cell and arrange the vertices, such that UCD understands them.
for (i=0; i< n_vertices; ++i) out << cell->vertex(ucd_to_deal[i]);
As the vertex numbering in deal.II versions <= 5.1 happened to coincide with the UCD numbering, this field can also be used like a old_to_lexicographic mapping.
const unsigned int GeometryInfo< dim >::dx_to_deal[vertices_per_cell] [static] |
Rearrange vertices for OpenDX output. For a cell being written in OpenDX format, each entry in this field contains the number of a vertex in deal.II
that corresponds to the DX numbering at this location.
Typical example: write a cell and arrange the vertices, such that OpenDX understands them.
for (i=0; i< n_vertices; ++i) out << cell->vertex(dx_to_deal[i]);
const unsigned int GeometryInfo< dim >::vertex_to_face[vertices_per_cell][dim] [static] |
This field stores for each vertex to which faces it belongs. In any given dimension, the number of faces is equal to the dimension. The first index in this 2D-array runs over all vertices, the second index over dim
faces to which the vertex belongs
const unsigned int GeometryInfo< dim >::unit_normal_direction[faces_per_cell] [static] |
For each face of the reference cell, this field stores the coordinate direction in which its normal vector points. In dim
dimension these are the 2*dim
first entries of {0,0,1,1,2,2,3,3}
.
Note that this is only the coordinate number. The actual direction of the normal vector is obtained by multiplying the unit vector in this direction with unit_normal_orientation.
const int GeometryInfo< dim >::unit_normal_orientation[faces_per_cell] [static] |
Orientation of the unit normal vector of a face of the reference cell. In dim
dimension these are the 2*dim
first entries of {-1,1,-1,1,-1,1,-1,1}
.
Each value is either 1
or -1
, corresponding to a normal vector pointing in the positive or negative coordinate direction, respectively.
Note that this is only the standard orientation of faces. At least in 3d, actual faces of cells in a triangulation can also have the opposite orientation, depending on a flag that one can query from the cell it belongs to. For more information, see the glossary entry on face orientation.
const unsigned int GeometryInfo< dim >::opposite_face[faces_per_cell] [static] |
List of numbers which denotes which face is opposite to a given face. Its entries are the first 2*dim
entries of { 1, 0, 3, 2, 5, 4, 7, 6}
.