Regina 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... | |
REGINA_INLINE_REQUIRED const Triangulation< 3 > * | buildLink () const |
Returns a full 3-manifold triangulation describing the link of this vertex. More... | |
Triangulation< 3 > * | buildLinkDetail (bool labels=true, Isomorphism< 4 > **inclusion=0) const |
Returns a full 3-manifold triangulation describing the link of this vertex. More... | |
bool | isIdeal () const |
Determines if this vertex is an ideal vertex. More... | |
void | writeTextShort (std::ostream &out) const |
Writes a short text representation of this object to the given output stream. 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... | |
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... | |
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... | |
void | writeTextLong (std::ostream &out) const |
Writes a detailed text representation of this object to the given output stream. More... | |
size_t | degree () const |
Returns the degree of this face. More... | |
const FaceEmbedding< dim, dim - codim > & | 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... | |
std::vector< FaceEmbedding< dim, dim - codim > >::const_iterator | begin () const |
A begin function for iterating through all appearances of this face within the various top-dimensional simplices of the underlying triangulation. More... | |
std::vector< FaceEmbedding< dim, dim - codim > >::const_iterator | 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, dim - codim > & | front () const |
Returns the first appearance of this face within a top-dimensional simplex of the underlying triangluation. More... | |
const FaceEmbedding< dim, dim - codim > & | 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 | 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... | |
bool | isLinkOrientable () const |
Determines if the link of this face is orientable. More... | |
size_t | markedIndex () const |
Returns the index at which this object is stored in an MarkedVector. 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 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 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 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 | nFaces |
The total number of subdim-dimensional faces in each dim-dimensional simplex. More... | |
Protected Member Functions | |
void | push_back (const FaceEmbedding< dim, dim - codim > &emb) |
Internal routine to help build the skeleton of a triangulation. More... | |
void | markBadIdentification () |
Marks this face as having a non-identity self-identification. More... | |
void | markBadLink () |
Marks this face as having a bad link. More... | |
void | markLinkNonorientable () |
Marks the link of this face as non-orientable. 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.
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.
|
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.
|
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, and does not contain any information on how the tetrahedra in the link correspond to pentachora in the original triangulation (though this is easily deduced; see below). If you want a writable triangulation, or one with this extra information, then call buildLinkDetail() instead.
The triangulation of the vertex link is built as follows. Let i lie between 0 and degree()-1 inclusive, let pent represent 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.
The vertices of each tetrahedron in the vertex link are numbered as follows. Following the discussion above, suppose that 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.
This Vertex<4> object will retain ownership of the triangulation that is returned. If you wish to edit the triangulation, you should make a new clone and edit the clone instead.
Triangulation<3>* regina::Face< 4, 0 >::buildLinkDetail | ( | bool | labels = true , |
Isomorphism< 4 > ** | inclusion = 0 |
||
) | const |
Returns a full 3-manifold triangulation describing the link of this vertex.
This routine is heavyweight (it computes a new triangulation each time). The benefit is that the triangulation is writeable, and optionally contain detailed information on how the tetrahedra in the link correspond to pentachora in the original triangulation. If you do not need this extra information, consider using the faster buildLink() instead.
See the buildLink() documentation for an explanation of exactly how the triangulation will be constructed.
If labels is passed as true
, each tetrahedron of the new vertex link will be given a text description of the form p (v)
, where p
is the index of the pentachoron the tetrahedron is from, and v
is the vertex of that pentachoron that this tetrahedron links.
If inclusion is non-null (i.e., it points to some Isomorphism<4> pointer p), then it will be modified to point to a new Isomorphism<4> that describes in detail how the individual tetrahedra of the link sit within pentachora of the original triangulation. Specifically, after this routine is called, 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.
The triangulation that is returned, as well as the isomorphism if one was requested, will be newly allocated. The caller of this routine is responsible for destroying these objects.
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).
|
inlineinherited |
Returns the component of the triangulation to which this face belongs.
|
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 |
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.
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 |
An end 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.
|
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. |
|
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.
|
inherited |
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.
|
inherited |
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.
This routine is only available where dim is one of Regina's standard dimensions, since testing this condition in arbitrary dimensions is undecidable. For higher dimensions dim, this routine is not present.
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 and only if the link of this face is not appropriate.
|
inlineinherited |
Returns the index of this face within the underlying triangulation.
|
inherited |
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.
|
inherited |
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.
|
inherited |
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).
|
protectedinherited |
Marks this face as having a non-identity self-identification.
|
protectedinherited |
Marks this face as having a bad link.
|
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.
|
protectedinherited |
Marks the link of this face as non-orientable.
|
inlineprotectedinherited |
Internal routine to help build the skeleton of a triangulation.
This routine pushes the given object onto the end of the internal list of appearances of this face within top-dimensional simplices.
emb | the appearance to push onto the end of the internal list. |
|
inherited |
Returns a short text representation of this object.
This text should be human-readable, should fit on a single line, and should not end with a newline. Where possible, it should use plain ASCII characters.
__str__()
.
|
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 fit on a single line, and should not end with a newline. In addition, it may use unicode characters to make the output more pleasant to read. This string will be encoded in UTF-8.
|
inherited |
Writes a detailed 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. |
void regina::Face< 4, 0 >::writeTextShort | ( | std::ostream & | out | ) | const |
Writes a short text representation of this object to the given output stream.
out | the output stream to which to write. |
|
staticinherited |
The total number of subdim-dimensional faces in each dim-dimensional simplex.