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

ehrhart -- calculates the Ehrhart polynomial of a polytope

Synopsis

Description

ehrhart can only be applied to polytopes, i.e. compact polyhedra. To calculate the Ehrhart polynomial, the number of lattice points in the first n dilations of the polytope are calculated, where n is the dimension of the polytope. A system of linear equations is then solved to find the polynomial.

P = convexHull transpose matrix {{0,0,0},{1,0,0},{0,1,0},{1,1,3}}
ehrhart P

Ways to use ehrhart :