Given integers v and n this function returns a random lattice polytope with v vertices in ambient dimension n contained in [-1000,1000]n.
i1 : P=randZPoly(5,3)
o1 = {ambient dimension => 3 }
dimension of lineality space => 0
dimension of polyhedron => 3
number of facets => 6
number of rays => 0
number of vertices => 5
o1 : Polyhedron
|
i2 : vertices P
o2 = | -265 -865 -904 -740 -927 |
| -802 -224 113 585 167 |
| -536 -448 -412 330 334 |
3 5
o2 : Matrix QQ <--- QQ
|
You can also specify an integer e. This has the effect of changing the randomisation procedure so that a random polytope in [-10e,10e]n is returned.
i3 : P=randZPoly(5,3,5)
o3 = {ambient dimension => 3 }
dimension of lineality space => 0
dimension of polyhedron => 3
number of facets => 6
number of rays => 0
number of vertices => 5
o3 : Polyhedron
|
i4 : vertices P
o4 = | 3297 61657 62920 -64604 -92414 |
| -49728 -20276 -40785 45628 14550 |
| -86696 -76074 -66164 -61192 35327 |
3 5
o4 : Matrix QQ <--- QQ
|