Macaulay2 » Documentation
Packages » Polyhedra :: polyhedralComplex(Matrix,Matrix,Matrix,List)
next | previous | forward | backward | up | index | toc

polyhedralComplex(Matrix,Matrix,Matrix,List) -- Constructing a polyhedral complex.

Synopsis

Description

Basic constructor for polyhedral complices that takes a matrix containing the vertices of the polyhedral complex and a list of lists with the indices of the vertices and rays in the maximal cells. Both the rays and the lineality space are optional arguments. If two matrices are provided, then the second matrix is considered to contain rays. To input a lineality space, one must provide three matrices.

This constructor does not check well-definedness, see isWellDefined.

i1 : M = matrix {{0,1,2}}

o1 = | 0 1 2 |

              1       3
o1 : Matrix ZZ  <-- ZZ
i2 : L = {{0,1},{1,2}}

o2 = {{0, 1}, {1, 2}}

o2 : List
i3 : PC = polyhedralComplex(M,L)

o3 = PC

o3 : PolyhedralComplex
i4 : C = hypercube 2

o4 = C

o4 : Polyhedron
i5 : F = faces(1,C)

o5 = {({0, 2}, {}), ({1, 3}, {}), ({0, 1}, {}), ({2, 3}, {})}

o5 : List
i6 : V = vertices C

o6 = | -1 1  -1 1 |
     | -1 -1 1  1 |

              2       4
o6 : Matrix QQ  <-- QQ
i7 : L = linealitySpace C

o7 = 0

              2
o7 : Matrix QQ  <-- 0
i8 : PC = polyhedralComplex(V,L,F)

o8 = PC

o8 : PolyhedralComplex
i9 : vertices PC

o9 = | -1 1  -1 1 |
     | -1 -1 1  1 |

              2       4
o9 : Matrix QQ  <-- QQ
i10 : maxPolyhedra PC

o10 = {({0, 2}, {}), ({1, 3}, {}), ({0, 1}, {}), ({2, 3}, {})}

o10 : List
i11 : dim PC

o11 = 1

Ways to use this method: