application: topaz

The TOPology Application Zoo deals with abstract simplicial complexes. A complex is given as a list of facets. You can ask for its global properties (manifold recognition, homology groups, etc.), explore the local vertex environment (stars, links, etc.), and make a lot of constructions.

The visualization means are constrained, as they are mostly based on the GRAPH (1-skeleton) of a complex.


imports from: common, graph

Objects

User Functions

  •  
    cap_product ()

    Compute and print all cap products of cohomology and homology cycles. args: SimplicialComplex

  •  
    homology (complex, co)

    Calculate the (co-)homology groups of a simplicial complex.

    Parameters
    Array<Set<int>>complex
    Boolco
    Options
    Intdim_low
    narrows the dimension range of interest, with negative values being treated as co-dimensions
    Intdim_high
    see dim_low
  •  
    homology_and_cycles (complex, co)

    Calculate the (co-)homology groups and cycle representatives of a simplicial complex.

    Parameters
    Array<Set<int>>complex
    Boolco
    Options
    Intdim_low
    narrows the dimension range of interest, with negative values being treated as co-dimensions
    Intdim_high
    see dim_low
  •  
    is_vertex_decomposition ()

    Check whether a given ordered subset of the vertex set is a vertex decomposition. Works for 1-, 2- and 3-manifolds only!

  •  
    mixed_graph ()

    Produces the mixed graph of a simplicial @a complex. args: complex [ edge_weight => VALUE ]

  •  
    •  
      find_facet_vertex_permutations (complex1, complex2) → Pair<Array<Int>, Array<int>>

      Find the permutations of facets and vertices which maps the first complex to the second one. The facet permutation is the first component of the return value. If the complexes are not isomorphic, an exception is thrown.

    •  
      isomorphic (complex1, complex2) → Bool

      Determine whether two given complexes are combinatorially isomorphic. The problem is reduced to graph isomorphism of the vertex-facet incidence graphs.

      Parameters
      SimplicialComplexcomplex1
      SimplicialComplexcomplex2
      Returns
      Bool
    •  
      pl_homeomorphic (complex1, complex2) → Bool

      Tries to determine wheter two complexes are pl-homeomorphic by using bistellar flips and a simulated annealing strategy.

      You may specify the maximal number of rounds, how often the system may relax before heating up and how much heat should be applied. The function stops computing, once the size of the triangulation has not decreased for rounds iterations. If the abs flag is set, the function stops after rounds iterations regardless of when the last improvement took place. Additionally, you may set the threshold min_n_facets for the number of facets when the simplification ought to stop. Default is d+2 in the CLOSED_PSEUDO_MANIFOLD case and 1 otherwise.

      If you want to influence the distribution of the dimension of the moves when warming up you may do so by specifying a distribution. The number of values in distribution determines the dimensions used for heating up. The heating and relaxing parameters decrease dynamically unless the constant flag is set. The function prohibits to execute the reversed move of a move directly after the move itself unless the allow_rev_move flag is set. Setting the allow_rev_move flag might help solve a particular resilient problem.

      If you are interested in how the process is coming along, try the verbose option. It specifies after how many rounds the current best result is displayed.

      The obj determines the objective function used for the optimization. If obj is set to 0, the function searches for the triangulation with the lexicographically smallest f-vector, if obj is set to 1, the function searches for the triangulation with the reversed-lexicographically smallest f-vector and if obj is set to 2 the sum of the f-vector entries is used. The default is 1.

      Parameters
      SimplicialComplexcomplex1
      SimplicialComplexcomplex2
      Options
      Introunds
      Boolabs
      Intobj
      Intrelax
      Intheat
      Boolconstant
      Boolallow_rev_move
      Intmin_n_facets
      Intverbose
      Intseed
      Boolquiet
      Array<Int>distribution
      Returns
      Bool
  •  
    •  
      alexander_dual (complex) → SimplicialComplex

      Computes the Alexander dual complex, that is, the complements of all non-faces. The vertex labels are preserved unless the nol flag is specified.

      Parameters
      SimplicialComplexcomplex
      Options
      Boolnol
      Returns
      SimplicialComplex
    •  
      balanced_prism (complex) → SimplicialComplex

      Produce a prism over a given SimplicialComplex.

      Parameters
      SimplicialComplexcomplex
      Options
      Boolgeom_real
      Returns
      SimplicialComplex
    •  
      barycentric_subdivision (complex)

      Create a simplicial complex as a barycentric subdivision of a given complex. Each vertex in the new complex corresponds to a face in the old complex.

      Parameters
      SimplicialComplexcomplex
      Options
      Boolrelabel
      generate vertex labels from the faces of the original complex.
      Boolgeom_real
      read GEOMETRIC_REALIZATION of the input complex, compute the coordinates of the new vertices and store them as GEOMETRIC_REALIZATION of the produced complex.
    •  
      bistellar_simplification (complex) → SimplicialComplex

      Heuristic for simplifying the triangulation of the given manifold without changing its PL-type. The function uses bistellar flips and a simulated annealing strategy.

      You may specify the maximal number of rounds, how often the system may relax before heating up and how much heat should be applied. The function stops computing, once the size of the triangulation has not decreased for rounds iterations. If the abs flag is set, the function stops after rounds iterations regardless of when the last improvement took place. Additionally, you may set the threshold min_n_facets for the number of facets when the simplification ought to stop. Default is d+2 in the CLOSED_PSEUDO_MANIFOLD case and 1 otherwise.

      If you want to influence the distribution of the dimension of the moves when warming up you may do so by specifying a distribution. The number of values in distribution determines the dimensions used for heating up. The heating and relaxing parameters decrease dynamically unless the constant flag is set. The function prohibits to execute the reversed move of a move directly after the move itself unless the allow_rev_move flag is set. Setting the allow_rev_move flag might help solve a particular resilient problem.

      If you are interested in how the process is coming along, try the verbose option. It specifies after how many rounds the current best result is displayed.

      The obj determines the objective function used for the optimization. If obj is set to 0, the function searches for the triangulation with the lexicographically smallest f-vector, if obj is set to any other value the sum of the f-vector entries is used. The default is 1.

      Parameters
      SimplicialComplexcomplex
      Options
      Introunds
      Boolabs
      Intobj
      Intrelax
      Intheat
      Boolconstant
      Boolallow_rev_move
      Intmin_n_facets
      Intverbose
      Intseed
      Boolquiet
      Array<Int>distribution
      Returns
      SimplicialComplex
    •  
      cone (complex, k) → SimplicialComplex

      Produce the k-cone over a given simplicial complex.

      Parameters
      SimplicialComplexcomplex
      intk
      default is 1
      Options
      Array<String>apex_labels
      labels of the apex vertices. Default labels have the form apex_0, apex_1, .... In the case the input complex has already vertex labels of this kind, the duplicates are avoided.
      Boolnol
      don't generate any vertex labels.
      Returns
      SimplicialComplex
    •  
      connected_sum (complex1, complex2, f_1, f_2)

      Compute the connected sum of two complexes.

      Parameters f_1 and f_2// specify which facet of the first and second complex correspondingly are glued together. Default is the 0-th facet of both.

      The vertices in the selected facets are identified with each other according to their order in the facet (that is, in icreasing index order). The option permutation allows to get an alternative identification. It should specify a permutation of the vertices of the second facet.

      The vertices of the new complex get the original labels with _1 or _2 appended, according to the input complex they came from. If you set the no_labels flag, the label generation will be omitted.

      Parameters
      SimplicialComplexcomplex1
      SimplicialComplexcomplex2
      intf_1
      default is 0
      intf_2
      default is 0
      Options
      Array<int>permutation
      Boolno_lables
    •  
      deletion (complex, face) → SimplicialComplex

      Remove the given face and all the faces containing it.

      Parameters
      SimplicialComplexcomplex
      Set<Int>face
      specified by vertex indices. Please use labeled_vertices if you want to specify the face by vertex labels.
      Options
      Boolno_labels
      do not write vertex labels.
      Returns
      SimplicialComplex
    •  
      disjoint_union (complex1, complex2)

      Produce the disjoint union of the two given complexes.

      Parameters
      SimplicialComplexcomplex1
      SimplicialComplexcomplex2
      Options
      labelscreates
      VERTEX_LABELS. The vertex labels are built from the original labels with a suffix _1 or _2 appended.
    •  
      edge_contraction (complex) → SimplicialComplex

      Heuristic for simplifying the triangulation of the given manifold without changing its PL-type. Choosing a random order of the vertices, the function tries to contract all incident edges.

      Parameters
      SimplicialComplexcomplex
      Options
      Intseed
      Returns
      SimplicialComplex
    •  
      h_induced_quotient (C, vertices) → SimplicialComplex

      Let C be the given simplicial and A the subcomplex induced by the given vertices. Then this function produces a simplicial complex homotopy equivalent to C mod A by adding the cone over A with apex a to C. The label of the apex my be specified via the option apex.

      Parameters
      SimplicialComplexC
      Set<Int>vertices
      Options
      Boolno_labels
      tells the client not to write any labels.
      Stringapex
      Returns
      SimplicialComplex
    •  
      induced_subcomplex (complex, vertices)

      Produce the subcomplex consisting of all faces which are contained in the given set of vertices.

      Parameters
      SimplicialComplexcomplex
      Set<Int>vertices
      Options
      Boolno_label
      tells the client not to create any labels.
      Boolgeom_real
      tells the client to inherit the GEOMETRIC_REALIZATION.
    •  
      join_complexes (complex1, complex2) → SimplicialComplex

      Creates the join of complex1 and complex2.

      Parameters
      SimplicialComplexcomplex1
      SimplicialComplexcomplex2
      Options
      Boollabels
      creates VERTEX_LABELS. The vertex labels are built from the original labels with a suffix _1 or _2 appended.
      Returns
      SimplicialComplex
    •  
      k_skeleton (complex, k) → SimplicialComplex

      Produce the k-skeleton.

      Parameters
      SimplicialComplexcomplex
      intk
      Options
      Boolnol
      suppresses creation of VERTEX_LABELS
      Returns
      SimplicialComplex
    •  
      link_complex (complex, face)

      Produce the link of a face of the complex

      Parameters
      SimplicialComplexcomplex
      Set<int>face
      Options
      Boolno_labels
      tells the client not to create any labels.
    •  
      simplicial_product (complex1, complex2)

      Computes the simplicial product of two complexes. Vertex orderings may be given as options.

      Parameters
      SimplicialComplexcomplex1
      SimplicialComplexcomplex2
      Options
      Array<Int>vertex_order1
      Array<Int>vertex_order2
      Boolgeom_real
      Boolcolor_cons
      Boolno_labels
    •  
      star (complex, face) → SimplicialComplex

      Produce the star of the face of the complex.

      Parameters
      SimplicialComplexcomplex
      Set<int>face
      Options
      Boollabels
      creates VERTEX_LABELS.
      Returns
      SimplicialComplex
    •  
      star_deletion (complex, face) → SimplicialComplex

      Remove the star of a given face.

      Parameters
      SimplicialComplexcomplex
      Set<Int>face
      specified by vertex indices. Please use labeled_vertices if you want to specify the face by vertex labels.
      Options
      Boolno_labels
      do not write vertex labels.
      Returns
      SimplicialComplex
    •  
      stellar_subdivision (complex, faces) → SimplicialComplex

      Computes the complex obtained by stellar subdivision of the given faces of the complex.

      Parameters
      SimplicialComplexcomplex
      Array<Set<int>>faces
      Options
      Boolno_labels
      Boolgeom_real
      Returns
      SimplicialComplex
    •  
      stellar_subdivision (complex, faces) → SimplicialComplex

      Computes the complex obtained by stellar subdivision of the given faces of the complex.

      Parameters
      SimplicialComplexcomplex
      Array<Set<int>>faces
      Options
      Boolno_labels
      Boolgeom_real
      Returns
      SimplicialComplex
    •  
      suspension (complex, k)

      Produce the k-suspension over a given simplicial complex.

      Parameters
      SimplicialComplexcomplex
      Intk
      default value is 1
      Options
      Array<String>labels
      for the apices. By default apices are labeled with apex_0+, apex_0-, apex_1+, etc. If one of the specified labels already exists, a unique one is made by appending _i where i is some small number.
      Boolnol
      do not produce any labels.
    •  
      union (complex1, complex2) → SimplicialComplex

      Produce the union of the two given complexes, identifying vertices with equal labels.

      Parameters
      SimplicialComplexcomplex1
      SimplicialComplexcomplex2
      Options
      Boollabels
      creates VERTEX_LABELS.
      Returns
      SimplicialComplex
  •  
  •  
    •  
      ball (d) → SimplicialComplex

      A d-dimensional ball, realized as the d-simplex.

      Parameters
      intd
      dimension
      Returns
      SimplicialComplex
    •  
      cube_complex ()

      Produces a triangulated pile of hypercubes: Each cube is split into d! tetrahedra, and the tetrahedra are all grouped around one of the diagonal axes of the cube. DOC_FIXME args: x_1, ... , x_d

    •  
      klein_bottle () → SimplicialComplex

      The Klein bottle.

    •  
      projective_plane () → SimplicialComplex

      The projective plane.

    •  
      rand_knot (n_edges) → SimplicialComplex

      Produce a random knot (or link) as a polygonal closed curve in 3-space. The knot (or each connected component of the link) has n_edges edges.

      The vertices are uniformly distributed in [-1,1]3, unless the on_sphere option is set. In the latter case the vertices are uniformly distributed on the 3-sphere. Alternatively the brownian option produces a knot by connecting the ends of a simulated brownian motion.

      Parameters
      Intn_edges
      Options
      Intn_comp
      number of components, default is 1.
      Boolon_sphere
      Boolbrownian
      Intseed
      Returns
      SimplicialComplex
    •  
      simplex (d) → SimplicialComplex

      A simplex of dimension d.

      Parameters
      intd
      dimension
      Returns
      SimplicialComplex
    •  
      sphere (d) → SimplicialComplex

      The d-dimansional sphere, realized as the boundary of the (d+1)-simplex.

      Parameters
      intd
      dimension
      Returns
      SimplicialComplex
    •  
      surface (g) → SimplicialComplex

      Produce a surface of genus g. For g >= 0 the client produces an orientable surface, otherwise it produces a non-orientable one.

      Parameters
      intg
      genus
      Returns
      SimplicialComplex
    •  
      torus () → SimplicialComplex

      The Császár Torus. Geometric realization by Frank Lutz, Electronic Geometry Model No. 2001.02.069

    •  
      unknot (m, n)

      Produces a triangulated 3-sphere with the particular NASTY embedding of the unknot in its 1-skeleton. The parameters m >= 2 and n >= 1 determine how entangled the unknot is. eps determines the GEOMETRIC_REALIZATION.

      Parameters
      intm
      intn
      Options
      Rationaleps

Property Types