Macaulay2 » Documentation
Packages » EdgeIdeals :: cliqueComplex
next | previous | forward | backward | up | index | toc

cliqueComplex -- returns the clique complex of a graph



This function returns the clique complex of a graph $G$. This is the simplicial complex whose faces correspond to the cliques in the graph. That is, $F = \{x_{i_1},...,x_{i_s}\}$ is a face of the clique complex of $G$ if and only if the induced graph on $\{x_{i_1},...,x_{i_s}\}$ is a clique of $G$.

i1 : R = QQ[w,x,y,z];
i2 : e = graph {w*x,w*y,x*y,y*z}  -- clique on {w,x,y} and {y,z}

o2 = Graph{"edges" => {{w, x}, {w, y}, {x, y}, {y, z}}}
           "ring" => R
           "vertices" => {w, x, y, z}

o2 : Graph
i3 : cliqueComplex e  -- max facets {w,x,y} and {y,z}

o3 = simplicialComplex | yz wxy |

o3 : SimplicialComplex
i4 : g = completeGraph R

o4 = Graph{"edges" => {{w, x}, {w, y}, {w, z}, {x, y}, {x, z}, {y, z}}}
           "ring" => R
           "vertices" => {w, x, y, z}

o4 : Graph
i5 : cliqueComplex g

o5 = simplicialComplex | wxyz |

o5 : SimplicialComplex

See also

Ways to use cliqueComplex :

For the programmer

The object cliqueComplex is a method function.