Regina 7.0 Calculation Engine
|
Represents a vertex in the skeleton of a 4-manifold triangulation. More...
#include <triangulation/dim4.h>
Public Member Functions | |
~Face () | |
Default destructor. More... | |
const Triangulation< 3 > & | buildLink () const |
Returns a full 3-manifold triangulation describing the link of this vertex. More... | |
Isomorphism< 4 > | buildLinkInclusion () const |
Returns details of how the tetrahedra are labelled in the link of this vertex. More... | |
bool | isIdeal () const |
Determines if this vertex is an ideal vertex. More... | |
size_t | index () const |
Returns the index of this face within the underlying triangulation. More... | |
Triangulation< dim > & | triangulation () const |
Returns the triangulation to which this face belongs. More... | |
Component< dim > * | component () const |
Returns the component of the triangulation to which this face belongs. More... | |
BoundaryComponent< dim > * | boundaryComponent () const |
Returns the boundary component of the triangulation to which this face belongs. More... | |
bool | isBoundary () const |
Determines if this face lies entirely on the boundary of the triangulation. More... | |
size_t | degree () const |
Returns the degree of this face. More... | |
const FaceEmbedding< dim, subdim > & | embedding (size_t index) const |
Returns one of the ways in which this face appears within a top-dimensional simplex of the underlying triangluation. More... | |
auto | embeddings () const |
Returns an object that allows iteration through and random access to all of the ways in which this face appears within a top-dimensional simplex of the underlying triangluation. More... | |
auto | begin () const |
A begin function for iterating through all appearances of this face within the various top-dimensional simplices of the underlying triangulation. More... | |
auto | end () const |
An end function for iterating through all appearances of this face within the various top-dimensional simplices of the underlying triangulation. More... | |
const FaceEmbedding< dim, subdim > & | front () const |
Returns the first appearance of this face within a top-dimensional simplex of the underlying triangluation. More... | |
const FaceEmbedding< dim, subdim > & | back () const |
Returns the last appearance of this face within a top-dimensional simplex of the underlying triangluation. More... | |
bool | inMaximalForest () const |
Determines whether a codimension-1-face represents a dual edge in the maximal forest that has been chosen for the dual 1-skeleton of the triangulation. More... | |
bool | isLinkOrientable () const |
Determines if the link of this face is orientable. More... | |
bool | isValid () const |
Determines if this face is valid. More... | |
bool | hasBadIdentification () const |
Determines if this face is identified with itself under a non-identity permutation. More... | |
bool | hasBadLink () const |
Determines if this face does not have an appropriate link. More... | |
Face< dim, lowerdim > * | face (int face) const |
Returns the lowerdim-face of the underlying triangulation that appears as the given lowerdim-dimensional subface of this face. More... | |
Face< dim, 0 > * | vertex (int i) const |
A dimension-specific alias for face<0>(). More... | |
Face< dim, 1 > * | edge (int i) const |
A dimension-specific alias for face<1>(). More... | |
Face< dim, 2 > * | triangle (int i) const |
A dimension-specific alias for face<2>(). More... | |
Face< dim, 3 > * | tetrahedron (int i) const |
A dimension-specific alias for face<3>(). More... | |
Face< dim, 4 > * | pentachoron (int i) const |
A dimension-specific alias for face<4>(). More... | |
Perm< dim+1 > | faceMapping (int face) const |
Examines the given lowerdim-dimensional subface of this face, and returns the mapping between the underlying lowerdim-face of the triangulation and the individual vertices of this face. More... | |
Perm< dim+1 > | vertexMapping (int face) const |
A dimension-specific alias for faceMapping<0>(). More... | |
Perm< dim+1 > | edgeMapping (int face) const |
A dimension-specific alias for faceMapping<1>(). More... | |
Perm< dim+1 > | triangleMapping (int face) const |
A dimension-specific alias for faceMapping<2>(). More... | |
Perm< dim+1 > | tetrahedronMapping (int face) const |
A dimension-specific alias for faceMapping<3>(). More... | |
Perm< dim+1 > | pentachoronMapping (int face) const |
A dimension-specific alias for faceMapping<4>(). More... | |
void | writeTextShort (std::ostream &out) const |
Writes a short text representation of this object to the given output stream. More... | |
size_t | markedIndex () const |
Returns the index at which this object is stored in an MarkedVector. More... | |
void | writeTextLong (std::ostream &out) const |
A default implementation for detailed output. More... | |
std::string | str () const |
Returns a short text representation of this object. More... | |
std::string | utf8 () const |
Returns a short text representation of this object using unicode characters. More... | |
std::string | detail () const |
Returns a detailed text representation of this object. More... | |
Static Public Member Functions | |
static constexpr Perm< dim+1 > | ordering (unsigned face) |
Given a subdim-face number within a dim-dimensional simplex, returns the corresponding canonical ordering of the simplex vertices. More... | |
static constexpr unsigned | faceNumber (Perm< dim+1 > vertices) |
Identifies which subdim-face in a dim-dimensional simplex is represented by the first (subdim + 1) elements of the given permutation. More... | |
static constexpr bool | containsVertex (unsigned face, unsigned vertex) |
Tests whether the given subdim-face of a dim-dimensional simplex contains the given vertex of the simplex. More... | |
Static Public Attributes | |
static constexpr int | dimension |
A compile-time constant that gives the dimension of the triangulation containing this face. More... | |
static constexpr int | subdimension |
A compile-time constant that gives the dimension of this face. More... | |
static constexpr bool | allowsNonOrientableLinks |
Indicates whether it is possible for a face of this dimension to have a non-orientable link. More... | |
static constexpr bool | allowsInvalidFaces |
Indicates whether it is possible for a face of this dimension to be invalid. More... | |
static constexpr int | oppositeDim = (dim - 1 - subdim) |
The dimension of the faces opposite these in a top-dimensional simplex of a dim-dimensional triangulation. More... | |
static constexpr bool | lexNumbering = (subdim <= oppositeDim) |
true if faces are numbered in lexicographical order according to their vertices, or false if faces are numbered in reverse lexicographical order. More... | |
static constexpr int | nFaces = binomSmall(dim + 1, lexDim + 1) |
The total number of subdim-dimensional faces in each dim-dimensional simplex. More... | |
Static Protected Attributes | |
static constexpr int | lexDim = (lexNumbering ? subdim : oppositeDim) |
Whichever of subdim or oppositeDim uses lexicographical face numbering. More... | |
Friends | |
class | Triangulation< 4 > |
class | detail::TriangulationBase< 4 > |
Represents a vertex in the skeleton of a 4-manifold triangulation.
This is a specialisation of the generic Face class template; see the documentation for Face for a general overview of how this class works.
These specialisations for Regina's standard dimensions offer significant extra functionality.
Vertices do not support value semantics: they cannot be copied, swapped, or manually constructed. Their location in memory defines them, and they are often passed and compared by pointer. End users are never responsible for their memory management; this is all taken care of by the Triangulation to which they belong.
regina::Face< 4, 0 >::~Face | ( | ) |
Default destructor.
|
inlineinherited |
Returns the last appearance of this face within a top-dimensional simplex of the underlying triangluation.
This is equivalent to calling embedding(degree()-1)
.
In most cases, the ordering of appearances is arbitrary. The exception is for codimension 2, where the appearances of a face are ordered in a way that follows the link around the face (which in codimension 2 is always a path or a cycle). In particular, for a boundary face of codimension 2, both front() and back() will refer to the two appearances of this face on the (dim-1)-dimensional boundary.
|
inlineinherited |
A begin function for iterating through all appearances of this face within the various top-dimensional simplices of the underlying triangulation.
In most cases, the ordering of appearances is arbitrary. The exception is for codimension 2, where these appearances are ordered in a way that follows the link around the face (which in codimension 2 is always a path or a cycle).
An iteration from begin() to end() will run through degree() appearances in total.
The type that is returned will be a lightweight iterator type, guaranteed to satisfy the C++ LegacyRandomAccessIterator requirement. The precise C++ type of the iterator is subject to change, so C++ users should use auto
(just like this declaration does).
Iterating from begin() to end() (that is, iterating directly over a face) is equivalent to iterating over embeddings(). Iterating directly over a face generates a tiny bit less overhead, but you may also find it to be less readable. In particular, the following three blocks of code are all equivalent:
|
inlineinherited |
Returns the boundary component of the triangulation to which this face belongs.
See the note in the BoundaryComponent overview regarding what happens if the link of the face itself has more than one boundary component. Note that such a link makes both the face and the underlying triangulation invalid.
For dimensions in which ideal and/or invalid vertices are both possible and recognised: an ideal vertex will have its own individual boundary component to which it belongs, and so will an invalid vertex boundary component if the invalid vertex does not already belong to some real boundary component.
null
if this face does not lie entirely within the boundary of the triangulation.
|
inline |
Returns a full 3-manifold triangulation describing the link of this vertex.
This routine is fast (it uses a pre-computed triangulation). The downside is that the triangulation is read-only (though you can always clone it).
Regarding the labelling of tetrahedra in the vertex link:
embedding(i).pentachoron()
, and let v represent embedding(i).vertex()
. Then buildLink()->tetrahedron(i)
is the tetrahedron in the vertex link that "slices off" vertex v from pentachoron pent. In other words, buildLink()->tetrahedron(i)
in the vertex link is parallel to tetrahedron pent->tetrahedron(v)
in the surrounding 4-manifold triangulation.buildLink()->tetrahedron(i)
sits within pent
and is parallel to pent->tetrahedron(v)
. Then vertices 0,1,2,3 of the tetrahedron in the link will be parallel to vertices 0,1,2,3 of the corresponding Tetrahedron<4>. The permutation pent->tetrahedronMapping(v)
will map vertices 0,1,2,3 of the tetrahedron in the link to the corresponding vertices of pent
(those opposite v
), and will map 4 to v
itself.Isomorphism< 4 > regina::Face< 4, 0 >::buildLinkInclusion | ( | ) | const |
Returns details of how the tetrahedra are labelled in the link of this vertex.
This is a companion function to buildLink(), which returns a full 3-manifold triangulation of the vertex link.
The documentation for buildLink() describes in plain English exactly how the vertex link will be triangulated. This function essentially returns the same information in a machine-readable form.
Specifically, this function returns an Isomorphism<4> that describes how the individual tetrahedra of the link sit within the pentachora of the original triangulation. If p is the isomorphism returned, then p.pentImage(i)
will indicate which pentachoron pent of the 4-manifold triangulation contains the ith tetrahedron of the link. Moreover, p.facetPerm(i)
will indicate exactly where the ith tetrahedron sits within pent: it will send 4 to the vertex of pent that the tetrahedron links, and it will send 0,1,2,3 to the vertices of pent that are parallel to vertices 0,1,2,3 of this tetrahedron.
Strictly speaking, this is an abuse of the Isomorphism<4> class (the domain is a triangulation of the wrong dimension, and the map is not 1-to-1 into the range pentachora). We use it anyway, but you should not attempt to call any high-level routines (such as Isomorphism<4>::apply).
This is the same isomorphism that was accessible through the old buildLinkDetail() function in Regina 6.0.1 and earlier.
|
inlineinherited |
Returns the component of the triangulation to which this face belongs.
|
staticconstexprinherited |
Tests whether the given subdim-face of a dim-dimensional simplex contains the given vertex of the simplex.
face | a subdim-face number in a dim-simplex; this must be between 0 and (dim+1 choose subdim+1)-1 inclusive. |
vertex | a vertex number in a dim-simplex; this must be between 0 and dim inclusive. |
true
if and only if the given subdim-face contains the given vertex.
|
inlineinherited |
Returns the degree of this face.
This is the number of different ways in which the face appears within the various top-dimensional simplices of the underlying triangulation.
Note that if this face appears multiple times within the same top-dimensional simplex, then it will be counted multiple times by this routine.
|
inherited |
Returns a detailed text representation of this object.
This text may span many lines, and should provide the user with all the information they could want. It should be human-readable, should not contain extremely long lines (which cause problems for users reading the output in a terminal), and should end with a final newline. There are no restrictions on the underlying character set.
|
inlineinherited |
|
inlineinherited |
A dimension-specific alias for faceMapping<1>().
This alias is available for all facial dimensions subdim.
See faceMapping() for further information.
|
inlineinherited |
Returns one of the ways in which this face appears within a top-dimensional simplex of the underlying triangluation.
For convenience, you can also use begin() and end() to iterate through all such appearances, or equivalently you can iterate over the lightweight object returned by embeddings().
In most cases, the ordering of appearances is arbitrary. The exception is for codimension 2, where these appearances are ordered in a way that follows the link around the face (which in codimension 2 is always a path or a cycle).
index | the index of the requested appearance. This must be between 0 and degree()-1 inclusive. |
|
inlineinherited |
Returns an object that allows iteration through and random access to all of the ways in which this face appears within a top-dimensional simplex of the underlying triangluation.
The object that is returned is lightweight, and can be happily copied by value. The C++ type of the object is subject to change, so C++ users should use auto
(just like this declaration does).
The returned object is guaranteed to be an instance of ListView, which means it offers basic container-like functions and supports C++11 range-based for
loops. The elements of the list will be read-only objects of type FaceEmbedding<dim, subdim>. For example, your code might look like:
In most cases, the ordering of appearances is arbitrary. The exception is for codimension 2, where these appearances are ordered in a way that follows the link around the face (which in codimension 2 is always a path or a cycle).
Using embeddings() is equivalent to iterating over the face itself. It generates a tiny amount of extra overhead, but also may be considered more readable. In particular, the code above is equivalent to both of the following alternatives:
|
inlineinherited |
An end function for iterating through all appearances of this face within the various top-dimensional simplices of the underlying triangulation.
See begin() for full details on how this iteration works, and what other alternatives are available.
The type that is returned will be a lightweight iterator type, guaranteed to satisfy the C++ LegacyRandomAccessIterator requirement. The precise C++ type of the iterator is subject to change, so C++ users should use auto
(just like this declaration does).
|
inlineinherited |
Returns the lowerdim-face of the underlying triangulation that appears as the given lowerdim-dimensional subface of this face.
The argument face must represent a lowerdim-face number within a subdim-simplex. This lowerdim-face number will be interpreted with respect to the inherent labelling (0, ..., subdim) of the vertices of this subdim-face. See FaceEmbedding<dim, subdim>::vertices() for details on how these map to the vertex numbers of the dim-dimensional simplices that contain this face in the overall triangulation.
See FaceNumbering<subdim, lowerdim> for the conventions of how lowerdim-faces are numbered within a subdim-simplex.
face(lowerdim, face)
; that is, the template parameter lowerdim becomes the first argument of the function.face | the lowerdim-face of this subdim-face to examine. This should be between 0 and (subdim+1 choose lowerdim+1)-1 inclusive. |
|
inherited |
Examines the given lowerdim-dimensional subface of this face, and returns the mapping between the underlying lowerdim-face of the triangulation and the individual vertices of this face.
The argument face must represent a lowerdim-face number within a subdim-simplex. This lowerdim-face number will be interpreted with respect to the inherent labelling (0, ..., subdim) of the vertices of this subdim-face. See FaceEmbedding<dim, subdim>::vertices() for details on how these map to the vertex numbers of the dim-dimensional simplices that contain this face in the overall triangulation.
Let F denote this subdim-face of the triangulation, and let L denote the lowerdim-face of the triangulation that corresponds to the given subface of F. Then the permutation returned by this routine maps the vertex numbers (0, ..., lowerdim) of L to the corresponding vertex numbers of F. This is with respect to the inherent labellings (0, ..., lowerdim) and (0, ..., subdim) of the vertices of L and F respectively.
In particular, if this routine returns the permutation p, then the images p[0,...,lowerdim] will be some permutation of the vertices Face<subdim, lowerdim>::ordering(face)[0,...,lowerdim].
This routine differs from Simplex<dim>::faceMapping<lowerdim>() in how it handles the images of (lowerdim+1, ..., dim):
See FaceNumbering<subdim, lowerdim> for the conventions of how lowerdim-faces are numbered within a subdim-simplex.
faceMapping(lowerdim, face)
; that is, the template parameter lowerdim becomes the first argument of the function.face | the lowerdim-face of this subdim-face to examine. This should be between 0 and (subdim+1 choose lowerdim+1)-1 inclusive. |
|
staticconstexprinherited |
Identifies which subdim-face in a dim-dimensional simplex is represented by the first (subdim + 1) elements of the given permutation.
In other words, this routine identifies which subdim-face number within a dim-dimensional simplex spans vertices vertices[0, ..., subdim]
.
vertices | a permutation whose first (subdim + 1) elements represent some vertex numbers in a dim-simplex. |
|
inlineinherited |
Returns the first appearance of this face within a top-dimensional simplex of the underlying triangluation.
This is equivalent to calling *begin()
, or embedding(0)
.
In most cases, the ordering of appearances is arbitrary. The exception is for codimension 2, where the appearances of a face are ordered in a way that follows the link around the face (which in codimension 2 is always a path or a cycle). In particular, for a boundary face of codimension 2, both front() and back() will refer to the two appearances of this face on the (dim-1)-dimensional boundary.
|
inlineinherited |
Determines if this face is identified with itself under a non-identity permutation.
For example, if this face is an edge then this routine tests whether the edge is identified with itself in reverse.
Such a face will always be marked as invalid. Note that, for standard dimensions dim, there are other types of invalid faces also. See isValid() for a full discussion of what it means for a face to be valid.
true
if and only if this face is identified with itself under a non-identity permutation.
|
inlineinherited |
Determines if this face does not have an appropriate link.
See condition (2) in the documentation for isValid() for a full description of what "appropriate" means.
A face whose link is not appropriate will always be marked as invalid. Note that there are other types of invalid faces also. See isValid() for a full discussion of what it means for a face to be valid.
true
if the link of this face is not appropriate (thereby making the face invalid), or false
if the link is appropriate.
|
inlineinherited |
Returns the index of this face within the underlying triangulation.
|
inlineinherited |
Determines whether a codimension-1-face represents a dual edge in the maximal forest that has been chosen for the dual 1-skeleton of the triangulation.
This routine is only available for faces of codimension 1; that is, (dim-1)-faces of a dim-dimensional triangulation.
When the skeletal structure of a triangulation is first computed, a maximal forest in the dual 1-skeleton of the triangulation is also constructed. Each dual edge in this maximal forest represents a (dim-1)-face of the (primal) triangulation.
This maximal forest will remain fixed until the triangulation changes, at which point it will be recomputed (as will all other skeletal objects, such as connected components and so on). There is no guarantee that, when it is recomputed, the maximal forest will use the same dual edges as before.
This routine identifies whether this (dim-1)-face belongs to the dual forest. In this sense it performs a similar role to Simplex::facetInMaximalForest(), but this routine is typically easier to use.
If the skeleton has already been computed, then this routine is very fast (since it just returns a precomputed answer).
true
if and only if this (dim-1)-face represents a dual edge in the maximal forest.
|
inlineinherited |
Determines if this face lies entirely on the boundary of the triangulation.
For dimensions in which ideal and/or invalid vertices are both possible and recognised: both ideal and invalid vertices are considered to be on the boundary.
true
if and only if this face lies on the boundary.
|
inline |
Determines if this vertex is an ideal vertex.
To be an ideal, a vertex must (i) be valid, and (ii) have a closed vertex link that is not a 3-sphere.
true
if and only if this is an ideal vertex.
|
inlineinherited |
Determines if the link of this face is orientable.
This routine is fast: it uses pre-computed information, and does not need to build a full triangulation of the link.
true
if and only if the link is orientable.
|
inlineinherited |
Determines if this face is valid.
There are several conditions that might make a subdim-face of a dim-dimensional triangulation invalid:
Condition (1) is tested for all dimensions subdim and dim. Condition (2) is more difficult, since it relies on undecidable problems. As a result, (2) is only tested when dim is one of Regina's standard dimensions.
If this face is invalid, then it is possible to find out why. In non-standard dimensions, this must mean that the face fails condition (1) above. In standard dimensions, you can call the functions hasBadIdentification() and/or hasBadLink() to determine whether the failure is due to conditions (1) or (2) respectively.
true
if and only if this face is valid according to both conditions (1) and (2) above; for non-standard dimensions dim, returns true
if and only if this face is valid according to condition (1).
|
inlineinherited |
Returns the index at which this object is stored in an MarkedVector.
If this object does not belong to an MarkedVector, the return value is undefined.
|
staticconstexprinherited |
Given a subdim-face number within a dim-dimensional simplex, returns the corresponding canonical ordering of the simplex vertices.
If this canonical ordering is c, then c[0,...,subdim] will be the vertices of the given face in increasing numerical order. That is, c[0] < ... < c[subdim]. The remaining images c[(subdim + 1),...,dim] will be ordered arbitrarily.
Note that this is not the same permutation as returned by Simplex<dim>::faceMapping<subdim>():
face | identifies which subdim-face of a dim-dimensional simplex to query. This must be between 0 and (dim+1 choose subdim+1)-1 inclusive. |
|
inlineinherited |
|
inlineinherited |
A dimension-specific alias for faceMapping<4>().
This alias is available for facial dimensions subdim ≥ 5.
See faceMapping() for further information.
|
inherited |
Returns a short text representation of this object.
This text should be human-readable, should use plain ASCII characters where possible, and should not contain any newlines.
Within these limits, this short text ouptut should be as information-rich as possible, since in most cases this forms the basis for the Python str()
and repr()
functions.
str()
will use precisely this function, and for most classes the Python repr()
function will incorporate this into its output.
|
inlineinherited |
|
inlineinherited |
A dimension-specific alias for faceMapping<3>().
This alias is available for facial dimensions subdim ≥ 4.
See faceMapping() for further information.
|
inlineinherited |
|
inlineinherited |
A dimension-specific alias for faceMapping<2>().
This alias is available for facial dimensions subdim ≥ 3.
See faceMapping() for further information.
|
inlineinherited |
Returns the triangulation to which this face belongs.
|
inherited |
Returns a short text representation of this object using unicode characters.
Like str(), this text should be human-readable, should not contain any newlines, and (within these constraints) should be as information-rich as is reasonable.
Unlike str(), this function may use unicode characters to make the output more pleasant to read. The string that is returned will be encoded in UTF-8.
|
inlineinherited |
|
inlineinherited |
A dimension-specific alias for faceMapping<0>().
This alias is available for all facial dimensions subdim.
See faceMapping() for further information.
|
inlineinherited |
A default implementation for detailed output.
This routine simply calls T::writeTextShort() and appends a final newline.
out | the output stream to which to write. |
|
inherited |
Writes a short text representation of this object to the given output stream.
The class Face<dim, subdim> may safely override this function, since the output routines cast down to Face<dim, subdim> before calling it.
out | the output stream to which to write. |
|
staticconstexprinherited |
Indicates whether it is possible for a face of this dimension to be invalid.
|
staticconstexprinherited |
Indicates whether it is possible for a face of this dimension to have a non-orientable link.
|
staticconstexprinherited |
A compile-time constant that gives the dimension of the triangulation containing this face.
|
staticconstexprprotectedinherited |
Whichever of subdim or oppositeDim uses lexicographical face numbering.
|
staticconstexprinherited |
true
if faces are numbered in lexicographical order according to their vertices, or false
if faces are numbered in reverse lexicographical order.
|
staticconstexprinherited |
The total number of subdim-dimensional faces in each dim-dimensional simplex.
|
staticconstexprinherited |
The dimension of the faces opposite these in a top-dimensional simplex of a dim-dimensional triangulation.
|
staticconstexprinherited |
A compile-time constant that gives the dimension of this face.