next | previous | forward | backward | up | top | index | toc | Macaulay2 web site
Polyhedra :: cellDecompose

cellDecompose -- computes the regular cell decomposition

Synopsis

Description

This function computes the regular cell decomposition of P given by the weight vector w. This is computed by placing the i-th lattice point of P on height w_i in n+1 space, taking the convexHull of these with the ray (0,...,0,1), and projecting the compact faces into n space. Note that the polyhedron must be compact, i.e. a polytope and the length of the weight vector must be the number of lattice points.

i1 : P = crossPolytope 3

o1 = P

o1 : Polyhedron
i2 : w =  matrix {{1,2,2,2,2,2,1}}

o2 = | 1 2 2 2 2 2 1 |

              1        7
o2 : Matrix ZZ  <--- ZZ
i3 : L = cellDecompose(P,w)

o3 = {Polyhedron{...1...}, Polyhedron{...1...}, Polyhedron{...1...},
     ------------------------------------------------------------------------
     Polyhedron{...1...}, Polyhedron{...1...}, Polyhedron{...1...},
     ------------------------------------------------------------------------
     Polyhedron{...1...}, Polyhedron{...1...}}

o3 : List
i4 : apply(L,vertices)

o4 = {| 0 -1 0  0  |, | 0 1 0  0  |, | 0 -1 0 0  |, | 0 1 0 0  |, | 0 -1 0  0
      | 0 0  -1 0  |  | 0 0 -1 0  |  | 0 0  1 0  |  | 0 0 1 0  |  | 0 0  -1 0
      | 0 0  0  -1 |  | 0 0 0  -1 |  | 0 0  0 -1 |  | 0 0 0 -1 |  | 0 0  0  1
     ------------------------------------------------------------------------
     |, | 0 1 0  0 |, | 0 -1 0 0 |, | 0 1 0 0 |}
     |  | 0 0 -1 0 |  | 0 0  1 0 |  | 0 0 1 0 |
     |  | 0 0 0  1 |  | 0 0  0 1 |  | 0 0 0 1 |

o4 : List

Ways to use cellDecompose :