#include <nfacepairing.h>
Inheritance diagram for regina::NFacePairing:
Public Member Functions | |
NFacePairing (const NFacePairing &cloneMe) | |
Creates a new face pairing that is a clone of the given face pairing. | |
virtual | ~NFacePairing () |
Deallocates any memory used by this structure. | |
unsigned | getNumberOfTetrahedra () const |
Returns the number of tetrahedra whose faces are (potentially) paired in this particular matching. | |
const NTetFace & | dest (const NTetFace &source) const |
Returns the other face to which the given tetrahedron face is paired. | |
const NTetFace & | dest (unsigned tet, unsigned face) const |
Returns the other face to which the given tetrahedron face is paired. | |
const NTetFace & | operator[] (const NTetFace &source) const |
Returns the other face to which the given tetrahedron face is paired. | |
bool | isUnmatched (const NTetFace &source) const |
Determines whether the given tetrahedron face has been left deliberately unmatched. | |
bool | isUnmatched (unsigned tet, unsigned face) const |
Determines whether the given tetrahedron face has been left deliberately unmatched. | |
bool | isCanonical () const |
Determines whether this face pairing is in canonical form, i.e. | |
void | findAutomorphisms (NFacePairingIsoList &list) const |
Fills the given list with the set of all combinatorial automorphisms of this face pairing. | |
std::string | toString () const |
Returns a human-readable representation of this face pairing. | |
std::string | toTextRep () const |
Returns a text-based representation of this face pairing that can be used to reconstruct the face pairing. | |
bool | isClosed () const |
Determines whether this face pairing is closed. | |
bool | hasTripleEdge () const |
Determines whether this face pairing contains a triple edge. | |
void | followChain (unsigned &tet, NFacePair &faces) const |
Follows a chain as far as possible from the given point. | |
bool | hasBrokenDoubleEndedChain () const |
Determines whether this face pairing contains a broken double-ended chain. | |
bool | hasOneEndedChainWithDoubleHandle () const |
Determines whether this face pairing contains a one-ended chain with a double handle. | |
void * | run (void *param) |
Internal to findAllPairings(). | |
Static Public Member Functions | |
static NFacePairing * | fromTextRep (const std::string &rep) |
Reconstructs a face pairing from a text-based representation. | |
static bool | findAllPairings (unsigned nTetrahedra, NBoolSet boundary, int nBdryFaces, UseFacePairing use, void *useArgs=0, bool newThread=false) |
Generates all possible face pairings satisfying the given constraints. |
Given a fixed number of tetrahedra, each tetrahedron face is either paired with some other tetrahedron face (which is in turn paired with it) or remains unmatched. A tetrahedron face cannot be paired with itself.
Such a matching models part of the structure of a triangulation, in which each tetrahedron face is either glued to some other tetrahedron face (which is in turn glued to it) or is an unglued boundary face.
Note that if this pairing is used to construct an actual triangulation, the individual gluing permutations will still need to be specified; they are not a part of this structure.
|
Creates a new face pairing that is a clone of the given face pairing.
|
|
Deallocates any memory used by this structure.
|
|
Returns the other face to which the given tetrahedron face is paired. If the given face is left deliberately unmatched, the value returned will be boundary (as returned by NTetFace::isBoundary()).
|
|
Returns the other face to which the given tetrahedron face is paired. If the given face is left deliberately unmatched, the value returned will be boundary (as returned by NTetFace::isBoundary()).
|
|
Generates all possible face pairings satisfying the given constraints. Only connected face pairings (pairings in which each tetrahedron can be reached from each other via a series of individual matched faces) will be produced. Each face pairing will be produced precisely once up to isomorphism. Face pairings are considered isomorphic if they are related by a relabelling of the tetrahedra and/or a renumbering of the four faces of each tetrahedron. Each face pairing that is generated will be a minimal representative of its isomorphism class, i.e., will be in canonical form as described by isCanonical(). For each face pairing that is generated, routine use (as passed to this function) will be called with that pairing and its automorphisms as arguments.
Once the generation of face pairings has finished, routine use will be called once more, this time with The face pairing generation may be run in the current thread or as a separate thread.
|
|
Fills the given list with the set of all combinatorial automorphisms of this face pairing. An automorphism is a relabelling of the tetrahedra and/or a renumbering of the four faces of each tetrahedron resulting in precisely the same face pairing. This routine uses optimisations that can cause unpredictable breakages if this face pairing is not in canonical form. The automorphisms placed in the given list will be newly created; it is the responsibility of the caller of this routine to deallocate them.
|
|
Follows a chain as far as possible from the given point. A chain is the underlying face pairing for a layered chain; specifically it involves one tetrahedron joined to a second along two faces, the remaining two faces of the second tetrahedron joined to a third and so on. A chain can involve as few as one tetrahedron or as many as we like. Note that the remaining two faces of the first tetrahedron and the remaining two faces of the final tetrahedron remain unaccounted for by this structure. This routine begins with two faces of a given tetrahedron, described by parameters tet and face. If these two faces are both joined to some different tetrahedron, parameter tet will be changed to this new tetrahedron and parameter faces will be changed to the remaining faces of this new tetrahedron (i.e., the two faces that were not joined to the original faces of the original tetrahedron). This procedure is repeated as far as possible until either the two faces in question join to two different tetrahedra, the two faces join to each other, or at least one of the two faces is unmatched. Thus, given one end of a chain, this procedure can be used to follow the face pairings through to the other end of the chain.
|
|
Reconstructs a face pairing from a text-based representation. This text-based representation must be in the format produced by routine toTextRep(). The face pairing returned will be newly constructed; it is the responsibility of the caller of this routine to deallocate it.
|
|
Returns the number of tetrahedra whose faces are (potentially) paired in this particular matching.
|
|
Determines whether this face pairing contains a broken double-ended chain. A chain involves a sequence of tetrahedra, each joined to the next along two faces, and is described in detail in the documentation for followChain(). A one-ended chain is a chain in which the first tetrahedron is also joined to itself along one face (i.e., the underlying face pairing for a layered solid torus). A double-ended chain is a chain in which the first tetrahedron is joined to itself along one face and the final tetrahedron is also joined to itself along one face (i.e., the underlying face pairing for a layered lens space). A broken double-ended chain consists of two one-ended chains (using distinct sets of tetrahedra) joined together along one face. The remaining two faces (one from each chain) that were unaccounted for by the individual one-ended chains remain unaccounted for by this broken double-ended chain. In this routine we are interested specifically in finding a broken double-ended chain that is not a part of a complete double-ended chain, i.e., the final two unaccounted faces are not joined together.
|
|
Determines whether this face pairing contains a one-ended chain with a double handle. A chain involves a sequence of tetrahedra, each joined to the next along two faces, and is described in detail in the documentation for followChain(). A one-ended chain is a chain in which the first tetrahedron is also joined to itself along one face (i.e., the underlying face pairing for a layered solid torus). A one-ended chain with a double handle begins with a one-ended chain. The two faces that are unaccounted for by this one-ended chain must be joined to two different tetrahedra, and these two tetrahedra must be joined to each other along two faces. The remaining two faces of these two tetrahedra remain unaccounted for by this structure.
|
|
Determines whether this face pairing contains a triple edge. A triple edge is where two different tetrahedra are joined along three of their faces.
|
|
Determines whether this face pairing is in canonical form, i.e. , is a minimal representative of its isomorphism class. Isomorphisms of face pairings correspond to relabellings of tetrahedra and relabellings of the four faces within each tetrahedron.
Face pairings are ordered by lexicographical comparison of
|
|
Determines whether this face pairing is closed. A closed face pairing has no unmatched faces. |
|
Determines whether the given tetrahedron face has been left deliberately unmatched.
|
|
Determines whether the given tetrahedron face has been left deliberately unmatched.
|
|
Returns the other face to which the given tetrahedron face is paired. This is a convenience operator whose behaviour is identical to that of dest(). If the given face is left deliberately unmatched, the value returned will be boundary (as returned by NTetFace::isBoundary()).
|
|
Internal to findAllPairings(). This routine should never be called directly. Performs the actual generation of face pairings, possibly as a separate thread. At most one copy of this routine should be running at any given time for a particular NFacePairing instance.
Implements regina::NThread. |
|
Returns a human-readable representation of this face pairing. The string returned will contain no newlines.
|
|
Returns a text-based representation of this face pairing that can be used to reconstruct the face pairing. This reconstruction is done through routine fromTextRep(). The text produced is not particularly readable; for a human-readable text representation, see routine toString() instead. The string returned will contain no newlines.
|