# Cluster complex (or generalized dual associahedron)¶

EXAMPLES:

A first example of a cluster complex:

sage: C = ClusterComplex(['A', 2]); C
Cluster complex of type ['A', 2] with 5 vertices and 5 facets


Its vertices, facets, and minimal non-faces:

sage: C.vertices()
(0, 1, 2, 3, 4)

sage: C.facets()
[(0, 1), (0, 4), (1, 2), (2, 3), (3, 4)]

sage: for F in C.facets(): F.cluster()
[(-1, 0), (0, -1)]
[(-1, 0), (0, 1)]
[(0, -1), (1, 0)]
[(1, 0), (1, 1)]
[(1, 1), (0, 1)]

sage: C.minimal_nonfaces()
[[0, 2], [0, 3], [1, 3], [1, 4], [2, 4]]


We can do everything we can do on simplicial complexes, e.g. computing its homology:

sage: C.homology()
{0: 0, 1: Z}


AUTHORS:

• Christian Stump (2011) Initial version

class sage.combinat.cluster_complex.ClusterComplex(W, k, coxeter_element, algorithm)

A cluster complex (or generalized dual associahedron).

The cluster complex (or generalized dual associahedron) is a simplicial complex constructed from a cluster algebra. Its vertices are the cluster variables and its facets are the clusters, i.e., maximal subsets of compatible cluster variables.

The cluster complex of type $$A_n$$ is the simplicial complex with vertices being (proper) diagonals in a convex $$(n+3)$$-gon and with facets being triangulations.

The implementation of the cluster complex depends on its connection to subword complexes, see [CLS2014]. Let $$c$$ be a Coxeter element with reduced word $${\bf c}$$ in a finite Coxeter group $$W$$, and let $${\bf w}_\circ$$ be the $$c$$-sorting word for the longest element $$w_\circ \in W$$.

The multi-cluster complex $$\Delta(W,k)$$ has vertices in one-to-one correspondence with letters in the word $$Q = {\bf c^k w}_\circ$$ and with facets being complements in $$Q$$ of reduced expressions for $$w_\circ$$.

For $$k = 1$$, the multi-cluster complex is isomorphic to the cluster complex as defined above.

EXAMPLES:

A first example of a cluster complex:

sage: C = ClusterComplex(['A', 2]); C
Cluster complex of type ['A', 2] with 5 vertices and 5 facets


Its vertices, facets, and minimal non-faces:

sage: C.vertices()
(0, 1, 2, 3, 4)

sage: C.facets()
[(0, 1), (0, 4), (1, 2), (2, 3), (3, 4)]

sage: C.minimal_nonfaces()
[[0, 2], [0, 3], [1, 3], [1, 4], [2, 4]]


We can do everything we can do on simplicial complexes, e.g. computing its homology:

sage: C.homology()
{0: 0, 1: Z}


We can also create a multi-cluster complex:

sage: ClusterComplex(['A', 2], k=2)
Multi-cluster complex of type ['A', 2] with 7 vertices and 14 facets


REFERENCES:

Element

alias of ClusterComplexFacet

cyclic_rotation()

Return the operation on the facets of self obtained by the cyclic rotation as defined in [CLS2014].

EXAMPLES:

sage: ClusterComplex(['A', 2]).cyclic_rotation()
<function ...act at ...>

k()

Return the index $$k$$ of self.

EXAMPLES:

sage: ClusterComplex(['A', 2]).k()
1

minimal_nonfaces()

Return the minimal non-faces of self.

EXAMPLES:

sage: ClusterComplex(['A', 2]).minimal_nonfaces()
[[0, 2], [0, 3], [1, 3], [1, 4], [2, 4]]

class sage.combinat.cluster_complex.ClusterComplexFacet(parent, positions, facet_test=True)

A cluster (i.e., a facet) of a cluster complex.

cluster()

Return this cluster as a set of almost positive roots.

EXAMPLES:

sage: C = ClusterComplex(['A', 2])
sage: F = C((0, 1))
sage: F.cluster()
[(-1, 0), (0, -1)]

product_of_upper_cluster()

Return the product of the upper cluster in reversed order.

EXAMPLES:

sage: C = ClusterComplex(['A', 2])
sage: for F in C: F.product_of_upper_cluster().reduced_word()
[]


[1, 2]
[1, 2]

upper_cluster()

Return the part of the cluster that contains positive roots

EXAMPLES:

sage: C = ClusterComplex(['A', 2])
sage: F = C((0, 1))
sage: F.upper_cluster()
[]