next | previous | forward | backward | up | top | index | toc | Macaulay2 website
OldPolyhedra :: faceLattice(ZZ,Polyhedron)

faceLattice(ZZ,Polyhedron) -- computes the face lattice of a polyhedron

Synopsis

Description

The face lattice of a polyhedron P displays for eachk the faces of codimension k as two lists of integers, the first indicating the vertices of P and the second indicating the rays of P that generate this face together with the lineality space. If no integer is given the function returns the faces of all codimensions in a list, starting with the 0 dimensional faces

i1 : P = convexHull(matrix{{1,1,-1,-1},{1,-1,1,-1},{1,1,1,1}},matrix {{0},{0},{-1}})

o1 = {ambient dimension => 3           }
      dimension of lineality space => 0
      dimension of polyhedron => 3
      number of facets => 5
      number of rays => 1
      number of vertices => 4

o1 : Polyhedron
i2 : faceLattice(1,P)

o2 = {({0, 2}, {0}), ({1, 3}, {0}), ({0, 1}, {0}), ({2, 3}, {0}), ({0, 1, 2,
     ------------------------------------------------------------------------
     3}, {})}

o2 : List

Returns the faces of codimension one where the first list of integers give the columns in the vertices matrix of the polyhedron and the second list the columns in the rays matrix of the polyhedron:

i3 : V = vertices P

o3 = | -1 1  -1 1 |
     | -1 -1 1  1 |
     | 1  1  1  1 |

              3        4
o3 : Matrix QQ  <--- QQ
i4 : R = rays P

o4 = | 0  |
     | 0  |
     | -1 |

              3        1
o4 : Matrix ZZ  <--- ZZ

The complete face lattice is returned if no integer is given:

i5 : faceLattice P

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

o5 : List